ℹ️
Continuation: This is Part 2 of the Linux Administration common issues series. See Part 1 for disk space, CPU/memory, networking, service failures, and file permissions.
06
User Authentication Issues
Covers SSH login failures, password expiry, incorrect shells, and PAM misconfigurations.
# Check if user account is locked:
passwd -S <username>
# Unlock account:
passwd -u <username>
# Fix shell issues:
usermod -s /bin/bash <username>
# Check auth logs:
tail -100 /var/log/secure # RHEL/CentOS
tail -100 /var/log/auth.log # Ubuntu/Debian
07
Package Management Errors
Fix broken dependencies, corrupted caches, and missing repositories.
# Debian/Ubuntu:
apt update && apt upgrade
apt --fix-broken install
dpkg --configure -a
# RHEL/CentOS:
yum clean all && yum update
yum-complete-transaction
dnf distro-sync
08
Kernel Panics / System Freezes
Check kernel logs for the panic reason. Update or rollback the kernel module that caused the crash.
# Check kernel panic messages:
dmesg | grep -i 'panic\|oops\|bug'
cat /var/log/kern.log | tail -200
# Boot previous kernel (GRUB):
# Restart → hold Shift → select previous kernel entry
# Disable a suspect module:
rmmod <module_name>
echo 'blacklist <module_name>' >> /etc/modprobe.d/blacklist.conf
09
SELinux / AppArmor Denials
A service with correct file permissions may still fail if SELinux or AppArmor blocks it. Use audit tools to diagnose and generate policy fixes.
# Check SELinux status:
getenforce
setenforce 0 # temporarily set Permissive for testing
# Diagnose denial:
audit2why < /var/log/audit/audit.log
# Generate and apply allow rule:
audit2allow -a -M mypolicy
semodule -i mypolicy.pp
10
Time Synchronisation Issues
Drifted clocks cause Kerberos authentication failures, SSL certificate errors, and log correlation problems.
# Check current time and sync status:
timedatectl
# Restart time sync service:
systemctl restart chronyd # RHEL/CentOS 7+
systemctl restart ntp # older systems
# Force immediate sync:
chronyc makestep
# Check sync sources:
chronyc sources -v
💡
SELinux workflow: When a service fails despite correct permissions, set SELinux to Permissive temporarily (
setenforce 0), test if the service starts, then use audit2allow to build the correct policy rather than leaving SELinux disabled.