Forum Moderators: bakedjake
Another forum suggested:
00 12 * * * /usr/bin/cron.uptime >> /var/log/uptime.txt
This to did not work.
So I tried to chmod the txt to 777 and this did not work. Is there something I missed? The crontab -e shows the crontab was added, so it is running, just not working.
Joe
I changed it to 0 instead of 00 and it still does not work.
It just does not seem to be writing the file. I did the touch, but I have to log in as su (root) to do it, so the file is owned by root.
Joe
Edit: Could there be some other way to do this? Or maybe put the uptime.txt someplace else?
You are running this from root's crontab? If running '/usr/bin/uptime >> /var/tmp/uptime.txt' on the command line su'd to root works and the same command in root's crontab does not, I think something else is wrong with your system.