LinuxQuestions.org
Share your knowledge at the LQ Wiki.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie
User Name
Password
Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question? If it is not in the man pages or the how-to's this is the place!

Notices


Reply
  Search this Thread
Old 04-13-2004, 10:12 PM   #1
woranl
Member
 
Registered: Apr 2003
Location: Toronto
Distribution: Fedora Core
Posts: 119

Rep: Reputation: 15
Question Bash?? System Restart (shutdown -r now)


I've a question about restart / shutdown my Fedora system using the terminal.

when I'm not using X, i can simply type "shutdown -r now" to restart my computer
but when i'm using X and typed the same thing under the terminal...
it said "bash: shutdown: command not found" Why ???

Also, the command "Service" seem not to work under the terminal
For example, when I'm not using X, i can type "Service iptables start" to start firewall
but when i'm using X and typed the same thing
it said "bash: service: command not found"


What exactly is "bash" ?
 
Old 04-13-2004, 10:19 PM   #2
emetib
Member
 
Registered: Feb 2003
Posts: 482

Rep: Reputation: 33
http://www.gnu.org/software/bash/bash.html
 
Old 04-13-2004, 10:29 PM   #3
Demonbane
LQ Guru
 
Registered: Aug 2003
Location: Sydney, Australia
Distribution: Gentoo
Posts: 1,796

Rep: Reputation: 47
Problem is /sbin and /usr/sbin is not in the path when you 'su', there's several solutions
execute the commands using absolute paths, eg
Code:
/sbin/shutdown -r now
/sbin/service iptables start
use 'su -' instead of 'su'

or add the paths to /root/.bashrc
 
Old 04-13-2004, 10:29 PM   #4
woranl
Member
 
Registered: Apr 2003
Location: Toronto
Distribution: Fedora Core
Posts: 119

Original Poster
Rep: Reputation: 15
thx for the link, but i need some quick solution (no time to read all those text)
is there a way to restart my system using command ?
like what should i type in the terminal ?

thx a lot
 
Old 04-13-2004, 10:33 PM   #5
woranl
Member
 
Registered: Apr 2003
Location: Toronto
Distribution: Fedora Core
Posts: 119

Original Poster
Rep: Reputation: 15
Demonbane, thx for the quick and accurate answer
no proprietary support can be as fast as our open source community.
amazing!
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
Shutdown.....but it restart max_232 Linux - Laptop and Netbook 2 07-08-2005 05:32 AM
can shutdown but not restart... kernel 2.6.6 xtian Linux - General 1 06-19-2004 04:17 PM
shutdown & restart linuxzouk Linux - Newbie 2 06-11-2004 06:03 AM
Shutdown, restart menu gone Tec1 Linux - Newbie 3 08-12-2003 03:59 PM
shutdown / restart XServer esteeven Linux - Newbie 1 02-02-2002 10:10 PM


All times are GMT -5. The time now is 06:36 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration