Issue Details (XML | Word | Printable)

Key: GLASSFISH-17880
Type: Bug Bug
Status: Resolved Resolved
Resolution: Fixed
Priority: Critical Critical
Assignee: Yamini K B
Reporter: Bhavanishankar
Votes: 0
Watchers: 0
Operations

If you were logged in you would be able to see more operations.
glassfish

Unable to successfully start a suspended vm in kvm virtualization

Created: 01/Dec/11 02:49 PM   Updated: 26/Mar/12 02:46 PM   Resolved: 26/Mar/12 02:46 PM
Component/s: iaas
Affects Version/s: 4.0
Fix Version/s: 4.0_b31

Time Tracking:
Not Specified

File Attachments: 1. Java Source File CreateSimpleService.java (5 kB) 01/Dec/11 02:51 PM - Bhavanishankar
2. File kvm_setup.sh (0.9 kB) 01/Dec/11 02:51 PM - Bhavanishankar
3. Zip Archive source-files.zip (13 kB) 01/Dec/11 02:56 PM - Bhavanishankar
4. File virt-core.diff (15 kB) 01/Dec/11 02:56 PM - Bhavanishankar

Image Attachments:

1. vm_restart.png
(31 kB)
Issue Links:
Dependency
 

Tags:
Participants: Bhavanishankar, Tom Mueller and Yamini K B


 Description  « Hide

This is the scenario that will happen when an application goes through deploy, disable, enable lifecycle:

1. iaas.allocate(); // happens during 'asadmin deploy paas_app' -- respective SPEs will do this to create their VM.

2. vmLifecycle.stop(vm); // during  'asadmin disable paas_app' -- respective SPEs will invoke this on their VM

3. vmLifecycle.start(vm); // during  'asadmin enable paas_app' -- respective SPEs will invoke this on their VM

At step 3, looks like the VM is started without remounting the disk with new keys. Hence 'register-startup' fails when the VM comes up. VM console shows the error as attached (vm_restart.png)

Also, vmLifecycle.start(vm) seems to come out immediately without waiting for the VM to come up completely (this is to do with waiting for startupLatch).

This issue can be reproduced by creating a template for Database ServiceType (refer attached kvm_setup.sh) and run the attached 'create-simple-service' command.



Bhavanishankar added a comment - 01/Dec/11 02:51 PM

Run the testcase with : ./kvm_setup.sh && asadmin create-simple-service --templateid javadb test


Bhavanishankar added a comment - 01/Dec/11 02:55 PM

I have already communicated to Jerome about this issue a while back.

Also, as an experiment, tried the attached fix (virt-core.diff, source-files.zip). Although the change works, I would request Jerome to make the right fix.


Bhavanishankar added a comment - 01/Dec/11 02:56 PM

experimental fix.


Tom Mueller added a comment - 06/Mar/12 10:45 PM

Bulk update to reassign dochez issue to component lead.


Yamini K B added a comment - 26/Mar/12 02:46 PM

Suggested fix looks good, made some minor changes. Checked in r53152