Fix database configuration issues