Re: vmware server reboot and in process image updates

2012-06-18 Thread Mike Haudenschild
Hi Gary,

Prior to the reboot, the VCL site should go into maintenance mode to
prevent a user from creating a reservation while this reboot procedure
happens.  You'll want to write a script that enumerates the VMs running on
the VM host prior to shutdown, then bring those VMs back up after reboot.
 Once the VM host is back online, bring VCL out of maintenance mode.

I know this would be pretty straightforward with ESXi, but I'm not sure
about VMWare Server 2.  I just did a quick Google search and found this:

http://www.cyberciti.biz/tips/start-stop-vmware-virtualization-vms-command.html

Regards,
Mike

--
*Mike Haudenschild*
Education Systems Manager
Longsight Group
(740) 599-5005 x809
m...@longsight.com
www.longsight.com



On Thu, Jun 14, 2012 at 6:22 PM, Gary Trail tra...@rpi.edu wrote:

 -BEGIN PGP SIGNED MESSAGE-
 Hash: SHA1

 Thanks Mike.

 you are correct - rebooting during pulling image would be avoided if
 at all possible.

 To elaborate a bit.  Our objective is to run an unattended regular
 (weekly/monthly) vmware server restart/reboot without impacting the
 integrity of VCL.  Of course,  users would be disconnected when their
 guest vm shuts down but, upon restart vmware server (version 2) would
 restart any previously running vm's and users could just re-connect
 using the same IP address, user name etc and the VCL infrastructure
 would resume in its pre-reboot state and reservations would time out s
 if nothing happened.

 In our pilot project, the VCL management node and vmware server2
 services are running on the same physical hardware while the VCL
 database and VCL front-end components are on two different hardware
 hosts.  VM images currently reside on DAS disks on the
 management/vmware node hardware.

 Is this all possible/reasonable?

 How are others accomplishing this?

 Thanks
 Gary

 Mike Haudenschild wrote the following on 6/14/2012 5:02 PM:
  Hi Gary,
 
  I'm assuming you do NOT mean shutting down the VM host while VCL
  is actively pulling an image... That would surely be bad.
 
  I think that the reservation should still remain active in the
  database. Shut down the client image cleanly, then bring down the
  management node and front end cleanly, and reboot the VM host.
  Bring up the management node and front end.  You'll have to
  manually power on your image VM on via the vSphere Client, but as
  long as the reservation hasn't expired it should be okay. Should be
  the same credentials to login to the image VM, too.
 
  Regards, Mike
 
  On Thursday, June 14, 2012, Gary Trail wrote:
 
  Quick question -
 
  We're in the middle of a pilot VCL installation (3 machines -
  front-end, database and management node (VCL management and vmware
  server on one management node).
 
  What will happen to any in process image updates if the vmware
  server reboots?  Will the image updates survive the reboot?
 
  Thanks Gary
 
  Gary Trail Rensselaer Hartford Graduate Center 860-548-7869
  tra...@rpi.edu javascript:;
 
 
 

 - --
 Gary Trail
 Director of Network Services
 Rensselaer Hartford Graduate Center
 860-548-7869
 tra...@rpi.edu
 -BEGIN PGP SIGNATURE-
 Version: GnuPG v1.4.9 (MingW32)

 iQEcBAEBAgAGBQJP2mQyAAoJENG9onuHOfZFsEMIAKbQV0w9qxLraoiFkl6gIc0F
 sGmZ5a0QaZIXEUyryrlXgxuvJkp+/4XEHDNi8UVXAFam0gNo8jlbEKcTh84Ix6uk
 9p+Llmw2RTiQtqGXGF/cufkIDnw8lZB4KaU8zjjfdNnAcW6x1YmLOlfzMBVbxxzH
 gC9uU5UR0fZvwTxDM2HKwNsmg3Zugu7VhbxqXgDyFBNwS2AR2175pZT0PFP+wEAw
 1bNM77/8TCM/fsmHfAqejgEFWxqmwlxK3M+nf/vRCPc2KhWL9/mkTF4zKMy06iY8
 MHXylps30IGXHdH7nwsX/pZoc3NGxXN2vHcmhDsKXYASnYG2ofaPBxL9t4SSh30=
 =+CP6
 -END PGP SIGNATURE-




Re: Image capture succeeds, then fails

2012-06-18 Thread Michael Jinks
Thanks Mike.

Checking the storage profile for this VM host, Data Store Path is
/vmfs/volumes/T2_6045_dev_VCL_ds01.  That directory is present and
read/write on our ESXi machine.

VM Path is set to (empty).  That's what we want if we plan to store
our VM disks alongside our other VM data, right?

VM Disk is set to localdisk, in case that matters.

Repository Path is an NFS volume.  We want that to be read-only on the
hypervisor, read-write on the management node, but for the moment due to
a configuration oversight it's read-write everywhere.  I don't know if
that's significant for the present case or not.




On Fri, Jun 15, 2012 at 07:13:42PM -0400, Mike Haudenschild wrote:
Hi Michael,
 
It looks like the problem starts here:
|32473|14:14|reload| 2012-06-15
15:31:21|32473|14:14|reload|VMware.pm:load(395)|failed to prepare vmx
file for vcl-linux-template-2-bak on VM host: vcl0001
This is the second warning message in the log snippet.  The first
warning can be ignored.
This is VCL writing the VMX file used to tell VMWare about the VM
during the reload process.  After the image is collected, it brings it
up on that computer in read only mode.  That process appears to have
failed here.  Check that the VM path is configured correctly for the VM
host and that the directory is writable by te VM host.
I'm writing from an airport on an ipad, so I can't fully review your
log easily.
Regards,
Mike
On Friday, June 15, 2012, Michael Jinks wrote:
 
  I think I may have just run my first successful image capture.
  There's
  an image directory now in my templates directory, and when I browse
  to
  Manage Images and Edit Image Profiles, my base image is there.
  Hooray!
  ...But, shortly after the capture completed, our admin address
  received
  the message below.  I'm forwarding the whole thing because reading
  it
  myself I don't see anything that looks like a statement of a
  problem,
  except for the first reservation failed line.  Any idea what went
  wrong?  Or, maybe nothing went wrong and this is a spurious error?
  Where would I look for clues?
  Thanks,
  --Michael
  - Forwarded message from [1]r...@pilot-lab.uchicago.edu -
  reservation failed on vcl-linux-template-2-bak: process failed after
  trying to load or make available
  
  
  time: 2012-06-15 15:31:21
  caller: State.pm:reservation_failed(213)
  ( 0) State.pm, reservation_failed (line: 213)
  (-1) [2]new.pm, process (line: 298)
  (-2) vcld, make_new_child (line: 568)
  (-3) vcld, main (line: 346)
  
  
  management node: [3]pilot-lab.uchicago.edu
  reservation PID: 32473
  parent vcld PID: 2506
  request ID: 14
  reservation ID: 14
  request state/laststate: reload/image
  request start time: 2012-06-15 15:31:12
  request end time: 2012-06-15 16:01:12
  for imaging: no
  log ID: none
  computer: vcl-linux-template-2-bak
  computer id: 7
  computer type: virtualmachine
  computer eth0 MAC address: undefined
  computer eth1 MAC address: undefined
  computer private IP address: 10.50.84.15
  computer public IP address: 10.50.84.15
  computer in block allocation: no
  provisioning module: VCL::Module::Provisioning::VMware::VMware
  vm host: vcl0001
  vm host ID: 1
  vm host computer ID: 1
  vm profile: VMware ESXi - IT Services
  vm profile VM path: /vmfs/volumes/T2_6045_dev_VCL_ds01
  vm profile repository path: /vmfs/volumes/nfs-vcl-templates
  vm profile datastore path: /vmfs/volumes/T2_6045_dev_VCL_ds01
  vm profile disk type: localdisk
  image: vmwarelinux-Linuxtemplate2v218-v0
  image display name: Linux template 2v2
  image ID: 18
  image revision ID: 16
  image size: 30720 MB
  use Sysprep: yes
  root access: yes
  image owner ID: 1
  image owner affiliation: Local
  image revision date created: 2012-06-15 15:29:23
  image revision production: yes
  OS module: VCL::Module::OS::Linux
  user: vclreload
  user name: vcl reload
  user ID: 2
  user affiliation: Local
  
  
  RECENT LOG ENTRIES FOR THIS PROCESS:
  2012-06-15
  15:31:19|32473|14:14|reload|VMware.pm:get_image_size_bytes(3841)|ret
  rieved the size of the image from the datastore on the VM host:
  32,212,255,246
  2012-06-15
  15:31:19|32473|14:14|reload|VMware.pm:get_image_size_bytes(3851)|ima
  ge size retrieved from both the image repository and VM host
  datastore:
  |32473|14:14|reload| image repository: 2,397,636,084
  |32473|14:14|reload| VM host 

Re: Image capture succeeds, then fails

2012-06-18 Thread Michael Jinks
A little more information, maybe relevant, maybe not:

