Cloning Ubuntu installation

26 04 2009

Hi you might want to upgrade your disk from time to time, so you either need to clone or ghost it. Heres how I do it.

First prepare the disk with the GUI tool gparted. I like to have a few partitions, one for winblows, one for winblows games, one for ubuntu and one ext3 for storage.

Then copy your system (remember not to have too many apps open at this time wierd stuff could happen once you start up the other disk)
Open a terminal and write:

sudo rsync -a -x --exclude /media/newdisk / /media/newdisk

Make grub active on the new disc, in the same terminal or another write:

grub> setup (hd0) (hd0,0)

Which installs grub into the MBR of hd0 (hda) using the boot files that were already in /boot on hd0,0 (hda1).

Now you can do "kernel (hd0," and then tab in the grub command line to find partitions. Once you identify your drive you should also be able to do the math for the partition.

Okay almost done, now we have to go edit the grub menu.list located under the /boot folder of the new disk, ubuntu are using uuids to identify partitions. So it’s time to open gparted again, remember that we did it the last time from a terminal, we do the same thing again “sudo gparted”, and find the partition where you copied the system to and then right click and press info now theres a field called uuid, copy paste those into the appropriate of the menulist like here :

example

title Ubuntu 9.04, kernel 2.6.28-11-generic
uuid 49753240-3c10-4fdb-a624-6b07b5071d09
kernel /boot/vmlinuz-2.6.28-11-generic root=UUID=49753240-3c10-4fdb-a624-6b07b5071d09 ro quiet splash
initrd /boot/initrd.img-2.6.28-11-generic
quiet

title Windows XP Home
uuid 4D9D89C529CA8435
makeactive
chainloader +1

So before wiping the old disk I suggest that you try booting the new one, just in case something went wrong. I had no troubles with it, but it’s always nice to have a backup.. Most motherboards today have a option to boot from different disks.

I’ve used this blog here as source http://encodable.com/tech/blog/2006/10/30/Ubuntu_Linux_Hard_Drive_Upgrade
as well as this one http://samuelcheng.wordpress.com/2009/02/04/transferring-ubuntu-to-new-harddrive/





Adjust Webcam settings ubuntu

8 04 2009

My solution was to run this small tool :

luvcview -f yuv -l

I have a creative live im ultra.. Works like a charm.. Now if I could only get my twin display working when I play games!





Integration Testing With Nortel SCE / Part 1

3 04 2009

So you are developing with the Nortel SCE and want todo integration testing. Theres no support for it in the framework itself. So we think and think. The SCE communicates via voicexml or VXML towards the MPS. This happens over http protocol, that means the we can use Jmeter to sniff the communication between MPS and SCE (JBOSS / struts). So in practice to make this work you need to setup the http proxy on jmeter and then go into the SBClient.cfg located here : C:\Program Files\Nortel Networks\SelfService\PERIvxml\config\ on a standard installation , edit these two lines:


client.inet.proxyServer VXIString localhost
client.inet.proxyPort VXIInteger 9000

Proxy server are the machine where you have jmeter running and port are the one you specified when setting up the proxy, id recommend using 9000 since the default 8080 clashes with the SCE Jboss port. After changing the parameters you need to restart the MPS service.

So there are two was of recording, on your local machine using the mock interface provided with SCE / eclipse ( execution view / WVADS ). Or on your test facility where you actually can dial in as normal, and record the scenarios. Just remember when you end Jmeter the proxy goes down aswell, meaning the MPS & SCE can no longer communicate, just comment out the 2 lines in sbclient.cfg to get it working again.

Tips

  1. Remember to switch recording controller in jmeter between scenarios. And one more thing this will only record the dialog between SCE and MPS, not the audio server.
  2. If you add appropriate listeners to your jmeter scenario when you replay you can even see the vxml responses.

Heres how a scenario from a very simple application looks (Just playing a couple of prompts):

SCE Jmeter Scenario

SCE Jmeter Scenario

After recording the scenarios they can now be replayed at wish for example as part of integration test. In the next part I’ll try to digest howto put in test coverage with coberatura, so we get some metrics on how much of our code actually are tested with this approach. Now sadly since SCE does a lot of auto generation I think the process will be partially manual, so we cannot employ a building server like Hudson for this:( If you have any ideas on howto run the SCE auto generation as a MOJO from maven or something please do not hesitate to write. As always comments are more than welcome :)

If you are new to jmeter you can read more here, Jmeter site