Questions tagged [at-job]

"at" is a classic Unix command that read commands from standard input (or a specified file) which are to be executed at a later time, using /bin/sh. Use this tag for questions related to programmatic use of "at"; trouble shooting and general usage questions might be better suited for Super User or Unix & Linux.

at is used to schedule commands for one-time execution, as opposed to jobs, which are run at regular intervals.

Relevant links

Related tags

91 questions
0
votes
1 answer

Execute at command from php page with command line input

I want to execute the below command from PHP shell_script in Linux environment. shell_exec('at 12:39 <<< "mkdir newfolder"'); I have tried in all the method of PHP to execute this script but it is not working. In terminal when I am running at…
0
votes
1 answer

At job asking for time

#!/bin/bash at now +1 minutes -f ./test.sh logFile="/home/.../testLog.txt" time1="114000" time2="153000" currentTime=`date +"%H%M%S"` echo "" >> "$logFile" date >> "$logFile" echo "$currentTime" >> "$logFile" echo "" >> "$logFile" if [[…
principal-ideal-domain
  • 3,620
  • 5
  • 27
  • 62
0
votes
1 answer

Run script with arguments via ssh with at command from python script

I have a python program which needs to call a script on a remote system via ssh. This ssh call needs to happen (once) at a specified date which can be done via the linux at command. I am able to call both of these external bash commands using…
John
  • 1,486
  • 4
  • 24
  • 39
0
votes
2 answers

Running "at" command on Windows XP - Why the job is not executed?

On Windows XP I'm trying to add a job like this: at 17:07 /every:s dir I expect dir to be executed every Saturday at 17:07, however I don't see anything happens in the command line window. Here is the log: D:\temp>at 17:07 /every:s dir Added a new…
Misha Moroshko
  • 148,413
  • 200
  • 467
  • 700
0
votes
1 answer

at command inside docker container

I am trying to run the at command inside a docker. This command is present in the script, the entrypoint script, which runs when the container is started using the docker run command. Most of the times the at command runs successfully but for like 1…
tom
  • 153
  • 9
0
votes
2 answers

sending input to a program called by the "at command"

I have a program which accepts 2 prompts (y/n). For example: stopprogram do you want to stop the program (Y/N)? y do you want to send an email to the admin about it (Y/N)? y Now, I'd like to automate that using the 'at' command. the following works…
user3772839
  • 265
  • 3
  • 11
0
votes
1 answer

at command in ruby script

I am having simple ruby script which will send mail after certain time, this is my code : #!/usr/bin/env ruby system("at now + 1 day <
Rahul
  • 349
  • 6
  • 21
0
votes
1 answer

Trouble using the `at` command on mac

I'm unable to get the at command to run from the Mac Terminal. I've tried at -f test.txt 10:44 which puts it in the queue, but then it never runs. I've tried sh test.txt | at 10:43 which puts it in the queue (though it never runs), but it also runs…
dgig
  • 3,977
  • 2
  • 30
  • 44
0
votes
1 answer

Running python scripts using Windows AT command line prompt

The question is: How should exactly look the AT command to schedule a one-time task to be executed by python. Here is what I tried: at 20.00 "cmd python e:/path/to/file/script.py" at 20.00 c:/Python27/python.exe e:/path/to/file/script.py Neither…
Aleks_Saint
  • 57
  • 1
  • 9
0
votes
1 answer

Jobs executed using at command hangs

I have bash script test.sh which runs a simple command as below echo "test" >> /d2/tmp/test.txt Now I invoke this as below [root@labtspc1rg03 tmp]# at now < test.sh job 574 at 2015-12-30 05:26 Now this job never gets executed. [root@labtspc1rg03…
0
votes
1 answer

Capture ID of At Command in R

Problem: I want to capture the id of the at command job This is the normal code to execute the at command > system(command="echo touch my_path/test_file.in | at 05:26 AM") And this is the output job 984 at 2015-12-11 05:26 Since I want to…
JJC
  • 373
  • 1
  • 5
  • 10
0
votes
2 answers

This statement runs interactively but not from 'at' scheduled

if [ $(/sbin/iptables -w -L INPUT -n|grep --line-buffered -m 1 -c -w 66.128.56.213) == "0" ]; then /sbin/iptables -w -I INPUT "$(/sbin/iptables -w -L INPUT -n --line-numbers|stdbuf -o0 grep -m 1 -w DROP|stdbuf -o0 awk '{print $1}')" -i eth0 -s…
kenneth558
  • 69
  • 8
0
votes
1 answer

How to plan job in php script via exec and 'at'

I try to plan one-time job with 'at' command. There is next code in script: $cmd = 'echo "/usr/bin/php '.$script_dir.$script_name.' '.$args.'"|/usr/bin/at "'.$time.'" 2>&1'; exec($cmd, $output , $exit_code); When I run this command from script it…
super pantera
  • 165
  • 2
  • 11
0
votes
1 answer

How to refresh a page from Windows scheduled tasks?

we have a computer which only purpose is to display a web page on a big screen. This page has a calendar, which reloads its data every 60 seconds. The whole page reloads after 60 minutes. Both of these reloads are called from jQuery by…
WellBloud
  • 653
  • 1
  • 10
  • 27
0
votes
1 answer

at command throws 'cannot set egid: Operation not permitted error'

I'm trying to execute a command using the following command: /usr/local/bin/php xxx.php | at now + 10 minutes However, terminal throws this error: cannot set egid: Operation not permitted error I tried adding the user to /etc/at.allow but that…
user4951834
  • 591
  • 2
  • 9
  • 19