Bash

This short article describe how to reset lost root password on Linux system. IMPORTANT: This method require physical access to the machine.

On GRUB screen select normal boot option:

1Press ‘e’ to edit selected option. You will see short GRUB code.

2

Search for the line starting with “linux /boot/vmlinuz…” or similar depending of Linux distribution. This is the place where kernel and rootfs is selected. Change ‘ro’ option to ‘rw’ and add: Continue Reading

The Awk tool has a several build-in variables which allow to navigate through a fields of processing text. One of them is a NF. A value of this variable is a number of fields in a current line. This simple example shows how useful is this variable when we don’t know how much columns has the input file.

This is a contents of our testing text file:

$ cat ./file.txt
abc     def     ghi
123     456     789
jkl     mno
321     654

Continue Reading