Postgres perf, path migration, and shutdown race fixes
- Major query performance boost: replaced correlated subqueries with DistinctBy() in BaseItemRepository, added episode deduplication index, and increased default command timeout to 120s. - Fixed LibraryMonitor shutdown race: added disposal checks and exception handling in FileRefresher to prevent ObjectDisposedException. - Added PowerShell and SQL utilities for fixing Linux paths in config files and database; new scripts for WebDir and path migration. - Auto-fix for WebDir in startup.json on load; new helper scripts and docs. - Added automated weekly DB performance monitoring scripts and reporting. - Expanded documentation and README for all fixes, scripts, and migration steps. - Updated SQL scripts for index creation and diagnostics; improved output handling. - Updated db-config defaults and added new diagnostic/report files.
This commit is contained in:
Binary file not shown.
Binary file not shown.
@@ -0,0 +1,50 @@
|
||||
================================================================================
|
||||
JELLYFIN DATABASE WEEKLY PERFORMANCE SUMMARY
|
||||
================================================================================
|
||||
Report Date: 2026-03-05 08:00:21
|
||||
Database: jellyfin_testdata at 192.168.129.248
|
||||
Week Number: 10
|
||||
================================================================================
|
||||
|
||||
REPORTS GENERATED:
|
||||
* diagnostics_2026-03-05_080020.txt : Full diagnostic report
|
||||
* query_analysis_2026-03-05_080020.txt : Slow query analysis
|
||||
* index_usage_2026-03-05_080020.txt : Index usage statistics
|
||||
* table_sizes_2026-03-05_080020.txt : Table size and bloat info
|
||||
* summary_2026-03-05_080020.txt : This summary
|
||||
|
||||
================================================================================
|
||||
QUICK HEALTH CHECK:
|
||||
================================================================================
|
||||
|
||||
To view critical issues check diagnostics file for:
|
||||
* Section 5: TABLES WITH HIGH SEQUENTIAL SCANS
|
||||
* Section 8: UNUSED OR RARELY USED INDEXES
|
||||
* Section 10: SLOWEST QUERIES
|
||||
|
||||
To identify slow queries check query_analysis file for:
|
||||
* Section 2: TOP 20 SLOWEST QUERIES (by max execution time)
|
||||
* Section 5: BASEITEMS TABLE QUERIES ANALYSIS
|
||||
|
||||
================================================================================
|
||||
RECOMMENDED ACTIONS:
|
||||
================================================================================
|
||||
|
||||
* Review slow queries taking longer than 10 seconds
|
||||
* Check if new indexes are being utilized
|
||||
* Look for tables with many sequential scans
|
||||
* Monitor cache hit ratio (should be above 95 percent)
|
||||
* Check for tables with high dead tuples percentage (need VACUUM)
|
||||
|
||||
================================================================================
|
||||
AUTOMATION SETUP:
|
||||
================================================================================
|
||||
|
||||
To schedule this script weekly via Task Scheduler run Setup-Weekly-Monitor.ps1
|
||||
as Administrator. This will create a scheduled task to run every Monday at 6am.
|
||||
|
||||
To disable the scheduled task run Setup-Weekly-Monitor.ps1 with -Uninstall flag.
|
||||
|
||||
================================================================================
|
||||
NEXT REPORT: 03/05/2026 08:00:21.AddDays(7).ToString("yyyy-MM-dd")
|
||||
================================================================================
|
||||
Reference in New Issue
Block a user