Linux

lsof

Check which process has directory open or files within

lsof +d /var/lib/libvirt

Check recursively in directory which files are open by which process

lsof +D /var/lib/libvirt

Print bytes used by 'deleted' files.

lsof |grep deleted |awk '{s=(s+$8)} END {print s " bytes"}'

stat

stat

stat -c "%a %U:%G %n" /usr/bin/ping

unlock a user after failed password tries:

When you type the wrong password a few times, mostly 3, your account might get locked for a timeout. Often 10min To unlock your user again do the following:

Login as root. (without sudo)

Check if your user is actually blocked

faillock --user myUsername

Reset the failed attempts, unlocking the user

faillock --user myUsername --reset

boot in single user mode

at the end of the linux line in grub:

init=/bin/bash

or the following. Which will start a root shell on tty9

systemd.debug_shell