By comprateur on Saturday, 31 October 2015
Posted in Technical Issues
Replies 17
Likes 0
Views 1.7K
Votes 0
Hello,
I'm trying to setup the cron task but when I put the following command in cpanel (sitegrounds)
/bin/wget -O /dev/null "http://mifitnessysalud.com/index.php?option=com_easysocial&cron=1";
I have the following error json parse failed.

thanks for your help
Hey comprateur,

I am really sorry for the delay of this reply as it is a weekend for us here. It seems like you have the language redirect plugin enabled. Use this URL instead,

·
Sunday, 01 November 2015 00:01
·
0 Likes
·
0 Votes
·
0 Comments
·
which url?
·
Sunday, 01 November 2015 00:45
·
0 Likes
·
0 Votes
·
0 Comments
·
Hey Comprateur,

Use the code snippet above as your cron command instead
·
Sunday, 01 November 2015 15:19
·
0 Likes
·
0 Votes
·
0 Comments
·
Ah ok sorry the first time the snippet was not shown.

But it is the same, json parse failed.
·
Sunday, 01 November 2015 21:10
·
0 Likes
·
0 Votes
·
0 Comments
·
Hey Comprateur,

What is the exact error being thrown by the server? Have you checked with your hosting provider about this yet? The command should work actually.
·
Sunday, 01 November 2015 23:32
·
0 Likes
·
0 Votes
·
0 Comments
·
Please find the answer from siteground support

I checked again the server logs, and I can confirm that the cron executes, however if you receive an email this means that there is something wrong with the script itself.

When opening the URL via a browser: http://mifitnessysalud.com/es/?option=com_easysocial&cron=1 I get a pop-up to download the json file which doesn't seem right.

I will advise you to check this component and see if there is a setting to edit the export to another format and not the json one, or see if there are any other settings that can be causing the issue.

.



[{"status":"200","contents":"No hay nada que enviar por el momento.","time":"2015-10-31 12:48:05"},
{"status":"200","contents":"There is no banned users to release.","time":"2015-10-31 12:48:05"},
{"status":"200","contents":"There is no need to send reminder for user inactivity.","time":"2015-10-31 12:48:05"},
{"status":"200","contents":"There is no need to send reminder to users for upcoming events.","time":"2015-10-31 12:48:05"},
{"status":"200","contents":"Current videos storage is set to local.","time":"2015-10-31 12:48:05"},
{"status":"200","contents":"Current photos storage is set to local.","time":"2015-10-31 12:48:05"},
{"status":"200","contents":"Current photos storage is set to local.","time":"2015-10-31 12:48:05"},
{"status":"200","contents":"Current avatar storage is set to local.","time":"2015-10-31 12:48:05"},
{"status":"200","contents":"No files to upload to Amazon S3 right now.","time":"2015-10-31 12:48:05"},
{"status":"200","contents":"Stream archive disabled.","time":"2015-10-31 12:48:05"},
{"status":"200","contents":"There are no videos to process at this point of time.","time":"2015-10-31 12:48:05"},
{"status":"200","contents":"There are no videos that is being processed currently.","time":"2015-10-31 12:48:05"}]

can you please see what could be wrong with the json?

thanks.
·
Thursday, 05 November 2015 22:11
·
0 Likes
·
0 Votes
·
0 Comments
·
Hi Comprateur,

Ah I see. This is actually a normal behavior where easysocial will output the result of cron in json string format as you can see from my screenshot here when I opening your cron url through firefox browser, http://screencast.com/t/4VpCrRNGLJl .

I believe this is not an issue and your email notification should working correctly regardless on the error message that you mentioned above.
·
Friday, 06 November 2015 12:56
·
0 Likes
·
0 Votes
·
0 Comments
·
Hey there,

I am sorry for the delay of this reply,

I have a little bit lost here, may i know what is the exactly json parse error shown on your server?

At the above json string is fine, it just a status when the cron process, how many email already processed.
·
Friday, 06 November 2015 13:02
·
0 Likes
·
0 Votes
·
0 Comments
·
The error indicated is JSON PARSE FAILED

I really don't know then if the cron really works.

yes but because the cron found it with errors, I receive an error on my email everytime the crons runs.

I cannot then know if really there is an error or not, and it plugged my mailbox unfocusing me from important email or real cron errors.

What I don't understand is that easyblog works perfectly.

please find a solution.
·
Friday, 06 November 2015 16:43
·
0 Likes
·
0 Votes
·
0 Comments
·
Hi Comprateur,

To be honest we never encounter this issue before with all of our easyblog customer here that using cron. Perhaps you can provide us with your Joomla backend and FTP access instead so we can check on the issue directly. If possible kindly provide us with your cronjob access so we can test this out directly.
·
Friday, 06 November 2015 17:05
·
0 Likes
·
0 Votes
·
0 Comments
·
site details entered + cpanel for the cron job
·
Friday, 06 November 2015 17:28
·
0 Likes
·
0 Votes
·
0 Comments
·
Hi Comprateur,

I just try to check the cron response from your server and it seems like the everything is response correctly and it show no error message in my email:
--2015-11-06 04:30:01--  http://mifitnessysalud.com/es/?option=com_easysocial&cron=1
Resolving mifitnessysalud.com (mifitnessysalud.com)... 37.60.224.110
Connecting to mifitnessysalud.com (mifitnessysalud.com)|37.60.224.110|:80... connected.
HTTP request sent, awaiting response... 200 OK
Length: unspecified [text/x-json]
Saving to: '/dev/null'

0K . 49.8M=0s

2015-11-06 04:30:04 (49.8 MB/s) - '/dev/null' saved [1241]


Not really sure how can we reproduce the issue here.
·
Friday, 06 November 2015 18:32
·
0 Likes
·
0 Votes
·
0 Comments
·
I had same problem and asked my hosting
they told me ; you get Jason error when you using Http:// on Cronton

only high level admin can add this
so they add the cronjob with http:// for me
·
Saturday, 07 November 2015 01:44
·
0 Likes
·
0 Votes
·
0 Comments
·
John, thanks but I already have http://

Ezrul, No it does not show error but you should not received the email, if the cron is successful.
Go to the cpanel and try to edit or add a new cron job, and see the error. Json parse failed.
·
Saturday, 07 November 2015 16:21
·
0 Likes
·
0 Votes
·
0 Comments
·
Hey comprateur,

I am really sorry for the delay of this reply,

Actually you received that email is not json parse failed error, it just server response and send to your email address regarding the cronjob output.

By the way, I have help you added this >/dev/null 2>&1 command behind of the cron command, you shouldn't receive that server response when the cron is process.

/usr/bin/wget -O /dev/null "http://mifitnessysalud.com/es/?option=com_easysocial&cron=true" >/dev/null 2>&1


Can you give it a try now?
·
Monday, 09 November 2015 13:28
·
0 Likes
·
0 Votes
·
0 Comments
·
thanks, but how to test it?
·
Monday, 09 November 2015 15:31
·
0 Likes
·
0 Votes
·
0 Comments
·
You can check your mailbox and see is it got receive any email regarding the cronjob, to check this you have to wait for your cron process every 30 minutes. (If I am not wrong you have set 30 minute per time right)
·
Monday, 09 November 2015 15:38
·
0 Likes
·
0 Votes
·
0 Comments
·
View Full Post