Which file defines the default runlevel in a Linux system?

Disable ads (and more) with a premium pass for a one time $4.99 payment

Boost your Linux skills with the CompTIA Linux+ Certification Exam simulator. Engage with multiple choice questions and detailed feedback. Master Linux concepts and prepare for your exam with confidence!

The default runlevel in a Linux system is defined in the /etc/inittab file. This file contains system initialization information used by the init process, which is the parent of all processes on a Linux system. Within /etc/inittab, a line specifying the default runlevel can be found, typically denoted by the entry that starts with "initdefault." The runlevel essentially determines the operational state of the system at boot time, such as whether to start the graphical environment, a multi-user environment, or other modes.

The other options do not serve this specific function. The /etc/init.d directory contains scripts that manage services for different runlevels, but it does not define what those runlevels are. Similarly, /etc/rc.d is a directory that holds runlevel scripts, and /etc/rc.local is a script that allows for commands to be executed at the end of the boot process. Neither of these files directly defines the system's default runlevel, which is why /etc/inittab is the correct answer.

Subscribe

Get the latest from Examzify

You can unsubscribe at any time. Read our privacy policy