Re: [Users] VM with stateless snapshot won't start
On 12/05/2013 01:03 PM, Martijn Grendelman wrote: Hi, After maintenance on a host, I am trying to start a VM that has been running statelessly for a while. It refuses to start and Engine logs the following: 2013-12-05 11:59:18,125 INFO [org.ovirt.engine.core.dal.dbbroker.auditloghandling.AuditLogDirector] (pool-6-thread-48) Correlation ID: 43d49965, Job ID: 0d943a6d-9d65-4ac1-89b7-139d30b4813c, Call Stack: null, Custom Event ID: -1, Message: Failed to start VM WinXP, because exist snapshot for stateless state. Snapshot will be deleted. Should I submit a bug report for the poor English in this log line? ;-) yes, or better yet, a simple text patch ;) (the rest of the issues have been resolved via other replies in the thread) thanks, Itamar The 'Snapshots' tab for the VM doesn't show anything, but repeated attempts to start the VM just show the same message in the log. What can I do to start this VM? ___ Users mailing list Users@ovirt.org http://lists.ovirt.org/mailman/listinfo/users
Re: [Users] VM with stateless snapshot won't start
Just noticed that Gilad answered that there is a bug :) Thanks Gilad! Dafna On 12/05/2013 12:56 PM, Dafna Ron wrote: Martijn,Thank you for updating us on the solution, I really appreciate it. Doron,do you know if there is a bug on this? On 12/05/2013 12:01 PM, Martijn Grendelman wrote: Hello Dafna, If a failure happened and the stateless vm has shut down without delete of the snapshot, the next time you will try to run it we will try to delete the snapshot. from the engine log, it seems that there is a problem deleting the snapshot because of quota. can you please try to disable the quota and try to run the vm again? Quota were not enabled on this Data Center, I have never done anything with quota on oVirt. The 'quota' table was empty, and the 'quota_id' field on all VMs in the 'vm_static' table was NULL. Since it was seemingly trying to set the quota_id for this particular VM to '----', I manually inserted a record into the quota table using this ID. After that, I was able to start te VM. The quota_id field for the VM now contains a reference to this fake id. Please note that the first time you will run it after disabling the quota, the snapshot should be deleted but the vm will still not start. only after the snapshot is deleted you will be able to run the vm again. Indeed, it took two attempts to start the VM. Question: is it harmful to leave the fake quota record with id '----' and the reference to it in the vm_static table in place? Cheers, Martijn. On 12/05/2013 11:23 AM, Martijn Grendelman wrote: Hi, After maintenance on a host, I am trying to start a VM that has been running statelessly for a while. It refuses to start and Engine logs the following: 2013-12-05 11:59:18,125 INFO [org.ovirt.engine.core.dal.dbbroker.auditloghandling.AuditLogDirector] (pool-6-thread-48) Correlation ID: 43d49965, Job ID: 0d943a6d-9d65-4ac1-89b7-139d30b4813c, Call Stack: null, Custom Event ID: -1, Message: Failed to start VM WinXP, because exist snapshot for stateless state. Snapshot will be deleted. Should I submit a bug report for the poor English in this log line? ;-) The 'Snapshots' tab for the VM doesn't show anything, but repeated attempts to start the VM just show the same message in the log. What can I do to start this VM? It seems I missed some info in the log that may well indicate the root cause of this issue. Please see attached log excerpt. A database query is failing due to a foreign key constraint violation. Please advise how to fix the database inconsistency. Regards, Martijn. ___ Users mailing list Users@ovirt.org http://lists.ovirt.org/mailman/listinfo/users -- Dafna Ron ___ Users mailing list Users@ovirt.org http://lists.ovirt.org/mailman/listinfo/users
Re: [Users] VM with stateless snapshot won't start
Martijn,Thank you for updating us on the solution, I really appreciate it. Doron,do you know if there is a bug on this? On 12/05/2013 12:01 PM, Martijn Grendelman wrote: Hello Dafna, If a failure happened and the stateless vm has shut down without delete of the snapshot, the next time you will try to run it we will try to delete the snapshot. from the engine log, it seems that there is a problem deleting the snapshot because of quota. can you please try to disable the quota and try to run the vm again? Quota were not enabled on this Data Center, I have never done anything with quota on oVirt. The 'quota' table was empty, and the 'quota_id' field on all VMs in the 'vm_static' table was NULL. Since it was seemingly trying to set the quota_id for this particular VM to '----', I manually inserted a record into the quota table using this ID. After that, I was able to start te VM. The quota_id field for the VM now contains a reference to this fake id. Please note that the first time you will run it after disabling the quota, the snapshot should be deleted but the vm will still not start. only after the snapshot is deleted you will be able to run the vm again. Indeed, it took two attempts to start the VM. Question: is it harmful to leave the fake quota record with id '----' and the reference to it in the vm_static table in place? Cheers, Martijn. On 12/05/2013 11:23 AM, Martijn Grendelman wrote: Hi, After maintenance on a host, I am trying to start a VM that has been running statelessly for a while. It refuses to start and Engine logs the following: 2013-12-05 11:59:18,125 INFO [org.ovirt.engine.core.dal.dbbroker.auditloghandling.AuditLogDirector] (pool-6-thread-48) Correlation ID: 43d49965, Job ID: 0d943a6d-9d65-4ac1-89b7-139d30b4813c, Call Stack: null, Custom Event ID: -1, Message: Failed to start VM WinXP, because exist snapshot for stateless state. Snapshot will be deleted. Should I submit a bug report for the poor English in this log line? ;-) The 'Snapshots' tab for the VM doesn't show anything, but repeated attempts to start the VM just show the same message in the log. What can I do to start this VM? It seems I missed some info in the log that may well indicate the root cause of this issue. Please see attached log excerpt. A database query is failing due to a foreign key constraint violation. Please advise how to fix the database inconsistency. Regards, Martijn. ___ Users mailing list Users@ovirt.org http://lists.ovirt.org/mailman/listinfo/users -- Dafna Ron ___ Users mailing list Users@ovirt.org http://lists.ovirt.org/mailman/listinfo/users
Re: [Users] VM with stateless snapshot won't start
Gilad Chaplik schreef op 5-12-2013 13:48: > hi Martijn, > > Indeed we have a bug there, and we've already solved it [1]. > As long as you're not using quota, your workaround is great. > If you'll decide to use quota you can contact me and we will see how to > proceed. Ok, thanks! I have no plans for using quota ATM. Cheers, Martijn. > [1] http://gerrit.ovirt.org/#/c/21332/ > > - Original Message - >> From: "Martijn Grendelman" >> To: d...@redhat.com, "Doron Fediuck" >> Cc: users@ovirt.org >> Sent: Thursday, December 5, 2013 2:01:44 PM >> Subject: Re: [Users] VM with stateless snapshot won't start >> >> Hello Dafna, >> >>> If a failure happened and the stateless vm has shut down without delete >>> of the snapshot, the next time you will try to run it we will try to >>> delete the snapshot. >>> from the engine log, it seems that there is a problem deleting the >>> snapshot because of quota. >>> can you please try to disable the quota and try to run the vm again? >> >> Quota were not enabled on this Data Center, I have never done anything >> with quota on oVirt. The 'quota' table was empty, and the 'quota_id' >> field on all VMs in the 'vm_static' table was NULL. >> >> Since it was seemingly trying to set the quota_id for this particular VM >> to '----', I manually inserted a record >> into the quota table using this ID. After that, I was able to start te >> VM. The quota_id field for the VM now contains a reference to this fake id. >> >>> Please note that the first time you will run it after disabling the >>> quota, the snapshot should be deleted but the vm will still not start. >>> only after the snapshot is deleted you will be able to run the vm again. >> >> Indeed, it took two attempts to start the VM. >> >> Question: is it harmful to leave the fake quota record with id >> '----' and the reference to it in the >> vm_static table in place? >> >> Cheers, >> Martijn. >> >> >> >> >>> >>> >>> On 12/05/2013 11:23 AM, Martijn Grendelman wrote: >>>> Hi, >>>> >>>>> After maintenance on a host, I am trying to start a VM that has been >>>>> running statelessly for a while. It refuses to start and Engine logs the >>>>> following: >>>>> >>>>> 2013-12-05 11:59:18,125 INFO >>>>> [org.ovirt.engine.core.dal.dbbroker.auditloghandling.AuditLogDirector] >>>>> (pool-6-thread-48) Correlation ID: 43d49965, Job ID: >>>>> 0d943a6d-9d65-4ac1-89b7-139d30b4813c, Call Stack: null, Custom Event ID: >>>>> -1, Message: Failed to start VM WinXP, because exist snapshot for >>>>> stateless state. Snapshot will be deleted. >>>>> >>>>> Should I submit a bug report for the poor English in this log line? ;-) >>>>> >>>>> The 'Snapshots' tab for the VM doesn't show anything, but repeated >>>>> attempts to start the VM just show the same message in the log. >>>>> >>>>> What can I do to start this VM? >>>> It seems I missed some info in the log that may well indicate the root >>>> cause of this issue. Please see attached log excerpt. A database query >>>> is failing due to a foreign key constraint violation. >>>> >>>> Please advise how to fix the database inconsistency. >>>> >>>> Regards, >>>> Martijn. >>>> >>>> >>>> >>>> >>>> ___ >>>> Users mailing list >>>> Users@ovirt.org >>>> http://lists.ovirt.org/mailman/listinfo/users >>> >>> >> ___ >> Users mailing list >> Users@ovirt.org >> http://lists.ovirt.org/mailman/listinfo/users >> ___ Users mailing list Users@ovirt.org http://lists.ovirt.org/mailman/listinfo/users
Re: [Users] VM with stateless snapshot won't start
hi Martijn, Indeed we have a bug there, and we've already solved it [1]. As long as you're not using quota, your workaround is great. If you'll decide to use quota you can contact me and we will see how to proceed. Thanks, Gilad. [1] http://gerrit.ovirt.org/#/c/21332/ - Original Message - > From: "Martijn Grendelman" > To: d...@redhat.com, "Doron Fediuck" > Cc: users@ovirt.org > Sent: Thursday, December 5, 2013 2:01:44 PM > Subject: Re: [Users] VM with stateless snapshot won't start > > Hello Dafna, > > > If a failure happened and the stateless vm has shut down without delete > > of the snapshot, the next time you will try to run it we will try to > > delete the snapshot. > > from the engine log, it seems that there is a problem deleting the > > snapshot because of quota. > > can you please try to disable the quota and try to run the vm again? > > Quota were not enabled on this Data Center, I have never done anything > with quota on oVirt. The 'quota' table was empty, and the 'quota_id' > field on all VMs in the 'vm_static' table was NULL. > > Since it was seemingly trying to set the quota_id for this particular VM > to '----', I manually inserted a record > into the quota table using this ID. After that, I was able to start te > VM. The quota_id field for the VM now contains a reference to this fake id. > > > Please note that the first time you will run it after disabling the > > quota, the snapshot should be deleted but the vm will still not start. > > only after the snapshot is deleted you will be able to run the vm again. > > Indeed, it took two attempts to start the VM. > > Question: is it harmful to leave the fake quota record with id > '----' and the reference to it in the > vm_static table in place? > > Cheers, > Martijn. > > > > > > > > > > On 12/05/2013 11:23 AM, Martijn Grendelman wrote: > >> Hi, > >> > >>> After maintenance on a host, I am trying to start a VM that has been > >>> running statelessly for a while. It refuses to start and Engine logs the > >>> following: > >>> > >>> 2013-12-05 11:59:18,125 INFO > >>> [org.ovirt.engine.core.dal.dbbroker.auditloghandling.AuditLogDirector] > >>> (pool-6-thread-48) Correlation ID: 43d49965, Job ID: > >>> 0d943a6d-9d65-4ac1-89b7-139d30b4813c, Call Stack: null, Custom Event ID: > >>> -1, Message: Failed to start VM WinXP, because exist snapshot for > >>> stateless state. Snapshot will be deleted. > >>> > >>> Should I submit a bug report for the poor English in this log line? ;-) > >>> > >>> The 'Snapshots' tab for the VM doesn't show anything, but repeated > >>> attempts to start the VM just show the same message in the log. > >>> > >>> What can I do to start this VM? > >> It seems I missed some info in the log that may well indicate the root > >> cause of this issue. Please see attached log excerpt. A database query > >> is failing due to a foreign key constraint violation. > >> > >> Please advise how to fix the database inconsistency. > >> > >> Regards, > >> Martijn. > >> > >> > >> > >> > >> ___ > >> Users mailing list > >> Users@ovirt.org > >> http://lists.ovirt.org/mailman/listinfo/users > > > > > ___ > Users mailing list > Users@ovirt.org > http://lists.ovirt.org/mailman/listinfo/users > ___ Users mailing list Users@ovirt.org http://lists.ovirt.org/mailman/listinfo/users
Re: [Users] VM with stateless snapshot won't start
Hello Dafna, > If a failure happened and the stateless vm has shut down without delete > of the snapshot, the next time you will try to run it we will try to > delete the snapshot. > from the engine log, it seems that there is a problem deleting the > snapshot because of quota. > can you please try to disable the quota and try to run the vm again? Quota were not enabled on this Data Center, I have never done anything with quota on oVirt. The 'quota' table was empty, and the 'quota_id' field on all VMs in the 'vm_static' table was NULL. Since it was seemingly trying to set the quota_id for this particular VM to '----', I manually inserted a record into the quota table using this ID. After that, I was able to start te VM. The quota_id field for the VM now contains a reference to this fake id. > Please note that the first time you will run it after disabling the > quota, the snapshot should be deleted but the vm will still not start. > only after the snapshot is deleted you will be able to run the vm again. Indeed, it took two attempts to start the VM. Question: is it harmful to leave the fake quota record with id '----' and the reference to it in the vm_static table in place? Cheers, Martijn. > > > On 12/05/2013 11:23 AM, Martijn Grendelman wrote: >> Hi, >> >>> After maintenance on a host, I am trying to start a VM that has been >>> running statelessly for a while. It refuses to start and Engine logs the >>> following: >>> >>> 2013-12-05 11:59:18,125 INFO >>> [org.ovirt.engine.core.dal.dbbroker.auditloghandling.AuditLogDirector] >>> (pool-6-thread-48) Correlation ID: 43d49965, Job ID: >>> 0d943a6d-9d65-4ac1-89b7-139d30b4813c, Call Stack: null, Custom Event ID: >>> -1, Message: Failed to start VM WinXP, because exist snapshot for >>> stateless state. Snapshot will be deleted. >>> >>> Should I submit a bug report for the poor English in this log line? ;-) >>> >>> The 'Snapshots' tab for the VM doesn't show anything, but repeated >>> attempts to start the VM just show the same message in the log. >>> >>> What can I do to start this VM? >> It seems I missed some info in the log that may well indicate the root >> cause of this issue. Please see attached log excerpt. A database query >> is failing due to a foreign key constraint violation. >> >> Please advise how to fix the database inconsistency. >> >> Regards, >> Martijn. >> >> >> >> >> ___ >> Users mailing list >> Users@ovirt.org >> http://lists.ovirt.org/mailman/listinfo/users > > ___ Users mailing list Users@ovirt.org http://lists.ovirt.org/mailman/listinfo/users
Re: [Users] VM with stateless snapshot won't start
If a failure happened and the stateless vm has shut down without delete of the snapshot, the next time you will try to run it we will try to delete the snapshot. from the engine log, it seems that there is a problem deleting the snapshot because of quota. can you please try to disable the quota and try to run the vm again? Please note that the first time you will run it after disabling the quota, the snapshot should be deleted but the vm will still not start. only after the snapshot is deleted you will be able to run the vm again. On 12/05/2013 11:23 AM, Martijn Grendelman wrote: Hi, After maintenance on a host, I am trying to start a VM that has been running statelessly for a while. It refuses to start and Engine logs the following: 2013-12-05 11:59:18,125 INFO [org.ovirt.engine.core.dal.dbbroker.auditloghandling.AuditLogDirector] (pool-6-thread-48) Correlation ID: 43d49965, Job ID: 0d943a6d-9d65-4ac1-89b7-139d30b4813c, Call Stack: null, Custom Event ID: -1, Message: Failed to start VM WinXP, because exist snapshot for stateless state. Snapshot will be deleted. Should I submit a bug report for the poor English in this log line? ;-) The 'Snapshots' tab for the VM doesn't show anything, but repeated attempts to start the VM just show the same message in the log. What can I do to start this VM? It seems I missed some info in the log that may well indicate the root cause of this issue. Please see attached log excerpt. A database query is failing due to a foreign key constraint violation. Please advise how to fix the database inconsistency. Regards, Martijn. ___ Users mailing list Users@ovirt.org http://lists.ovirt.org/mailman/listinfo/users -- Dafna Ron ___ Users mailing list Users@ovirt.org http://lists.ovirt.org/mailman/listinfo/users
Re: [Users] VM with stateless snapshot won't start
Hi, > After maintenance on a host, I am trying to start a VM that has been > running statelessly for a while. It refuses to start and Engine logs the > following: > > 2013-12-05 11:59:18,125 INFO > [org.ovirt.engine.core.dal.dbbroker.auditloghandling.AuditLogDirector] > (pool-6-thread-48) Correlation ID: 43d49965, Job ID: > 0d943a6d-9d65-4ac1-89b7-139d30b4813c, Call Stack: null, Custom Event ID: > -1, Message: Failed to start VM WinXP, because exist snapshot for > stateless state. Snapshot will be deleted. > > Should I submit a bug report for the poor English in this log line? ;-) > > The 'Snapshots' tab for the VM doesn't show anything, but repeated > attempts to start the VM just show the same message in the log. > > What can I do to start this VM? It seems I missed some info in the log that may well indicate the root cause of this issue. Please see attached log excerpt. A database query is failing due to a foreign key constraint violation. Please advise how to fix the database inconsistency. Regards, Martijn. 2013-12-05 12:16:18,463 INFO [org.ovirt.engine.core.bll.RunVmCommand] (pool-6-thread-49) [7f341556] Running command: RunVmCommand internal: false. En tities affected : ID: de196133-0ccf-41c2-a91d-1760be442080 Type: VM 2013-12-05 12:16:18,475 ERROR [org.ovirt.engine.core.bll.RunVmCommand] (pool-6-thread-49) [7f341556] RunVmAsStateless - WinXP - found stateless snapsh ots for this vm - skipped creating snapshots. 2013-12-05 12:16:18,476 INFO [org.ovirt.engine.core.bll.VmPoolHandler] (pool-6-thread-49) [7f341556] VdcBll.VmPoolHandler.ProcessVmPoolOnStopVm - Del eting snapshot for stateless vm de196133-0ccf-41c2-a91d-1760be442080 2013-12-05 12:16:18,481 INFO [org.ovirt.engine.core.bll.RestoreStatelessVmCommand] (pool-6-thread-49) Running command: RestoreStatelessVmCommand inte rnal: true. Entities affected : ID: de196133-0ccf-41c2-a91d-1760be442080 Type: VM 2013-12-05 12:16:18,487 INFO [org.ovirt.engine.core.bll.RestoreAllSnapshotsCommand] (pool-6-thread-49) Running command: RestoreAllSnapshotsCommand in ternal: true. Entities affected : ID: de196133-0ccf-41c2-a91d-1760be442080 Type: VM 2013-12-05 12:16:18,488 INFO [org.ovirt.engine.core.bll.RestoreAllSnapshotsCommand] (pool-6-thread-49) Locking VM(id = de196133-0ccf-41c2-a91d-1760be 442080) without compensation. 2013-12-05 12:16:18,489 INFO [org.ovirt.engine.core.vdsbroker.SetVmStatusVDSCommand] (pool-6-thread-49) START, SetVmStatusVDSCommand( vmId = de196133 -0ccf-41c2-a91d-1760be442080, status = ImageLocked), log id: 7032f4da 2013-12-05 12:16:18,491 INFO [org.ovirt.engine.core.vdsbroker.SetVmStatusVDSCommand] (pool-6-thread-49) FINISH, SetVmStatusVDSCommand, log id: 7032f4 da 2013-12-05 12:16:18,562 ERROR [org.ovirt.engine.core.bll.RestoreAllSnapshotsCommand] (pool-6-thread-49) Command org.ovirt.engine.core.bll.RestoreAllSn apshotsCommand throw exception: org.springframework.dao.DataIntegrityViolationException: CallableStatementCallback; SQL [{call updatevmstatic(?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?)}]; ERROR: insert or update on table "vm_static" violates foreign key constraint "fk_vm_static_quota" Detail: Key (quota_id)=(----) is not present in table "quota". Where: SQL statement "UPDATE vm_static SET description = $1 , free_text_comment = $2 ,mem_size_mb = $3 ,os = $4 ,vds_group_id = $5 , VM_NAME = $6 ,vmt_guid = $7 , domain = $8 ,creation_date = $9 ,num_of_monitors = $10 ,single_qxl_pci = $11 , allow_console_reconnect = $12 , is_initialized = $13 , num_of_sockets = $14 ,cpu_per_socket = $15 , usb_policy = $16 ,time_zone = $17 ,auto_startup = $18 , is_stateless = $19 ,dedicated_vm_for_vds = $20 , fail_back = $21 ,vm_type = $22 , nice_level = $23 , cpu_shares = $24 , _update_date = LOCALTIMESTAMP,default_boot_sequence = $25 , default_display_type = $26 , priority = $27 ,iso_path = $28 ,origin = $29 , initrd_url = $30 ,kernel_url = $31 , kernel_params = $32 ,migration_support = $33 , predefined_properties = $34 ,userdefined_properties = $35 , min_allocated_mem = $36 , quota_id = $37 , cpu_pinning = $38 , is_smartcard_enabled = $39 , is_delete_protected = $40 , host_cpu_flags = $41 , tunnel_migration = $42 , vnc_keyboard_layout = $43 , is_run_and_pause = $44 , created_by_user_id = $45 WHERE vm_guid = $46 AND entity_type = 'VM'" PL/pgSQL function "updatevmstatic" line 2 at SQL statement; nested exception is org.postgresql.util.PSQLException: ERROR: insert or update on table "vm_static" violates foreign key constraint "fk_vm_static_quota" Detail: Key (quota_id)=(----) is not present in table "quota". Where: SQL statement "UPDATE vm_static SET description = $1 , free_text_comment = $2 ,mem_size_mb = $3 ,os = $4 ,vds_group_id = $5 , VM_NAME = $6 ,vmt_guid = $7 , doma
[Users] VM with stateless snapshot won't start
Hi, After maintenance on a host, I am trying to start a VM that has been running statelessly for a while. It refuses to start and Engine logs the following: 2013-12-05 11:59:18,125 INFO [org.ovirt.engine.core.dal.dbbroker.auditloghandling.AuditLogDirector] (pool-6-thread-48) Correlation ID: 43d49965, Job ID: 0d943a6d-9d65-4ac1-89b7-139d30b4813c, Call Stack: null, Custom Event ID: -1, Message: Failed to start VM WinXP, because exist snapshot for stateless state. Snapshot will be deleted. Should I submit a bug report for the poor English in this log line? ;-) The 'Snapshots' tab for the VM doesn't show anything, but repeated attempts to start the VM just show the same message in the log. What can I do to start this VM? Cheers, Martijn. ___ Users mailing list Users@ovirt.org http://lists.ovirt.org/mailman/listinfo/users