Using find in Linux

find /etc -type f -exec grep network \{\} –with-filename \; find /etc -type f -exec grep -i network \{\} –with-filename \; find /etc -type f -exec grep ‘\-\z’ \{\} –with-filename \; | less find /etc -type f -exec grep ‘\[\[‘ \{\} –with-filename \; find: find . -type f -exec grep -i mysearchstring \{\} –with-filename \; … Read more

Using vi in Linux

vi Singles: (Command executes immediately) iIaArRoOpPY DJxXu(U)sS~ insert, append, replace, open new line, paste, yank one line, delete to end of line, join 2 lines, delete chars, undelete, substitute, swap between upper and lower case Movement: (Command executes immediately) up/down/left/right kjhl CTRL+U CTRL+D wWeEbB number<ENTER-KEY> (jump that many lines down) Combo’s: yy (yank/copy 1 line) … Read more

Setting Routes in Linux

(Static Routes Page: static-routes.html) These methods of changing the route table don’t last accross reboots. Listed below are methods to make any of these changes permanent. Checking the route table in Linux netstat -rn route Adding and Removing a Network in Linux route add -net 10.10.10.0/24 gw 192.168.0.1 route del -net 10.10.10.0/24 gw 192.168.0.1 Adding … Read more

Linux Boot Process

The following is from /usr/src/linux-2.4/Documentation/initrd.txt When using initrd, the system typically boots as follows: 1) the boot loader loads the kernel and the initial RAM disk 2) the kernel converts initrd into a “normal” RAM disk and frees the memory used by initrd 3) initrd is mounted read-write as root 4) /linuxrc is executed (this … Read more