Oct 272009
 

Whether you are using ufs filesystems or zfs storage pools, Solaris has a rather nifty way of migrating storage from one SAN to another wih no (or little) downtime. Or various other reasons involving moving from one disk to another. The key advantage to the following method is to reducing or eliminating downtime. Even if your users can take the hit, not having to slowly watch a multiterabyte filesystem copying from one disk to another is reason enough to use this technique.

Basically it is by using mirroring. Using mirroring to copy a disk might seem a little odd to begin with, but once you’ve seen it work you’ll be a fan.

For UFS (and SVM) Filesystems

This section assumes that the source disk device (cXXXXX) is set in the variable ${sourcedisk} and the destination is in ${destdisk}.

For UFS filesystems, the first step (which does require an outage) is to :-

  1. Stop the application that uses the filesystem being migrated.
  2. Unmount the filesystem.
  3. Encapsulate the existing filesystem device into a SVM metadevice: metainit d1001 1 1 ${sourcedisk}
  4. Create a mirror device with the new metadevice as a submirror: metainit d1000 -m d1001
  5. Change the references in /etc/vfstab to the old device name (${sourcedisk}) to the new mirror (not sub-mirror!) device – d1000
  6. Remount the filesystem and restart the application.

This should take no more than 10 minutes and is the only outage involved. There are two remaining sets of steps :-

  1. Create a new metadevice using the new disk: metainit d1002 1 1 ${destdisk}
  2. Attach the new metadevice to the mirror as an additional sub-mirror: metattach d1000 d1002

At this point, the mirror will start resilvering. It may take some time to complete, but the time it takes to do so does not really matter. In particular the resilvering process should not cause a performance problem to your application – the application I/O takes priority.

When the resilvering is complete :-

  1. Remove the metadevice containing the old SAN disk: metadetach d1000 d1001
  2. Remove the metadevice that is no longer required: metaclear d1001
  3. Attach “nothing” to the mirror metadevice (this is to ensure that the mirror grows to the size of the new submirror): metattach d1000
  4. Finally, ignore the warning on the manual page (which is outdated) and grow the filesystem: growfs -M /mount/point /dev/md/rdsk/d1000

You will see that I have used the metadevice names d1000 (for the mirror), d1001 (for the old sub-mirror), and d1002 (for the new submirror). Whatever device names you use, it is worth trying to be consistent – it helps a lot when you have dozens of filesystems to process.

ZFS Storage Pools

This is even simpler. If you have a storage pool called ${pool} which contains a single device called ${sourcedisk}, you simply :-

  1. Attach the new device: zpool attach ${pool} ${sourcedisk} ${destdisk}
  2. Wait for the resilvering to finish.
  3. Dettach the old device: zpool detach ${pool} ${sourcedisk}

Of course be aware of anything you read on the Internet! I have not actually tested the above; I’m merely regurgitating memory that has recently been exercised – I’m doing a SAN migration at work right now.

Oct 222009
 

The BBC have invited Nick Griffin – the head of the BNP neanderthals onto Question Time (a public question and answer forum with a panel of politicians of various kinds). Of course there is a lot of fuss about this – any self-respecting person of almost every political persuasion is horrified at the prospect of seeing the BNP use national TV to peddle their filth. The BBC’s argument is that the BNP has achieved sufficient electoral success for them to be invited to take part – along the same lines as the Green party receive invitations.

The BBC has pointed out (quite rightly) that their role is not to impose any form of political censureship and if the BNP has achieved the level of electoral success that allows other political parties to be included in programmes such as Question Time, then they cannot legitimately not include the BNP. Given the amount of time that has passed since the BNP achieved its electoral success in the last European elections, the fault for “allowing” the BNP to take part in Question Time must be passed directly to those in parliament who hae not passed legislation prohibiting the BNP from being heard on TV or radio (as happened to Sinn Fein in the 1980s).

There is an argument that says that because we have free speech, we should allow Nick Griffin to spout any kind of rubbish he wants to on Question Time. Well, perhaps although our tradition of freedom of speech is not unlimited. And certainly Nick Griffin’s freedom of speech does not give him a license to spout his rubbish on Question Time.

Of course Nick Griffin’s appearance on Question Time does allow us to more easily see how foolish and immature his views are. Interestingly he has already portrayed just how deranged he is even before the programme when he was making comments on the way to the studio.

He claimed that the reason that the Labour Party had paid for protesters  to show up outside the BBC studios. Whilst I do not have any evidence to refute this, it does seem more than a little ridiculous to think that the anti-fascist protesters would need paying to turn up. Especially when you consider that protesters have shown up outside regional BBC offices – why would anyone pay for them to appear there when they could have been paid to appear in London ?

Let’s have a look at some of his statements …

“I am the most loathed man in Britain”

I somehow doubt it. He just isn’t that significant. Compare Nick Griffin with some of the British monsters like Harold Shipman.

“We are the aborigines here”

