Monthly Archives: April 2012

Confessions of a Monitoring Junkie

You may be asking yourself, “Self, why should I cough up cash for SQL Monitor or spend time (or pay someone to spend time) setting up Nagios?”

The answer, of course, is:  Do you want to know something is wrong now, or when a customer calls you and says their app is broken and they can’t do business?

(By the way, I don’t care if you’re a nonprofit.  They’re still a customer who can’t do business.  The students can’t print their term papers, the web site can’t take donations, they can’t do business.  As you were.)

You’ll also learn unexpected things, like that the last time you patched settings you made were changed by the patch, or that that relatively small customer is beating your server when you’re not looking.

I’m going to briefly discuss the two products I’ve used that I like, and will politely ignore the one that I was less taken with. (To be fair, I think their implementation is less mature and they’ll improve.)

If you don’t have Microsoft SQL Server, you’re going to want to skip down to Nagios.  If you do, read on, McDuff.

Thus far, I’ve found Red Gate’s SQL Monitor to be really nice right out of the box.  You give it credentials, and it starts nomming up your disk space with shiny happy data.  The very first day I had it installed, our sysadmin came over and asked me, “Do you know any reason why this particular server would have high CPU and memory use?” and I was able to tell him that a very large customer was running some really intensive reporting without looking at the server.  Of course, I knew this because they were generating a large number of long-running query alerts.  Oops.  (Those queries have since been optimized.)

Which leads, of course, to a few caveats.  Namely, that if you haven’t done any monitoring before you might receive a large number of alerts.  In fact, you might actually receive an email from SQL Monitor saying, “I’ve sent you 1000 emails today.  You cannot have more emails.  You have an email problem.”  (This isn’t the actual message, but maybe it should be.)  You’ll probably want to up the alert thresholds and slowly work them back down.  You also might want to set up Outlook filters and only send the emails to you and not your boss until things settle down.

The other caveat is:  You’re aware that when an application creates a SQL database, the defaults might not be optimal for your particular situation, right?  SQL Monitor starts off with a 1MB database that autogrows by 1MB.  If you have terabytes of data, you might see a bit of disk I/O from that.  Ahem.  Change those numbers to sane numbers.  (You don’t know what size to make the database?  Guess.  Your worst guess is better than 1MB.  Make the autogrow a large number, too.  And you do know about Instant File Initialization, don’t you?)

And then, there’s Nagios.

I love Nagios because it’s crazy extensible.  There are a lot of great user-contributed scripts over at Nagios Exchange in addition to the built-in stuff, and depending on who you are someone in your organization may already be running it and you might be able to get in on the action for the low price of beer, cookies, or pizza.  If none of the scripts at Nagios Exchange suit your needs, you can write one in any language that will return a valid return code to NRPE and/or NSClient++, including bash, python, perl, VBscript, batch, PowerShell, etc.  It can also read SNMP data.

So, Nagios caveats:  Out of the box, it pretty much tells you if your disk space, CPU, and Memory are okay and whether a service is running (all of which is awesome, but it’s maybe not the entire universe of things you want to know).  There are supplied check scripts for things like SMTP, FTP, HTTP, etc., and user-supplied scripts for all kinds of wild and crazy things (Available security patches!  Oracle!  Weather alerts!  Cat water dishes!).  If you want to know about the battery life of the UPS that doesn’t have a generator, you’re probably going to have to dig around under the hood, so make sure you (or the person running the system) enjoy that sort of thing.  Because, in my not-particularly-humble opinion:

  • If you’re just checking disk space, memory, and CPU, you’re not harnessing Nagios’ true power.  Find new and exciting things to check!  When something breaks, figure out how to monitor it!
  • If you’re sending the Exchange Administrator an email when the Web Server goes down, and the same guy/gal doesn’t manage them both, you’re doing it wrong.  Make contact groups your friend.
  • If you have 100 web servers and 100 service entries for HTTP,  you’re doing it wrong.  Make host and service groups your friends.  (Of course, groups do sometimes assume standards that may not exist at your workplace, but group as best as you can.)
  • Create separate contacts for email-worthy and pager-worthy alerts.  Do not page someone in the night about their scratch disk being 80% full.  That’s bad karma.
  • You want Nagiosgraph.  Trust me.

