Be part of JetBrains PHPverse 2026 on June 9 – a free online event bringing PHP devs worldwide together.

colinlongworth's avatar

Monitor Horizon on Worker Servers?

I've recently set up a server configuration that includes a Web, Worker, Cache and Database Server. My queue is a Redis queue, and I've confirmed all the servers are networked and communicating. The same code base is on the web and worker server, along with the correct .env

When I access Horizon via the web server, the queues are shown as inactive. When I look at Telescope on the web server, the jobs in the queue are shown as pending.

In Forge, for the worker server, Horizon and Scheduler are enabled.

Therefore it would appear the Horizon and Scheduler are not running. How can I debug this?

0 likes
2 replies
LaryAI's avatar
Level 58

To debug and resolve the issue with Laravel Horizon not showing active queues on your worker server, you can follow these steps:

  1. Check Horizon Status: First, ensure that Horizon is running on your worker server. You can do this by SSHing into your worker server and running the following command:

    php artisan horizon:status
    

    This command will tell you if Horizon is running or not. If it's not running, you can start it with:

    php artisan horizon
    
  2. Verify Supervisor Configuration: If you're using Supervisor to manage Horizon, ensure that your Supervisor configuration is correct. You should have a configuration file for Horizon, typically located at /etc/supervisor/conf.d/horizon.conf. It should look something like this:

    [program:horizon]
    process_name=%(program_name)s
    command=php /path/to/your/project/artisan horizon
    autostart=true
    autorestart=true
    user=youruser
    redirect_stderr=true
    stdout_logfile=/path/to/your/project/storage/logs/horizon.log
    

    After making any changes, reload Supervisor:

    sudo supervisorctl reread
    sudo supervisorctl update
    sudo supervisorctl start horizon
    
  3. Check .env Configuration: Ensure that your .env file on the worker server has the correct queue connection settings. It should be set to use Redis:

    QUEUE_CONNECTION=redis
    
  4. Network and Redis Configuration: Make sure that your Redis server is accessible from the worker server. You can test this by using a Redis client to connect to the Redis server from the worker server. Also, verify that the Redis configuration in your .env file is correct, including the host, port, and password if applicable.

  5. Check Logs: Look at the logs for any errors. You can check the Laravel logs located in storage/logs/laravel.log and the Horizon logs specified in your Supervisor configuration.

  6. Telescope Monitoring: Since you mentioned using Telescope, ensure that Telescope is correctly configured and running. It can provide insights into what jobs are being dispatched and their status.

  7. Firewall and Security Groups: Ensure that there are no firewall rules or security group settings blocking communication between your servers, especially between the worker server and the Redis server.

By following these steps, you should be able to identify and resolve the issue with Horizon not showing active queues on your worker server. If the problem persists, consider checking the Laravel and Horizon documentation for any additional troubleshooting steps.

rvanbaalen's avatar

Have you ever figured this out? I'm running into exactly the same issue. Horizon is executing jobs but the status says its Inactive.

Please or to participate in this conversation.