Hello,

I use several OpenBSD/i386 (versions 4.3 and 4.4)
VMs under VMWare Workstation and ESX.
They work great for my purposes (few LAMP servers +
1 OpenVPN server), but there is one annoyance:

when I close the VMWare or shutdown the host,
then the OpenBSD VMs aren't shutdown properly.

I've tried to install the FreeBSD-version of VMWare-Tools
as described in http://www.linux.com/feature/56683
but still the proper shutdown doesn't happen
even though I see the daemon being run in the VM:

$ ps uawwwx | grep vmware
root     26568 98.3  0.2   500   216 ??  Rs/0  12:24PM  607:02.63
/emul/freebsd/sbin/vmware-guestd --background
/var/run/vmware-guestd.pid --halt-command /sbin/shutdown -p -h now

I wonder how does this daemon work?
Does it listen at some TCP or UDP port maybe?

$ fstat |grep vmware
root     vmware-guestd 26568   wd /               2 drwxr-xr-x   r      512
root     vmware-guestd 26568    0 /          728803 crw-rw-rw-  rw     null
root     vmware-guestd 26568    1 /          728803 crw-rw-rw-  rw     null
root     vmware-guestd 26568    2 /          728803 crw-rw-rw-  rw     null
root     vmware-guestd 26568    3 pipe 0xd3e63048 state:
root     vmware-guestd 26568    4 pipe 0xd3e63048 state:

$ netstat -an | grep LISTEN
tcp        0      0  127.0.0.1.5432         *.*                    LISTEN
tcp        0      0  *.139                  *.*                    LISTEN
tcp        0      0  *.445                  *.*                    LISTEN
tcp        0      0  *.22                   *.*                    LISTEN
tcp        0      0  *.443                  *.*                    LISTEN
tcp        0      0  *.37                   *.*                    LISTEN
tcp        0      0  *.13                   *.*                    LISTEN
tcp        0      0  *.113                  *.*                    LISTEN
tcp        0      0  *.80                   *.*                    LISTEN
tcp        0      0  127.0.0.1.587          *.*                    LISTEN
tcp        0      0  127.0.0.1.25           *.*                    LISTEN
tcp6       0      0  ::1.5432               *.*                    LISTEN
tcp6       0      0  *.22                   *.*                    LISTEN
tcp6       0      0  *.443                  *.*                    LISTEN
tcp6       0      0  *.37                   *.*                    LISTEN
tcp6       0      0  *.13                   *.*                    LISTEN
tcp6       0      0  *.113                  *.*                    LISTEN
tcp6       0      0  ::1.587                *.*                    LISTEN
tcp6       0      0  ::1.25                 *.*                    LISTEN

Does anybody know? The vmware-guestd daemon
can't be that complicated, maybe I could replace it
by a Perl-script, if I knew how does it get the "signal"
that the host is about to shutdown...

Regards
Alex

OpenBSD 4.3-stable (GENERIC.MP) #1: Tue Sep 16 17:02:42 CEST 2008
    afar...@xxx.my.domain:/usr/src/sys/arch/i386/compile/GENERIC.MP
