Cron: output processqueue

this is my cron command:

php /home3/realpas1/public_html/krazytee/lists/admin/index.php -p processqueue -c/home3/realpas1/public_html/krazytee/lists/config/config.php

when the cron runs it emails me a huge page of code

does anyone use shared server on

there support does not help on cron setup

So funny I’m trying to do the same on which I believes shares servers or at least has a similar setup to bluehost.

I get the same response with the listing the code (which is index.php) instead of actually processing the queue.

The one thing that I see that might be the issue and let me know if you get them is.

“Warning: commandline only works well with the cli version of PHP” not sure how to use a different version of php.

please let me know if you get anywhere.

Just as a test, you can run these 2 commands from an SSH window and see what happens.
I suggest queuing a test email being sent to only a few addresses of your own.

cd '/home3/realpas1/public_html/krazytee/lists/admin/'
php -q index.php -p processqueue -c/home3/realpas1/public_html/krazytee/lists/config/config.php > /dev/null

what do you mean by this? If the output looks like html then it is likely that you are running the wrong version of php. You need to ask your hosting company how to run php-cli (command line).

that is what I thought too. My hosting company was far from helpful on how to use php cli though. Is there a switch that you can use to go over to the other version. To use regular php all we need to do is.

php /home/username/public_html/domain/lists/admin/index.php -pprocessqueue

@malcolms Are you saying that phplist doesn’t actually process the queue, or just that you do not want the voluminous output?

well spent the better part of today and 10 support chats later and still nowhere on setting up crons with bluehost

here is the output im getting
sorry for the image, but if i posted the text some parts would not show up, it was running the code

i will pay someone to set it up

dont have time to teach myself

any takers

ssh in and ran those 2 files and it did change to that directory and next command did nothing

i have come to the conclusion that BLUEHOST sucks !!!

im goin to a hosting company that likes to help their customers

Good Grief !

What Scott and I are suffering from is it not actually processing. It is obviously find the file and is running it but looks like it runs as a html (hence the big output) but not actually the php. I get the error that it works better in command line so it not using that version. I think the solution is to use php cli I think. anyone have any idea how to do that though?

Thanks to duncanc he fixed the cron script in about 2 min with a simple

php-cli in front of the command

php-cli /home3/realpas1/public_html/krazytee/lists/admin/index.php -pprocessqueue -c/home3/realpas1/public_html/krazytee/lists/config/config.php >processqueue.log 2>&1

why for the life of me the tech support at blue host could not have told me that in 5 seconds and wasted literally 9 hours of real time chat telling me to go look at articles is beyond me

thank you again DUNCANC !!!

ps. i have noticed that hostdime my other hosting company when installing phplist through “softaculous” it creates the cron for you with the proper php command when you install it.

why wont bluehost just do the same. this cron is a major function of the software and for bluehost not to remedy this problem is rediculous. its been the same cron script for phplist for ever.

now for some wine and sleep !!

Worked for me too Thank you DUNCANC !!!

1 Like

sco77m4r7in, most shared hosts will not allow phplist to run, if you do try it eventually it will get shut down. Actually most VPS plans dont allow that either if u look at it closely but some hosts turn a blind eye to them. let me know if ure looking for a host i can recommend you mine, hes cheaper then phplist but more expensive then shared hosts…

@duncanc Following your suggestion given here, I used following command

php-cli /home1/pmwaresc/public_html/nl/lists/admin/index.php -pprocessqueue -c/home1/pmwaresc/public_html/nl/lists/config/config.php >~/processqueue.log 2>&1

processqueue.log is empty but it does not process the queue. Campaign is always in submitted state.

Any idea why queue is not getting processed?

@vpphplist Are you sure that the cron job is actually scheduled? What is the frequency of running it?

I have kept it 5 minutes…I am sure it is scheduled because time stamp of processqueue.log is changing after every 5 minutes.

Let me brief what I have done so far. I scheduled around 5000 email keeping MAILQUEUE_BATCH_SIZE as 300. When after first 300, queue did not process. I realized I have to setup a cron job. I stopped (i.e. paused) the process. Did some troubleshooting to schedule a cron job. Seeing your suggestion in this thread, I finally put the command as you suggested. Now there is no error message in processqueue.log. I resubmit the campaign. It shows Submitted 4725 still to process. The queue is not being processed. Time stamp of processqueue.log keeps changing.

Am I doing anything wrong?

@vpphplist Are you sure that php-cli is the correct command to use? Ask your hosting company to confirm that.

I can check…but let me tell you I have another installation of an older version of PHPList where I used this command

/usr/bin/php /home1/pmwaresc/public_html/newsletter/lists/admin/index.php page=pageaction action=processqueue login=login password=password >/dev/null

It was working fine except I used to get following email every time I launched a campaign…

/bin/sh: line 1: 24734 Terminated /usr/bin/php /home1/pmwaresc/public_html/newsletter/admin/index.php page=pageaction action=processqueue login=login password=password > /dev/null

But it was processing the queue.

Now I have a fresh installation of latest PHPList. Obviously I used the same command with new path to index.php but I got following error in processqueue.log and queue was not getting processed…

Content-type: text/html

Warning: commandline only works well with the cli version of PHPCannot find config file

So I started searching for cli version of command…that is how I reached to this thread. Now I used the command you suggested. There is no error in processqueue.log but queue is still not getting processed.

Where am I going wrong? it is hosted on hostmonster. Should I talk to server support?

@ Try just changing php-cli to /usr/bin/php otherwise you should raise the problem with your hosting support.

I checked with hostmonster help and they are saying we should use like this

php -q /home/username/public_html/cron.php

So I changed the command to

php -q /home1/pmwaresc/public_html/nl/lists/admin/index.php -c /home1/pmwaresc/public_html/nl/lists/config/config.php >~/processqueue.log 2>&1

I got following line in processqueue.log

Warning: commandline only works well with the cli version of PHP

Queue is still not getting processed. campaign is still in submitted state

As chat with hostmonster was closed so I could not give him feedback…I am not sure if the command he has advised is right because warning is still there.