Fedora Linux Support Community & Resources Center
  #1  
Old 23rd November 2008, 06:55 PM
anitha2324 Offline
Registered User
 
Join Date: Jun 2007
Posts: 72
Exclamation init.d start up scripts

Hi All,

I am newbie to linux , i am using fedora 8 , i have installed some softwares like mysql , apache ...etc , but the problem is that all those services are not starting at the boot time automatically,

for starting that i have to do it manually , for example to start mysql , i have to do that manually using the command
#/etc/init.d/mysqld start

is my installation of the software is wrong , or is it something related to some settings in some configuration files , please help me and let me know
Reply With Quote
  #2  
Old 23rd November 2008, 08:02 PM
BlueC Offline
Registered User
 
Join Date: Aug 2007
Location: Liverpool, UK
Posts: 733
see "man chkconfig"

for example, a (simplified) way to make mysqld start at boot would be:

Code:
chkconfig mysqld on
and to see what software is configured to run at boot on all different run levels:

Code:
chkconfig --list
as I said, see "man chkconfig" for more info.

hth
C
Reply With Quote
  #3  
Old 23rd November 2008, 09:38 PM
marcrblevins's Avatar
marcrblevins Offline
Registered User
 
Join Date: Jun 2006
Location: Texas
Age: 42
Posts: 4,168
You use yum to install those package right? If so, then chkconfig is the right way.
If you downloaded the package elsewhere that are not a .rpm file and manually installed it yourself, you are out of luck.
Reply With Quote
  #4  
Old 23rd November 2008, 10:55 PM
anitha2324 Offline
Registered User
 
Join Date: Jun 2007
Posts: 72
thanks for the reply


yes i have installed them using yum , i ll check chkconfig
Reply With Quote
  #5  
Old 24th November 2008, 05:34 PM
anitha2324 Offline
Registered User
 
Join Date: Jun 2007
Posts: 72
Exclamation

Hi thanks alot for the help

i have execute this command

#chkconfig mysqld on

and now mysql is starting automatically when the system boots ,

but am going to install some other services and i have to repeat the same thing for each service

, what i want now is permanent configuration which runs automatically all the services under /etc/init.d at the boot time and i will not be in need to execute such above command for any new installed service ,
Reply With Quote
  #6  
Old 24th November 2008, 05:54 PM
markkuk Offline
Registered User
 
Join Date: Apr 2005
Location: Finland
Posts: 5,076
Quote:
Originally Posted by anitha2324 View Post
, what i want now is permanent configuration which runs automatically all the services under /etc/init.d at the boot time and i will not be in need to execute such above command for any new installed service ,
No, you really don't want any such program. Only those services that you actually need should be configured to start at boot, and only after you have made all necessary configuration.
Reply With Quote
  #7  
Old 25th November 2008, 01:26 AM
LBCoder Offline
Registered User
 
Join Date: Oct 2008
Posts: 221
for FILE in `ls /etc/init.d`; do /sbin/chkconfig $FILE on; done

**** BUT DON'T DO IT!!!

Take a look at what is in the directory /etc/rc.d. Notice you have your init.d directory (/etc/init.d is actually just a symlink to /etc/rc.d/init.d), and you have a bunch of rcX.d directories. Each "X" is a runlevel (see "cat /etc/inittab"). Every time you start into runlevel 5, it runs all the "S*" scripts that are in /etc/rc.d/rc5.d. When it *leaves* runlevel 5, it runs all the "K*" scripts in the same directory. The "chkconfig" program creates symlinks in the various rcX.d directories to scripts in /etc/rc.d/init.d/.
Reply With Quote
  #8  
Old 25th November 2008, 01:33 AM
marko's Avatar
marko Offline
Registered User
 
Join Date: Jun 2004
Location: Laurel, MD USA
Posts: 5,449
Like post 7 says, chkconfig changes are persistent over boots.

If you want a nicer tool to setup services, try system-config-services
since it's a bit more efficient than chkconfig
Reply With Quote
Reply

Tags
initd, scripts, start

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

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 On
HTML code is Off

Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
Run scripts before init.d drunkahol Using Fedora 7 5th December 2007 10:19 AM
init scripts and ifup-tunnel HELP? diman Servers & Networking 0 26th January 2007 08:30 AM
Init scripts logged anywhere? philpem Using Fedora 0 4th November 2006 08:09 PM
user for init scripts, fc5 tobim Using Fedora 0 28th March 2006 09:02 PM


Current GMT-time: 06:36 (Thursday, 23-05-2013)

TopSubscribe to XML RSS for all Threads in all ForumsFedoraForumDotOrg Archive
logo

All trademarks, and forum posts in this site are property of their respective owner(s).
FedoraForum.org is privately owned and is not directly sponsored by the Fedora Project or Red Hat, Inc.

Privacy Policy | Term of Use | Posting Guidelines | Archive | Contact Us | Founding Members

Powered by vBulletin® Copyright ©2000 - 2012, vBulletin Solutions, Inc.

FedoraForum is Powered by RedHat