Loading

Follow Us

Follow us on Spiceworks

Subscribe by Email

Your email:

Browse by Tag

Current Articles | RSS Feed RSS Feed

Monitor your SQL databases with Admin Arsenal

  
  
  
  

If you have a critical database in your environment then you owe it to yourself to perform, at the very least, the basic monitoring of the health of the database.

There are a few Performance Counters that I generally reference when I want to passively monitor the DB health. One of these counters is Log Flushes in the SQLServer:Databases category.

Your SQL server will flush a log (I know, I know, it sounds appealing) whenever it completes a transaction that involves inserting (or updating). Acceptable  flushes per second will vary depending on the muscle of your hardware (RAM, CPU, High Performance HDD, etc).

In the example below, you will see a monitor that looks at the Log Flushes per Second counter. Every 30 seconds the number of flushes will be sampled and if the number of flushes is greater than 800 for three (3) consecutive samples then our defined Actions will be executed.

We have two defined actions. The first will fire off an email to an administrator displaying the reasons for the event.

In future posts we will show additional performance counters.

Monitor SQL databases | Admin Arsenal

Monitor properties | Admin Arsenal
Monitor Properties
Define your actions in monitors | Admin Arsenal
Define your actions
Email Action for monitors | Admin Arsenal
Eventlog Action

Local Drive Map

  
  
  
  

 

Windows Local Drive Map | Admin Arsenal
    Photo by Qfamily
Today's command line adventure is an oldie but a goodie. Many years ago I was helping my father set up an accounting software package. This program had a server and workstation component. My dad had only two computers and so he wanted to use one of the workstations as the server. But there was a catch.

The workstation component would only access the server on a mapped drive letter, the drive letter couldn't be local. No problem, I thought, I'll just map to the server share locally, as though I'm running off a normal workstation. No go, the workstation actually had the temerity to check if the map was to a shared volume on the local computer.

