Thursday, 28 April 2011

Phone Bombing....

So, I recently used a really excellent company... like one of the best companies I've used for this little task ever... and I've been a recurring customer to them because their face to face service is so good...

But, whenever I've used their online services about 2 days later I get my phone ringing over and over with a withheld number...  I don't answer unidentified numbers... so I leave it...

And it rings...

And Rings...

And RINGS....

Luckily I don't turn the answering service on... so in the end some bright spark their end decides to phone from a regular land line... it's the scottish part of this excellent company... and they totally ruin the great customer service given in person...

In person you're treated nicely, you get spoken to like a person... and then two days later these fuck wits from Scotland phone up, shouting at you in their deranged accents asking "Doooo Yoooo Haaaave Teyme Te Ansa E Foo Kestions Abuut Ye Service Yooo Received?".... And I say "No"...

"Auch c'mon It'll Onlee Take A Minute".

"I've already given my feedback online, and the customer service was excellent, the only thing ruining it is when you guys phone bomb me for a week afterwards.  Stop this part of the feedback mechanism and everything would be superb."

"What, Canae Ask Ye A Kestion?"

"No, I've already left my feedback online"

"Right, Nae Pleeazin' Sum Peepol"

And she hangs up... yes, yes that's the shocker, this burly voiced kilted barn pot... who sounded for all the Earth like a character from the Simpons... was a woman!

Wednesday, 27 April 2011

Apple Aluminium Keyboard

My Apple Keyboard is slowly dying the space key is working less and less than a British Leyland employee from the 1970's.

I'm disappointed, as I really like the action of the keys.  They've always felt light and flowing, but I guess they can't stand up to just over 2 years of hard programming slog.

I'm in two minds whether to buy a new one.

I've had the keys off to see if there is anything obviously wrong, but nothing springs to attention.

If it were not nearly 2am, I would whack it on the wall to see if I can gee it up a bit.

Wednesday, 20 April 2011

Oh god help him...

A chap whom I work with has an iPhone and he's been a bit loose with his hips (shall we put it that way?) but his wife, whom I also know, is rather techie... so when this little gem popped up on the wire this afternoon...


she innocently swapped his iPhone for hers at lunch.... and she's been doggedly trying to work out how to read this hidden data to work out where he's been... specifically if his penis been to a certain address in Chilwell... 

But having read the Apple Terms and conditions, yes they can do this, but the things they're collecting... it makes the heading of the section a right laugh "Privacy Policy", which basically means 'You do everything we say'.

■ We may collect information such as occupation, language, zip code, area code, unique device identifier, location, and the time zone where an Apple product is used so that we can better understand customer behavior and improve our products, services, and advertising.

Sunday, 17 April 2011

Late, Tardy, Behind Schedule, Running Late

I hate when people are late, I feel so embarrassed when I'm late for other people or meetings... I like punctuality... I'm a programmer, I hate running late on projects...

So right now, Sunday afternoon, one of my precious days off, and I'm sat idle waiting on other people...whom have neither text nor called to say they're running late.. and you know what, I bet money when they get here they'll not even apologise.

Saturday, 16 April 2011

Experts Exchange

I joined Experts Exchange in 2002... at a time when I was between contracts and bored... and I answered a few questions at the time... I thought nothing of it, recently though I've noticed google is showing Experts Exchange search results up in a lot of its indices.

So I went back into that site to see what the game was.  And I got instantly pissed off... because you have to pay for answers.  They used to be free.  But you can earn free premium services by getting 5000 something points... I was already well over half way there... If I answered 8 more questions (ish) I'd get free access.

So I set about helping people in C#, Web and Linux areas...

And you know what... what fucking morons there are there... one guy I gave him not only an answer, but a program to do the job... you drag drop and then click this program... and his comment back "That's too technical for my boss to use"... WHAT?  What is this boss doing?  If he can't use my program he certainly can't use the application the guy was telling me he wanted moving about... jesus fucking christ how low can you go?

Another was a guy wanting to save all attributes from a class... I show him how, I give him a link and a code example to a library doing it... and he flat ignores it... it's just like everyone posting in the C# section has ADHD, with emphasis on AD.

Gah.

I'm going to quit that site, I hate it.

Friday, 15 April 2011

Dell Power Edge 2650 Stuck In Standby Mode

