Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people, just like you, are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
Solved

shutdown

Posted on 2000-04-16
4
343 Views
Last Modified: 2010-04-20
Hello, Im a new Linux user and i was wondering what is the correct way to shutdown from the command line prompt.  Ive tried exit but it would just take me back to the login screen.  Do i just turn off my computer at this stage?  Thanks in advance
0
Comment
Question by:rlivings
4 Comments
 

Accepted Solution

by:
babar_ahsan earned 50 total points
ID: 2721744
if u want to shutdown immediatly and reboot again use: "shutdown -r now"

if u want to shutdown immediatly and and dont want to reboot again but halt the system use: "shutdown -h now"

if u want to reboot use(it behaves same as first option): "reboot"
0
 

Expert Comment

by:hv
ID: 2721757
You should not just take of the power,
that may harm your linuxsystem, and makes the next boot slower even if no harm was done.

From linux you can use the command "halt" if you want to stop using the pc, or the command "reboot" if you want to reboot rather than stop.  If you do a
"man shutdown" you can learn about
more optoins.

Running any of those commands you either
need to be logged on as root, or have permissions set which allow your userid
to run them.

Finally, if time is short you have the
keyboard reboot command:
left_ctrl + left_alt + del

If you use an x-windows manager, like
kde, gnome, or whatever, it is always
wise to logout from that separately,
before taking down linux.
0
 
LVL 1

Expert Comment

by:andrewljohn70
ID: 2722777
hi rlivings,
Also try to use the following:

1. To shutdown your computer
    init 0

2. To reboot your computer
    init 6

These generally are not used - but I though to just adding this bit.
The shutdown command is used but by using these u type in less and hence quicker with lesser parameters and also easier to remember.
Cheers  :)
0
 

Author Comment

by:rlivings
ID: 2723852
Thank you
0

Featured Post

Master Your Team's Linux and Cloud Stack!

The average business loses $13.5M per year to ineffective training (per 1,000 employees). Keep ahead of the competition and combine in-person quality with online cost and flexibility by training with Linux Academy.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

The purpose of this article is to demonstrate how we can use conditional statements using Python.
Google Drive is extremely cheap offsite storage, and it's even possible to get extra storage for free for two years.  You can use the free account 15GB, and if you have an Android device..when you install Google Drive for the first time it will give…
Learn how to get help with Linux/Unix bash shell commands. Use help to read help documents for built in bash shell commands.: Use man to interface with the online reference manuals for shell commands.: Use man to search man pages for unknown command…
Learn how to navigate the file tree with the shell. Use pwd to print the current working directory: Use ls to list a directory's contents: Use cd to change to a new directory: Use wildcards instead of typing out long directory names: Use ../ to move…

856 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question