I wasn't sure what to do, my dad didn't want to buy another computer just for this one program. After some Googling (it may have actually been AltaVista-ing back then) I found the subst command. Subst is short for substitute (I guess, the documentation doesn't say.) It lets you create a drive drive letter that points to a local directory, it's like mapping to a local share but without having to share. That did the trick, it was enough to fool the workstation software into thinking it was talking to a remote server.

I've found this command useful over the years when I need to access a directory in a deep hierarchy multiple times, and it saves me from having to constantly navigate down into it. It was particularly useful back in the day when I spent most of my time on the command line and having to cd back and forth between 10 directory deep paths got really tedious.

Where can I find a device's firmware version in WMI?

  
  
  
  

Many hardware vendors store the firmware version of their devices in WMI. Extracting this value can give you some very important information when it comes to determining which devices may need to have their firmware updated.

In this example I am using the Microsoft WMI Object Browser (available free for download here).

Let's say that I want to script a solution that reports the Firmware version for all the Smart Card Readers in my organization. In the following screenshots you can see where this data can be viewed via the Device Manager:

Windows Device Manager

Device Instance ID

Firmware Revision

By looking at the properties of the device I can see both the Device Instance ID (this is important when you need to extract this device via WMI) and the Firmware Version.

When you open the WMI Object Browser change the namespace from root\cimv2 to root\WMI.

WMI Browse for Instance

WMI Browse for Instance 2

WMI Object Browser

The property that we are interested in is FirmwareRevision.

Here is an example of extracting this property in Visual Basic .NET.

Private Function GetFirmware(ByVal id As String) As String
Dim firmWare As String = ""
Try
Dim objFirmWare As New ManagementObjectSearcher("\\.\root\WMI", "SELECT * FROM MSDeviceUI_FirmwareRevision where InstanceName = '" & id.Replace("\", "\\") & "_0'")
For Each objMgmt As ManagementObject In objFirmWare.Get
firmWare = AsString(GetWmiValue(objMgmt, "FirmwareRevision"))
Next
Catch ex As Exception
' do nothing
End Try
Return firmWare
End Function

When this function is instantiated it processes an argument called ID. This ID is extracted in a previous Class via the Microsoft tool DevCon.exe. Devcon.Exe is a decent command line utility used to extract information available via Device Manager. While this article is not centered on Devcon.exe, I will include an example of the output of devcon.

Devcon

As you can see from the example, the first line returned is the DeviceID that I need in my WMI Query.

As always, if you have questions, comments or smart-ass remarks, let me know.

Where's the damned setting?

  
  
  
  


Can my workstation fit in this VM box?
    Photo by crowt59
Quite often I find myself in a situation where I need to determine where a setting is located in the registry. It usually requires some detective work, but I have refined a technique that helps me find out quickly most of the time.

 

It's a four step process:

  1. Export the section of the registry that I expect to contain the setting, using regedit.exe.
    Navigate to the top key of the section to export, right-click, and Export. I name this file before.reg.
  2. Make a change to the setting, making sure to apply the setting so that it's written to the registry. Try to do as little else as possible at this time, to prevent unwanted changes to the registry.
  3. Export the same section from the registry as step 1. Name this file after.reg.
  4. Use a file comparison tool, such as WinDiff to see what changed.

Most of the time this takes me right to where the setting is stored. Usually if it doesn't it's because I'm looking in the wrong part of the registry or because the act of saving the setting changes so much else that there's too much noise.

Hopefully this little tip will help you out at some point.

The Scourge of the Bloated Inbox

  
  
  
  
Keeping your inbox clean | Admin Arsenal
    Photo by z287marc

Many moons ago (102 to be exact) I was getting fed up with my constantly growing inbox. I would get an e-mail, read it, make a mental note that I needed to take care of it soon, and then be shocked three weeks later when I found it buried under a pile of 300 other messages. Something had to be done.

It was then that I created two strategies. The first was to treat my e-mail inbox as a *gasp* INBOX. If it was still in my inbox, it was something that I needed to take care of.  The problem that I had, and that I suspect most people have, was that I was both afraid to delete anything in case I needed it again and afraid that I'd never be able to keep everything filed and organized if I tried to clean-up. My solution was to just give up on any semblance of organization and take all the thousands of e-mails bloating my inbox and stick them all in the same folder called "Archive." I figured that I could search for something if I needed it again. And you know what? It worked great. On the rare occasion that I needed something after it left my inbox, the little bit of extra time searching was never more than the time it would have taken to organize the thousands of e-mails I would never need again.

Over the years I did eventually add two additional folder for ex-inbox messages, one called Info and one called Fun. Info is for things that I'm more likely to need again such as invoices and travel itineraries (it makes searching for them a bit easier.) And the Fun folder is for all the jokes and pictures I get from friends. I don't know if there's any value in keeping them separate but it feels nice to have a folder completely dedicated to bad jokes and even worse Photoshops. I suppose one day my biographer can dig in there to get a window into my psyche (perversions?)

With all this in mind, it was great to run across a concept called "Inbox Zero" which was pretty much what I was doing instinctually. Now, when people hear that I only have 2 messages in my inbox I don't worry when they look at me like I'm either wildly unpopular or hyper anal retentive. I can just point them to the resources where they too can tame their inbox.

And you're RDPing into that server why, again?

  
  
  
  
RDP not always necessary | Admin Arsenal
    Photo by mandj98

While attending TechEd in 2008 I heard over and over again a technique used for running a command on a server; remote desktop. A few people were using sysinternals for this common task, and my hat is off to them. That's a much more efficient way of running a command or two without the headache of logging into the system.

We've seen this problem too and our system administrator product, Admin Arsenal, has a quiet little feature that handles this very challenge. We call it "Remote Command".

It's simple. You select the computer(s) that you wish to run a command and you run it from within the Admin Arsenal GUI. The output is provided back to you as though you had issued the command locally.

I was surprised at the number of admins who were using the manual method. It's a good reminder to keep your eyes and ears open. Doing so will keep you more attentive as you discover solutions to problems you didn't know that you had.

Good Options, Bad Options

  
  
  
  
What are your shares worth?
    Photo by Est Bleu2007

I've been laid-off once in my career. It was just after the .com bomb. I was at this company for only 2 1/2 months.  During the employment negotiations I was offered quite a bit of stock options. I had just seen the Simpson's episode about the .com company that issued it's stock in the form of toilet paper rolls with each square equalling one share of the company. I told them that while I would certainly accept stock options I wasn't going to take the options in lieu of decent pay. I told them the amount of $$$ that I would work for and they finally accepted my counter offer.

It became clear that I was the only new hire that had not been talked down in my salary requirements by accepting liberal stock options. After being at this company for three days I knew I had made the right decision. The service that this company was providing was, in my opinion, pathetic. While I won't divulge the name of the company the service provided was an early version of VoIP for call centers. The software had been developed at a call center and then this call center was so pleased with itself it spun the software into it's own company. The goal of the employees of this new company was clear:

Go Public!

The software lacked. The services provided were laughably pathetic. Almost all of the money available had come in from Venture Capitalists. I looked around: Almost everyone there thought that all their problems would be solved when the company went public. Going public WAS the exit strategy. From the office doors of Vice Presidents to cubicles of developers and engineers a similar theme was expounded in the form of print outs: Go Public. There was always a date that was a goal for going public. In the 2 1/2 months that I was there the date was pushed back three times.  I would hear of customers calling in and complaining about service interruptions and all-in-all poor service but the goal for everyone wasn't resolving the issues at hand as much as shutting the customers up so that we can GO PUBLIC. I even heard one Vice President say "Once we go public we won't need this customer anymore."

I was laid off with about 40 or so other people. I believe the company had relieved about 60% of its workforce in one layoff. I chuckled when I heard the news. I packed up my desk and soon I was enjoying the weekend with my Great Dane. I took the one month severance pay (remember I hadn't even been there for three months) and landed a great gig the following Monday. I had learned some excellent lessons in the preceeding three months about priorities.

There certainly is a time for "going public". I'm not pretending to be an expert on when this time is or should be. There are far wiser and more intelligent folks than I to explain that. I just know that if I, as a customer, ever run across a company that seems to spend most of its energy on preparations for going public I am going to run so fast in the other direction that flames (not just blue darts) will literally shoot out of my ass.

Paranoid Backup - Now with Cloudy Goodness

  
  
  
  
Backup the right way
    Photo by kevindooley

This post is a follow up to my recent post on Paranoid Backup. A couple of commenters pointed out that my use of a Godaddy web server was a violation of their terms of service. I decided that I would look for an online storage system that I could use without annoying a pack of hungry lawyers.

As I mentioned in my prior post, I had already rejected the various cloud backup solutions for one reason or another. Instead, I looked for simple online storage of data. In the end I whittled it down to two contenders, Amazon S3 and Rackspace Cloud Files. Both had about the same pricing, but Rackspace seemed to have a better support for developers (they provide a Python wrapper around their RESTful API along with some other languages.) Also, I liked Rackspace's web interface and reports better.

Each uploaded file is stored in a container. There is no limit to the number of containers or the number of objects in the containers. One thing to be aware of is that containers can't be nested. It makes the API a lot simpler, but it could be a limit depending on what you want to store. Each object can also have extended attributes attached to them as name/value pairs.

Along with storing the data, Rackspace allows for the data to be made public through a high speed Content Delivery Network. Since I won't be using this feature, I didn't delve into too much.

Pricing is $0.15 per GB of data stored per month, $0.08 per GB uploaded, and $0.22 per GB downloaded. There is also a small charge of $0.01 per 500 uploads of files smaller than 250 KB. All told it will cost me about $5 to do my initial upload and $9 per month in storage. Downloading the whole thing would cost me about $13.

So far, I'm very pleased with the quality of the service. It's going to take a few weeks to get my sixty some-odd gigabytes of data floating in the cloud, so I'll be sure to post if I run into any problems.

The Perplexity of Outrage - An Apple iPod Commentary

  
  
  
  

iPod sales vs. the other guysWhen you are king of the hill your every move is watched, anticipated, predicted, exalted, and even reviled. Microsoft can't get away with much on their OS platforms. If they sit too long (XP) they stagnate. When they have a success (Win2000) they are touted. When they have a bomb (Vista), even they can't buy a friend.

It's lonely at the top, so the saying goes. Just ask two companies who are still getting used to their perch; Apple & Google. My thoughts today will focus on the former.

I was watching the Apple Media Event yesterday and was fairly pleased with the announcements. (I had been waiting for a 64GB iPod Touch and placed my order yesterday. It's already shipped). Following the event I decided to see what others thought about it. I searched Twitter and some common Mac forums and I discovered that the comments were, by-and-large, negative.

It seems that some people were looking for an earth shattering announcement. Many were disappointed that the event was centered around the iPod (September is commonly the month for iPod upgrades and announcements). Apple released the theme of the conference last week which I'm certain they hoped would quell any discontent; "It's Only Rock 'n Roll". That's a pretty good sign that Apple would be focusing on the iPod.

So why the outrage? The answer is in the numbers.

According to Apple, 220 million iPods have been sold since 2004. Greater than 50% of new purchases come from first time buyers. Apple commands 73.8% of the market share for portable music players. (The joke was that the next largest chunk of the pie was attributed to "other".) Microsoft Zune came in at 1.1%. According to these numbers Microsoft could announce a major upgrade to the Zune and approximately 1% of us would give a crap.

Are we becoming immune to great news? It's almost like there are those who see a construction site and get as close as they can, watching every brick getting laid, only to continually lament that it's just another stupid brick.

I prefer to sit back a ways. I don't need to see every brick being laid to realize that a building is being erected. Besides, the view from the back is better. I may not be the first person in the building, but the experience will still be worth it.

Random Thoughts on a Passing Scene - A Rebuttal

  
  
  
  

Randon Thoughts - A RebuttalMy "esteemed" colleague Shane recently posted his random thoughts on the passing scene. Well, he couldn't be more wrong... allow me to elucidate.*

  1. Windows 7 is proving to be pretty slick thanks, in part, to finally bundling PowerShell.
    PowerShell, SmowerShell, bring back autoexec.bat!
  2. Tom Waits is the greatest songwriter in my lifetime.
    Tom's sound (I can't use the term "music") is like the long, drawn out death rattle of a man dying of terminal flatulence.
  3. I’m not ready to forgive Microsoft for Vista which continues to be the greatest over-correction in the history of micro-computing. This is one grudge that is going to be hard for me to lose.
    Vista was one of the greatest... um... okay, even I can't disagree here.
  4. All truth can be circumscribed into South Park, Simpson, MASH and Seinfeld quotes.
    What? Are you crazy? You forgot Red Dwarfxkcd, and Firefly.
  5. Women should make a point to go Microsoft Tech-Ed if only to enjoy seeing the long queues out of the mens restroom while the womens room is virtually empty.
    Well, loser, for your information that's only because more men attend than women. Ha! Boy, are you dumb.
  6. The Big Lebowski is more than a movie, it’s a way of life. (c’mon, bowling, marmots, purple one-piece outfits, white russians and the occasional acid flashback).
    All I can say is "The Dude Abides."
  7. I’m starting to have doubts that PowerShell will “take off”.
    That's what they said about VBScript, and look where it is today.
  8. Any meeting that lasts longer than 28 minutes is a %*$#@!^ waste of time.
    I assume by %*$#@!^ you mean "complete not"... in which case you're wrong.
  9. It’s rare to dazzle with brilliance but common to baffle with bullshit.
    As your supposed "blog post" clearly illustrates.
  10. Everyone has at least one good story.
    Not my dad. I've been trying for years to identify one, only to be left wanting.
  11. I use a Mac but make my money off of Windows.
    Working for the same company as you, and also using a Mac, I must ask: What money?
  12. Give me South Park or give me death!
    Death.
  13. I still recommend Revolution OS. If you haven’t seen it, well, you have a homework assignment.
    [end of line]

Thank you, I'll be here all week, try the roast beef.

* For the record: Shane, I'm only kidding, you are 1000% correct (please don't hurt me.)

Random thoughts on a passing scene

  
  
  
  
Random Thoughts | Shane Corellian | Admin Arsenal
    Photo by epSos.de
  1. Windows 7 is proving to be pretty slick thanks, in part, to finally bundling PowerShell.
  2. Tom Waits is the greatest songwriter in my lifetime.
  3. I'm not ready to forgive Microsoft for Vista which continues to be the greatest over-correction in the history of micro-computing. This is one grudge that is going to be hard for me to lose.
  4. All truth can be circumscribed into South Park, Simpson, MASH and Seinfeld quotes.
  5. Women should make a point to go Microsoft Tech-Ed if only to enjoy seeing the long queues out of the mens restroom while the womens room is virtually empty.
  6. The Big Lebowski is more than a movie, it's a way of life. (c'mon, bowling, marmots, purple one-piece outfits, white russians and the occasional acid flashback).
  7. I'm starting to have doubts that PowerShell will "take off".
  8. Any meeting that lasts longer than 28 minutes is a %*$$#@!^ waste of time.
  9. It's rare to dazzle with brilliance but common to baffle with bullshit.
  10. Everyone has at least one good story.
  11. I use a Mac but make my money off of Windows.
  12. Give me South Park or give me death!
  13. I still recommend Revolution OS. If you haven't seen it, well, you have a homework assignment.

Windows 7 Trial Now Available

  
  
  
  

Windows 7 Trial Available | Admin ArsenalDownload your trial of Windows 7 from here. This is great news for those system admins whose company does not participate in TechNet or have a volume licensing deal with Microsoft.

If you are seriously considering Windows 7 then I highly recommend the Windows 7 Team Blog from Microsoft. While there are a ton of reviewsblogs, and tweets surrounding Windows 7, you'll quickly note that many cite sources from this team blog.

Want to bypass the Team Blog and go straight to the springboard download page?

Thanks to the Windows 7 Team Blog. Please keep the information coming. (It'll get out anyway).

Tags: 

Managing your virtual environment

  
  
  
  

Managing your virtual environment | Admin ArsenalWhere will "Systems Management" be in five years?

This is the very question that we were asking ourselves this past week as we contemplated our product strengths. The answer was quick and unanimous; virtualization.

In studying what others have been saying about this topic I came across a story from April 2009 that discussed virtualizaton with two established products and two newer-to-the-scene solutions (Microsoft, CA, Insystek, and DynamicOps). The results were a little discouraging as no solution came across as giving warm fuzzies. In the end if you have the largest of the large environments then CA walked away with the nod.

It's worth a read if you're already walking in the VM world. We have a client that just refreshed over 300 servers on a 1 for 1 swap. They were looking into virtualization but they were just so confused at the multiple offerings that they didn't feel it was wise to spend a year trying to figure it all out.

It can be daunting but your homework still needs to done. Doing more with less may be the mantra of the day, but is it really true? We're not doing with less bandwidth or storage space. These areas continue to grow in availability while dropping in price. In fact the one area where we see slower growth is in processor power, which of course is, arguably, the most limiting aspect in virtualization. Still, it may be wise to start on the road for your server farms.

We virtualize in our environment wherever we can. It just makes sense.

All Posts