I notice that VCL *is* getting to the point of creating a VM directory
in that path.  On the hypervisor:

 # pwd
 /vmfs/volumes/T2_6045_dev_VCL_ds01
 # ls |grep 218
 vmwarelinux-Linuxtemplate2v218-v0

That directory name appears to have been generated by VCL.  In the
directory we have two files:

 # ls
 vmwarelinux-Linuxtemplate2v218-v0-flat.vmdk
 vmwarelinux-Linuxtemplate2v218-v0.vmdk

But, as Mike suggested, the vmx file isn't appearing.

What might account for the fact that VCL can write one set of files but
then fails when it tries to write something else?


On Mon, Jun 18, 2012 at 12:58:25PM -0500, Michael Jinks wrote:
 Thanks Mike.
 
 Checking the storage profile for this VM host, Data Store Path is
 /vmfs/volumes/T2_6045_dev_VCL_ds01.  That directory is present and
 read/write on our ESXi machine.
 
 VM Path is set to (empty).  That's what we want if we plan to store
 our VM disks alongside our other VM data, right?
 
 VM Disk is set to localdisk, in case that matters.
 
 Repository Path is an NFS volume.  We want that to be read-only on the
 hypervisor, read-write on the management node, but for the moment due to
 a configuration oversight it's read-write everywhere.  I don't know if
 that's significant for the present case or not.
 
 
 
 
 On Fri, Jun 15, 2012 at 07:13:42PM -0400, Mike Haudenschild wrote:
 Hi Michael,
  
 It looks like the problem starts here:
 |32473|14:14|reload| 2012-06-15
 15:31:21|32473|14:14|reload|VMware.pm:load(395)|failed to prepare vmx
 file for vcl-linux-template-2-bak on VM host: vcl0001
 This is the second warning message in the log snippet.  The first
 warning can be ignored.
 This is VCL writing the VMX file used to tell VMWare about the VM
 during the reload process.  After the image is collected, it brings it
 up on that computer in read only mode.  That process appears to have
 failed here.  Check that the VM path is configured correctly for the VM
 host and that the directory is writable by te VM host.
 I'm writing from an airport on an ipad, so I can't fully review your
 log easily.
 Regards,
 Mike
 On Friday, June 15, 2012, Michael Jinks wrote:
  
   I think I may have just run my first successful image capture.
   There's
   an image directory now in my templates directory, and when I browse
   to
   Manage Images and Edit Image Profiles, my base image is there.
   Hooray!
   ...But, shortly after the capture completed, our admin address
   received
   the message below.  I'm forwarding the whole thing because reading
   it
   myself I don't see anything that looks like a statement of a
   problem,
   except for the first reservation failed line.  Any idea what went
   wrong?  Or, maybe nothing went wrong and this is a spurious error?
   Where would I look for clues?
   Thanks,
   --Michael
   - Forwarded message from [1]r...@pilot-lab.uchicago.edu -
   reservation failed on vcl-linux-template-2-bak: process failed after
   trying to load or make available
   
   
   time: 2012-06-15 15:31:21
   caller: State.pm:reservation_failed(213)
   ( 0) State.pm, reservation_failed (line: 213)
   (-1) [2]new.pm, process (line: 298)
   (-2) vcld, make_new_child (line: 568)
   (-3) vcld, main (line: 346)
   
   
   management node: [3]pilot-lab.uchicago.edu
   reservation PID: 32473
   parent vcld PID: 2506
   request ID: 14
   reservation ID: 14
   request state/laststate: reload/image
   request start time: 2012-06-15 15:31:12
   request end time: 2012-06-15 16:01:12
   for imaging: no
   log ID: none
   computer: vcl-linux-template-2-bak
   computer id: 7
   computer type: virtualmachine
   computer eth0 MAC address: undefined
   computer eth1 MAC address: undefined
   computer private IP address: 10.50.84.15
   computer public IP address: 10.50.84.15
   computer in block allocation: no
   provisioning module: VCL::Module::Provisioning::VMware::VMware
   vm host: vcl0001
   vm host ID: 1
   vm host computer ID: 1
   vm profile: VMware ESXi - IT Services
   vm profile VM path: /vmfs/volumes/T2_6045_dev_VCL_ds01
   vm profile repository path: /vmfs/volumes/nfs-vcl-templates
   vm profile datastore path: /vmfs/volumes/T2_6045_dev_VCL_ds01
   vm profile disk type: localdisk
   image: vmwarelinux-Linuxtemplate2v218-v0
   image display name: Linux template 2v2
   image ID: 18
   image revision ID: 16
   image size: 30720 MB
   use Sysprep: yes
   root access: yes
   image owner ID: 1
   image owner affiliation: Local
   image revision date