Using virtual serial ports via named pipes in ESX 3.5

Create a named pipe as you typically would as the server on your first VM.

Image

The corresponding entries in the vmx file:

serial0.present = “true”
serial0.yieldOnMsrRead = “true”
serial0.fileType = “pipe”
serial0.fileName = “/vmfs/volumes/472c028b-dd6c1d22-a8f4-001aa0c0b349/Zangief-Fileserver/Zangief-pipe”
serial0.pipe.endPoint = “server”
serial0.tryNoRxLoss = “true”

Create the same named pipe on your second VM, using the same pipe, but connected as a client, opposed to the server.

Image

The corresponding vmx file entries:
serial0.present = “true”
serial0.yieldOnMsrRead = “true”
serial0.fileType = “pipe”
serial0.fileName = “/vmfs/volumes/472c028b-dd6c1d22-a8f4-001aa0c0b349/Zangief-Fileserver/Zangief-pipe”
serial0.pipe.endPoint = “client”
serial0.tryNoRxLoss = “true”

After you power up the VM, you’ll find it strange that the pipe is not visible in the service console.

ls -l /vmfs/volumes/472c028b-dd6c1d22-a8f4-001aa0c0b349/Zangief-Fileserver/Zangief-pipe
ls: /vmfs/volumes/472c028b-dd6c1d22-a8f4-001aa0c0b349/Zangief-Fileserver/Zangief-pipe: No such file or directory

If you connect to it on the second VM however, you’ll see that it works.

Image

VMware VI SDK information

The VI SDK allows you to control VMs and machines managed by an ESX or VC instance.

Here’s a link to the documentation: http://www.vmware.com/support/pubs/sdk_pubs.html

1. A good place to start for a tutorial is the VMware SDK Webinar series here: http://act.vmware.com/servlet/website/R … lipghMM_si

2. The most complete VMware Developer resources are http://www.vmware.com/support/developer/ & http://www.vmware.com/support/developer/vc-sdk/ (includes Porting Guide, Programming Guide, Reference Guide, etc)

Here’s a link to the reference guide: http://www.vmware.com/support/developer … index.html

3. VMware Discussion Forum dedicated to the APIs: http://www.vmware.com/community/categor … goryID=114

[ad#ad-1]

More FUD – MSFT vs. VMware

http://www.forbes.com/2007/12/13/micros … artner=msn

I can’t believe people are writing stuff like this. VMware has a product that’s better in VMware Server and it’s free too!

Read this http://www.infoworld.com/article/07/12/ … iew_1.html and see that you should really be using VMware server which is free and better than HyperV!

How to manually build an initrd for ESX 3.5

notes came from here:

http://communities.vmware.com/thread/116768

Hi,

i managed to get my ESX3.5 to boot and run on a HP ML 115.

onboard raid: yes, this “raid” really sucks, because my rescue cd found 2 controllers/disks -> NO RAID

TODO-List to get ESX-3.5 up and running.

1.) install it from the cd (of course)

2.) reboot with a linux live cd of your choice.

and now i hope that there are no typos…because i created this “script” on my laptop during i tried and tested it on my ESX box!

mkdir /mnt/eboot
mkdir /mnt/eroot

1. /boot of ESX box

mount /dev/sda1 /mnt/eboot

1. /root of ESX box

mount /dev/sda2 /mnt/eroot

mkdir /mnt/eroot/tmp/initrd
mkdir /mnt/eroot/tmp/initrd/extracted
mkdir /mnt/eroot/tmp/initrd/extractednew

cp /mnt/eboot/boot/initrd-2.4.21-47.0.1.ELvmnix.img /mnt/eroot/tmp/initrd

cd /mnt/eroot/tmp/initrd
mv initrd-2.4.21-47.0.1.ELvmnix.img initrd-2.4.21-47.0.1.ELvmnix.img.gz
gunzip initrd-2.4.21-47.0.1.ELvmnix.img.gz
mount initrd-2.4.21-47.0.1.ELvmnix.img extracted -o loop

