It appears lvm always returns error code 5 on failure... for any kind of failure. So I'm not sure exactly what we should do here to fix this problem. Often the problem is actually just a can't get lock issue like the following, but without having a useful error code we can't know when to retry or to just fail.
20.35.01.198672267
/sbin/vgcreate vg-lDNyug.. /dev/loop6
/var/lock/lvm/P_orphans: flock failed: Resource temporarily unavailable
Can't get lock for orphan PVs
status = 5
It appears lvm always returns error code 5 on failure... for any kind of failure. So I'm not sure exactly what we should do here to fix this problem. Often the problem is actually just a can't get lock issue like the following, but without having a useful error code we can't know when to retry or to just fail.
20.35.01.198672267 lock/lvm/ P_orphans: flock failed: Resource temporarily unavailable
/sbin/vgcreate vg-lDNyug.. /dev/loop6
/var/
Can't get lock for orphan PVs
status = 5