1e77b1042b
Problem: Plesk MySQL requires password authentication User report: "ERROR 1045 (28000): Access denied for user 'root'@'localhost'" Result: 0 databases detected on Plesk servers Root Cause: Plesk stores MySQL admin password in /etc/psa/.psa.shadow All MySQL queries were using passwordless 'mysql' command This works on cPanel (uses ~/.my.cnf) but fails on Plesk Solution: build_databases_section() in lib/reference-db.sh 1. Check if running on Plesk and /etc/psa/.psa.shadow exists 2. Read admin password from file 3. Build mysql_cmd variable with credentials 4. Use $mysql_cmd for all database queries Changes (lib/reference-db.sh): Lines 161-166: Added Plesk credential detection Line 168: Use $mysql_cmd for SHOW DATABASES Line 179: Use $mysql_cmd for size calculation Line 184: Use $mysql_cmd for table count Impact: ✅ Database discovery now works on Plesk ✅ Backwards compatible with cPanel/InterWorx/Standalone ✅ No performance impact (password read once) Status: Ready for testing on Plesk server