0

I installed my Laravel app on Ubuntu system and already installed pdo_mysql and mysqli and all extension.

Code is working fine when I run the job without Redis driver, but not working fine when using Redis driver.

I am getting below error and it's very strange for me:

could not find driver (SQL: insert into failed_jobs (connection, queue, payload, exception, failed_at) values (redis, default, {"type":"job","timeout":null,"tags":{},"id":"1","data":{"command":"O:26:\"App\Jobs\SapProductSyncJob\":8:{s:9:\"user_data\";a:1:{s:7:\"user_id\";i:3;}s:6:\"\u0000*\u0000job\";N;s:10:\"connection\";N;s:5:\"queue\";N;s:15:\"chainConnection\";N;s:10:\"chainQueue\";N;s:5:\"delay\";N;s:7:\"chained\";a:0:{}}","commandName":"App\Jobs\SapProductSyncJob"},"displayName":"App\Jobs\SapProductSyncJob","timeoutAt":null,"pushedAt":"1584684956.0182","job":"Illuminate\Queue\CallQueuedHandler@call","maxTries":null,"delay":null,"attempts":2}, PDOException: could not find driver in /home/path/vendor/doctrine/dbal/lib/Doctrine/DBAL/Driver/PDOConnection.php:27

2
  • Do you have Redis installed? Do you have predis/predis installed? laravel.com/docs/5.8/redis Commented Mar 20, 2020 at 11:23
  • Yes it's already installed Commented Mar 20, 2020 at 11:30

1 Answer 1

0

You should download, install and run redis-server in your server: Download Redis

Or alternatively you can use database as a storage for your jobs by editing .env file:

QUEUE_CONNECTION=database
Sign up to request clarification or add additional context in comments.

2 Comments

I also tried with "QUEUE_CONNECTION=database" and also installed predis/predis
predis/predis is for your project to use the redis-server in your server, If you are running on windows you should run redis-server.exe file and if you are in linux you should run and set it to run on each boot. try apt-get install redis-server for linux in your terminal and systemctl enable redis-server.service to launch it each time os boots up.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.