cd extracted
cd etc/vmware
cp simple.map simple.map.org

vi simple.map
2nd go for SED!

search for 037e
double this line
change one 037e to 037f
save

cd ..
cd ..

dd if=dev/zero of=initrd.img bs=1k count=97000
mke2fs -i 1024 -b 1024 -m 5 -F -v initrd.img

mount initrd.img extractednew -t ext2 -o loop

tar -C extracted/ -cmf – . | tar -C extractednew/ -xmf – .

1. umount initrd.img

umount extracted
umount extractednew

gzip -best initrd.img
ls -alh
mv initrd.img.gz initrd.img

cd /mnt/eboot
mv initrd-2.4.21-47.0.1.ELvmnix.img initrd-2.4.21-47.0.1.ELvmnix.img.org
cp /mnt/eroot/tmp/initrd/initrd.img initrd-2.4.21-47.0.1.ELvmnix.img

cd /mnt/eroot
cd etc
cd vmware

cp pci.ids pci.ids.org
vi pci.ids
2nd go for SED!

search for 037e
double this line
change one 037e to 037f
save

cp pci.xml.merged pci.xml.merged.org
vi pci.xml.merged
2nd go for SED!

search for 037e
double this SECTION
change one 037e to 037f
save

cd pciid
cp sata_nv.xml sata_nv.xml.org
vi sata_nv.xml
2nd go for SED!

search for 037e
double this SECTION
change one 037e to 037f
save

reboot from your resuce system into ESX and JUCHEEEEE….

kind regards,

Reinhard

________________________________________________________________________________________

#!/bin/bash

vmware esx initrd changer
#/bin/bash
Reinhard Partmann
date created: 2007-12-17
date modified: 2007-12-17
version: 0.2
echo “creating directories…”
mkdir -p /mnt/eboot
mkdir -p /mnt/eroot

echo “mounting..”
mount /dev/sda1 /mnt/eboot
mount /dev/sda2 /mnt/eroot
mount | grep sda

echo “copying original initrd file…”
mkdir -p /mnt/eroot/tmp/initrd/extracted
cp /mnt/eboot/initrd-2.4.21-47.0.1.ELvmnix.img /mnt/eroot/tmp/initrd/initrd-2.4.21-47.0.1.ELvmnix.img.gz
cd /mnt/eroot/tmp/initrd

echo “unpacking & mounting original initrd file…”
gunzip -f initrd-2.4.21-47.0.1.ELvmnix.img.gz
mount initrd-2.4.21-47.0.1.ELvmnix.img extracted -t ext2 -o loop
cd extracted
cd etc
cd vmware

echo “changing simple.map…”
echo “10de:037f 0000:0000 sata_nv.o” >> simple.map

cd ..
cd ..
cd ..

umount extracted
echo “replacing original initrd file…”
gzip –best initrd-2.4.21-47.0.1.ELvmnix.img
mv /mnt/eroot/tmp/initrd/initrd-2.4.21-47.0.1.ELvmnix.img.gz /mnt/eboot/
cp /mnt/eboot/initrd-2.4.21-47.0.1.ELvmnix.img.gz /mnt/eboot/initrd-2.4.21-47.0.1.ELvmnix.img

echo “patching xml files”

cd /mnt/eroot/etc/vmware/pciid
lines=`wc -l sata_nv.xml | awk ‘ { print $1 } ‘`
echo “lines: $lines”
(( lines -= 2))
echo “subtr lines: $lines”
mv sata_nv.xml sata_nv.xml.org
head -$lines sata_nv.xml.org > sata_nv.xml

echo ” ” >> sata_nv.xml
echo ” ” >> sata_nv.xml
echo ” sata_nv” >> sata_nv.xml
echo ” ” >> sata_nv.xml
echo ” MCP55 SATA Controller” >> sata_nv.xml
echo ” ” >> sata_nv.xml
echo ” ” >> sata_nv.xml
echo “” >> sata_nv.xml

