Grant McWilliams
  • Food
    • Blog
    • Websites
    • Seattle Food Events
    • Seattle Farmers Markets
  • Travel
    • Travel Blog
    • Travel Photos
    • Travel Links
    • Trip Journals
      • Europe - 2015
      • New Orleans - 2013
      • Central Mexico - 2010
      • Toulouse/Paris - 2009
      • Paris/Lyon - 2008
      • Peru/Ecuador - 2007
      • British Columbia - 2007
      • Central Mexico - 2006
      • Eastern Europe - 2006
      • Washington D.C. - 2006
      • Where's the rest?
  • Technology
    • Gadgets
      • Blog
      • Websites
      • Android
      • Nokia n900
      • SailfishOS
    • Technology
      • Blog
      • Websites
    • Virtualization
      • Virtualization Blog
      • Websites
      • Xen Howtos
      • Xenserver Howtos
      • KVM Howtos
      • VirtualBox Howtos
      • Virtual OS images
      • Xenapi Admin Tools github
    • Programming
      • Blog
      • Bash
      • Python
      • Websites
      • Downloads
    • Transportation
      • Blog
      • Websites
    • Sustainable Tech
      • Blog
      • Websites
  • Photography
    • Blog
    • Portfolio
  • Random
    • Grantianity
      • Basics
      • Grantisms
      • The River of Life
      • Bus Maintainance
      • Believing in Yourself
    • Creative Writing
    • Login/Logout
    • About

Tech

Xen disk images vs LVM

Details
Category: Virtualization Blog
July 8, 2008

 

In setting up a Xen virtualized web server with about 15 GB of static files I questioned the wisdom of using a disk image as apposed to LVM. I read a bunch of forums about which is better and it seems the disk images are easier to manage because you can just copy to make backups etc.. LVM you just can't move it and pop it up whereever you want but you have more flexibility in resizeing and backing them up within the host OS. However what I didn't find on the forums is performance tests. People theororized about the speed difference but it seems nobodies sat down and done some tests. It's my goal that after summer vacation to put together a performance whitepaper comparing all the virtual machine solutions. For now I'll just put up xen disk images against LVM.

So I created a 10 GB empty disk image using dd and I created a 10 GB LVM Logical volume and assigned both of them to the domU.

 

name = "centtest"
memory = "512"
disk = [ 'tap:aio:/srv/xen/centos5.img,xvda,w', 'tap:aio:/srv/xen/centtest.img,xvdb,w', 'phy:/dev/vgsys/lvtest,xvdc,w' ]
vif = [ 'bridge=xenbr0', ]
bootloader="/usr/bin/pygrub"
vcpus=1
on_reboot = 'restart'
on_crash = 'restart'

Read more …

Create a Zimbra mail server on Xen

Details
Category: Xen Howtos
July 6, 2008

I this tutorial we'll set up a Xen domU specifically for Zimbra because it likes to take over an entire machine. We'll also set up authenticated mail sending via gmails smtp servers and configure our router to forward requests to the appropriate domU. Lastly we'll use Apache on another machine (virtual or not) to proxy web connections to our DomU.

 

You will want to follow the Create a Centos virtual machine on Xen tutorial before continuing with these instructions. Once you have created your Xen Virtual Machine running CentOS5 proceed with this tutorial.

 

Preparing for installation

Before you install Zimbra you want to set the network settings and hostname. I would advise you to set a static IP address for the Virtual Machine as well as setting the hostname to something unique. If this Virtual Machine is behind a NAT you'll get errors about the DNS name not being able to be resolved. We can edit the /etc/hosts to get rid of those.

/etc/hosts

192.168.1.102   mail.soundlinuxtraining.com

/etc/sysconfig/network

NETWORKING=yes

NETWORKING_IPV6=yes

HOSTNAME=mail.soundlinuxtraining.com

Edit system network settings - set IP address, Netmask etc.. and set the current hostname

system-config-network
hostname mail.soundlinuxtraining.com
service network restart

Shut down Sendmail to avoid conflicts on port 25

service sendmail stop
chkconfig sendmail off

Before installing Zimbra we'll install some of it's dependencies.

yum install fetchmail gmp compat-libstdc++-296 compat-libstdc++-33 libtool-ltdl 

Installing Zimbra

We need to download Zimbra in order to install it.

Read more …

Centos 5 virtual machine (32 bit) installation on Xen

Details
Category: Xen Howtos
July 5, 2008

 

 

