Help answer threads with 0 replies.
Go Back > Forums > Linux Forums > Linux - Software
User Name
Linux - Software This forum is for Software issues.
Having a problem installing a new program? Want to know which application is best for the job? Post your question in this forum.


  Search this Thread
Old 04-03-2008, 03:55 PM   #1
LQ Newbie
Registered: Feb 2008
Posts: 16

Rep: Reputation: 0
bash: service: command not found

so i'm trying to make windows and linux talk to eachother via vnc. i've got vnc and vnc-server packages installed along with all listed dependancies. what i can't figure out is that the place i'mg etting my information is telling me to issue the "service vncserver restart" command. which is not working. here is the dilema. i've got a second linux box that is nearly identicle to this one and that specific command works fine. what have i dont to make this not work right. any ideas

Fedora Core 8

Old 04-03-2008, 04:05 PM   #2
Senior Member
Registered: Mar 2002
Location: Los Angeles, CA
Distribution: Debian, Ubuntu
Posts: 1,334

Rep: Reputation: 51
"service" is just a way of launching programs (scripts) in /etc/init.d, so this should do the same:

/etc/init.d/vncserver restart

this assumes that there is an executable called "vncserver" in /etc/init.d
Old 04-04-2008, 08:45 AM   #3
LQ Newbie
Registered: Feb 2008
Posts: 16

Original Poster
Rep: Reputation: 0
right, that is kind of what i figured but since i posted i also noticed that the chkconfig function also does not work. if i understand correctly these are built in functions of the Bash shell, but these do not work so i'm wondering if i've got a corruption. also, when i issue the "vncserver start/stop/restart" commands they do nothing. i have to reboot to restart this service.this is not the case on my other fedora 8 box. Other services are responding normally though (i.e. mysqld, snmpd). And yes vncserver is in the /etc/init.d/ folder. Is there a way to reload the Bash shell, or some sort of system files that reference the above commands.

side note: since posting the first post i did get the vncserver, and viewer working.
Old 04-04-2008, 10:43 AM   #4
Registered: Aug 2006
Location: Saint Paul, MN, USA
Distribution: {Free,Open}BSD, CentOS, Debian, Fedora, Solaris, SuSE
Posts: 731

Rep: Reputation: 75

I use CentOS 5. The service command is in /sbin/service. It is not a bash builtin.

service runs a System V init script in as predictable environment as
possible, removing most environment variables and with current working
directory set to /.

The SCRIPT parameter specifies a System V init script, located in
--excerpt from man service
Best wishes ... cheers, makyo
Old 04-04-2008, 11:24 AM   #5
Registered: Mar 2008
Location: Florida
Distribution: Fedora mainly, but I am open to others.
Posts: 273

Rep: Reputation: 33
Just co-signing what Makyo said... the command is /sbin/service. I'm a Fedora 8 user as well.


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
Restart services - 'service' command not found davee Linux - Newbie 9 03-16-2013 01:34 AM
bash: rpm: command not found && sudo: alien: command not found Java_Code Ubuntu 7 07-28-2006 12:57 AM
service: command not found anjanesh Linux - Newbie 3 05-23-2006 11:37 AM
service: command not found aap Linux - Newbie 8 01-06-2006 09:15 PM
-bash: service: command not found Labyrinth Slackware 1 05-12-2004 08:13 AM > Forums > Linux Forums > Linux - Software

All times are GMT -5. The time now is 09:48 PM.

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