LinuxQuestions.org
Welcome to the most active Linux Forum on the web.
Home Forums Tutorials Articles Register
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 06-28-2016, 06:28 AM   #1
QWE123
Member
 
Registered: Nov 2014
Posts: 55

Rep: Reputation: Disabled
command list of all service is running


I use Redhat 6.5 , and want to list all service are running in the system , I found there are two command can do that .

#service --status-all |more
#chkconfig --list |more

I have two questions .

1) the second command ( chkconfig ) seems show more service are running , may I know what is the difference of these two command ?

2) some services can not show in these two command , may be it is because these services are not installed by yum , if so , how can I list ALL services are running includes such kind of services ?

Thanks
 
Old 06-28-2016, 07:14 AM   #2
business_kid
LQ Guru
 
Registered: Jan 2006
Location: Ireland
Distribution: Slackware, Slarm64 & Android
Posts: 16,292

Rep: Reputation: 2322Reputation: 2322Reputation: 2322Reputation: 2322Reputation: 2322Reputation: 2322Reputation: 2322Reputation: 2322Reputation: 2322Reputation: 2322Reputation: 2322
Have you tried
Code:
ps -e
 
Old 06-28-2016, 07:28 AM   #3
Turbocapitalist
LQ Guru
 
Registered: Apr 2005
Distribution: Linux Mint, Devuan, OpenBSD
Posts: 7,308
Blog Entries: 3

Rep: Reputation: 3721Reputation: 3721Reputation: 3721Reputation: 3721Reputation: 3721Reputation: 3721Reputation: 3721Reputation: 3721Reputation: 3721Reputation: 3721Reputation: 3721
Those ways will show which ones are officially installed and what their official settings are. You can see all the processes that are actively running and listening using "netstat"

Code:
netstat -ntlp
Hopefully it will be a subset of those officially installed.

It's best to stick with programs installed via the package manager only, since that makes them far easier to maintain and keep track of.
 
Old 06-28-2016, 07:55 AM   #4
pan64
LQ Addict
 
Registered: Mar 2012
Location: Hungary
Distribution: debian/ubuntu/suse ...
Posts: 21,842

Rep: Reputation: 7308Reputation: 7308Reputation: 7308Reputation: 7308Reputation: 7308Reputation: 7308Reputation: 7308Reputation: 7308Reputation: 7308Reputation: 7308Reputation: 7308
would be nice to show some examples, what do you really mean
 
Old 06-28-2016, 07:58 AM   #5
jpollard
Senior Member
 
Registered: Dec 2012
Location: Washington DC area
Distribution: Fedora, CentOS, Slackware
Posts: 4,912

Rep: Reputation: 1513Reputation: 1513Reputation: 1513Reputation: 1513Reputation: 1513Reputation: 1513Reputation: 1513Reputation: 1513Reputation: 1513Reputation: 1513Reputation: 1513
Quote:
Originally Posted by QWE123 View Post
I use Redhat 6.5 , and want to list all service are running in the system , I found there are two command can do that .

#service --status-all |more
#chkconfig --list |more

I have two questions .

1) the second command ( chkconfig ) seems show more service are running , may I know what is the difference of these two command ?
chkconfig shows all POSSIBLE services and their state in each of the run levels (around 6). If you see the word "ON" then it should be started when the system in the corresponding run level.
Quote:

2) some services can not show in these two command , may be it is because these services are not installed by yum , if so , how can I list ALL services are running includes such kind of services ?
The only way to see what is running on the system is by using the "ps" command (process status), or "top" (which sorts the list before displaying it, and repeats on a time interval).
Quote:

Thanks
 
  


Reply



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
is there a command that will list all running services baronobeefdip Linux - General 7 10-27-2014 03:48 PM
Running service command as root in a daemon on RHEL 6.5 linuxuser26 Red Hat 2 09-12-2014 11:22 AM
just wondering if my code is sound for running a command remotely on server list wlandymore Linux - Newbie 3 05-24-2013 10:58 PM
Solaris 9: could not run `svcs` to list service running teppyvn Solaris / OpenSolaris 4 04-24-2009 12:02 AM
Command to list all running processes GSX Linux - General 4 02-23-2005 03:42 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie

All times are GMT -5. The time now is 06:21 PM.

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
Open Source Consulting | Domain Registration