touch /mnt/eroot/etc/init.d/rp-esxcfg-pciid-boot
echo “#!/bin/bash” >> /mnt/eroot/etc/init.d/rp-esxcfg-pciid-boot
echo “esxcfg-pciid” >> /mnt/eroot/etc/init.d/rp-esxcfg-pciid-boot
echo “sleep 5” >> /mnt/eroot/etc/init.d/rp-esxcfg-pciid-boot
echo “rm /etc/rc3.d/S99rp-esxcfg-pciid-boot” >> /mnt/eroot/etc/init.d/rp-esxcfg-pciid-boot
chmod a+x /mnt/eroot/etc/init.d/rp-esxcfg-pciid-boot
cd /mnt/eroot/etc/rc3.d/
ln -s ../init.d/rp-esxcfg-pciid-boot S99rp-esxcfg-pciid-boot

echo “cleanup…”
cd /
rm -f -r /mnt/eroot/tmp/initrd
umount /mnt/eboot
umount /mnt/eroot
rm -f -r /mnt/eboot
rm -f -r /mnt/eroot]]>

[ad#ad-1]

Microsoft FUD that idiot’s writing a story about …

This is a total load of FUD. Like most of the comments here, I must agree. Even WHEN this so-called HyperV does come out, it still will lack the features that VMware currently HAS! If you’re already running VMware, why would you DOWNGRADE!? If you’re not, why would you adopt an UNPROVEN LOSER 1.0 release!? Just like a lot of people are upgrading from Vista to XP, people will be upgrading from HyperV to VI3, which will be 2 years OLD by the time HyperV comes out. VMware stays atop for at least 5 years as nobody comes close just yet.

Here’s the story:
http://www.marketwatch.com/news/story/m … teid=yhoof

[ad#ad-1]

quick deploy of VMs from – linked clones from 1 base disk

test_list.txt needs the names.

for i in `cat /tmp/test_list.txt`

do mkdir /vmfs/volumes/46a50aa4-65c3bb7e-d6d2-0014221878f9/$i; cp /tmp/sample.vmx $i/$i.vmx

echo “displayName = $i”>> /vmfs/volumes/46a50aa4-65c3bb7e-d6d2-0014221878f9/$i/$i.vmx

vmware-cmd -s register /vmfs/volumes/46a50aa4-65c3bb7e-d6d2-0014221878f9/$i/$i.vmx

vmware-cmd /vmfs/volumes/46a50aa4-65c3bb7e-d6d2-0014221878f9/$i/$i.vmx createsnapshot $i “linked clone to gold disk- DO NOT DELETE VM\!”;done

So in this case here, I have all of the names of the VMs I wanted in test_list.txt. I have a copy of /tmp/sample.vmx – it’s just a basic vmx file with the UUIDs, etc removed, so it would generate a new one. I then give the name of the vmx, the display name, register the VM, and create a snapshot, so that powering up and using the VM won’t mess up all of my other VMs that use the same underlying vmdk.

update …

If the offset is at 128 rather than 63, this won’t work. What you’ve done will not have hurt it though; you just need to rewrite it again. Go through the same process except after it’s done, go to x for expert mode, then b for byte and start it at 128. This is the case when creating vmfs volumes in Virtual Center 2.0.1 or higher.

lost vmfs volume – says 100% available – SAN LUN, storage pr

1) fdisk -l

this would show which device doesn’t have a partition.

2) dd if=/dev/sd(x) of=/tmp/dump_sdx.txt count=100 bs=1024

file /tmp/dump_sdx.txt shows x86 boot sector.

strings /tmp/dump_sdx.txt shows some vmdk files

3) fdisk -lu /dev/sd(x) shows that there are no partitions on the disk.

4) ran fdisk /dev/sd(x). created new partition spanning entire lun and then used partition type fb.

5) run “vmkfstools -V”

That’s it