Not sending emails/invoices

Hello all,
I am using IN 5.3.76-C77 on shared hosting deployed by softaculous.
No matter what, I cannot make the system to send emails and also I cannot get rid of the error saying that Cron jobs not running.

Cron jobs are running on my server and have double checked with the hosting company.

My env file is as follows:

APP_NAME=“Invoice Ninja”



DB_DATABASE="dbname "
DB_USERNAME=“db username”


QUEUE_CONNECTION=database (I have tried with sync without any success)



When I send an email I.e. to a new user I get a pop up saying an email was send but I never receive anything.

No errors are produced, only in the db jobs table I can see some.
Here is one of these errors:


Any suggestions?
Many thanks


@david any thoughts?

I would suggest first putting the QUEUE_CONNECTION to sync and then running /update?secret=secret

This will remove queues and should fire the email job inline.

You could also turn on debug temporarily to see what the problem is, in the .env set APP_DEBUG=true

and then run /update?secret=secret

Good morning and thank you for your help.

App debug is already true but not producing any errors. The system logs are empty as well.

When I change the queue connection to sync, the system is slower, i still get the message ‘An email has been sent to confirm the email address’ but i don’t receive anything. When i do a health check i get a warning Queue not enabled.

Re smtp and email settings, i use MS365, i have set it to allow all apps and an App password has been setup for IN.

The cron job i have setup is running every minute cd /home/user/ && /usr/bin/php -d register_argc_argv=On artisan schedule:run >> /dev/null 2>&1

I have about 80 logs in the database jobs. Do you want me to share them with you somehow?

I am in the same situation, no emails are sent despite that I use InvoiceNinja to remind my clients to pay for invoices 60, 30, 15, 7, 3 days before payment. I upgrade regularly, now using v5.3.78-L77. This started to happens since january I guess. I cannot tell you exactly when, because there is no log about sending emails.
Yesterday I deleted ’laravel.log’. Today, I used the send email to remind a client for an invoice.
I saw the notification that an email has been send, but the log file is still empty. And looking in the hisorique and activity sections are both empty. I confirm that APP_DEBUG=“true”.

Any help would be greatly appreciated.
Best regards.

I did some online research and it seems that Microsoft is deprecating basic and legacy authentication. I created a new no-reply email account on my cpanel and used that to send emails with Invoice Ninja and now it works. Not sure why it is not working with the MS account or why it is not producing any errors.
I am using the very same account for other apps and they do work.

The cron job error at the bottom left hand side is still there though. Any thoughts how i can fix this?

It may help to log the output of the cron to ensure it’s working correctly or try running it from the command line.

So I ran the cron from the command line and this time, all the emails went by.
I’m on a shared hosting and I tried to configure the cron with these 2 different methods.

* * * * * cd /path-to-your-project && php artisan schedule:run >> path-to-your-project/storage/logs/laravel.log 2>&1
* * * * * php /path-to-your-project/artisan schedule:run >> path-to-your-project/storage/logs/laravel.log 2>&1

So this is the output for both:

Laravel Framework 8.83.6

command [options] [arguments]

-h, --help            Display help for the given command. When no command is given display help for the list command
-q, --quiet           Do not output any message
-V, --version         Display this application version
    --ansi|--no-ansi  Force (or disable --no-ansi) ANSI output
-n, --no-interaction  Do not ask any interactive question
    --env[=ENV]       The environment the command should run under
-v|vv|vvv, --verbose  Increase the verbosity of messages: 1 for normal output, 2 for more verbose output and 3 for debug

