Last active 1 month ago

helpful-commands.sh Raw
1sudo mkdir /mnt/sys
2sudo mount -o ro /dev/sdXN /mnt/sys # find the right partition with lsblk first
3sudo smartctl -a /dev/sdX # look for reallocated sectors, pending sectors, offline uncorrectable
4sudo fsck -n /dev/sdXN # dry-run check, don't fix yet
5
6chroot /mnt/sys /bin/bash # after binding /dev /proc /sys in
7cat /etc/passwd # any new/unexpected user accounts?
8cat /etc/shadow # password hash changed on admin account?
9last -f /var/log/wtmp # login history, any logins melo doesn't recognize?
10systemctl list-units --state=enabled | less # anything unfamiliar enabled?
11crontab -l -u root # rogue cron jobs?
12ls -la /etc/systemd/system/ # anything dropped in that shouldn't be there?