ArticleslgStudy

computer science

At (command)

At (command) is a computer science topic covered in the lgStudy science library. This page brings together a partial reference excerpt, illustrations, worked examples, real-world applications and a short study plan, so you can understand At (command) rather than just read about it. In short: at is a shell command for scheduling commands to be executed once, at a future time. The command was originally developed for use with Unix and is now available on a variety of Unix-like systems, as well as Windows, and ReactOS.

At (command) — main illustration
At (command) — illustration

Key takeaways

  • At (command) belongs to computer science; place it in that map before memorising details.
  • Learn the definition first, then one example that makes the definition concrete.
  • Connect At (command) to a quantity you can measure, compute or draw — that is where exam questions come from.
  • Reproduce the core statement of At (command) from memory before moving on to harder problems.

Reference excerpt

at is a shell command for scheduling commands to be executed once, at a future time. The command was originally developed for use with Unix and is now available on a variety of Unix-like systems, as well as Windows, and ReactOS. Microsoft deprecated at in Windows 8 and Server 2012. It was removed in Windows Insider Preview Build 29671.

Variants

Unix-like On Unix-like operating systems, at reads a series of commands from standard input and collects them into one "at-job" which is carried out at a date and time that is specified as part of the command. The job inherits the current environment, so that it is executed in the same working directory and with the same environment variables set as when it was scheduled. at differs from cron, which is used for scheduling recurring execution, e.g., once an hour, every Tuesday, January 1 every year, etc.. As with cron, many Unix systems allow the administrator to restrict access to the at command. at can be made to send E-mail to a user when done carrying out a scheduled job, can use more than one job queue, and can read a list of commands to execute out from a file instead of standard input. The Linux at command was mostly written by Thomas Koenig. The batch command can be used instead of at to only run scheduled jobs if the system's load average is below a certain value.

Examples A sample command to compile a C program at 11:45 a.m. on January 31 would be:

or

The atq program lists the currently queued jobs, while atrm removes jobs from the queue:

In some Unix-like computer operating systems, it uses a daemon, atd, which waits in the background periodically checking the list of jobs to do and executing those at their scheduled time on behalf of at.

Windows and ReactOS In addition to the graphical user interface for Windows Task Scheduler in Control Panel, Windows provides an at shell command that schedules operations to run at a specified time and date (similar to cron). It is available since Windows NT, but is now deprecated in favor of schtasks. It can only be used when the Schedule service is running. When used without parameters, at lists scheduled commands. at cannot access tasks created or modified by Control Panel or schtasks.exe. Also, tasks created with at are not interactive by default; interactivity needs to be explicitly requested. The ReactOS implementation is based on the Windows implementation. It was developed by Eric Kohl and is licensed under the GPLv2.

Examples To use at, the user must be a member of the local Administrators group. The command-syntax is:

at [\\ComputerName] [{[ID] [/delete]|/delete [/yes]}] at [[\\ComputerName] hours:minutes [/interactive] [{/every:date[,...]|/next:date[,...]}] command] \\ ComputerName This parameter specifies a remote computer. If it is omitted, at schedules the commands and programs on the local computer. ID This parameter specifies the identification number assigned to a scheduled command. /delete This parameter cancels a scheduled command. If ID is omitted, all of the scheduled commands on the computer are canceled. /yes This parameter answers yes to all queries from the system when you delete scheduled events. hours : minutes This parameter specifies the time when to run the command. /interactive This parameter allows the given command to interact with the desktop of the user who is logged on at the time command runs. /every: This parameter runs the given command on every specified day or days of the week or month. date This parameter specifies the date when to run the given command. One or more days of the week can be specified. If date is omitted, at uses the current day of the month. /next: This parameter runs command on the next occurrence of the day. command This parameter specifies the Windows command, program (that is, .exe or .com file), or batch program (that is, .bat or .cmd file) that will be run. /? Displays help for the command.

See also cron, runs scheduled tasks at regular intervals Launchd, Apple’s init software which handles at in macOS List of POSIX commands schtasks (Microsoft command shell) systemd, incorporates atd

References

Further reading Barrett, Daniel J. (2012). Macintosh Terminal Pocket Guide: Take Command of Your Mac. O'Reilly. ISBN 978-1449328986. John Paul Mueller (2007). Windows Administration at the Command Line for Windows Vista, Windows 2003, Windows XP, and Windows 2000. John Wiley & Sons. ISBN 978-0470165799.

External links

at: execute commands at a later time – Shell and Utilities Reference, The Single UNIX Specification, Version 5 from The Open Group batch: schedule commands to be executed in a batch queue – Shell and Utilities Reference, The Single UNIX Specification, Version 5 from The Open Group

Illustrations

At (command) illustration

Worked examples

Example 1 — a first encounter with At (command)

Start with the simplest possible case. Write down what At (command) claims or describes in one sentence, then invent the smallest concrete situation in which that sentence is true. In computer science, the smallest case is usually a single object, a single equation or a single measurement. Check that every symbol or term in your sentence has a meaning in that case.

Example 2 — changing one variable

Take the situation from Example 1 and change exactly one quantity: double it, halve it, or set it to zero. Predict what should happen to At (command) before you calculate. Comparing your prediction with the result is the fastest way to find out whether you understand the idea or only the words.

Example 3 — an exam-style question

Typical questions about At (command) ask you to (a) state it precisely, (b) apply it to given data, and (c) explain a limitation. Practise writing all three answers in under five minutes; the third part is what separates a full-mark answer from an average one.

Applications of At (command)

In research
At (command) appears in computer science research whenever the underlying quantities have to be modelled precisely. Papers usually cite it as a starting assumption and then explore where it breaks down.
In technology and industry
Engineering practice reuses At (command) in design rules, simulations and safety margins. Knowing the idea lets you read a specification sheet and understand why the numbers look the way they do.
In the classroom
At (command) is common in secondary-school and first-year university syllabi. It links to neighbouring topics ReactOS commands, Standard Unix programs, Unix SUS2008 utilities, so understanding it makes those chapters shorter.
In everyday life
Look for At (command) outside the textbook — in sport, cooking, traffic, electronics or the sky above you. An example you found yourself is remembered far longer than one you were given.
Ask Teacher Smith questions about this articleOpens your AI tutor with a question about “At (command)” →

How to study At (command) in 20 minutes

  1. Read the reference excerpt below once, without taking notes.
  2. Close the page and write down what At (command) means in your own words.
  3. Compare your version with the excerpt and mark what you missed.
  4. Work through the three examples above with pen and paper.
  5. Explain At (command) out loud to somebody else — or to Teacher Smith in the lgStudy chat.

Frequently asked questions

What is At (command) in simple terms?

at is a shell command for scheduling commands to be executed once, at a future time. The command was originally developed for use with Unix and is now available on a variety of Unix-like systems, as well as Windows, and ReactOS.

Why does At (command) matter?

Because it connects several computer science ideas at once: it gives you a definition you can apply, a quantity you can calculate, and a way to check whether a result is plausible.

How should I study At (command)?

Read the excerpt, restate it from memory, then work through the examples and applications listed on this page. The five-step study plan above takes about twenty minutes.

What does this page cover?

It gives you a compact reference excerpt plus original lgStudy explanations, examples, applications and study material on At (command).

Tags

  • ReactOS commands
  • Standard Unix programs
  • Unix SUS2008 utilities
  • Unix process- and task-management-related software
  • Windows administration
  • Windows commands

Keep exploring