Hi Jim,

You can try the taskcleaner script on dbutils. 
For instance: 
# PGPASSWORD={pass} ./taskcleaner.sh -u engine -d engine -t {disk,snapshot} -z

I recommend you to check all the options available for it.

Cheers,
Gonza.-

On Tue, Apr 25, 2017 at 5:58 PM, Jim Kusznir <jim@palousetech.com> wrote:
(sorry. e-mail client sent message prematurely)

Ok, I figured out that this needs to be run on the engine, I figured out that PGPASSWORD is the postgres password, and I finally figured out that the db password is stored in:
/etc/ovirt-engine/engine.conf.d/10-setup-database.conf

Unfortunately, when I run the command provided, I get just an empty line back, no UUIDs.

I looked in the gui, under the disks tab and found the ID there.  I ran the command on the two UUIDs for the two disks in question:

[root@ovirt ~]# PGPASSWORD=<deleted> /usr/share/ovirt-engine/setup/dbutils/unlock_entity.sh -q -t disk -u engine

[root@ovirt ~]# PGPASSWORD=<deleted> /usr/share/ovirt-engine/setup/dbutils/unlock_entity.sh -t snapshot -u engine 405fabe0-873c-4e8e-ae10-9990debf96c0
Caution, this operation may lead to data corruption and should be used with care. Please contact support prior to running this command
Are you sure you want to proceed? [y/n]
y
select fn_db_unlock_snapshot('405fabe0-873c-4e8e-ae10-9990debf96c0');
 

INSERT 0 1
unlock snapshot 405fabe0-873c-4e8e-ae10-9990debf96c0 completed successfully.
[root@ovirt ~]# PGPASSWORD=<deleted> /usr/share/ovirt-engine/setup/dbutils/unlock_entity.sh -t snapshot -u engine eada2c1c-1d99-4391-9be3-352c411a0a91
Caution, this operation may lead to data corruption and should be used with care. Please contact support prior to running this command
Are you sure you want to proceed? [y/n]
y
select fn_db_unlock_snapshot('eada2c1c-1d99-4391-9be3-352c411a0a91');
 

INSERT 0 1
unlock snapshot eada2c1c-1d99-4391-9be3-352c411a0a91 completed successfully.

Unfortunately, this doesn't appear to have accomplished anything.  In the web UI, the disks are still shown as locked, and the tasks are still shown as pending.

I logged into a host node and found the directory by the same UUID:

root@ovirt1 images]# cd 405fabe0-873c-4e8e-ae10-9990debf96c0/
[root@ovirt1 405fabe0-873c-4e8e-ae10-9990debf96c0]# ls
8e4a02a7-760b-478c-a694-81466d601356  8e4a02a7-760b-478c-a694-81466d601356.lease  8e4a02a7-760b-478c-a694-81466d601356.meta
[root@ovirt1 405fabe0-873c-4e8e-ae10-9990debf96c0]# du -sh
514M .


I'm assuming I should NOT just rm these files and the containing directory....

Suggestions moving forward?


On Tue, Apr 25, 2017 at 8:50 AM, Jim Kusznir <jim@palousetech.com> wrote:
Ok, I figured out that this needs to be run on the engine, I figured out that PGPASSWORD

On Tue, Apr 4, 2017 at 2:02 AM, Nathanaël Blanchet <blanchet@abes.fr> wrote:

For instance

PGPASSWORD=XXXXX /usr/share/ovirt-engine/setup/dbutils/unlock_entity.sh -q -t disk -u engine
296c010e-3c1d-4008-84b3-5cd39cff6aa1 | 525a4dda-dbbb-4872-a5f1-8ac2aed48392

PGPASSWORD=XXXXX /usr/share/ovirt-engine/setup/dbutils/unlock_entity.sh -t snapshot -u engine 525a4dda-dbbb-4872-a5f1-8ac2aed48392


Le 01/04/2017 à 19:55, Jim Kusznir a écrit :
Hi:

A few days ago I attempted to create a new VM from one of the ovirt-image-repository images.  I haven't really figured out how to use this reliably yet, and in this case, while trying to import an image, one of my nodes spontaneously rebooted (or at least, it looked like that to ovirt...Not sure if it had an OOM issue or something else).  I assume it was the node that got the task of importing those images, as ever since then (several days now), on my management screen under "Tasks" it shows the attempted imports, still stuck in "processing".  I'm quite certain its not actually processing.  I do believe it used some of my storage up in the partially downloaded images, though (they do show up as GlanceDisk-<numbers>, with a status of "Locked" under the main Disks tab.

How do I "properly" recover from this (abort the task and delete the partial download)?

Thanks!

--Jim


_______________________________________________
Users mailing list
Users@ovirt.org
http://lists.ovirt.org/mailman/listinfo/users

-- 
Nathanaël Blanchet

Supervision réseau
Pôle Infrastrutures Informatiques
227 avenue Professeur-Jean-Louis-Viala
34193 MONTPELLIER CEDEX 5 	
Tél. 33 (0)4 67 54 84 55
Fax  33 (0)4 67 54 84 14
blanchet@abes.fr 



_______________________________________________
Users mailing list
Users@ovirt.org
http://lists.ovirt.org/mailman/listinfo/users