Sooo, I bought a couple of very cheap Power Edge 2650's off of ebay, well everything was hunky dory, they were filthy so I've cleaned them out inside and spent a while updating the BIOS and Firmware versions (hence the 3.5" floppy disks from my earlier post)... but last night something weird happened.  I issued a shutdown -r now to reboot the machine and it never ever came back up.

It was sat with the front power light flashing constantly, the front LED would come on flashing blue and the server name (which I had put in the BIOS) would show.  But that was it, the fans were spinning like mad but no screen activity, nothing on the ESM NIC nothing on the on board network cards... just the front power light flashing on and off constantly.

I've read all over the internet about this, everyone and their mother has suggestions... from stripping the whole machine down, to something shorting the main board out, to a dodgy PSU fitting, even as far as a known bug in the BIOS (which I have no trace of, except their word) whereby shutting down with Ubuntu in APCI mode results in the machine being un-bootable.

However, for me, it was none of those.  It was that one of the processor voltage regulars had failed.  I found this out by taking out the secondary processor and then using its voltage regulator on the primary processor.  Low and behold the machine came to life.

Now, this isn't the end of the story, I found this state the machine had been in very frustrating... the front panel lit, the green power light flashing constant, just like its in standby... but its not, that's not what its all about.  According to an ex-Dell employee whom I got up on the wire earlier its all about sort of making sure that Dell get to sell their customers a new server now and again.  I'm not knocking them for it, I'd love a brand new server and they have to drive their business some how... however, this sort of semi-built in problem, which server engineers know about and can spot is a contrivance, the BIOS should be able to tell you there's a voltage error in these circumstances; after all it was able to tell me its own name from the settings I'd put in...

So, I've set about adding and removing components, I've deliberately scored lines in the back of ECC ram modules and broken pins off of processors, cut fan wires and ruined a perfectly good 300w slide in PSU to help you guys read all the signs of these unreportable (on the front panel) states that look like stand by... so anyone wanting to give me a few quid for ruining a perfectly good server for our collective benefit can do so... please god do so.

Anyway here's the list:

Symptoms:
  Front panel/bezel showing blue - normal.
  Front panel power button green LED flashing off & on at a constant rhythm.
  Fans on full blast for ~10 seconds then they slow to 50% speed and sit idle.
  Various fan indicator lights are green (even if  you remove a fan)
  No screen activity at all (not even BIOS post)
  No activity on network cards.
  No activiy or access to ESM via rear ESM NIC.

This is what I'm going to term the zombie state, because the front panel is basically telling you that the machine is in standby mode, but everything else is saying its hung.  Even stripping the system right down and rebuilding it, if you build back in the one component which is faulty it'll hang again.

So, my primary recommendation is, do a slow build up from nothing... remove everything right down to the motherboard coming off the holding tray... brush everything with a paint brush to remove dust and debris, use an air duster if you have one around... clean it all carefully.

Check the motherboard for any obvious signs of damage or burning - which if you see, read no more, go buy a new motherboard.



Causes & Specific Signs:

  CPU Undervolt - If processor 0 (the main CPU) has insufficient voltage the green fan LED on the main board closest the SCSI back board (front edge) closest to the processor will stay off, with only one of the four quarters lighting up very dimly orange.   The solution here, replace the voltage regulator.

  If you can't replace the voltage regulator, remove your secondary CPU, and use its voltage regulator.

  CPU Undervolt - If Processor 1 (the secondary CPU) has insufficient voltage both the green fan LEDs closest the front edge on the main board will remain dim, with only one quarter showing a very dim flicker of orange.

  Again here you must replace the voltage regulator, or remove the secondary CPU, until you can replace it.

  With both these CPU Voltage situations, and indeed with a dead CPU itself, you can run your 2650 on a single goo CPU and regulator, at least check it now posts the BIOS.

  Dead memory - this shows up on the front panel in orange and doesn't got into the standby like mode.

  Dead PSU - a dead PSU can cause this issue, but only if its connected and dead and the other PSU is slightly off connection.  I could get the machine to go into the zombie standby like state just by having two powered PSUs connected, but not firmly pushed home.  Push one or both PSU's home and it'll spring to life.

  +12 volt battery failure - this gets shown on the front panel LED in orange.

  RAID memory module damage - if you have the RAID key installed and the RAID battery and the memory module you have for RAID memory is defective you can't really get it to hang in the standby like mode, however you do end up stuck when the RAID BIOS tries to load.  I didn't see any failure warning shown in orange however, so unless you've got a screen directly wired into your 2650 you're not going to know what's going on.

  RAID key not inserted fully - this can cause the system to sit in the standby idle state, however, the difference here is that all 4 CPU fan green LED's are lit green.  So, this looks like same symptoms but this time the internal four fan LED's around the CPU's are all lit green.  Even if there are no fans installed!  So, make sure your raid key is pressed firmly into place, and both blue side holders are clicked up into the vertical to hold it into place.

  Don't forget while you're pulling things in and out of your machine that if you leave the PCI riser card up a fraction, it'll stop your machine powering on... this is not zombie mode... this is where not even the fans come on... so press the PCI riser cards down into place (with the blue lever on the left of your chasis).

  The next failure is of the front panel itself... if it has failed you'll need to look at the rear light only, that rear light won't give you the green power LED clue about the zombie mode.  What will happen in zombie mode is that the machine will show blue and maybe flashing blue on the rear and that is all.

In this situation, the approach I've found best is to uninstall both processors, or all the RAM, and fire up the machine by applying power, then you will get a definite orange on the rear - this tells you that your machine is not in zombie mode, its just stuck in the boot somewhere.  If however after removing all the RAM and both processors the machine still shows blue on the back.. its in zombie mode... so start to strip out and check the processors.

Top tips:

  • Look for screws, debris or dust shorting the mainboard.
  • Look for damage to the mainboard.
  • Make sure your PSUs are firmly inserted.
  • Make sure your voltage regulators are both working.
  • If in doubt go down to a singe CPU, then try the other CPU, then try the other voltage regulator.
  • Seat your RAID Key.
  • Seat all the RAM and the RAID RAM.

  And if in doubt, contact me.

Wednesday, 13 April 2011

Holy Moly...

I'm not a religious man, but I am a technophile.. and boy has this got me gob smacked:

Friday, 8 April 2011

Re-constructive Archaeology

Tonight I want to update the firmware and BIOS eeproms in my Dell Power Edge servers... this means I needed to carry out some re-constructive archaeology... You know, the kind of archaeology where people spend vast time and energies in living the lives of people from antiquity to feel and experience the situation?  Its a bit like L.A.R.Ping but for history, rather than games...

So, what did I do, you might ask... Well... I went out... and bought a pack of 3.5" Floppy Disks!!!!

Yes, you can still buy them (if you look hard enough).

The reason for having to buy them is a bit galling, I had to because all the ones I have in a disk tray at home seem to have degraded beyond the point of use... this is worrying as they're in the same box as a whole bunch of Atari ST software, which is on 3.5" DSDD disks... these PC DSHD floppies are a lot younger than the ST ones... which means my ST disks are probably utterly useless... (sob).

Tuesday, 5 April 2011

Temporary File names in C & C++ in Windows and Linux

So, I ran into a little bit of a programming problem involving the C call “tmpnam” which is used to generate you a temporary file name in C and C++. It's not a safe call, because other libraries and applications might call “tmpnam” before you get to use the name given, and they might grab the same file name. But my code needed to generate just a file name... so this will suffice for me (I'll so checking etc. myself).

