|
Home > Archive > Unix questions > December 2007 > problem with "at" command
You are viewing an archived Text-only version of the thread.
To view this thread in it's original format and/or if you want to reply to
this thread please [click here]
| Author |
problem with "at" command
|
|
| geantbrun 2007-12-19, 7:27 pm |
| Hi,
I want to schedule a job with the at command. Maybe I don't understand
something but the following (very simple) example doesn't work:
run.sh is a file that contains one line: date>testfile
When I run the command:
at -f run.sh now + 1 minute
I get the following message:
warning: commands will be executed using /bin/sh
job 36851 at 2007-12-19 13:08
When I type atq 5 minutes later, I see
36851 2007-12-19 13:08 a geantbrun
36851 2007-12-19 13:08 = geantbrun
but no testfile was generated. It's like if the job is not
terminating.
Where am I wrong?
Cheers,
Patrick
| |
| Doug McIntyre 2007-12-19, 7:27 pm |
| geantbrun <agin.patrick@gmail.com> writes:
>I want to schedule a job with the at command. Maybe I don't understand
>something but the following (very simple) example doesn't work:
>run.sh is a file that contains one line: date>testfile
Okay, so date is probably in /bin/sh's path when executed by atd,
but where do you expect testfile to be created??
Maybe try an absolute path, because atd's CWD is probably not what you
are expecting.
| |
| geantbrun 2007-12-19, 7:27 pm |
| Thank you for your answer Doug.
I tried date>/home/geantbrun/testfile and it still doesn't create the
testfile.
atq still shows the job running (one line with an 'a' and one other
with a '=').
I don't understand.
Patrick
|
|
|
|
|