Skip to content
Archive of posts tagged awk

BASH Script Performace

Today we will look at some bash code snippests and the performance issues. Lets first look at the problem and the implemented solution: Problem: We needed to log the output of the ps command for all the process’s. This was required to be done on per minute basis and the output was required in comma [...]

Rekursive Grep on Solaris or AIX Systems without GNU egrep -r funcionality

If you work regularly on a Solaris or systems which do not have the “-r” (recursive grep) for grep, then you know what a lifesaver this command can be. Here is one from command line fu: find . -type f -exec awk ‘/linux/ { printf “%s %s: %s\n”, FILENAME, NR, $0; }’ {} \; The [...]

Linux hardware details.

Here is one of the scripts that I found on the net while searching for something … Note the URL for the script in the Description. #!/bin/bash – #=============================================================================== # # FILE: linux_hw.sh # # USAGE: ./linux_hw.sh # # DESCRIPTION: http://www.howtogeek.com/howto/solaris/get-the-processor-type-on-solaris/ # # OPTIONS: — # REQUIREMENTS: — # BUGS: — # NOTES: — # [...]