I'm running a variety of crontab curl requests and I'm not sure why SOME of them stopped outputting the contents to log files. The only change I made was removing cronlocks from all of the entries since they were really pointless for me and a pain to manage. In my testing, I've noticed that when I put them back for the entries that are failing, they work again. What is the problem?
Please note, that I have removed file extensions through .htaccess. If you need any other info, please let me know! Thanks for your time!
Here's one that works properly:
00 6 * * * /usr/bin/curl -sS http://thisismysite.com/updater?no_header=1 >> $(date "+/home/jborn/thisismysite.com/cronlogs/\%Y\%m\%dlogUPDATER.txt") && mutt -s "UPDATER" -a $(date "+/home/jborn/thisismysite.com/cronlogs/\%Y\%m\%dlogUPDATER.txt") -- me@email.com
Here's one that doesn't output to the file like it did with cronlocks:
2 3 * * * /usr/bin/curl -sS http://thisismysite.com/mw?sp_ids=21,22,23,24,25,26&no_header=1 >> $(date "+/home/jborn/thisismysite.com/cronlogs/\%Y\%m\%dlogMIDWEST.txt")
I didn't want to leave pertinent info out, so here's how it was (working) with cronlocks:
2 3 * * * /usr/local/bin/setlock -n /tmp/cronlock.3783699908.155536 sh -c $'/usr/bin/curl -sS http://thisismysite.com/mw?sp_ids=21,22,23,24,25,26&no_header=1' >> $(date "+/home/jborn/thisismysite.com/cronlogs/\%Y\%m\%dlogMIDWEST.txt")