Personal tools
You are here: Home technical-info
Tag cloud
christchurch cssxhtml food-and-drink general japan kiwipycon lca2010 linux nzpug plone sci-fi technical-info zopeplone
Topics
Topics in Detail…
Our Sponsors
 

technical-info

26-10-2007

How I Restored My QEMU Windows XP Environment

Filed Under:
Recently I had to setup Enfold Server on Windows XP and as I run Kubuntu on my notebook, the virtual environment I've chosen to run Windows under is QEMU. I've been running QEMU for some time now and it provides all the features I need in a virtual machine, especially with kqemu installed. When I was in the process of setting up Enfold Server, though, I accidentally loaded the same QEMU image twice and the 2nd instance started running a CHKDSK on the drive and writing to it. After closing the 2nd instance down and restarting the already running Windows XP QEMU instance, Windows XP would get as far as the loading Windows XP screen and then cyclicly boot. I then attempted to mount the QEMU image (as it was in the RAW format) but when I did, I got the following error message: "primary boot sector is invalid". This was when alarm bells really started to ring as I'd put quite a lot of time and effort into this Windows XP QEMU image (including setting up all the Internet Explorer browsers and Safari for Windows), and unfortunately due to a file size error I was getting when attempting to backup the QEMU image, I didn't have a backup! After fruitlessly googling around for a resolution, I decided I'd attempt to boot off the Windows XP cdrom and attempt to recover the image that way. The following are the steps I took to restore my QEMU Windows XP Environment:
  1. Booted off the Windows XP cdrom by typing the following at the command prompt:
    qemu winxp.img -cdrom /dev/cdrom -boot d
  2. When the "Welcome to Setup" screen appeared, pressed R to start the Recovery Console.
  3. Executed the FIXMBR command from the Recovery Console.
  4. Ran a CHKDSK to fixup any other problems that may have existed.

17-05-2007

I Beat Paul Everitt To The Punch

I gave the first Plone speech at a well known academic research institute in Taiwan.

I had the honour of giving the first Plone speech at the Academia Sinica in Taipei, Taiwan recently. TsungWei Hu, who arranged for me to give the speech, manages the Open Source Software Foundry (OSSF) project, whose key objectives are to promote Open Source Software in Taiwan. TsungWei mentioned that he had been meaning to ask Paul Everitt to give a speech regarding Plone at the Academia Sinica (Paul - hint, hint) but hadn't, so I got in first ;-)

TOSSUG MeetupThis speech was the last in a series of Plone presentations I have been giving. The first of which was in Tokyo, Japan, and the next was for the Taipei Open Source Software User Group (TOSSUG). At the TOSSUG meetup I was able to meet Sean Moss-Pultz and Harald Welte of the OpenMoko project. Sean is the General/Technical Manager for the OpenMoko project, while Harald is the Lead System Level Architect. As I'm an Open Source fan and enjoy hacking my own computer, I'm really excited about what Sean, Harald and the rest of the OpenMoko Core Team are doing as mobile phones in general are pretty much closed devices nowadays.

13-02-2007

Achieving Server Xen

Filed Under:

A summary of my experiences installing Xen 3 on Debian Etch.

Recently I had to setup Xen 3 for a client, and the following are the steps I undertook to install it (N.B. As a guide for the installation, I followed the instructions listed here).

