Troubleshooting Guide
1. Common Issues
"Tenant Not Found" (404)
- Symptom: User visits
foo.olow.comand sees 404 or generic error. - Cause:
- No property exists with
subdomain = 'foo'. - Nginx is not routing wildcards correctly.
- DNS record
*.olow.comis missing.
- No property exists with
- Fix: Check
propertiestable. Verify Nginxserver_namedirective.
"Method Not Allowed" on Login
- Symptom: POST to
/loginreturns 405. - Cause: Often mixed content (HTTP vs HTTPS). Laravel redirects POST to GET if protocol mismatch.
- Fix: Ensure
APP_URLuseshttps://and Nginx forces HTTPS.
SMS Not Sending
- Symptom: Booking confirmed, no SMS received.
- Check:
- Is the Queue Worker running? (
php artisan queue:work). - Check
sms_logstable. If status isfailed, checkerror_message. - Check Balance on the Gateway.
- Is the Queue Worker running? (
2. Debugging Tools
Laravel Logs
- Location:
storage/logs/laravel.log. - Search for Exception Stack Traces.
Telescope (If Installed)
- Visit
/telescope(Super Admin only). - Inspect "Jobs" and "Exceptions".
Artisan Commands
php artisan tenant:list: View all active properties.php artisan tinker: Interactive shell to query DB.
3. Performance Issues
Slow Dashboard Load
- Cause: Often N+1 queries on
Booking::with('room', 'customer'). - Fix: Run
CheckNPlusOneaudit or inspect Laravel Debugbar.
Database Deadlocks
- Cause: High concurrency on
walletstable. - Fix: Verify
lockForUpdate()is used in Transaction services.
4. Accounting Issues
"No accounting mapping found for key" Error
- Cause:
AccountingMapServicecan't find a mapping for a logical key (e.g.,revenue.room) in the current property. - Fix: Navigate to Finance > Accounting Setup and map all required keys to GL accounts. Ensure the property has been seeded with default mappings.
"Property ID is required for accounting entries" Error
- Cause:
AccountingPostercan't determine the property context. - Fix: Ensure
current_property_idis bound in the container, or passpropertyIdexplicitly.
5. WebSocket Issues
Reverb Connection Failed
- Cause: WebSocket server not running.
- Fix: Run
php artisan reverb:start. In production, use Supervisor to keep it running.
Real-Time Notifications Not Appearing
- Check:
- Is Reverb running? (
php artisan reverb:start) - Are environment variables set? (
REVERB_APP_ID,REVERB_APP_KEY,REVERB_APP_SECRET) - Check browser console for WebSocket connection errors.
- Is Reverb running? (
6. Authentication Issues
Logging Into Wrong Portal
- Cause: The system uses 3 auth guards (
web,customer,admin). Using the wrong login form directs to the wrong guard. - Fix:
- Staff login:
{subdomain}.hotels.test/admin/login - Guest login:
{subdomain}.hotels.test/login - Super Admin:
{subdomain}.hotels.test/platform/login
- Staff login: