Limit SSH User Logins
SSH logins can be limited to only certain users who need remote access. If you have many user accounts on the system then it makes sense to limit remote access to only those that really need it thus limiting the impact of a casual user having a weak password. Add an AllowUsers line followed by a space separated list of usernames to /etc/ssh/sshd_config. For example:
and restart the sshd service.
Disable Root Logins
SSH server settings are stored in the /etc/ssh/sshd_config file. To disable root logins, make sure you have the following entry:
# Prevent root logins:
PermitRootLogin no
and restart the sshd service:
If you need root access, login as a normal user and use the su command.
How to uninstall apf in linux machine
You can use the following steps to uninstall apf in a linux machine:
Stop the apf service running in the server.
$ /etc/rc.d/init.d/apf stop
Remove the apf files from the server.
$ rm -Rf /etc/apf
$ rm -Rf /etc/rc.d/init.d/apf
$ rm -Rf /var/log/apf_log
$ rm -Rf /var/log/apfados_log
$ rm -Rf /usr/local/sbin/apf
Disable apf in the run levels.
$ /sbin/chkconfig –level 345 apf off
Open up and remove this line:
$ vi /etc/cron.daily/fw
/etc/rc.d/init.d/apf restart >> /dev/null 2>&1
What is kjournald
kjournald:
It is for the journaling feature of the EXT3 file system. Kjournald is the journaling kernel thread for ext3 filesystem. One for each mounted ext3 filesystem.
# ps auxfw |grep kjournald
root 494 0.0 0.0 0 0 ? S< Jun17 27:45 \_ [kjournald]
root 1827 0.0 0.0 0 0 ? S< Jun17 0:00 \_ [kjournald]
root 2124 0.0 0.0 0 0 ? S< Jun17 0:23 \_ [kjournald]
Chkconfig
The chkconfig command can also be used to activate and deactivate services. If you use the chkconfig –list command, you will see a list of system services and whether they are started (on) or stopped (off) in runlevels 0-6 (at the end of the list, you will see a section for the services managed by xinetd.
If you use chkconfig –list to query a service managed by xinetd, you will see whether the xinetd service is enabled (on) or disabled (off). For example, the following command shows that finger is enabled as an xinetd service:
$ chkconfig –list finger
finger on
More importantly, chkconfig can be used to set a service to be started (or not) in a specific runlevel. For example, to turn nscd off in runlevels 3, 4, and 5, use the command:
chkconfig –level 345 nscd off