Go Back   The UNIX and Linux Forums > Top Forums > UNIX for Dummies Questions & Answers
Search Forums:



UNIX for Dummies Questions & Answers If you're not sure where to post a UNIX or Linux question, post it here. All UNIX and Linux newbies welcome !!

Reply    
 
Thread Tools Search this Thread Display Modes
    #1  
Old 02-08-2012
Registered User
 

Join Date: Jan 2009
Posts: 124
Thanks: 18
Thanked 0 Times in 0 Posts
question on init.d

Hi,

I added snmpd RPM. The main script is in /etc/init.d/ I went to each of the rc folder to check if SNMP is there or not. Just wondering if there is easy way to check other than cd to each folder to check if the service is there or not.
For example, this is what I did.

Code:
 
ls -l /etc/rc3.d/*snmp*
ls -l /etc/rc2.d/*snmp*
ls -l /etc/rc1.d/*snmp*

Sponsored Links
    #2  
Old 02-08-2012
in2nix4life's Avatar
Registered User
 

Join Date: Oct 2007
Location: East Coast
Posts: 144
Thanks: 0
Thanked 22 Times in 20 Posts
What OS are you using?
Sponsored Links
    #3  
Old 02-08-2012
methyl methyl is offline Forum Staff  
Moderator
 

Join Date: Mar 2008
Posts: 5,652
Thanks: 205
Thanked 560 Times in 539 Posts
Please post the results of the "ls" commands you post. On most unix O/S these would be soft links back to /etc/init.d (or some similar named directory) in which case you would only need to look for the original file. An init script should be written to react to the standard parameter "start" or "stop" which is provided by "rc" when unix changes run state.
I assume that "is there" means that the package is installed.
There will almost certainly be a parameter file which sets whether the service itself actually starts (read the init script to find the parameter file).
    #4  
Old 02-09-2012
Registered User
 

Join Date: Feb 2012
Location: India
Posts: 102
Thanks: 9
Thanked 2 Times in 2 Posts
# rpm -qlp httpd-2.2.3-53.el5.centos.i386.rpm | grep -i httpd

You can find where it will save the binary ...

--Shirish
Sponsored Links
    #5  
Old 02-09-2012
Registered User
 

Join Date: Jan 2009
Location: Pune ,India
Posts: 131
Thanks: 12
Thanked 22 Times in 22 Posts
this search the snmp inside /etc directory
find /etc -name "*snmp*"
Sponsored Links
Reply

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

More UNIX and Linux Forum Topics You Might Find Helpful
Thread Thread Starter Forum Replies Last Post
init-script failing because of /etc/rc.d/init.d/functions bakunin Red Hat 1 05-06-2011 07:46 AM
What is the diffe b/w init s and init S ranumala Solaris 6 10-22-2010 05:29 PM
Problem on init 0, execution is the same with init 6 Yenthanh UNIX for Advanced & Expert Users 2 09-16-2010 02:27 AM
Difference between 'init s' and 'init 1' praveen_b744 Red Hat 6 02-01-2010 02:25 PM
How to I change init levels after typing init 1 z1dane Linux 8 01-06-2010 07:37 PM



All times are GMT -4. The time now is 03:45 AM.