Oracle Shell Scripting Now Available!

Oracle Shell ScriptingExactly 15 months after I first posted about it my book Oracle Shell Scripting: Linux and UNIX Programming for Oracle has finally been printed and is available!

The book offers an introduction to shell scripting, an in-depth look at many useful shell commands and tools and a bunch of example scripts to use as-is or as a basis for your own custom scripts. As a long-time database and system administrator I have compiled some of the best tools, tips and tricks I have found for administration, monitoring and automation of DBA tasks.

I know you’re just dying to go out and get it, but it will probably take a couple weeks for it to hit book stores and Amazon. The best way to buy the book is directly from the publisher. They have it in stock and ready to go.

I will be posting more about the book here in the near future. It really covers a lot of what I have learned in my professional career and I’m thrilled at the opportunity to share my experience in this form. If you have questions about the book please feel free to leave a comment. I don’t always get to my comments quickly, but I do read and reply to all of them.

unix, oracle, shell scripting, linux, book, database tuning, database administration, database security

Get rid of color ‘ls’ output in Linux

Color ls outputMany popular varieties of Linux use a “feature” which causes the ls command output to show files, directories, links, etc. all in different colors. I guess some people prefer this, but I find it at best annoying, and at worst illegible. Specifically the color-coding of symbolic links tend to show in such a light color that it is often impossible to read.

The color output is accomplished by adding the --color=tty or a similar option to the ls command. This is typically accomplished by creating an alias to ls in either the user’s profile or in one of the system-wide profiles.

alias ls='ls --color=tty'

My personal preference is to remove this line from any system-wide configuration files (such as /etc/profile) and allow users to set it in their own profile if preferred. If you don’t have the desire or ability to make this change universally than a user can easily disable the color output by using the unalias command:

unalias ls

This can either be added to the user’s configuration file (e.g. the .profile or .bash_profile in their home directory), or you can just type unalias ls anytime to disable color ls output for the rest of the current shell session. This can be especially useful to turn off the color output when you’re working on someone else’s system.

Color-coded ls output can cause permissions errors in some circumstances, so in my opinion it is best left off, but if you’re stuck with it then it’s nice to know how it can be disabled when necessary.

ls, sysadmin, system administration, linux, shell, bash, sh, UNIX

You find it in the strangest places…

Humor me for a moment and read the following statements:

“If there are any competent Asians, I failed to meet them.”

Asian or Arab origin people are incompetent. My point is proved by the fact that they have always been slaves and will remain in such conditions. The west has always dominated the east.

I know what you’re thinking, there’s a lot of shit out there on the net, but would you believe that this racist garbage is tolerated on the forums of Oracle’s own website?

And if you think the statements above are bad (or you think I have somehow taken it out of context) you should read the whole thread. It’s amazing that (allegedly) educated professionals can be so ignorant.

More amazing to me is that Oracle doesn’t pursue and remove these posts. After all, for every person who will speak up against this racist crap there are ten who will just leave with a bad taste for the people who host the content.

oracle, racism, racist, prejudice

Oracle 11g, automatic features and a few warnings

If you’re an Oracle DBA like me you are probably wondering how 11g, Oracle’s most recent release, will affect you. Don Burleson who points out some great new features of 11g:

The new Oracle data compression utility promises to save on disk storage up to three times over storing data in an uncompressed format, with relatively small overhead.

SPA [SQL Performance Analyzer] is one of the most exciting features. It’s a holistic tuning tool that allows you to define and replay a representative workload on your database.

And some appropriate warnings:

Oracle has created artificial intelligence to advise on self-healing operations, and these are often misunderstood and misapplied by people without the requisite background.

Check out the whole article, and if you have a chance be sure to catch Don’s 11g New Features presentation! I was lucky enough to see it before my presentation at the North Carolina Oracle User Group meeting a few weeks ago and learned a lot!

oracle, database, dba

What’s in a name?!

I make no secret of the point that I love the webcomic xkcd and if I blogged every strip I like I would basically end up mirroring the entire comic here.

With that in mind, there is no way I could pass up posting this commic:

xkcd - Exploits of a Mom

Next time someone asks you what a SQL injection is you can point them at this, then explain nicely.

sql, oracle, pl/sql, plsql, exploit, security, sql exploit, dba, database, database administration, comic, fun, funny, sql injection