find/xargs/grep tricks

Because xargs will die if you have an unescaped quote, but using -0 screws everything up if you’re reading a list of files: sed s/\’/\\\\\’/|cut -d \: -f 1|xargs -i rm “{}” The sed pattern will put the escape character in front of any single quotes so that xargs doesn’t screw up. Using md5sum to […]

,

No Comments

Allowing password-less SSH logins

Because I don’t care too much about what happens to my test servers, I’ve been setting up password-less SSH logins. Using a Linux system to login is trivial, because it’s a simple matter of doing ssh-keygen on the system that will be connecting to the remote server, and just hitting enter until the key is […]

No Comments

Provisioning & management

When I first found Kickstart, I had great joy in customizing my install files. I now have a set of PHP scripts that will create a customized Kickstart file for any install based on parameters passed in the URL. Now, looking into management of VMs (in terms of software), I’ve found that there are actually […]

No Comments

Mirroring Fedora 14 repos

Since I’m a Fedora/RH guy, I’ve been using Fedora 13 for most of my VMs. (The main exception is OpenIndiana, which I have for the ZFS support – It’s sharing my crucial stuff over the network.) Since Fedora 14’s been released, I’m going to move to that to play around with my VM infrastructure. But, […]

No Comments

Virsh/Xend management

Since I can’t really make head or tails of the xend/xenstore and the virsh way of configuring domains to autostart, I’ve just settled with exporting the config files from virsh and converting them to the native xen format. Like so: virsh dumpxml hydrogen > /etc/xen/hydrogen.xml && virsh domxml-to-native /etc/xen/hydrogen.xml > /etc/xen/hydrogen && ln -s /etc/xen/hydrogen […]

No Comments

Recovering VMs when they fail with disk errors

My setup is carving out a logical volume on my domU physical volume, and handing that to virt-install to use as the root disk. Now, it also partitions the LV, then installs LVM on top of it. BUT, that change isn’t passed back to the VM host, so the what’s inside the disk image is […]

1 Comment

Xen 64 bit HVM strangeness

Don’t know if I mis-installed something, but trying to create a 64 bit HVM causes a libvirt error when using Virtual Manager to create a new VM. Namely that the device module “/usr/lib64/xen/bin/qemu-dm” isn’t found. But, qemu-dm exists in “/usr/lib/xen/bin”. So a cp /usr/lib/xen/bin/* /usr/lib64/xen/bin/ later, my OpenIndiana system boots, albeit running as 32bit, not […]

No Comments

Content of Kickstart install file

install lang en_US.UTF-8 keyboard us network –device eth0 –bootproto dhcp –hostname helium rootpw –iscrypted longstringofcharacters firewall –service=ssh authconfig –enableshadow –passalgo=sha512 –enablefingerprint selinux –permissive timezone –utc Asia/Singapore bootloader –location=mbr –driveorder=xvda –append=” LANG=en_US.UTF-8 SYSFONT=latarcyrheb-sun16 KEYTABLE=us console=hvc0″ # The following is the partition information you requested # Note that any partitions you deleted are not expressed # here […]

No Comments

virt-install command for fedora

virt-install -p -r 1024 -n fedora14 -f /dev/domU/fedora14 –location ftp.jaist.ac.jp/pub/Linux/Fedora/development/14/x86_64/os/ -x ks=”chaotic/~kyl191/ks.php?hostname=helium” -p => paravirtualized -r => 1024MB of RAM -n => Name of the new VM -f => file/location to install to (I believe it’s supposed to be an image file, but an LVM partition works just as well) –location => Straightforward, location to […]

No Comments

MAC Address changes when using virt-install

The MAC address seems to change after you use virt-install, which leads to the ifup script complaining that the hardware address doesn’t match what’s in the ifcfg-eth0 file. However, after the domain is defined, the MAC address seems to stick, so the fix is to change the ifcfg-eth0 to reflect the new MAC address.

No Comments