Available commands:
clear-compiled               Remove the compiled class file
completion                   Dump the shell completion script
db                           Start a new database CLI session
down                         Put the application into maintenance / demo mode
env                          Display the current framework environment
help                         Display help for a command
inspire                      Display an inspiring quote
list                         List commands
migrate                      Run the database migrations
optimize                     Cache the framework bootstrap files
serve                        Serve the application on the PHP development server
test                         Run the application tests
tinker                       Interact with your application
up                           Bring the application out of maintenance mode
auth:clear-resets            Flush expired password reset tokens
cache:clear                  Flush the application cache
cache:forget                 Remove an item from the cache
cache:table                  Create a migration for the cache database table
config:cache                 Create a cache file for faster configuration loading
config:clear                 Remove the configuration cache file
countries:migration          Creates a migration following the Laravel-countries specifications.
db:seed                      Seed the database with records
db:wipe                      Drop all tables, views, and types
debugbar:clear               Clear the Debugbar Storage
event:cache                  Discover and cache the application's events and listeners
event:clear                  Clear all cached events and listeners
event:generate               Generate the missing events and listeners based on registration
event:list                   List the application's events and listeners
key:generate                 Set the application key
l5-swagger:generate          Regenerate docs
make:cast                    Create a new custom Eloquent cast class
make:channel                 Create a new channel class
make:command                 Create a new Artisan command
make:component               Create a new view component class
make:controller              Create a new controller class
make:event                   Create a new event class
make:exception               Create a new custom exception class
make:factory                 Create a new model factory
make:job                     Create a new job class
make:listener                Create a new event listener class
make:mail                    Create a new email class
make:middleware              Create a new middleware class
make:migration               Create a new migration file
make:model                   Create a new Eloquent model class
make:notification            Create a new notification class
make:observer                Create a new observer class
make:policy                  Create a new policy class
make:provider                Create a new service provider class
make:request                 Create a new form request class
make:resource                Create a new resource
make:rule                    Create a new validation rule
make:seeder                  Create a new seeder class
make:test                    Create a new test class
migrate:fresh                Drop all tables and re-run all migrations
migrate:install              Create the migration repository
migrate:refresh              Reset and re-run all migrations
migrate:reset                Rollback all database migrations
migrate:rollback             Rollback the last database migration
migrate:status               Show the status of each migration
model:prune                  Prune models that are no longer needed
module:delete                Delete a module from the application
module:disable               Disable the specified module.
module:dump                  Dump-autoload the specified module or for all module.
module:enable                Enable the specified module.
module:install               Install the specified module by given package name (vendor/name).
module:list                  Show list of all modules.
module:make                  Create a new module.
module:make-command          Generate new Artisan command for the specified module.
module:make-component        Create a new component-class for the specified module.
module:make-component-view   Create a new component-view for the specified module.
module:make-controller       Generate new restful controller for the specified module.
module:make-event            Create a new event class for the specified module
module:make-factory          Create a new model factory for the specified module.
module:make-job              Create a new job class for the specified module
module:make-listener         Create a new event listener class for the specified module
module:make-mail             Create a new email class for the specified module
module:make-middleware       Create a new middleware class for the specified module.
module:make-migration        Create a new migration for the specified module.
module:make-model            Create a new model for the specified module.
module:make-notification     Create a new notification class for the specified module.
module:make-policy           Create a new policy class for the specified module.
module:make-provider         Create a new service provider class for the specified module.
module:make-request          Create a new form request class for the specified module.
module:make-resource         Create a new resource class for the specified module.
module:make-rule             Create a new validation rule for the specified module.
module:make-seed             Generate new seeder for the specified module.
module:make-test             Create a new test class for the specified module.
module:migrate               Migrate the migrations from the specified module or from all modules.
module:migrate-refresh       Rollback & re-migrate the modules migrations.
module:migrate-reset         Reset the modules migrations.
module:migrate-rollback      Rollback the modules migrations.
module:migrate-status        Status for all module migrations
module:publish               Publish a module's assets to the application
module:publish-config        Publish a module's config files to the application
module:publish-migration     Publish a module's migrations to the application
module:publish-translation   Publish a module's translations to the application
module:route-provider        Create a new route service provider for the specified module.
module:seed                  Run database seeder from the specified module or from all modules.
module:setup                 Setting up modules folders for first use.
module:unuse                 Forget the used module with module:use
module:update                Update dependencies for the specified module or for all modules.
module:use                   Use the specified module.
module:v6:migrate            Migrate laravel-modules v5 modules statuses to v6.
ninja:backup-update          Shift backups from DB to storage
ninja:check-data             Check/fix data
ninja:check-db               Check MultiDB
ninja:create-account         Create Single Account
ninja:create-single-account  Create Single Sample Account
ninja:create-test-data       Create Test Data
ninja:demo-mode              Setup demo mode
ninja:design-update          Update the system designs when changes are made.
ninja:import                 Import a v4 migration file
ninja:mobile-localization    Generate mobile localization resources
ninja:old-import             Massively import the migrations.
ninja:pcheck-data            Check company data in parallel
ninja:post-update            Run basic upgrade commands
ninja:s3-cleanup             Remove orphan folders/files
ninja:send-recurring         Sends the recurring invoices
ninja:send-reminders         Force send all reminders
ninja:send-test-emails       Sends Test Emails to check templates
ninja:subdomain              Pad subdomains
ninja:sync-users             Syncs Invoice Ninja Users
ninja:translations           Transform translations to json
notifications:table          Create a migration for the notifications table
optimize:clear               Remove the cached bootstrap files
package:discover             Rebuild the cached package manifest
queue:batches-table          Create a migration for the batches database table
queue:clear                  Delete all of the jobs from the specified queue
queue:failed                 List all of the failed queue jobs
queue:failed-table           Create a migration for the failed queue jobs database table
queue:flush                  Flush all of the failed queue jobs
queue:forget                 Delete a failed queue job
queue:listen                 Listen to a given queue
queue:monitor                Monitor the size of the specified queues
queue:prune-batches          Prune stale entries from the batches database
queue:prune-failed           Prune stale entries from the failed jobs table
queue:restart                Restart queue worker daemons after their current job
queue:retry                  Retry a failed queue job
queue:retry-batch            Retry the failed jobs for a batch
queue:table                  Create a migration for the queue jobs database table
queue:work                   Start processing jobs on the queue as a daemon
route:cache                  Create a route cache file for faster route registration
route:clear                  Remove the route cache file
route:list                   List all registered routes
schedule:clear-cache         Delete the cached mutex files created by scheduler
schedule:list                List the scheduled commands
schedule:run                 Run the scheduled commands
schedule:test                Run a scheduled command
schedule:work                Start the schedule worker
schema:dump                  Dump the given database schema
session:table                Create a migration for the session database table
storage:link                 Create the symbolic links configured for the application
stub:publish                 Publish all stubs that are available for customization
vendor:publish               Publish any publishable assets from vendor packages
view:cache                   Compile all of the application's Blade templates
view:clear                   Clear all compiled view files
X-Powered-By: PHP/8.0.17
Content-type: text/html; charset=UTF-8