how to restart linux using terminal code example Example 1: command to restart linux sudo reboot Example 2: restart server centos reboot -h now