LX0-103 · Question #88
Which of the following commands reboots the system when using SysV init? (Choose TWO correct answers.)
The correct answer is A. shutdown -r now C. telinit 6. In SysV init, a reboot is triggered either by shutdown with the -r flag or by switching to runlevel 6 via telinit.
Question
Which of the following commands reboots the system when using SysV init? (Choose TWO correct answers.)
Options
- Ashutdown -r now
- Bshutdown -r "rebooting"
- Ctelinit 6
- Dtelinit 0
- Eshutdown -k now "rebooting"
How the community answered
(28 responses)- A86% (24)
- B4% (1)
- D4% (1)
- E7% (2)
Why each option
In SysV init, a reboot is triggered either by shutdown with the -r flag or by switching to runlevel 6 via telinit.
shutdown -r now sends a reboot signal immediately; it notifies logged-in users, cleanly terminates processes, unmounts filesystems, and then instructs SysV init to reboot the system.
shutdown -r requires a time argument before the message string; 'shutdown -r "rebooting"' passes the quoted string as the time argument, which is invalid and will cause an error.
In SysV init, runlevel 6 is defined as reboot; telinit 6 instructs the init process to transition to that runlevel, triggering a clean system reboot.
telinit 0 transitions the system to runlevel 0, which is halt or poweroff - not a reboot.
The -k flag tells shutdown to send warning messages to logged-in users but explicitly does NOT perform any shutdown or reboot action.
Concept tested: SysV init runlevels and reboot commands
Source: https://man7.org/linux/man-pages/man8/shutdown.8.html
Topics
Community Discussion
No community discussion yet for this question.