Bash Cookbook 278
Chad_Wollenberg writes "Anyone who has used a derivative of Unix over the past 20 years has used Bash, which stands for Borne Again Shell. The geek in all of us makes us want to extend our ability to rule the command line. To truly master a Unix environment, you need to know a shell, and Bash is easily the most popular of them. Any Unix/Linux/BSD administrator knows the power at your fingertips is fully extended by what you can do within the Bash environment, and all of us need the best recipes to get the job done." Keep reading for the rest of Chad's review.
Enter Bash Cookbook. Properly named for the series of O'reilly books that gives you valuable information on subjects in the form of recipes, this book was refreshing in that it was properly organized, and surprisingly contemporary, even citing Virtualized platforms as a way to try out different OS's for Bash. The book does a good job of pointing out the different operating systems that do run Bash, even citing Cygwin for Windows. They also use the POSIX standard, so that all of the examples are portable across platforms.Bash Cookbook | |
author | Carl Albing, JP Vossen, Cameron Newham |
pages | 598 |
publisher | O'Reilly |
rating | 9 |
reviewer | Chad Wollenberg |
ISBN | 978-0-596-52678-8 |
summary | A good book for intermediate and above users of Bash |
Bash Cookbook is by no means for the feint of heart. It seems that the book is meant for intermediate and above users of Bash. However, the first several chapters do a significant job of over viewing basic concepts of Bash navigation and combing simple commands. The book quickly changes gears to complex statements on how to get things done in Bash.
By Chapter 7, Bash Cookbook extends out of Bash commands and begins exploring combining the power of bash scripting with useful command such as grep, awk, and sed. To quote the authors, "if our scripting examples are going to tackle real-world problems, they need to use the wider range of tools that are actually used by real-world bash users and programmers." And that is exactly what they do. This chapter alone gave me the ability to do more in the command line environment simply by explaining the functions of the scripts put forth. That is something that any reader, intermediate to expert, can take from this book. The detailed explanations really do give everyone the ability to learn something about the commands, and the references to additional resources often lead me to the computer, looking up further details.
I found Chapter 11 to be very useful (pun intended) finally grasping some concepts on the find command that have previously escaped me. From Chapter 12 on, the book focuses on writing useful and complex scripts. This is where the book really begins to shine for the Unix enthusiast and system administrator. The scripts found in Chapter 12, and their elaborate descriptions begin to show the true power of Bash scripting, and how much you can automate. Chapter 14 is about securing your scripts, and is a heavy read, but well worth reading for any administrator that would be using their scripts in a production environment.
Just when you think this book has reached its limits, it gives very handy customization examples in Chapter 16 on how to configure and customize Bash. And also goes into common mistakes made by the novice user. Combine all of that with the Appendices for quick reference, and this book has not left my side since it arrived. While I would not recommend this book for the novice user, I would recommend this book to any system administrator that has to work with Unix or Linux. If nothing else, the examples given here are full of good, reusable code to make tasks easier in your day to day functions. Well done.
You can purchase Bash Cookbook from amazon.com. Slashdot welcomes readers' book reviews -- to see your own review here, read the book review guidelines, then visit the submission page.
"feint" of heart? (Score:5, Funny)
So, what, does this refer to people who act like they're going to rip your heart out of your chest, only it all turns out to be a ruse so they can kick you in the balls?
Re:BASH != Bourne Shell (Score:5, Funny)
<begin file A>
#!/bin/bash
perl <<EOP
print "hello world\n";
EOP
<end file A>
<begin file B>
#!/bin/sh
perl <<EOP
print "hello world\n";
EOP
<end file B>
See? Both work, it's so easy!
Re:BOURNE (Score:5, Funny)
It's the Born again Bourne Again shell. Now with more Jesus.
Bash cookbook? (Score:5, Funny)
Well, ok... Cookbook sucks!
Oh, did I parse that wrong?
Comment removed (Score:2, Funny)
Re:Nice review, but I don't understand something. (Score:5, Funny)
Okay, somebody had to say it.
Re:BOURNE (Score:2, Funny)
Crackers or wine?
Re:Bourne-Again Shell (Score:5, Funny)
Seriously now, this is like posting a LOTR review by someone who thinks it was written by RJ Tokelen. Or a Star Trek review from a fan of "the late Rod N. Barry".
You gotta love our editors!
Anyway, back to my review of Dark Night... Chris Nolon did it again!
Obligatory. (Score:4, Funny)
http://xkcd.com/149/ [xkcd.com]
Holding Out (Score:3, Funny)
I'm still waiting for jbosh, the Jason BOurne SHell, to be released. I hear it can really kick some ass.
Re:Shell as a general-purpose language... (Score:1, Funny)
+1 bowing to my new master...
To Serve Webpages (Score:4, Funny)
It's a cookbook!!!
Re:Shell as a general-purpose language... (Score:5, Funny)
He'd written a particle physics Monte Carlo sim using Bash and Linux command line tools (in particular, there were calls to bc everywhere).
Well, I, for one, welcome our new particle physicist bash programming overlord!
Re:Holding Out (Score:5, Funny)
Do you really want a shell that runs out of memory and starts killing all of your processes?
Feminists don't need this book (Score:5, Funny)
They can just enter "man bash" on the command line
Re:Bourne-Again Shell (Score:2, Funny)
Are you saying the poster had a problem with The Bourne Identity [imdb.com]?
Re:Shell as a scripting language... (Score:4, Funny)
What are these "datastructures" you speak of?
And faint of heart (Score:5, Funny)
And it's "faint of heart" not "feint of heart".
And it would be "overviewing basic concepts" not "over viewing basic concepts" if "overview" were a verb.
I made it as far as:
before threwing in the trowl.
--MarkusQ
Re:BASH != Bourne Shell (Score:3, Funny)
Re:It's for people like me. (Score:3, Funny)
Dude, seriously? Where? Cool!
Oh, wait, you were being sarcastic. Dammit. Don't get my hopes up like that.
Re:Nice review, but I don't understand something. (Score:1, Funny)
Re:BASH != Bourne Shell (Score:5, Funny)
I'd stick a rocket up the arse of anyone who sent me a product that wouldn't install because of a basic, newbie mistake like that.
You'd need a lot of rockets. In my experience, this sort of error is very, very common.
Re:And faint of heart (Score:2, Funny)
before threwing in the trowl.
I should of done the same. I don't like picking apart people's writings, but it's a doggy-dog world.
Re:Shell as a general-purpose language... (Score:4, Funny)
Bash scripting is dangerous. I wrote a client script to test a Helix multimedia server, once - we're talking millions of socket connections purely from a shell here (not even using netcat), and the professor gave us a B+ for the project. Needless to say, I wrote another script that summer, much smaller and more elegant, that thrashed and brought down the clueless bastard's website.
Parents: talk to your kids about Bash, before someone else does.
Re:It's for people like me. (Score:5, Funny)
A good analogy is like a car.
No. A good analogy is like a metaphor.
Re:BOURNE (Score:2, Funny)
Yes. Just don't fsck without intending to mkfs, or you'll be sent straight to /dev/null.
Re:And faint of heart (Score:1, Funny)
I could care less about things like that. Noone is perfect.