Anyway, the problem comes up when, in a mix of brain-dead and bad document mode I do this:

char* l_temporaryBuffer = new char[L_tmpnam];
int l_error = tmpnam (l_temporaryBuffer, l_tmpnam);

It leaked memory, in fact it leaked 12 bytes per call, and I was just so brain frazzled at 2am last night that I couldn't wrap my head around why, in the cold light of day however I know why, its because I'm a cock, the 12 bytes were from this buffer... you don't need to assign memory to the buffer you pass in, tmpnam stores the resultant string in a static location.

This was painfully demonstrated when I tried to delete l_temporaryBuffer and was promptly told I had corrupted my application's heap.

So, the correct way of using tmpnam, on Windows and Linux is:

char* l_ptrBuffer;
l_ptrBuffer = tmpnam(NULL);

Or if you're going to use windows you'll likely get a warning that tmpnam is unsafe, and if like me you heed the advice of your warnings (as you all should) you'll want to use tmpnam_s, so on Windows the corrected code is:

char *l_ptrBuffer;
int l_error = tmpnam_s (l_ptrBuffer, L_tmpnam);
if ( error == 0 )
{
    // use the buffer it's valid
}
else
{
    // Scream blue murder the file name is invalid
}

What you should never do is delete[] l_ptrBuffer. In this code, it's not your string to delete, its a static in your runtime.

Likewise if you use tmpnam and get a heap corruption, it maybe because you are disposing of memory which is not yours. Beware.