Linux sleep command

Updated: 05/04/2019 by Computer Hope
sleep command

On Unix-like operating systems, the sleep command is used to delay for a specified time.

This page covers the GNU/Linux version of sleep.

Description

The sleep command pauses for a set time defined by NUMBER.

SUFFIX may be "s" for seconds (the default), "m" for minutes, "h" for hours, or "d" for days.

Some implementations require that NUMBER be an integer, but modern Linux implementations allow NUMBER to also be a floating-point value.

If more than one NUMBER is specified, sleep delays for the sum of their values.

Syntax

sleep NUMBER[SUFFIX]...
sleep OPTION

Options

--help Display a help message, and exit.
--version Display version information, and exit.

Examples

sleep 10

Delays for 10 seconds.

date — Output the current date and time.
time — Report how long it takes for a command to execute.
wait — Await process completion.