NiceToKnow.co.za

Useful tips, tricks and articles about Linux, Windows and computers in general

Search for

How To Start and Stop a Service in Linux

Date added: 2014-03-31 21:26:09
Platform: Linux
Tested on: Fedora 17

At some stage as a Linux user you will run into a scenario where you will have to start and stop services on your system.

To check the status of a service (for example Samba), run the following command from a terminal window:

systemctl status smb

This will check the status of the Samba (smb) service and tell you whether it is active or inactive.

To start a service, run the following command from a terminal window (obviously you will have to be root to execute this command):

systemctl start smb

This will start the Samba (smb) service.

To stop a service, run the following command from a terminal window (once again you will have to be root to execute this command):

systemctl stop smb

This will stop the Samba (smb) service.

Related Tips & Articles:

How To Enable or Disable a Service in The Linux Bootup