nerdexam
CompTIA

XK0-005 · Question #53

Which of the following commands brings a system running SysV init into a state in which it is safe to perform maintenance tasks? (Choose TWO correct answers.)

The correct answer is C. init 1 D. telinit 1. To transition a SysV init system into a safe maintenance state, which corresponds to runlevel 1 (single-user mode), both the init 1 and telinit 1 commands can be used.

System Management

Question

Which of the following commands brings a system running SysV init into a state in which it is safe to perform maintenance tasks? (Choose TWO correct answers.)

Options

  • Ashutdown -R 1 now
  • Bshutdown -single now
  • Cinit 1
  • Dtelinit 1
  • Erunlevel 1

How the community answered

(49 responses)
  • A
    4% (2)
  • B
    2% (1)
  • C
    94% (46)

Why each option

To transition a SysV init system into a safe maintenance state, which corresponds to runlevel 1 (single-user mode), both the `init 1` and `telinit 1` commands can be used.

Ashutdown -R 1 now

`shutdown -R 1 now` is an incorrect syntax; `shutdown -r now` initiates a reboot, but `shutdown -R 1` is not a valid way to enter runlevel 1 for maintenance.

Bshutdown -single now

`shutdown -single now` is not a standard or valid command for entering single-user mode in SysV init systems.

Cinit 1Correct

The `init` command, followed by a runlevel number, is used in SysV init systems to change the current runlevel; `init 1` specifically switches the system to runlevel 1, which is typically single-user mode, ideal for maintenance.

Dtelinit 1Correct

The `telinit` command is generally a symbolic link to `init` and serves the same purpose of changing the system's runlevel; `telinit 1` will also switch the system to runlevel 1 (single-user mode) for maintenance.

Erunlevel 1

The `runlevel` command displays the current and previous runlevels, but it does not change the system's runlevel.

Concept tested: SysV init runlevels for maintenance

Source: https://man7.org/linux/man-pages/man8/init.8.html

Topics

#SysV init#Runlevels#init command#System maintenance

Community Discussion

No community discussion yet for this question.

Full XK0-005 Practice