A lot of this tutorial was stolen from the CentOS wiki - http://wiki.centos.org/HowTos/Xen/InstallingCentOSDomU. I've shortened it by quite a bit to make it easier.  I assume you know this already but you will need to be logged in as root or have root privileges in order to execute this tutorial.

Creating an Image

The first step is to create an image that will hold the domU virtual disk. Since this can just be a file filled with zeros, our usual friend dd comes in handy.  The following command will create a /srv/xen/centos5.img file of 11GB, although the actual data blocks are allocated in a lazy fashion meaning that the disk image doesn't actually take up the whole 11GB until you fill it up. This is referred to as a sparse file.

 

dd if=/dev/zero of=/srv/xen/centos5.img oflag=direct bs=1M seek=10240 count=1

 

Preparing the Xen configuration file for installation

Xen uses one configuration file per domain. The configuration for the domain will be slightly different during the installation, because we have to provide installation kernels, and possibly some boot parameters. Here we download the installation kernel, ramdisk and xen config file.

Read more …

New blogging component for Joomla

Details
Category: Joomla!
June 26, 2008

The start of something great

  • akocomment
  • Bookmarks
  • Jootags
  • weblog ping
  • article calender

Upgrade Nokia n800/n810 firmware to Diablo

Details
Category: Nokia Tablet
June 26, 2008

If you want to reflash your brand new Nokia n800/n810, follow the steps below:

  • On the n800/n810 run the Backup/Restore app and backup all your data to a flash card
  • On a Linux PC download the Linux flasher-3.0
  • In the same directory download the latest firmware image. As of June 26th, 2008 it's Diablo:
    • n800 - OS 2008 firmware
    • n810 - OS 2008 firmware
  • Make sure the battery of your n800/n810 is fully charged.
  • Unplug the charger and switch off the Nokia n800/n810.
  • Connect the tablet to your computer via USB without turning it on
  • On the Linux PC execute as root:
  ./flasher-3.0 -F RX-34_DIABLO_4.2008.23-14_PR_COMBINED_MR0_ARM.bin -f -R
  • It should display: "Suitable USB device not found, waiting" in the terminal window
  • While holding the "home" button (the bottom one with the house on it), plug in the charger or push the power button.
  • You should see the upgrade status on the n800/n810 after which it reboots automatically -- you're done now!

You might find that if you've stored the firmware and the flasher on a remote network filesystem you might get a permission denied message. If this happens just move both to a local filesystem until you're done flashing. Once you've written the firmware you'll want to configure networking and check for updates.

  • Connect to a wireless network (may need to reconfigure network security)
  • Start Application Manager - Settings -> Application Manager
  • Enable Extras catalog - Menu -> Tools -> Application Catalog
  • Insert flash card with recent backup
  • Start Backup/Restore -  System -> Backup/Restore
  • Choose most recent backup and select the Restore button
  • Select data to restore, make sure Application list is checked
  • It will reboot when done

 

Convert a Qemu image to Vbox vdi

Details
Category: Virtualization Blog
May 26, 2008

 

To convert a QEMU qcow format disk to VirtualBox vdi format you need to have Qemu installed. Qemu has tools to help convert disk formats.

grant@workstation:~$ qemu-img convert hda-qcow.img -O raw hda.img
grant@workstation:~$ VBoxManage convertdd hda.img hda.vdi
VirtualBox Command Line Management Interface Version 1.6.0
(C) 2005-2008 Sun Microsystems, Inc.
All rights reserved.

Converting VDI: from DD image file="hda.img" to file="hda.vdi"...
Creating fixed image with size 1024966656 bytes (978MB)...


This will convert a QEMU qcow format disk image to VirtualBox vdi format.

 

 

Virtual disk formats

Details
Category: Virtualization Blog
May 26, 2008

The problem with Virtualization systems is none of them want to standardize on one particular disk format. Actually they all do, they want their format to be the standard.

  • VMware has VMDK
  • QEMU has qcow and qcow2
  • UML has cow
  • Parallels has HDD
  • VirtualPC uses VHD
  • VirtualBox has VDI
  • Xen uses raw disk images

To make matters more confusing VirtualBox has some support for VMDK, Commercial Xen supports VHD, the open source Xen supports qcow2 and Qemu can convert between many formats. So what I'm doing about this is putting up a series of Howtos in the Tech -> Virtualization areas on how to convert and use various disk formats in different Virtualization systems. To start with I just put together the following two Howtos.

Read more …

Intel chipsets with IOMMU support

Details
Category: Virtualization Blog
May 26, 2008

