One of the things I do after an installation is to disable services that I will never need.
The below code window shows four ways I use to view the status of a service. All of these commands are installed by default in MX-18, 19 and 21.
The first command will show the status of all the services.
The second will show the status of one service.
The third shows the status of only enabled services.
The fourth (
sysv-rc-conf) will show services in a SysV runlevel configuration table. The arrow keys are used to select run levels that a particular service will run, but may be a little more difficult for removing a service because all the enabled levels will have to be toggle off.
Code: Select all
sudo service --status-all
sudo service <service> status
systemctl list-unit-files --type=service --state=enabled
sudo sysv-rc-conf
I use the following command to disable a service from all run levels:
Code: Select all
sudo update-rc.d <service> disable
To add, disable, enable, or remove a service with update-rc.d:
Code: Select all
sudo update-rc.d <service> defaults (add service)
sudo update-rc.d <service> disable (disable service with init script available)
sudo update-rc.d <service> enable (enable service)
sudo update-rc.d <service> remove (remove service)
While you said you were interested in removing services that "listen unnecessarily" I though you might be interested in the services that I disabled (MX-18, 19, and 21) because I have no need for them:
avahi-daemon (I don't use printers)
bluetooth (I don't use bluetooth)
cups (I don't use printers)
cups-browsed (I don't use printers)
*nfs-common (I don't have a NFS)
nfs-kernel-server (I don't have a NFS)
nmbd (I don't use samba)
pppd-dns (I don't use dial-up Internet)
*rpcbind (I don't use NFS)
*saned (I don't have a scanner)
smbd (I don't use samba)
* These required a reboot for the disabled status to show.