And now, general monitoring caveats:

Some people just don’t get monitoring.  They see it as “being bugged.”  I see it as “finding out things are about to break before they actually break.”

A paraphrased but otherwise true conversation, which I will call “F my F: Drive”:

Guy:  Can you turn off email alerts for the F: drive?  I don’t care if it fills up.
Me: Even during business hours?
Guy: Yeah. Don’t care.
Me: What’s on it?
Guy: Our logging app writes logs there.
Me: Do you care if the logging app is running?
Guy: Oh, yeah! Make sure I get an alert for that!
Me: Will it stop running if F: fills up?
Guy: Yes…
Me: Then you care if F: fills up.
Guy: No, I don’t.  I only care if our logging app is running.

If you’re the one setting up Nagios for someone else, just smile and nod at these people and let their F: drive fill up.  But you?  You care if your F: drive fills up.

As for which one you want, well, they’re not really equivalent products.  SQL Monitor is only for SQL servers, and is an analysis and performance tuning tool.  It’s really nice for SQL Servers, and it would be really hard to duplicate all of the functionality in Nagios.  On the other hand, if you don’t have the money for SQL Monitor, well, I think setting up Nagios instead is worth it.  Free is everyone’s favorite price, and I want to run both because, you know, crazy extensible.  Besides, Nagios’ main purpose in life is to tell you that something is broken or about to break, which I want to know!

As such, Nagios is smarter than SQL Monitor about alerts.  In Nagios, I can define that my connection to the two instances on SQL Server 1 is dependent upon my ability to get through two routers, and if the network faceplants Nagios will tell me that the server is unreachable, not that it’s down and every service on it is down.  During the last application of Microsoft patches, SQL Monitor told me that the host was down, and the instances were all down, and that all the databases were unavailable, and that I cannot have more emails because I have an email problem.  And then I investigated “scheduled downtime.”

Comments Off on Confessions of a Monitoring Junkie

Filed under monitoring

The Motivational Spreadsheet of Doom

Hi, my name is Katherine and I’m a metrics junkie.

I have an outline spreadsheet based on the Snowflake method to which I’ve added wordcount secret sauce formulas.  I downloaded it for NaNoWriMo many years ago.  I then have a tab that’s nothing but date, wordcount, and then it generates for you words remaining, words over goal, and days since last written.  If you plug the wordcounts into the scene listings, the spreadsheet will tell you if you’re on track or likely to end up long or short.

Apparently, however, this doesn’t help unless you put “finish outline” on your to-do list.  You know, the one that also has your laundry and work-related projects all in one big lump.  With–this is important–a deadline.

Now, “Finish story” is on the to-do list, so I have an appointment with Write Or Die every day.  I’m going to go for 250 words a day.  That worked well for me.  (NaNoWriMo requires about 1500 a day, and that’s fall asleep while typing time.)

I’m a fitness metrics junkie, too.  Write it down or it didn’t happen.  For example, I already have 115 miles on my new running shoes (yikes, already?).

Comments Off on The Motivational Spreadsheet of Doom

Filed under procrastination

You and Your Resume

I should really call this post, “Everything I ever learned about job hunting I learned from writing,” even though that’s not really true.  However, there are, in fact, writing links in here.  (I’m a published short fiction author under a pseudonym.)

[Note:  I have a new job and am not looking at this time. I do, however, have friends and relatives who have requested resume help.]

The first thing you need to keep in mind when job hunting is that it’s not personal.  It’s not about you at all.  It’s about an employer who has a need to fill.  When I was job hunting, I kept this link in mind. A sample:

Anyway, as I was saying, it realio trulio honestly isn’t about you the writer per se. If you got rejected, it wasn’t because we think you’re an inadequate human being. We just don’t want to buy your book. To tell you the truth, chances are we didn’t even register your existence as a unique and individual human being. You know your heart and soul are stapled to that manuscript, but what we see are the words on the paper. And that’s as it should be, because when readers buy our books, the words on the paper are what they get.

