Remove from multiple directories

To remove from mutliple directories.

Use the below regex on the remove command.

rm {1..2}/somedir/somefile*


Command Description
grep . /proc/sys/net/ipv4/* List the contents of flag files
set | grep $USER Search current environment
tr ” ‘\n’ < /proc/$$/environ Display the startup environment for any process
echo $PATH | tr : ‘\n’ Display the $PATH one per line
kill -0 $$ && echo process exists and can accept signals Check for the existence of a process (pid)
find /etc -readable | xargs less -K -p’*ntp‘ -j $((${LINES:-25}/2)) Search paths and data with full context. Use n to iterate
namei -l ~/.ssh Output attributes for all directories leading to a file name
Low impact admin
# apt-get install “package” -o Acquire::http::Dl-Limit=42 \
-o Acquire::Queue-mode=access
Rate limit apt-get to 42KB/s
echo ‘wget url’ | at 01:00 Download url at 1AM to current dir
# apache2ctl configtest && apache2ctl graceful Restart apache if config is OK
nice openssl…

View original post 1,018 more words

good list



Command Description
apropos whatis Show commands pertinent to string. See also threadsafe
man -t ascii | ps2pdf – > ascii.pdf make a pdf of a manual page
which command Show full path name of command
time command See how long a command takes
time cat Start stopwatch. Ctrl-d to stop. See also sw
dir navigation
cd – Go to previous directory
cd Go to $HOME directory
(cd dir && command) Go to dir, execute command and return to current dir
pushd . Put current dir on stack so you can popd back to it
file searching
alias l=’ls -l –color=auto’ quick dir listing
ls -lrt List files by date. See also newest and find_mm_yyyy
ls /usr/bin | pr -T9 -W$COLUMNS Print in 9 columns to width of terminal
find -name ‘*.[ch]’ | xargs grep -E ‘expr’ Search ‘expr’ in this…

View original post 2,259 more words