The most pertinent hardware specifications for the server we installed Xen 3 on are as follows:
  • 2x Intel Xeon 1.6 Ghz CPUs
  • 4GB DDR2-667 RAM
  • 3ware 9550SX-4LP PCI-X-to-SATA II RAID controller
  • 4x Seagate Barracuda ES SATA 3.0GB/s 250GB hard drives (configured as RAID 5)
  1. Firstly, I downloaded and burned the Debian testing (etch) netinst CD image to CD.
  2. Following this, I began installing Debian etch on the server using the netinst CD.
    At the disk partitioning screen, I setup the hard drive as follows:
    Disk /dev/sda: 749.9 GB, 749966721024 bytes

    255 heads, 63 sectors/track, 91178 cylinders
    Units = cylinders of 16065 * 512 = 8225280 bytes

    Device Boot Start End Blocks Id System
    /dev/sda1 * 1 365 2931831 83 Linux
    /dev/sda2 366 1581 9767520 8e Linux LVM
    /dev/sda3 1582 4013 19535040 82 Linux swap / Solaris
    /dev/sda4 4014 91178 700152862+ 8e Linux LVM

    N.B. The /dev/sda4 LVM partition is where the logical volumes for the Xen guest domains (virtual servers) are to be stored.
    I left the rest of the installation steps at their setup defaults.
  3. I then installed Xen 3 on the server by entering the following command:
    apt-get install xen-linux-system-2.6.18-3-xen-686 xen-tools \\
    xen-docs-3.0 libc6-xen file xen-hypervisor-3.0.3-1-i386-pae \\
    xen-linux-system-2.6.18-3-xen-vserver-686 bridge-utils
  4. Following this, I made the following change in the /etc/xen/xend-config.sxp file and rebooted the server:
    replace
    (network-script network-dummy)
    with
    (network-script 'network-bridge netdev=eth0')
  5. I now made the following changes to the /etc/xen-tools/xen-tools.conf file:
    lvm = vservers
    debootstrap = 1
    size = 10Gb
    memory = 512Mb
    swap = 1Gb
    fs = reiserfs
    dist = etch
    image = sparse
    kernel = /boot/vmlinuz-2.6.18-3-xen-vserver-686
    initrd = /boot/initrd.img-2.6.18-3-xen-vserver-686
    mirror = http://debian.orcon.net.nz/debian

  6. Following this, I created a new guest domain (or virtual server) on the server by entering the following command:
    xen-create-image --hostname myservername.mydomain.co.nz --dhcp
  7. I then booted the guest domain by entering the following:
    xm create /etc/xen/myservername.mydomain.co.nz.cfg
  8. I now connected a virtual console to my newly created guest domain by entering the following and then logged on as root:
    xm console myservername.mydomain.co.nz
  9. Finally, I set the root password and then logged off the
    virtual console by typing CTRL+] and then made a ssh connection to the guest domain and started setting up the services on it.

24-12-2006

Sysadmin Stresses

What helped me to sleep at night.

This may be my last post as a sysadmin as like some other people, I've discovered that being a sysadmin has its own challenges, most especially the need to be constantly available, as computer systems can fall over at any time. Something, though, that proved invaluable in my previous role was some Systems Monitoring software called Zenoss (another attraction was that it runs on Zope!).
After ensuring I had the prerequisite software, the installation wasn't difficult. It was a bit of a nuisance that Zenoss creates its own Zope instance but the specific python products it installed within the Zope instance really required this for ease of setup.
Once the Zenoss server software was installed, I then had to configure the network devices to notify Zenoss via SNMP of their current status. Though the organisation where I worked had a few varied operating systems and devices, this wasn't a problem. SNMP Informant (with the MBM module for CPU, case, and component monitoring), Syslog, and Zenwin provided monitoring for the Windows 2003 server (there were some gotchas with the setup of the SNMP service but a big thanks to #zenoss as they helped me resolve the particular issues I had). The snmp package took care of my Linux boxes and Zenoss' builtin Cisco support provided monitoring for the Cisco router.
Once I had added all the network devices, I then setup Zenoss to send notifications via email whenever specified Zenoss events occured.
When Zenoss is notified of an event it categorises the event by such things as type of event, severity, etc. When Zenoss is unsure of how to categorise an event, you can categorise it manually. Zenoss can use this criteria for its event notification system.
Something that really impressed me about the Zenoss project was that when I subscribed to the mailing list, I requested a Zenoss t-shirt and though I live at the bottom of the world in New Zealand they sent me one!

30-08-2006

Setting Up Windows Active Directory LDAP Authentication In Plone 2.5

Filed Under:

A howto regarding setting up authentication against Active Directory in Plone 2.5 (PlonePAS)

Emerge Technology had an enquiry from a client recently regarding setting up authentication via Active Directory in Plone 2.5. I share our response here for the benefit of anyone else who wishes to do this (the test environment I setup included Microsoft Small Business Server 2003, Zope 2.9, and Plone 2.5):

One recommendation I would have is that you install LDAPMultiPlugins1.2 (available from here http://www.dataflake.org/software/ldapmultiplugins/ldapmultiplugins_1.2) and remove LDAPUserFolderExt-0.41 (As per normal Zope Product installation procedures you will need to stop and start your Zope instance after installing the product).

Following this, do the following:

  1. Go to acl_users and add a 'ActiveDirectory Multi Plugin'
  2. Go to 'Contents' of the new plugin, go to 'acl_users' and configure your LDAP settings there. You can test if it works correctly by searching for users via the 'Users' tab
  3. Setup your LDAP Schema mappings to Plone fields in the 'LDAP Schema' tab
  4. Go back to the ActiveDirectory Multi Plugin and enable the functionalities you require in the 'Activate' tab.

Powered by Plone, the Open Source Content Management System