cpu0: Intel(R) Core(TM)2 Quad CPU Q9300 @ 2.50GHz ("GenuineIntel"
686-class) 2.50 GHz
cpu0: 
FPU,V86,DE,PSE,TSC,MSR,PAE,MCE,CX8,APIC,SEP,MTRR,PGE,MCA,CMOV,PAT,PSE36,CFLUSH,DS,ACPI,MMX,FXSR,SSE,SSE2,SS,SSE3,DS-CPL,CX16
real mem  = 133722112 (127MB)
avail mem = 121208832 (115MB)
mainbus0 at root
bios0 at mainbus0: AT/286+ BIOS, date 04/10/07, BIOS32 rev. 0 @
0xfd880, SMBIOS rev. 2.31 @ 0xe0010 (45 entries)
bios0: vendor Phoenix Technologies LTD version "6.00" date 04/10/2007
bios0: VMware, Inc. VMware Virtual Platform
apm0 at bios0: Power Management spec V1.2
apm0: AC on, battery charge unknown
acpi at bios0 function 0x0 not configured
pcibios0 at bios0: rev 2.1 @ 0xfd880/0x780
pcibios0: PCI IRQ Routing Table rev 1.0 @ 0xfdf30/176 (9 entries)
pcibios0: PCI Interrupt Router at 000:07:0 ("Intel 82371FB ISA" rev 0x00)
pcibios0: PCI bus #2 is the last bus
bios0: ROM list: 0xc0000/0x8000 0xc8000/0x1000 0xdc000/0x4000! 0xe0000/0x4000!
mainbus0: Intel MP Specification (Version 1.4)
cpu0 at mainbus0: apid 0 (boot processor)
cpu0: apic clock running at 66MHz
mainbus0: bus 0 is type PCI
mainbus0: bus 1 is type PCI
mainbus0: bus 2 is type PCI
mainbus0: bus 3 is type ISA
ioapic0 at mainbus0: apid 1 pa 0xfec00000, version 11, 24 pins
pci0 at mainbus0 bus 0: configuration mode 1 (no bios)
pchb0 at pci0 dev 0 function 0 "Intel 82443BX AGP" rev 0x01
ppb0 at pci0 dev 1 function 0 "Intel 82443BX AGP" rev 0x01
pci_intr_map: bus 0 dev 1 func 0 pin 1; line 5
pci_intr_map: no MP mapping found
pci_intr_map: bus 0 dev 1 func 0 pin 2; line 11
pci_intr_map: no MP mapping found
pci1 at ppb0 bus 1
piixpcib0 at pci0 dev 7 function 0 "Intel 82371AB PIIX4 ISA" rev 0x08
pciide0 at pci0 dev 7 function 1 "Intel 82371AB IDE" rev 0x01: DMA,
channel 0 configured to compatibility, channel 1 configured to
compatibility
wd0 at pciide0 channel 0 drive 0: <VMware Virtual IDE Hard Drive>
wd0: 64-sector PIO, LBA, 20480MB, 41943040 sectors
wd0(pciide0:0:0): using PIO mode 4, Ultra-DMA mode 2
atapiscsi0 at pciide0 channel 1 drive 0
scsibus0 at atapiscsi0: 2 targets
cd0 at scsibus0 targ 0 lun 0: <NECVMWar, VMware IDE CDR10, 1.00> SCSI0
5/cdrom removable
cd0(pciide0:1:0): using PIO mode 4, Ultra-DMA mode 2
uhci0 at pci0 dev 7 function 2 "Intel 82371AB USB" rev 0x00: apic 1
int 19 (irq 9)
piixpm0 at pci0 dev 7 function 3 "Intel 82371AB Power" rev 0x08: SMBus disabled
vga1 at pci0 dev 15 function 0 "VMware Virtual SVGA II" rev 0x00
wsdisplay0 at vga1 mux 1: console (80x25, vt100 emulation)
wsdisplay0: screen 1-5 added (80x25, vt100 emulation)
mpi0 at pci0 dev 16 function 0 "Symbios Logic 53c1030" rev 0x01: apic
1 int 17 (irq 11)
scsibus1 at mpi0: 16 targets
ppb1 at pci0 dev 17 function 0 "VMware Virtual PCI-PCI bridge" rev 0x02
pci_intr_map: bus 0 dev 17 func 0 pin 2; line 9
pci_intr_map: no MP mapping found
pci_intr_map: bus 0 dev 17 func 0 pin 3; line 5
pci_intr_map: no MP mapping found
pci_intr_map: bus 0 dev 17 func 0 pin 4; line 11
pci_intr_map: no MP mapping found
pci2 at ppb1 bus 2
vic0 at pci2 dev 0 function 0 "AMD 79c970 PCnet-PCI" rev 0x10: apic 1
int 18 (irq 10), address 00:0c:29:06:6f:9e
eap0 at pci2 dev 1 function 0 "Ensoniq AudioPCI97" rev 0x02: apic 1
int 19 (irq 9)
ac97: codec id 0x43525913 (Cirrus Logic CS4297A rev 3)
audio0 at eap0
midi0 at eap0: <AudioPCI MIDI UART>
ehci0 at pci2 dev 2 function 0 "VMware Virtual EHCI" rev 0x00: apic 1
int 16 (irq 5)
usb0 at ehci0: USB revision 2.0
uhub0 at usb0 "VMware EHCI root hub" rev 2.00/1.00 addr 1
isa0 at piixpcib0
isadma0 at isa0
pckbc0 at isa0 port 0x60/5
pckbd0 at pckbc0 (kbd slot)
pckbc0: using irq 1 for kbd slot
wskbd0 at pckbd0: console keyboard, using wsdisplay0
pmsi0 at pckbc0 (aux slot)
pckbc0: using irq 12 for aux slot
wsmouse0 at pmsi0 mux 0
pcppi0 at isa0 port 0x61
midi1 at pcppi0: <PC speaker>
spkr0 at pcppi0
lpt0 at isa0 port 0x378/4 irq 7
npx0 at isa0 port 0xf0/16: reported by CPUID; using exception 16
pccom0 at isa0 port 0x3f8/8 irq 4: ns16550a, 16 byte fifo
pccom1 at isa0 port 0x2f8/8 irq 3: ns16550a, 16 byte fifo
fdc0 at isa0 port 0x3f0/6 irq 6 drq 2
fd0 at fdc0 drive 0: 1.44MB 80 cyl, 2 head, 18 sec
usb1 at uhci0: USB revision 1.0
uhub1 at usb1 "Intel UHCI root hub" rev 1.00/1.00 addr 1
mtrr: Pentium Pro MTRR support
softraid0 at root
root on wd0a swap on wd0b dump on wd0b

Reply via email to