This all becomes clearer if you think about it with your reader-mind instead of your author-mind. Authors with books are like mothers with infants: theirs is the center of the universe, uniquely wonderful, and will inevitably and infallibly be loved by all who make its acquaintance. This has its good aspects; books, like infants, need someone to unconditionally love them, and champion all their causes. On the other hand, it can be a form of blindness.

Your reader-mind has a different understanding of the whole book thing. Your reader-mind knows what it’s like to walk into a bookstore, or a Costco, or a Target, and confront a wire rack the size of your living-room wall, with slot after slot filled with books. At that moment, standing there in front of that rack, you don’t much care about encouraging new writers, or helping create a more diverse literary scene, or giving some author a chance to express herself. You want a book that will please you, and suit your needs, and do it right now. Dear reader, you are many things, but “gentle” isn’t one of them.

So, to extend the metaphor, pretend you’re hiring and have five hundred resumes on your desk and then look at yours.  (This may be easier if you’ve ever been on a hiring committee or sorted through resumes, but even if you haven’t, imagine.)  A recent article said that recruiters look at your resume for 6 seconds.  Make it easy for them, and put the stuff they mention specifically up near the top of the lists.  Don’t bury the shiny halfway down the page.  They might not get that far.

I also had a couple of people say that they weren’t sure what to do with the education portion.  Look, if you’re applying for jobs that say, “Associate’s degree or four years of relevant experience,” and you have five years of relevant experience and no degree, don’t put your high school under education or apologize for not having a degree (or, worse, claim you’re an MIT graduate).  Just don’t.  Leave that section off.  Opt for a compelling silence.  The resume police aren’t going to come get you if you leave off information they’re not even asking you to provide.  If, on the other hand, you have a degree in an unrelated subject, well, so do I.  Put it on there.  Your Master’s degree in Divinity from Harvard will give you and the interviewer something to talk about.

Cover letters:  This is a fiction cover letter, but I used this basic strategy for my job hunting cover letters.  Several years ago, someone asked me about cover letters, saying, in an aggrieved tone of voice and with an accompanying eyeroll, “So, I just rehash what my resume already says?”

No!  You do an eclectic celebration of the dance! You do Fosse Fosse Fosse Fosse Fosse! You do Martha Graham Martha Graham Martha Graham, or Twyla Twyla Twyla, or Michael Kidde Michael Kidde Michael Kidde Michael Kidde, or Madonna Madonna Madonna Madonna… but you keep it all inside.


No, you personalize your resume to the job listing, and your cover letter is a chance to explain why you are FREAKING AWESOME and perfect for the job by highlighting what’s already in your resume.  You know, in case they miss it by only looking at your resume for six seconds.

These are not a dry rehashes of your entire life up until this point.  They’re  marketing documents, and you’re the product.

By the way, you know they’re googling you, right?

And don’t forget the thank-you note.

Comments Off on You and Your Resume

Filed under career

Fitting it all in.

Yes, it’s another post on the continuing saga.

New job.  New job means new schedule.  New schedule means figuring out how to work all the other, non-job things I want to do into my life. Yeah.  It’s a process.

First up:  running.  Since I’m off the evil early morning schedule (OMG SO not a morning person!) that means that I can go run in the mornings.  That may seem counter-intuitive, but the idea is that I have very little brain in the mornings and therefore it’s more efficient to do tasks that don’t require brain then.  Trotting along on mechanical conveyances does not require brain.  This also means I often get in 10,000 steps before noon, and have my evenings available for having an actual social life.  This week I ran 14.9 miles total, so I declare the new running plan a success.

Next up:  scheduling writing time.  My lunch hour might work.  Hmmmm.  I’ll have to try that.

Other things that need scheduling:  Weights and yoga.  Since running is Monday-Wednesday-Friday-Saturday, there’s a logical Tuesday-Thursday or Tuesday-Thursday-Saturday slot for that.  Hmm.

Comments Off on Fitting it all in.

Filed under life, the universe, and everything

SQL Saturday #111

