How to perform addition on a set of values from a file in bash script Every Unix Administrator has had this at some point… have written a script that extracts multiple rows with values in each column that you want to add up to get the total…. And every Unix Administrator will have written a… Read More »
How to extract emails from a PST file How to extract emails from a PST file using Bash on Centos How to extract emails from a PST file using Bash on Centos – Todays post explains something I have been looking to do for some time now to extract the email data from a PST… Read More »
In bash how to get the field before the last one? Parse field before last in bash shell script – An interesting piece of code today which could hit any system administrator who handles a lot of data parsing and processing, is how to extract some data from a comma seperated file when one of… Read More »
How to test if lftp has worked in bash script Hi everyone, one of the things I tend to do a lot when writing Bash Scripts is to create a lot of small and simple checking scripts for various functionality. I have been using lftp quite frequently with a client of mine for some time… Read More »
Bash remove duplicate lines without sorting One of the most frequent requirements I face when bash scripting, is to extract a column of data from an input file, find each unique value from within a number of rows, and then do something with that output. The standard way I achieve that is something like this… Read More »
Loops in bash are something Ive covered before, including parsing a file record by record (HERE), but one of the other uses I have frequently is a never ending script which watches something changing.
Run cron job every 90 mins Running a cron job is normally easy enough when you do not try and get over-complicated. Every hour or minute, or even every Monday is a simple task using the standard columns included in cron. Just to refresh you here are the first columns of a standard crontab for… Read More »
Im a guy who likes SOLUTIONS to issues, not neccesarily wanting or needing to know the reasons why something happens…. so heres another one… Bash – How to echo an exclamation mark So you would think something simple like this : echo “abcde!abcde” BUT echo “abcde!abcde” -bash: !abcde”: event not found Damn… ok the solution… Read More »