M01:
Introduction to Operating Systems |
TU1: Installing, configuring and exploiting
a computer system |
ASIX1 |
Practical Exercise 9: Managing services | 07-02-14 |
Practical
Exercise 9: Managing services
4- Adding o
removing a service during the system boot process
a) If you want to
totally remove a
service during the system
boot process you have to run the following command:
update-rc.d
-f
service_name remove
For intance, if you want to remove apache2 during the system boot process you have to run the following command:
update-rc.d -f apache2 remove
a) If you want to add a service during the system boot process you have to run the following command:
update-rc.d
service_name
defaults
For intance, if you want to add apache2 during the system boot process you have to run the following command:
update-rc.d
apache2
defaults
PRACTICAL
EXERCISE
1-
Find out the
following features of apache2
and cups, using
the GNOME
System Monitor: a) PID, b)
owner, c) status
and d) command-line.
2-
Using
a command-line tool, find out if ssh
is runnig or stopped. Take note of its PID and who its
owner is.
3- Using a command-line
tool, stop
the ssh service.
Check
if that service has been stopped using a command-line tool.
4- Using a command-line tool, start the
ssh service.
Check if that service is running again using a command-line
tool. Check
its PID. Any change?.
5- Using a command-line tool, restart
the ssh service.
Using a command-line tool, check if that service is running.
Check its
PID. Any change?.
6- Check the status of all
your
system network services. Could you tell me if apache2, ssh and
cups
ares network services?. Why?
7- Check
the status of apache2,
cups and ssh using netstat
and one single
command (*1).
8- Check the running level of your system. Show services
which
start during the computer boot process.
9- Remove apache2 and ssh as services started by
the
computer during the boot process. Reboot your system and check
that
both services are not running.
10- Add apache2 and ssh as services started by
the
computer during the boot process. Reboot your system and check
that
both services are running.
(*1) -->
Help: grep
-E '(cups|ssh|apache)'.