As always, I had an awesome time at SQL Saturday.  I heard at least two people say that the SQL community is full of genuinely nice people, and it certainly seems to be true.  I followed a bunch of new people on Twitter and won a Kindle Fire!

(By the way, if you’re a SQL person and are not on Twitter, you really should be.  I’ve specifically heard that you want to know about #sqlhelp.)

The amusement started when my friend iffer pointed out that they were using a Lord of the Rings theme.  The panel tracks were named things like Merry, Pippin, Arwen, Aragorn, and Gandalf.  Hee!

As a DBA stolen originally from the System Administration side of the house, I spent most of my time in panels with words like “internals” in their titles.  I’ve always believed that the more you know about how things really work, the more able you’ll be to fix them.  Brian Kelley and Denny Cherry in particular fed the geek within with the FREAKING AWESOME “Windows Operating System Internals for DB Pros” and “Index Internals.”  I also enjoyed Brian’s professional development panel (“Being the Swiss Army Knife of DB Pros“).  (The other panels I went to were also really good.)

I also want to put in a plug for the PASSWIT informal lunch.  (Photo by Jennifer Levy.)  We talked about outreach to girls about STEM careers, and asking for better Barbies.  Tell your daughters/nieces/young cousins that they can go into computers today!  Encourage a girl in math or science!  (By the way, the man in the photo is a college computer science professor.  W00t!!!)

Biggest SQL Saturday regret?  I didn’t make it to any PowerShell panels this time. 🙁  I’ll have to download some and check ’em out.  (I’m particularly interested in “PowerShell Modules You Should Know About.”  I’m also interested in “Manage SQL Server 2012 on Server Core w/PowerShell,” but my interest in that is pretty academic, as I think my employer is unlikely to be using either SQL Server 2012 or Server Core in the near future.)

In short?  If you work with SQL Server and have never been to SQL Saturday, you probably want to.  It’s free!  What’s not to love?

Comments Off on SQL Saturday #111

Filed under geekiness

Broad Universe Rapid-Fire Reading

I’ll be reading at WisCON again this year!

May 26, 1pm, Conference 2, Concourse Hotel, Madison, Wisconsin.

A chance to meet the writers and hear the work of some of the most exciting new talent in our genres. The readers of Broad Universe will drop you into their fictional universes with dynamic readings. You will need warp drive because within the session you will hear from ten writers who will transubstantiate you from the subgenres of space opera, speculative fiction, alternative history, steampunk, fantasy, intergalactic romance and generation starship to new mythologies and the paranormal. Come prepared to lengthen your To-Read-Immediately list.

Moderator: Karon Crow Rilling. Kimberley Long-Ewing, Karon Crow Rilling, Sandra Ulbrich Almazan, Ada Milenkovic Brown, Gwynne Garfinkle, Deirdre M. Murphy, Michelle Murrain, Larissa N. Niec, Katherine Mankiller, Phoebe Wray

Comments Off on Broad Universe Rapid-Fire Reading

Filed under cons

As promised…

I said that all would be revealed in the fullness of time.  I have a new job.  One with a less heinous commute.

Which means, of course, that it’s time to get back on the writing horse.  And the running horse, because working 40 hours a week + 4 hours a day commuting doesn’t leave one a lot of running time.  I have a new story partially outlined, and it’s been that way for months, so it’s time to finish that outline.

In other news, I’ll be in the Broad Universe sampler and will read with Broad Universe at WisCon on the Saturday of Memorial Day weekend.

Comments Off on As promised…

Filed under life, the universe, and everything

This Saturday is SQL Saturday!

This Saturday, I’ll be joining all the SQL geeks (including someone who’s been my friend since 1996) to listen to talks on SQL at the GSU campus in Alpharetta.  I’d say “Be there or be square!” but it’s sold out, so, alas, if you’re not already registered you’re doomed to be one of the uncool kids.  😉

I have a shiny new job to go with the shiny SQL goodness, too.  Let’s see what kind of new shiny I learn that will help me with the new shiny!

Comments Off on This Saturday is SQL Saturday!

Filed under geekiness