Solved

service and service status aix ibm

Posted on 2014-02-12
3
835 Views
Last Modified: 2014-02-12
is there anyway to list on aix ibm 5.3 or 6.1. or services installed as part of the OS and their status, i.e. running, disabled, and write the report out to txt file?

i know you can use commands such as # ps -ef |grep smbd for individual services, but with so many it would be easy to get a report in one go.
0
Comment
Question by:pma111
  • 2
3 Comments
 
LVL 68

Accepted Solution

by:
woolmilkporc earned 500 total points
ID: 39852868
Hi,

let's start with this one.

You can see all configured services and their status with

lssrc -a

For services which control "subservers", such as inetd or syslogd you can run e.g.

lssrc -ls inetd
lssrc -ls syslogd

to see their status.

Services without subservers but which provide statistics, such as sendmail or xntpd, can also be checked with "-ls", e.g.

lssrc -ls sendmail
lssrc -ls xntpd

The above applies to services under control of SRC, the "System Resource Controller".

There are a few services which are started "standalone" via inittab, such as utmpd.
These services can indeed in most cases only be checked with "ps".

Some demons provide their own mechanisms, such as errdemon. Its status can be viewed with

/usr/lib/errdemon -l

wmp
0
 
LVL 3

Author Comment

by:pma111
ID: 39852870
so lssrc -a >report.txt would write you a file with status?

are the results easy to interpret, i.e. does is have "running" "disabled" type outputs?
0
 
LVL 68

Expert Comment

by:woolmilkporc
ID: 39852979
- Yes
- Yes

Example "lssrc -a":
Subsystem         Group            PID          Status
 xntpd            tcpip            3145854      active
 portmap          portmap          2949256      active
 snmpd            tcpip            3408002      active
 snmpmibd         tcpip            3539052      active
 aixmibd          tcpip            3604724      active
 ypbind           yp               2490508      active
 biod             nfs              4522136      active
 nfsrgyd          nfs              4128900      active
 nfsd             nfs              5701808      active
 rpc.mountd       nfs              5374132      active
 rpc.statd        nfs              3735748      active
 rpc.lockd        nfs              4718772      active
 ...
 lpd              spooler                       inoperative
 ypserv           yp                            inoperative
 ypupdated        yp                            inoperative
 yppasswdd        yp                            inoperative
 keyserv          keyserv                       inoperative
 llbd             iforncs                       inoperative
 glbd             iforncs                       inoperative
 cdromd                                         inoperative
 LUMlmd           lumls                         inoperative
 LUMgdb           lumls                         inoperative
 i4lmd            iforls                        inoperative
 i4glbcd          iforncs                       inoperative
 i4gdb            iforls                        inoperative
 i4llmd           iforls                        inoperative
 muxatmd          tcpip                         inoperative
... 

Open in new window

Example "lssrc -ls inetd":
Subsystem         Group            PID          Status
 inetd            tcpip            19071026     active
Debug         Inactive
Signal        Purpose
 SIGALRM      Establishes socket connections for failed services
 SIGHUP       Rereads configuration database and reconfigures services
 SIGCHLD      Restarts service in case the service dies abnormally
Service       Command                  Arguments                Status
 swat         /opt/pware/sbin/swat     swat                     active
 xmquery      /usr/bin/xmtopas         xmtopas -p3              active
 time         internal                                          active
 daytime      internal                                          active
 time         internal                                          active
 echo         internal                                          active
 ntalk        /usr/sbin/talkd          talkd                    active
 systat       /usr/bin/ps              ps -ef                   active
 bootps       /usr/sbin/bootpd         bootpd /etc/bootptab     active
 login        /usr/sbin/rlogind        rlogind                  active
 shell        /usr/sbin/rshd           rshd                     active
 telnet       /usr/sbin/telnetd        telnetd -a -s            active
 ftps         /usr/sbin/ftpd           ftpd                     active
 ftp          /usr/sbin/ftpd           ftpd                     active

Open in new window

The above "inetd" settings are NOT secure (!), it's just an example.
0

Featured Post

Why You Should Analyze Threat Actor TTPs

After years of analyzing threat actor behavior, it’s become clear that at any given time there are specific tactics, techniques, and procedures (TTPs) that are particularly prevalent. By analyzing and understanding these TTPs, you can dramatically enhance your security program.

Join & Write a Comment

Using libpcap/Jpcap to capture and send packets on Solaris version (10/11) Library used: 1.      Libpcap (http://www.tcpdump.org) Version 1.2 2.      Jpcap(http://netresearch.ics.uci.edu/kfujii/Jpcap/doc/index.html) Version 0.6 Prerequisite: 1.      GCC …
Java performance on Solaris - Managing CPUs There are various resource controls in operating system which directly/indirectly influence the performance of application. one of the most important resource controls is "CPU".   In a multithreaded…
Learn several ways to interact with files and get file information from the bash shell. ls lists the contents of a directory: Using the -a flag displays hidden files: Using the -l flag formats the output in a long list: The file command gives us mor…
Learn how to find files with the shell using the find and locate commands. Use locate to find a needle in a haystack.: With locate, check if the file still exists.: Use find to get the actual location of the file.:

743 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

Need Help in Real-Time?

Connect with top rated Experts

16 Experts available now in Live!

Get 1:1 Help Now