• Categories
    Category
    {{ postCtrl.tags }}
    • {{ category.tag_type }}

      • {{tag.tag_name}}
      • View more
  • Categories
    Category
    {{ postCtrl.tags }}
    • {{ category.tag_type }}

      • {{tag.tag_name}}
      • View more
  • News
  • Tutorials
  • Forums
  • Tags
  • Users
Tutorial News Comments FAQ Related Articles

How to remove unwanted service in your Linux system

{{postValue.id}}

To Stop and Disable unwanted service in your Linux system

In this article let us discuss how to remove the unwanted service and packages which is installed automatically without the user permission while setting up the server. These services consumes more system resource and slows down your system boot up process.

To show all process and Services

Use ps command to display currently running process with process id.

Example

[root@linuxhelp Desktop]# ps ax
PID  TTY     STAT   TIME COMMAND
1    ?       Ss     0:01 /sbin/init
2    ?       S      0:00 [kthreadd]
3    ?       S      0:00 [migration/0]
4    ?       S      0:00 [ksoftirqd/0]
5    ?       S      0:00 [migration/0]
6    ?       S      0:00 [watchdog/0]
7    ?       S      0:07 [events/0]
8    ?       S      0:00 [cgroup]
9    ?       S      0:00 [khelper]
10   ?       S      0:00 [netns]
11   ?       S      0:00 [async/mgr]
.
.
.
.
4371 ?       Sl     0:00 /usr/bin/gnome-terminal -x /bin/sh -c cd ' /root/Deskt
4372 ?       S      0:00 gnome-pty-helper
4373 pts/0   Ss     0:00 /bin/bash
4385 pts/0   R+     0:00 ps ax

To display all available services

Run the service command to display all available services in your system.

Example

[root@linuxhelp Desktop]# service --status-all
abrt-ccpp hook is installed
abrtd (pid 1899) is running...
abrt-dump-oops is stopped
acpid (pid 1680) is running...
atd (pid 1954) is running...
auditd (pid 1439) is running...
automount (pid 1788) is running...
bgpd is stopped
Usage: /etc/init.d/bluetooth {start|stop}
certmonger (pid 2064) is running...
Running
cgred is stopped
conmand is stopped
cpuspeed is stopped
crond (pid 1943) is running...
cupsd (pid 1655) is running...
cyrus-imapd is stopped
dhcpd is stopped

Stop the process

If you want to kill the running process use kill command.

Example

[root@linuxhelp Desktop]# kill -9 1913
[root@linuxhelp Desktop]# service httpd status
httpd dead but pid file exists

To disable the service

In red Hat distribution basically chkconfig command is used to start and stop the services.

Example

[root@linuxhelp Desktop]# chkconfig httpd of

After this chkconfig you must restart your system. After restarting the “ httpd” service, it does not start automatically. Because we have stopped that httpd service.

Example

[root@linuxhelp Desktop]# service httpd status
httpd is stopped

If you use kill command it stops the service temporarily. If you want to stop unwanted service you use chkconfig command.

To stop and disable the services in graphical mode

Following procedure is used to stop and disable the unwanted service in graphical mode.

First Go to task bar and choose system.

system

Next choose Administration option and select Service options.

Administration

Now you can see Service configuration dialogue box.

service config

Let' s choose httpd service

httpd

The httpd service is stopped in the service configuration.

httpd service

Next start httpd service again. Click start button.

service start

Now to disable the httpd service. click disable button.

service disable

Now you can see this httpd service is in disable mode.

service config disable

Next I’ m going to enable this service. Click enable button.

service enable

Now you can see this service is enabled.

httpd service enabled

Tags:
liam
Author: 

Comments ( 0 )

No comments available

Add a comment
{{postCtrl.cmtErrMsg}}

Frequently asked questions ( 5 )

Q

In my RHEL 7 "chkconfig" throws command not found error?

A

In RHEL/Centos 7 chkconfig command will not work in which you can use "systemctl enable service name"

Q

How can I check process running under a particular port?

A

Use lsof -i: port number for checking the status of it.

Q

What is the purpose of using chkconfig?

A

If you enable a service in chkconfig the service remains enabled on every boot.

Q

How to kill a process ?

A

Use ps -ax grep with the service and provide pkill PID to kill them.

Q

How can I display all the running services?

A

Use service --status-all option for it.

Back To Top!
Rank
User
Points

Top Contributers

userNamenaveelansari
135850

Top Contributers

userNameayanbhatti
92510

Top Contributers

userNamehamzaahmed
32150

Top Contributers

1
userNamelinuxhelp
31040

Top Contributers

userNamemuhammadali
24500
Can you help Owen ?
How to add SSH key to my Gitlab account

I need to add the SSH key in my gitlab account. How to do so ????

Networking
  • Routing
  • trunk
  • Netmask
  • Packet Capture
  • domain
  • HTTP Proxy
Server Setup
  • NFS
  • KVM
  • Memory
  • Sendmail
  • WebDAV
  • LXC
Shell Commands
  • Cloud commander
  • Command line archive tools
  • last command
  • Shell
  • terminal
  • Throttle
Desktop Application
  • Linux app
  • Pithos
  • Retrospect
  • Scribe
  • TortoiseHg
  • 4Images
Monitoring Tool
  • Monit
  • Apache Server Monitoring
  • EtherApe 
  • Arpwatch Tool
  • Auditd
  • Barman
Web Application
  • Nutch
  • Amazon VPC
  • FarmWarDeployer
  • Rukovoditel
  • Mirror site
  • Chef
Contact Us | Terms of Use| Privacy Policy| Disclaimer
© 2025 LinuxHelp.com All rights reserved. Linux™ is the registered trademark of Linus Torvalds. This site is not affiliated with linus torvalds in any way.