When Intel and AMD added hardware virtualization support to their CPUs it was a boon to those of us trying to virtualize Operating Systems that don't know they're being virtualized. KVM the somewhat native Linux virtualizer built into the kernel only operates in this mode so you need a CPU with Intel VT-x or AMD-V support built into it and the ability to turn it on in the BIOS. This seems like a really great thing but in reality anyone wanting to extract the maximum performance out of their Virtualization machine is going to be using paravirtualization anyway (sorry KVM). Everyone is working on paravirtuaization including the KVM folks. So the addition to VT extensions in the CPU are really not getting used much besides those that don't have a choice (ahem, KVM). A year from now people using KVM will be using paravirtualized drivers because they're just plain faster. VirtualBox uses a mix of software emulation and virtualization depending on what's fastest. Xen will run in both Full Virtualization (HVM) or paravirtualization (PV) modes depending on how you set it up. There are limitations to PV mode though becuase it's using the same QEMU code that KVM uses. They will reach parity in installation modes between PV and HVM soon though. The cool thing about everyone using QEMU (KVM, Xen, VirtualBox etc..) is that if you change the code once the rest get the updates. Isn't that the way it's supposed to work in the Open Source world?

Anyway the point of this article is not to talk about VT but IOMMU. The problem with Virtualization systems like Parallels and Xen are that they're passing PCI devices through to guest operating systems which is a good thing but because they haven't had support in the CPUs it's been a bit hacked up. There's been a number of security vulnerabilities with pci passthrough in Xen. All of this is changing because Intel and AMD are adding device virtualization to their kernels. Intel announced it in 2006 and has a number of chipsets that support it and AMD will have their first out next year.

Read more …

Convert raw disk images to vdi format

Details
Category: Virtualization Blog
May 25, 2008

If you're moving from a real server installation to a VirtualBox virtualized configuration you may want to take your real physical disk and just turn it into a virtual disk. There are advantages to creating a new disk and rsyncing your OS into it but this tutorial will show you how to make an exact copy of it. Note the exact copy will be the same size as the real physical disk so make sure you have enough drive space. This is most useful for Operating System images with shared storage for data. I wouldn't advise anyone to make a 1TB copy of their new drive and turn it into a VDI file!

To get the image from the disk use the dd command.

  1. dd if=/dev/hda of=./hda.img
  2. VBoxManage convertdd hda.img hda.vdi
grant@workstation:~$ dd if=/dev/hda of=./hda.img
grant@workstation:~$ VBoxManage convertdd hda.img hda.vdi
VirtualBox Command Line Management Interface Version 1.6.0
(C) 2005-2008 Sun Microsystems, Inc.
All rights reserved.

Converting VDI: from DD image file="hda.img" to file="hda.vdi"...
Creating fixed image with size 1024966656 bytes (978MB)...

This will make an exact copy of /dev/hda to the raw image file hda.img. Then VBoxManage will convert the raw disk hda.img to hda.vdi for use with VirtualBox.

Audio plug USB charger

Details
Category: Gadget Blog
May 23, 2008

Here's an interesting idea. I don't know how much power is sent through headjack plugs but this device from Inflight Power Recharger Cables will allow you to recharge USB devices by plugging into the audio jack. It has one cable that plugs into the audio jack and on the other side it's a standard USB outlet so with the appropriate adapter you can charge about anything. I imagine it doesn't charge very fast but if you're on an airplane asleep you might as well be charging your phone, ipod, Nokia web tablet or whatever. Price is $35 for the basic one with no adapters and then add about another $10 for each adapter. Or you could just go online and buy the adapters for abotu $5 ea. It also has 2 AAA batteries in it so I'm guessing it can double as additional battery power for your gadget if it's not plugged in.

I contacted them about the methods of charging the batteries and here's what they said.

"You can only power via audio input or battery input, the unit can use
any form of AAA battery. The max output is 250mA at 5v."

The only real problem I see is you can't charge your device while watching a movie on the plane, and any other time you'd have to look around for a radio or laptop in order to charge it up. It seems like the standard Wall outlet to USB backup may be more versatile everywhere except the plane. I guess if you normally charge things with you laptops USB port you could charge this and a USB device at the same time. Makes me wonder if someone makes a USB to audio jack adpater so I could charge this from a USB wall converter. Maybe I'm getting a bit carried away but I bet one could hack a USB to audio jack adapter pretty easy.

I might buy one anyway and review it just beause I'm curious.

 

  • 7
  • 8
  • 9
  • 10
  • 11
  • 12
  • 13
  • 14
  • 15
  • 16

Page 15 of 16

Search