Diary of a geek

November 2008
Mon Tue Wed Thu Fri Sat Sun
         

Andrew Pollock

Categories

Other people's blogs

Subscribe

RSS feed

Contact me

JavaScript required


Friday, 28 November 2008

Wising up about SMART

I've always installed the smartmontools package on my servers because I figured it'd maybe give me some early warning about an impending disk failure.

Getting proper SMART access was one of the motivating factors in moving my home-brew SAN from IDE-to-USB disks to native SATA.

Since then, I've had two drives fail on me. One of the original four that I bought, and the replacement one that Seagate shipped to me. (Incidentally, I love how your only recourse to a replacement drive failing with Seagate is they'll ship you another (reconditioned) replacement drive. I can see the shipping expenses racking up very quickly).

I decided to do the expedited return when the second drive failed, just because it meant I didn't have to be without a disk in my RAID-10 for a week while I waited for them to receive my drive and turn around and ship me a replacement drive, and it also meant I didn't have to mess around with packaging it myself.

(Incidentally, I wonder what happens in Seagate's reconditioning process? Will someone else get my failed drive (i.e. the same serial number) after they replace the platters or whatever it was that failed? Would it be interesting to set up a website where people could register the serial numbers of drives they returned to Seagate, and how they died, and at how many power-on hours? How many times does a drive get "reborn"?)

Whilst I was waiting for the replacement drive to arrive, I messed around with the failed one (I removed it from the RAID array), fiddling with the SMART self-tests that smartctl can initiate for you. The faulty drive failed the long self-test at the same LBA every time I ran it.

It was around this time that I realised that the default configuration that comes with the Debian smartmontools package isn't all that useful with SATA disks.

It ships with

DEVICESCAN -m root -M exec /usr/share/smartmontools/smartd-runner

which, as it turns out, doesn't detect SATA drives properly. I got

Nov 24 22:00:13 minotaur smartd[2990]: Device /dev/sda: ATA disk detected behind SAT layer 
Nov 24 22:00:13 minotaur smartd[2990]:   Try adding '-d sat' to the device line in the smartd.conf file. 
Nov 24 22:00:13 minotaur smartd[2990]:   For example: '/dev/sda -a -d sat' 

logged. It seems to me that if the software can detect this situation, it should be able to just try the "-d sat" behaviour automatically.

So it seems that this whole time, I haven't been getting any SMART monitoring of my SATA drives. hddtemp has been happily logging the temperatures for me though.

So I took the advice in the comments of /etc/smartd.conf and removed the DEVICESCAN entry in favour of explicitly naming the disks I wanted to monitor.

I also discovered that I can have smartd kick off scheduled short and long self-tests on whatever schedule floats my boat.

So now I've got something like this:

/dev/sda -d sat \
         -M exec /usr/share/smartmontools/smartd-runner \
         -s (L/../.././01|S/../.././(00|12))

This runs a long self-test at 1am every day, and a short one at midnight and midday. Hopefully this will help predict the next drive failure a bit earlier.

I'm now debating whether to set up an active Nagios monitor for SMART, or to see if I can write a passive one that runs as part of the smartd-runner infrastructure that the smartmontools package provides (and is pretty neat). I guess it's already setup to email me, so it doesn't really matter whether it's Nagios emailing me, or smartd itself.

[23:05] [tech] [permalink]

Thursday, 27 November 2008

Sprained ankle, part 2

My ankle still isn't quite right since I sprained it back at the end of August.

It still looks more swollen compared to my other foot, gets stiff when elevated, and my foot doesn't have the same range of movement as my left one.

I trundled off to a podiatrist yesterday, and he had a poke around, and then looked at it under a fluoroscope while he torqued my ankle.

Based on that, it looks like I have a anterior talofibular ligament instability. When he torqued my ankle in one direction, there was a 1.5cm gap between the bones of my foot where there should have been about a 0.5cm gap. This ligament's position certainly corresponds with where there's still some swelling, so it makes sense.

I've got some (utterly boring) exercises to do, and I have to go back and see him again in 5 weeks. He said surgery may be necessary to fix it, as left uncorrected, I could have a bad time with arthritis in my 50's, and there'd be not a lot that could be done about it at that stage.

So we went out and bought a balance board last night, and I'll be spending the small amount of time I watch TV standing on one leg.

[23:37] [life] [permalink]

Saturday, 22 November 2008

Expedia class action

[22:47] [life/americania] [permalink]

Friday, 21 November 2008

This is why $DEITY invented the Epoch

[15:03] [ubuntu] [permalink]

Monday, 17 November 2008

Watch this space

Those infamous Somali pirates have hijacked an oil supertanker

A Saudi oil supertanker at that. Carrying $100 million worth of oil, which I believe was headed for the US.

They've also got the Ukrainian ship full of tanks and what-not, which apparently pissed off the Russians.

I predict that real soon there's going to be serious action in that part of the world...

[23:15] [opinion] [permalink]

Sunday, 09 November 2008

Keeping hard drives cool

I've had this crazy ATA over Ethernet SAN for my MythTV setup for as long as I've been running MythTV. I'm using minotaur, an old Pentium III 1RU VA Linux server as the "head".

Originally, I had 4 IDE hard drives, attached to minotaur via IDE-USB adapters. This worked perfectly fine, but I missed the ability to query SMART information, and do other low-level drive tweaking with hddparm

So a while ago, NewEgg had a sale on 750Gb SATA drives, and I bought a 4 port eSATA card, and took the plunge with SATA. That all went fine.

The entire time, I've had the 4 hard drives themselves just sitting on top of minotaur, on cork trivets. The whole arrangement is in the bottom of our linen closet, as this is where the patch panel for the apartment is.

I've graphed the temperature of linen closet for some time now, but the benefit of having hard drives connected via SATA was that I could easily graph the temperature of them as well, which I started doing recently.

The catalyst for wanting to do this was that I had a drive fail, and I was concerned that they were getting too hot, just sitting in the closet with no airflow. Matt Bottrell's recent reminder of Google's research into hard drive failures also helped bring this concern to forefront.

Seagate's product documentation for the Barracuda 7200.10 claims that ambient operating temperature must be between 0°C and 60°C. I'm assuming that's the environment the hard drive is in, and not the temperature of the drive itself as reported by something like hddtemp. The closet is typically in the high 30's. If you believe what SMART reports, it seems to imply that anything over 45°C is a Bad Thingtm.

So after I had a drive fail, I figured I should probably try to do something about the temperature situation, and started looking around for an external enclosure.

I'd previously had problems with the IEC-to-Molex power supplies I was using to power the disks, and think that they'd been the cause of some failures of my IDE disks, so was quite eager to stop using them as well, which was something else an external enclosure would give me.

I had trouble finding an enclosure that presented 4 separate eSATA ports, and I was talking to Marc about SATA port multipliers, when he mentioned he had a brand-new unused full-height SCSI enclosure, for four disks, which was surplus to his requirements. Since all I really needed was external power and cooling, I thought I could cannibalise this to my needs.

Sure enough, I could just remove the SCSI cables and their Centronics connectors, and feed the eSATA cables out the gap they left, and use the molex-SATA power splitters I already had. Because the enclosure was intended for full-height 3.5" hard drives, there was plenty of air space between each disk. The enclosure included two fans.

The results? Well the graph speaks for itself:

Graph of hard drive temperatures

(I'm not entirely sure why minotaur's internal disk occasionally reports a very low temperature)

The added bonus is I've cleaned up the rats nest of cables in the linen closet. So thanks very much, Marc!

[14:22] [tech] [permalink]

Tuesday, 04 November 2008

On being a fly on the wall for the 2008 Presidential Election...

(or Taxation without Representation)

Wow, it's finally over, and best and right man won. I'm very excited and happy with the result.

It has been very interesting being able to observe the entire process from start to finish. All the primaries and caucuses, the protracted battle between Clinton and Obama in the Democratic primaries, the record breaking money Obama raised, the campaigning, the misinformation.

It'll be very interesting to see what the next four years brings. It's an exciting time to be living in America.

California is an interesting state. It has "ballot initiatives". Its constitution can (and has been) amended by essentially referendums whenever there's some other excuse for a vote. Anyone can propose a ballot initiative with sufficient backing by petition. Wikipedia has a good writeup of all of California's propositions. Probably the most controversial one this time around is Proposition 8, which seeks to essentially reverse the same-sex marriage right that the Californian Superior Court ruled on earlier this year.

This concept of ballot initiatives seems to trickle all the way down to the city level, where they're called Measures. San Francisco has some ridiculous number of them this time around. They use letters, and I think they go all the way to V. There's one to rename a sewage treatment plant after George W Bush, there's one to decriminalise prostitution. A co-worker who lives in San Francisco brought the official voter guide book to work with her today. It's about the size of a phone book and about 1.5 centimetres thick. I don't see how it's possible to make an informed decision on everything you're expected to vote on, when there's that much reading.

The observation I've made is that Americans seem to have an inherent distrust of their governments, so that's why so many bits of it are directly elected by the people. Judges are voted for, county sheriffs are voted for. You vote for your school board. It seems like very few positions of any power are appointed by someone.

Coming from Australia, where it's really the opposite, I'm not sure what I think is better. I think I like the simplicity of the Australian system. You vote for someone, and you essentially delegate power to and place trust in them.

[22:38] [life/americania] [permalink]

Sunday, 02 November 2008

Graphing hard drive temperatures with Cacti

These add-on scripts make it very easy, and need their Googlejuice boosted, so people don't find the stuff on the forums first.

[12:24] [tech] [permalink]