diff --git a/README.md b/README.md index 6b303eb..f37bc40 100644 --- a/README.md +++ b/README.md @@ -744,6 +744,7 @@ Linux Security Expert - trainings, howtos, checklists, security tools an * [tr](#tool-tr) * [chmod](#tool-chmod) * [who](#tool-who) + * [last](#tool-last) * [screen](#tool-screen) * [du](#tool-du) * [inotifywait](#tool-inotifywait) @@ -1246,6 +1247,16 @@ who -b ___ +##### Tool: [last] + +###### Was the last reboot a panic? + +```bash +(last -x -f $(ls -1t /var/log/wtmp* | head -2 | tail -1); last -x -f /var/log/wtmp) | grep -A1 reboot | head -2 | grep -q shutdown && echo "Expected reboot" || echo "Panic reboot" +``` + +___ + ##### Tool: [screen](https://en.wikipedia.org/wiki/GNU_Screen) ###### Start screen in detached mode