Comments on: How to Disable Shutdown and Reboot Commands in Linux https://www.tecmint.com/disable-shutdown-and-reboot-commands-in-linux/ Tecmint - Linux Howtos, Tutorials, Guides, News, Tips and Tricks. Thu, 13 Jul 2023 14:59:14 +0000 hourly 1 By: Ravi Saive https://www.tecmint.com/disable-shutdown-and-reboot-commands-in-linux/comment-page-1/#comment-1574069 Tue, 24 Aug 2021 06:38:01 +0000 https://www.tecmint.com/?p=25753#comment-1574069 In reply to dave.

@Dave,

You can remove execute perimssion as shown.

# chmod -x /sbin/shutdown
# chmod -x /sbin/reboot
]]>
By: dave https://www.tecmint.com/disable-shutdown-and-reboot-commands-in-linux/comment-page-1/#comment-1574059 Tue, 24 Aug 2021 05:15:07 +0000 https://www.tecmint.com/?p=25753#comment-1574059 # chmod o-x /sbin/shutdown # chmod o-x /sbin/reboot

how to revert them?

]]>
By: Felix Andre https://www.tecmint.com/disable-shutdown-and-reboot-commands-in-linux/comment-page-1/#comment-1271649 Sat, 19 Oct 2019 17:56:46 +0000 https://www.tecmint.com/?p=25753#comment-1271649 Hello, how many white spaces should I leave between the user and the rest of this sentence:

tecmint   ALL=(ALL:ALL) ALL, !SHUTDOWN

Same question for this one as well:

Cmnd_Alias     SHUTDOWN = /sbin/shutdown,/sbin/reboot,/sbin/halt,/sbin/poweroff

And this file needs to be reloaded after I modify it with some /etc/init.d … ? Thank you

]]>
By: Aaron Kili https://www.tecmint.com/disable-shutdown-and-reboot-commands-in-linux/comment-page-1/#comment-1246760 Wed, 18 Sep 2019 07:34:56 +0000 https://www.tecmint.com/?p=25753#comment-1246760 In reply to Dimitry.

@Dimitry

Simply remove the Cmnd_Alias SHUTDOWN = /sbin/shutdown,/sbin/reboot,/sbin/halt,/sbin/poweroff line from sudoers file and !SHUTDOWN.

]]>
By: Dimitry https://www.tecmint.com/disable-shutdown-and-reboot-commands-in-linux/comment-page-1/#comment-1245641 Mon, 16 Sep 2019 16:19:23 +0000 https://www.tecmint.com/?p=25753#comment-1245641 How to bring back this commands for all users?

]]>