We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
losetup -a
hva shows an error when launching an instance.
2015-09-29 12:51:51 JobContext thr=JobWorker[0/1] [ERROR]: Caught RuntimeError: Failed to find loop device from: /var/lib/wakame-vdc/instances/i-3rq0dr2o/metadata.img /opt/axsh/wakame-vdc/dcmgr/lib/dcmgr/helpers/block_device_helper.rb:77:in `detach_loop' /opt/axsh/wakame-vdc/dcmgr/lib/dcmgr/drivers/hypervisor/linux_hypervisor.rb:146:in `setup_metadata_drive'
It happens here: https://github.com/axsh/wakame-vdc/blob/develop/dcmgr/lib/dcmgr/helpers/block_device_helper.rb#L55
if i =~ %r{^(/dev/loop\d+): \[([0-9a-f]+)\]:(\d+) } && $2.hex == stat.dev && $3.to_i == stat.ino
It assumes $2 as a hex value where stat and losetup -a show different results than expected.
$2
stat
"stat: #<File::Stat dev=0x803, ino=2382902, mode=0100644, nlink=1, uid=0, gid=0, rdev=0x0, size=10485760, blksize=4096, blocks=312, atime=2015-09-29 12:51:51 -0700, mtime=2015-09-29 12:51:51 -0700, ctime=2015-09-29 12:51:51 -0700>"
[root@localhost dcmgr]# losetup -a /dev/loop0: [2051]:141745283 (/var/lib/wakame-vdc/instances/i-1wllauqo/metadata.img (deleted))
0x803 is 2051 in decimal, but "2051".hex is not 0x803 so it fails.
"2051".hex
The text was updated successfully, but these errors were encountered:
on CentOS 6.4
[root@localhost i-zb241121]# which losetup /sbin/losetup [root@localhost i-zb241121]# rpm -qf /sbin/losetup util-linux-ng-2.17.2-12.18.el6.x86_64
on CentOS 7
[root@localhost dcmgr]# losetup --version losetup from util-linux 2.23.2
Sorry, something went wrong.
No branches or pull requests
hva shows an error when launching an instance.
It happens here:
https://github.com/axsh/wakame-vdc/blob/develop/dcmgr/lib/dcmgr/helpers/block_device_helper.rb#L55
It assumes
$2
as a hex value wherestat
andlosetup -a
show different results than expected.0x803 is 2051 in decimal, but
"2051".hex
is not 0x803 so it fails.The text was updated successfully, but these errors were encountered: