Saturday, June 30, 2012

2012 is the year of the Linux desktop

... For me, that is.  I have been contemplating for many years on making the switch to Linux as my main desktop operating system, and finally decided to take the plunge in a not so smooth journey.

Not so smooth, not because of Linux, but because of Windows!  So I decided I wanted to do a dual boot with my existing (new) Windows 7 install so I can ease into Linux and if I need to get something done real quick I can just go back in Windows, at least until I get myself setup in Linux.  Wellllll, they sure don't make dual booting as easy as it used to be.  Naturally, first step to a dual boot is I resized the windows partition and move it over to make room for Linux. Before installing any distro I decide to make sure I can boot into Windows.  This is where things get hairy.  I get a very generic  error that windows failed to boot.  Gee thanks Microsoft.  "Windows failed to boot" is as generic as an error gets.  It does say to run a repair, but the CD says that this version of Windows is not compatible with the CD.  O RLY? It's the same CD I used to install it!  So I figure, I'll deal with this later, I'll start testing out different Linux distros.

I wanted to go with an Ubuntu flavor because of the great package support and overall great support it has, even though I'm typically a RH guy.  One thing I noticed as well is Nvidia sucks when it comes to Linux.  The screen was flashing and it was VERY irritating to go through the install process.  I could not even use the live CD to poke around because it felt like I was going to get a seizure. It was pretty awful.   I just wanted to go through the install as fast as possible so I can go sit down and watch TV or something and come back when it's done.

Long story short I tried Xubuntu, Kubuntu and Lubuntu and liked them all but prefered Xubuntu so decided to go with that.

Back to Windows, I decided that if I move back the partitions like it was, maybe it will work. So I delete the Linux partitions and move everything back like it was.  Nope, still wont boot.  Long story short I tried all sorts of stuff but could not get it to boot. So I finally decide it's time to accept my losses, and I just delete the windows partition with the intention of reinstalling it and starting from scratch.  Well, suddenly, it no longer wants to install at all on this machine.  This is what I get:

I will be buying another SSD so I can try installing it on it's completely own drive, to see if I get better results. 

So yeah windows really does not play nice with dual booting like it used to.  I know it can be done as I've heard of people doing it, it's just not as easy as before.  I should have planed this ahead of time and leave extra room when I installed it the first time.  Probably would have been ok that way. 

Thursday, June 28, 2012

Zalman ZM-VE200 Enclosure Power Fix

The Zalman ZM-VE200 enclosure is unique because it offers a cdrom simulation mode.  Basically you create a folder called _iso on the root of the drive, put ISOs in it, and with the toggle switch on the unit you can select an ISO to load as a cdrom drive. This is great for installing an OS or booting off ANY CD.  While lot of Linux distros and other software may have a way to make a USB boot drive, not all CD/DVD can simply be "burnt" to a USB drive.  So for example if you want to install a legacy operating system like windows 98, you need a CD.  But what if all you have is an ISO and you don't want to burn a CD for only this one time?  This drive comes in handy.  Put away all your CDs, and store the ISOs on here (and a backup elsewhere of course) and you'll never have to start looking for a CD again. 

This is great for trying out different Linux distros as well, it's much easier to just download the ISO, then to go through a USB stick conversion tool and all that given ISOs are universal so anything will usually be available in that format.

Now here comes the issue with this drive, for some reason the designers thought that USB alone would be powerful enough to power a hard drive.  WRONG!!  It is barely enough, unless you happen to hit a port that has more power than the standard.  Since this device is made to use on different computers, you don't want to rely on that.  By design USB provides about 500ma of power.  A 2.5" hard drive will typically need about 550ma.  That's cutting it close, especially when you consider that the enclosure's controller itself needs power too.   So what often happens is the drive will fail to spin up, or it will spin up, but the transfers will be very sloppy and it will also completely fail and spin down. 

The solution?

MORE POWER!!!!!11!!    Just inject more power into the USB! 

I sliced the USB cable, located the red (+5v) and black (ground) wires, sliced it without cutting it in half, and carefully soldered the positive and negative of a power adapter as to add more power.    I could have done this at the sata level that way I'm leaving USB alone, but this was cleaner as I can keep the drive in the enclosure.

I tested this on a computer that did have trouble running it before, and it ran fine.  It seems on newer machines it's less of an issue, but on older ones it is an issue.

Now, you'd think Zalman would have included a port on the enclosure to plug a 5v adapter. 

Tuesday, June 26, 2012

Enviromental Monitoring Device

Something I've been wanting to make for a while, and finally decided to tackle it.   Found out about Arduino which is an open source C++ based electronic platform.  In very basic it is a device with inputs and outputs where you can connect things to it.  You can set the pins to input or output.  In input mode, analog pins will read a voltage from 0 to 5 and convert it to a value of 0 to 1024.  Using a voltage divider circuit (where 12v can be equal to 2 volts and 6 volts equal to 1, for example) then you can measure voltage.  Certain devices such as gas detectors will generate a voltage based on the concentration.   Then there are digital inputs which have a voltage threshold, if they get less, it's 0 if they get more it's 1.  This is good for on/off stuff like whether AC power is present, for example.  You can read up more about it here.  It's really cool, and they are fairly cheap.  I bought mine at

So that said, I set it up in a "box" which is actually a HDD insert for my supermicro enclosure.

Like my hvac control system I posted about previously, I wanted a central point where sensors can be wired to, and to make it cleaner I added some power distribution blocks.  Rather than use the voltage and ground from the arduino device and splicing it by soldering a bunch of wires together and ending up with a mess, I now use the enviromental control server's PSU output to feed the voltage.  Conveniently, the DC ground of a computer, and most electronics, is bonded to the earth ground. Otherwise I would not be able to do it this way as the +5v from the power supply would not be at the same potential as the +5 volt of the arduino board.  But thankfully it is, so it makes my life easier.

It looks complicated, but all it really is is 3 terminal blocks that are interconnected with the center bar in the middle.  One wire per block goes to the server to get power.  All the other wires go to the other DIN blocks to feed the sensor's ground and +5v.   I also feed the hvac relay controller off this, that way it shuts down when the server shuts down.

I'm hoping to get the voltage sensor and AC power fail sensor connected shortly.  The AC power fail sensor will be as simple as having a power adapter plugged directly in the wall and it will keep a relay open.  When the power goes out that relay will close, closing the input on the arduino and triggering a power outage notice.

I still have to code the software that will interface with the arduino to get and interpret the readings. 

I will also add it to Pandora, or other monitoring tool. Eventually I want to add smoke detectors and CO detectors to this so if one goes off, I will get an email notification if I'm at work.  I may even look at SMS text.  

Saturday, June 2, 2012

The end of Age of Valor

Well last night was the official date to shut down my Ultima Online game server for good.  It has been running for over 5 years, a lot of work has gone towards it, and there was a lot of work left, and it got to a point where I had to decide if it was worth all this effort for the few players that played.  It took me months to decide and the decision was made to shut it down last night.  Plenty of notice given to players.

The plug has been pulled. It's been a great 5+ years, but all good things must come to an end.

With all the spare time I will now have, it's time to start thinking of another project I could dedicate my time to.  Maybe something that I can monetize, this time. 

In completely unrelated news, I also upgraded my UPS. 

That is a Tripp Lite APS750 inverter-charger.  it is basically a UPS without batteries: You supply your own, bigger, better batteries!

So I went with 2 100AH deep cycle marine batteries.  The best bang for the buck.  I could go higher end and use absorbed glass mat cells, or a string of 2 volt telco grade cells, but that would cost quite a lot, this was a compromise between decent quality, and price.  If they last me 5 years I've got my money's worth.  Since this system is standby only, I'm sure they will last quite a long time. 

Hydrogen production has been taken into account. Given the size of the room it's in, and the fact that they only charge after a power outage or when discharging naturally, there wont be much hydrogen produced.  I will still look into a hydrogen sensor to be on the safe side though.

Upon testing I can run 300w of equipment for about 4-5 hours on this setup.  I have not switched my production gear to it yet but I will shortly.  I still need to look into a method of monitoring the voltage so the systems can be shut down properly when nearly discharged.