- Apache error_log files BackEnd errors: grep -r -h --include=error_log Backend . | awk '{print $2 " " $3}'| sort | uniq -c
- Oracle connections: while true; do netstat -an|grep 1521; netstat -an|grep 1521|wc -l; echo "+++++++++++++++++++"; sleep 4; done;
Showing posts with label unix. Show all posts
Showing posts with label unix. Show all posts
Thursday, April 16, 2009
Unix commands help on diagnosing Weblogic problems
While working on diagnosing the Weblogic problems, I found the unix commands help me a lot, here they are:
Thursday, August 16, 2007
bash shortcuts
Here is a list of bash shortcuts, credit to this blog.
alt-f -- move forward one word
alt-b -- move backwards one word
ctrl-a -- takes you to the begining of the command you are currently typing.
ctrl-b -- move backwards one character
ctrl-c -- kills the current command or process.
ctrl-d -- kills the shell.
ctrl-e -- takes you to the end of the command you are currently typing in.
ctrl-f -- move forward one character
ctrl-h -- deletes one letter at a time from the command you are typing in.
ctrl-l -- clear screen
ctrl-r -- does a search in the previously given commands so that you don't have to repeat long command.
ctrl-u -- clears the typing before the hotkey.
ctrl-z -- puts the currently running process in background
esc-b -- takes you back by one word while typing a command.
esc-p -- like ctrl-r lets you search through the previously given commands.
esc-. -- gives the last command you typed.
Another good reference.
Here "2T" means Press TAB twice
$ 2T - All available commands(common)
$ (string)2T - All available commands starting with (string)
$ /2T - Entire directory structure including Hidden one
$ 2T - Only Sub Dirs inside including Hidden one
$ *2T - Only Sub Dirs inside without Hidden one
$ ~2T - All Present Users on system from "/etc/passwd"
$ $2T - All Sys variables
$ @2T - Entries from "/etc/hosts"
$ =2T - Output like ls or dir
alt-f -- move forward one word
alt-b -- move backwards one word
ctrl-a -- takes you to the begining of the command you are currently typing.
ctrl-b -- move backwards one character
ctrl-c -- kills the current command or process.
ctrl-d -- kills the shell.
ctrl-e -- takes you to the end of the command you are currently typing in.
ctrl-f -- move forward one character
ctrl-h -- deletes one letter at a time from the command you are typing in.
ctrl-l -- clear screen
ctrl-r -- does a search in the previously given commands so that you don't have to repeat long command.
ctrl-u -- clears the typing before the hotkey.
ctrl-z -- puts the currently running process in background
esc-b -- takes you back by one word while typing a command.
esc-p -- like ctrl-r lets you search through the previously given commands.
esc-. -- gives the last command you typed.
Another good reference.
Here "2T" means Press TAB twice
$ 2T - All available commands(common)
$ (string)2T - All available commands starting with (string)
$ /2T - Entire directory structure including Hidden one
$ 2T - Only Sub Dirs inside including Hidden one
$ *2T - Only Sub Dirs inside without Hidden one
$ ~2T - All Present Users on system from "/etc/passwd"
$ $2T - All Sys variables
$ @2T - Entries from "/etc/hosts"
$ =2T - Output like ls or dir
Thursday, April 26, 2007
while loop on unix shell command line
Would like to repeat the ls -l command on unix command line every 30 seconds?
$ while true; do ls -l; sleep 30; done;
$ while true; do ls -l; sleep 30; done;
Subscribe to:
Posts (Atom)