Forem

ダニエリ for WoMakersCode

Posted on

4

[Tutorial Linux] Terminal: Desligando o computador

Para desligar o computador através do terminal, digite:

$ shutdown -h now
Enter fullscreen mode Exit fullscreen mode
  • $ indica que você deve usar o usuário comum para fazer essa operação.

  • shutdown programa um horário para que o sistema seja desligado, mas também pode ser usado para reiniciar ou travar a máquina.

  • -h para finalizar e desligar o sistema.

  • now diz a máquina para desligar imediatamente.

Também é possível especificar um horário para o desligamento. Exemplo:

$ shutdown -h 21:55
Enter fullscreen mode Exit fullscreen mode

Depois do -h temos o horário descrito em hh:mm (horas e minutos).

Caso queira desligar usando daqui a um determinado tempo, por exemplo, daqui a 45 minutos, usamos o comando

$ shutdown -h +45
Enter fullscreen mode Exit fullscreen mode

Para cancelar qualquer um desses desligamentos agendados, digite:

$ shutdown -c
Enter fullscreen mode Exit fullscreen mode
  • -c do inglês, cancel, para cancelar.

Top comments (0)

Image of Docusign

🛠️ Bring your solution into Docusign. Reach over 1.6M customers.

Docusign is now extensible. Overcome challenges with disconnected products and inaccessible data by bringing your solutions into Docusign and publishing to 1.6M customers in the App Center.

Learn more

👋 Kindness is contagious

Dive into an ocean of knowledge with this thought-provoking post, revered deeply within the supportive DEV Community. Developers of all levels are welcome to join and enhance our collective intelligence.

Saying a simple "thank you" can brighten someone's day. Share your gratitude in the comments below!

On DEV, sharing ideas eases our path and fortifies our community connections. Found this helpful? Sending a quick thanks to the author can be profoundly valued.

Okay