Presumably meaning that the English white people originally arrived in the UK shortly after the last ice age finished. Well perhaps there are some still left but the UK has seen immigration ever since the ice age – first of all Celts (yes! they didn’t originally come from here), Angles, Saxons (the BNP of course lump the two into the mythical “Anglo-Saxons”), Vikings, and Normans.

And of course the Romans who undoubtedly left more than a few genes behind. Which undoubtedly included a few ‘black’ genes given that they also (in their later days) included “native” troops in their army and shipped them around to where they might be needed. Wouldn’t it be funny if Nick were “tainted” with a bit of “black blood” ? I’m not normally given to using such phrases; I don’t believe in them, but old Nick would certainly be upset if he found out he wasn’t “pure white”.

At least in the UK, the whole concept of “indigenous” people at least in terms of “aborigines” is foolish in the extreme and shows an immense ignorance of British history. Really quite peculiar for someone thinks they are as patriotic as Nick undoubtedly thinks he is.

The reason behind Nick’s blatant racism is that he is terrified of being swarmed under by hordes of non-British immigrants. Even ignoring that immigration makes Britain a more dynamic and interesting place, such fears show that the racists are the kind of people who need to take their socks off to count beyond 10. If you look at the statistics, 92% of the current population of the UK is white. We’re hardly in danger of disappearing!

“I can’t explain …”

In relation to his allegedly changed views on the truth of the Jewish holocaust in WWII. Of course the obvious conclusion when he claims he cannot explain himself due to European law is that his views have not changed and that he still denies the holocaust. Or perhaps he refuses to accept the holocaust because he would loose his core supporters if he did.

And of course there is no European law in force in this country against denying the holocaust; that clause of the law can be blocked in individual countries who feel that it is an unacceptable limit on freedom of expression. And yes the UK opted out of that bit of the law. It is interesting that someone who has previously denied the holocaust and is a European politician is ignorant of this!

“You can stay …”

In response to a question from an Englishman asking whether he (not white enough for Nasty Nick) would be allowed to stay in a BNP controlled country. Kind of contradicts the BNP website (and the constitution) where it is campaigning for a white Britain. Which one is it ? Are you confused Nick ? Or just lying ?

“Adolf (Hitler) went a bit too far”

Which was not something that Nick said on the programme itself, but something he is supposed to have said in a video. The interesting thing that came out in the programme is that Nick consistent denies having said embarrassing things in the past even when there is clear evidence that he did say such things.

It was plainly obvious that you simply cannot believe any denials Nick makes.

Oct 202009
 

Now we all know that the BNP are the lowest form of scum in the political cesspool … even low and putrid enough that they cause other politicians to feel nauseous. But in a long history of astonishing ineptitude and a quality of thought that would bring shame to any self-respecting cockroach, they have managed a piece of grossly offensive stupidity. They are using various military images to promote their pathetic and ridiculous creed. One of the images used is the that of a spitfire which previously caused a row in early 2009. In addition the BNP have tried to lay claim to the British Legion’s poppy symbol which is also pretty offensive.

The opposition to the BNP using military images comes initially from some old generals. Now I’m hardly a fan of the British military and I’m certainly not normally on their side. But they’re definitely right – using the military images to inflate the BNPs “Britishness” is definitely wrong. And offensively wrong given that many of those involved in the British military (including the WWII military!) were not the kind of people that the BNP would approve of. Personally I’d say there’s a lot to be said to being the kind of person that the BNP would not approve of – after all there is no chance that anyone would mistake you for being one of them!

The BNP would have you believe that the immigration “issue” of today is comparable to the attempted invasion by the Axis forces in WWII. This is preposterous in numerous ways and shows pretty well that the members of the BNP are at best woefully and dangerously delusional. First of all, an invasion is vastly different to a migration; in fact an invasion does not even require permanent residence for many of the invasion force. Even more an invasion is a rejection of our society and standards whereas a migration is an acceptance of the same (the migrant might change his or her mind later on).

Secondly the war against the Axis forces was not simply defeating an attempted invasion of Britain. It was bigger by far than that. The war started before the attempted invasion and went on long after the invasion was turned back. It was very much the realisation that the cancerous beliefs of fascism could not be tolerated and that defeating fascism was of sufficient value that the masters of capitalism felt that allying ourselves with the “evil communists” was the lesser of two evils. Whilst Nick Griffin is no more than the palest shadow of a buffoon alongside someone like Hitler, and the BNP are similarly shown to be inadequate alongside the Nazi party, they are very much cut from the same mould.

Nick Griffin and his mindless thugs (look at their criminal records sometime) would be very happy in a world where Britain had been defeated by Nazi Germany. After all they could persecute their favourite ethnic minorities in any way they wished.

Comparing the “struggle” against immigration to the struggle against fascism and Nazi Germany is a slap in the face of every veteran who fought in WWII.

