Disable Ctrl-Alt-Delete Key Combination on Linux | LFCS Exam Answer

SysV Init Configuration File to Disable Ctrl-Alt-Delete Key Combination


Which SysV init configuration file should be modified to disable the ctrl-alt-delete key combination?



Click on the arrows to vote for the correct answer

A. B. C. D. E.


The correct answer is C. /etc/inittab.

The ctrl-alt-delete key combination is used to reboot the system. By default, this is enabled on most Linux distributions. However, there are situations where you might want to disable this key combination to prevent accidental reboots.

In the SysV init system, the /etc/inittab file is responsible for setting the default runlevel and defining system initialization and shutdown processes. It is also used to configure various system settings, including disabling the ctrl-alt-delete key combination.

To disable ctrl-alt-delete, you need to modify the /etc/inittab file and comment out the line that references the ctrlaltdel service. Here are the steps to do this:

  1. Open the /etc/inittab file in a text editor with root privileges (e.g., sudo vi /etc/inittab).

  2. Look for a line that starts with the following:

ca:ctrlaltdel:/sbin/shutdown -t3 -r now

This line defines the ctrlaltdel service and what command to run when the ctrl-alt-delete key combination is pressed.

  1. Comment out the line by adding a "#" at the beginning of the line:
#ca:ctrlaltdel:/sbin/shutdown -t3 -r now
  1. Save and close the file.

After making this change, the ctrl-alt-delete key combination will no longer reboot the system. Instead, it will do nothing when pressed.

Note that this change only affects the current session. If you want to make this change permanent, you will need to add a line to the /etc/rc.local file to disable ctrl-alt-delete at boot time.