Showing posts with label Unix/Linux. Show all posts
Showing posts with label Unix/Linux. Show all posts

Wednesday, February 18, 2009

How to find a file in the current directory/subdirectories by ignoring the errors?

find . -name "<filename.extension>" 2>/dev/null

How to find the time it took a command to complete execution?

time <Command Name With Parameters>

Tuesday, February 17, 2009

How to find files in the current directory/sub-directories that contain the search string?

find . | xargs grep "<searchstring>"

Thursday, February 12, 2009

How to Identify your login shell?

grep $LOGNAME /etc/passwd