[linux] Hoe weet ik dat ik in Nomachine zit?

Geert-Jan gj op wyna.nl
Vr Sep 13 14:41:20 CEST 2019


user op host:~$ sudo reboot
W: molly-guard: SSH session detected!
Please type in hostname of the machine to reboot: ^C
Good thing I asked; I won't reboot host ...

user op host:~$

Dat is handig, tnx!


Geert-Jan


Maar goed:
> Package: molly-guard
> Description-en: protects machines from accidental shutdowns/reboots
>  The package installs a shell script that overrides the existing
>  shutdown/reboot/halt/poweroff commands and first runs a set of scripts, which
>  all have to exit successfully, before molly-guard invokes the real command.
>  .
>  One of the scripts checks for existing SSH sessions. If any of the four
>  commands are called interactively over an SSH session, the shell script
>  prompts you to enter the name of the host you wish to shut down. This should
>  adequately prevent you from accidental shutdowns and reboots.
>  .
>  This shell script passes through the commands to the respective binaries in
>  /sbin and should thus not get in the way if called non-interactively, or
>  locally.
>
> Of dit ook werkt voor Nomachine weet ik niet, misschien kun je het wel
> aanpassen.
>
>
> Paul
>


Meer informatie over de Linux maillijst