I notice that the BNP website today still shows :-

  • A red poppy (pah!)
  • A photograph of a spitfire (perhaps not the same photo they used in early 2009 which was flown by a Polish pilot)
  • And a picture of Churchill.

I somehow doubt that Churchill or his descendants would be too pleased about his image being used to popularise the BNP scum. The funny thing is that this great British leader may not have been quite British enough to be allowed to join the BNP – his mother was American and there is a chance that her descendants include Iroquois and/or Jews (neither of which are any form of “stain” of course), and considering his father came from the British aristocracy was likely to be not quite so British as the BNP would like. If you read the BNPs constitution, the clause concerning membership (quite possibly to be removed shortly) restricts membership to a wide variety of different “folk” people (indicating a rather confused grasp on British history), but excludes various proto-French ethnic groupings which could well exclude Churchill (at which he breathes a huge sigh of relief, or would if he could).

The BNPs big “thing” is race. They might well appear on TV or in other forms of media campaigning on other issues, but it’s still written large in their constitution that they want to return Britian to some pre-1948 mythical “white” utopia. Well first of all, the whole white thing is a bit mythical in itself – it’s only when you look at us from a distance that we look white; look a bit closer and you start to see differences (English, Welsh, Scottish, etc.). Secondly Britain has long been a home to people whose ancestors weren’t European.

And it is doubtful that the proto-English that the BNP want us all to revert to were all that concerned about “racial purity”. The Saxon warlord who defeated the last Celtic king around these parts, and went on to found the House of Wessex was called “Cerdic”. His name indicates that his ancestry included some Celtic blood somewhere (the most popular theory was that his mother was Celtic) in addition to his Saxon blood. For the benefit of those whose history is as poor as the BNPs most undoubtedly is, this “House of Wessex” later went on to unite the newly formed kingdom of England – the most important Saxons of the “Anglo-Saxon” peoples.

And now that I’m been writing of the BNP, I’m in urgent need of a long, hot cleansing bath to take away the stench.

Oct 172009
 

If you are old enough to remember a time when if you were really lucky you might have access to a computer over a 9600 baud serial line connecting with a terminal, you may well have encountered the Compose key on DEC serial terminals (or in many other places). If you aren’t, I’ll have to explain what they are …

Imagine you have a US or UK keyboard, and suddenly have a need to enter an accented character (such as ü) – perhaps in a place name or perhaps you simply want to spell “café” properly for once. If you look at your keyboard you’ll find that the relevant characters do not appear anywhere. One of the solutions to this are the “dead letters” where certain symbols (such as “) work by putting the mark on the key over the next letter you type.

This apparently works well enough for those who enter such letters every other word or so, but I’m a monolingual Englishman who does not need them so often and I would rather have my quote key left alone thank you very much.

Now imagine a special key on the keyboard. Let us call it “Compose” for the want of any other name. You press it, and a fourth LED on your keyboard lights up. You can then enter any suitable two character sequence to generate accented characters or other symbols (½, «, ¡, ♯, ə, þ, etc.). Perhaps it might stretch your memory a bit remembering all the sequences, but you soon get used to much of it … it doesn’t take much memory capacity to remember that compose, u, ” becomes a ü, and that if you want anything with an umlaut on it, just use compose, whatever needs an umlaut, and “.

Back when I got started in IT, we had a bewildering variety of different types of keyboards with different layouts (and many of which were better by far for typing than most modern crud). For better or worse the IBM keyboard layout effectively won (the Macintosh keyboard is an IBM one with a few extra function keys and some of the modifiers relabelled). One of the big losses was the lack of a Compose key.

Let’s have it back!

Oh! And if you are going to have an “Alt GR” key to function as a “shift” key to enter funky symbols, please engrave the symbols on the front of the keys. You will notice that where the Shift key produces a different symbol, the different symbol is shown on the key – see the 1 key with ! shown.

Oct 162009
 

For some reason the term ‘wardrobe malfunction’ has come to be used in reference to those little ‘accidents’ that happen to people when their clothing slips to reveal a little more than is conventional. For some peculiar reason this seems to happen more frequently with famous people and even more frequently when cameras are rolling.

However that’s not the reason I’m writing this. Who first coined the phrase ‘wardrobe malfunction’ in reference to incidents of this kind ? Said person needs to be gently informed that a more correct phrase would be ‘clothing malfunction’ seeing as it is the clothes that are causing the problem.

A wardrobe malfunction relates to those tall cupboards that store clothes. A malfunction of one could be one of the following :-

Whilst opening the door, you trip and fall into the wardrobe and get tangled up in the clothes and have to call for your partner to help you get released. Who is out in the garden at the time and doesn’t hear your calls until they come in a few hours later.

Or you pull open the door and the door falls off, lands on your foot to cause you to jump about in pain and to fall backwards down the stairs.

Of course there are those who will say that one of the meanings of “wardrobe” is clothes themselves. Maybe so, but that refers to a collection of clothes. You do not wear a collection unless you want to get hot and sweaty to the point of unconsciousness.