nerdexam
CompTIA

LX0-103 · Question #51

Which of the following commands can be used to determine how long the system has been running? (Choose TWO correct answers.)

The correct answer is A. uptime C. top. Both uptime and top report how long the system has been running, while the remaining options are not valid commands for this purpose.

GNU and Unix Commands

Question

Which of the following commands can be used to determine how long the system has been running? (Choose TWO correct answers.)

Options

  • Auptime
  • Bup
  • Ctop
  • Duname -u
  • Etime up

How the community answered

(16 responses)
  • A
    94% (15)
  • D
    6% (1)

Why each option

Both uptime and top report how long the system has been running, while the remaining options are not valid commands for this purpose.

AuptimeCorrect

The uptime command is specifically designed to display how long the system has been running, along with current time, logged-in user count, and load averages. The top command also displays uptime prominently in its header line, making both valid tools for determining system run duration.

Bup

up is not a standard Linux command and will produce a 'command not found' error on a typical system.

CtopCorrect

top displays a continuously updated summary that includes uptime in the first header line, alongside load averages and task statistics, making it a valid secondary source for uptime information.

Duname -u

uname does not have a -u flag; it reports kernel name, hostname, and architecture details, but has no option to display uptime.

Etime up

time is used to measure the execution duration of another command, and up is not a valid command, making this combination meaningless.

Concept tested: Linux commands for checking system uptime

Source: https://man7.org/linux/man-pages/man1/uptime.1.html

Topics

#uptime#top#system monitoring#running time

Community Discussion

No community discussion yet for this question.

Full LX0-103 Practice