Librenix
Headlines | Linux | Apps | Coding | BSD | Admin | News
Information for Linux System Administration 

Detailed Error Handling In Bash

Up
vote
Down

Shell scripts are often running as background processes, doing useful things without running in a visible shell. To write such scripts can be quite painful, as all errors occur out of sight as well. While log files can hold a lot of information, finding the relevant information is a bit trickier. My solution is to log only the errors with all the details to a small database. This database contains tables for the message, the corresponding stack trace and the important environment variables. I have chosen for an SQLite database in this howto, but the same principle works with other databases as well.
 read more | mail this link | score:9748 | -falko, February 21, 2013
More Programming articles...

Large Canvas Abstract Art Prints

coding headlines

No Starch Press has published my Perl One-Liners book!

OpenShift Online: a non-developer guide

Tutorial: Create an NFS-like Storage Server with GlusterFS on Ubuntu 12.10

Develop your own Raspberry Pi OS

E-book: Perl One-Liners Explained

Debugging Shell Scripts

 

Firefox sidebar

Site map

Site info

News feed

Features

Login
(to post)

Search

 
Articles are owned by their authors.   © 2000-2012 Ray Yeargin