remove shutdown messages in console

Hi. How can I remove shutdown messages on the console, or even print my arbitrary messages on the console?

Code:
*** FINAL System shutdown message from root@geekiam ***                     
System going down IMMEDIATELY

Some messages like these. I don't want it to print theses messages. It's not pretty for embedded systems.
 
In your situation you might want to use reboot(8) instead of shutdown. In general it does the same thing (flushing caches, sending a SIGTERM signal to running processes) but without all the warnings.
 
ShelLuser said:
In your situation you might want to use reboot(8) instead of shutdown. In general it does the same thing (flushing caches, sending a SIGTERM signal to running processes) but without all the warnings.

No it's not quite the same. The difference is that reboot(8) does not call the rc(8) scripts to shut down services properly but only kills them with a signal. This is in stark contrast with the SYSV init(8) suite on Linux where shutdown(8) and reboot(8) are aliases for each other.
 
Indeed, @kpa is right here; sending a SIGTERM (see reboot(8)) is obviously not the same (and perhaps not even preferred) when looking at the rc.d structure.

So when looking things over again I think instead of reboot you might want to use init instead. If you bring the system to runlevel 6 you're basically initiating a reboot. To my knowledge one without warnings and this approach will make sure that all the processes are terminated in the intended manner (by using their rc(8) scripts).
 
Last edited by a moderator:
Last time I checked, you could use a custom warning message in shutdown(8). Another thing that comes to my mind is to modify the source of the command and recompile to eliminate the output that you do not want. After all, it is an embebed system.
 
Back
Top