"cinder-volumes" not recognized

asked 2017-05-03 14:44:30 -0600

tiger gravatar image

OK, so in the packstack answers file it creates a 20GB volume by default. I changed that to 400GB and re-ran "packstack --answer-file" thinking it would re-create the volume. Of course that would be too good to be true. ALright, let's do it the hard way...

vgremove cinder-volumes dd if=/dev/zero of=cinder-volumes bs=1 count=0 seek=400G losetup /dev/loop2 /home/volume/cinder-volumes pvcreate /dev/loop2 vgcreate cinder-volumes /dev/loop2

Next,

[root@kvm7 nova(keystone_admin)]# pvdisplay
  --- Physical volume ---
  PV Name               /dev/loop2
  VG Name               cinder-volumes
  PV Size               400.00 GiB / not usable 4.00 MiB
  Allocatable           yes
  PE Size               4.00 MiB
  Total PE              102399
  Free PE               25599
  Allocated PE          76800
  PV UUID               bxwygW-Jf1T-eOF0-hFyv-pXAU-Xv3L-B15R1J

  --- Physical volume ---
  PV Name               /dev/sda2
  VG Name               cl
  PV Size               557.37 GiB / not usable 3.00 MiB
  Allocatable           yes (but full)
  PE Size               4.00 MiB
  Total PE              142687
  Free PE               0
  Allocated PE          142687
  PV UUID               ZVADbO-d3dQ-74Gi-GzcV-sifU-o8Lk-lgkgDR

Next,

[root@kvm7 nova(keystone_admin)]# vgdisplay
  --- Volume group ---
  VG Name               cinder-volumes
  System ID
  Format                lvm2
  Metadata Areas        1
  Metadata Sequence No  3
  VG Access             read/write
  VG Status             resizable
  MAX LV                0
  Cur LV                1
  Open LV               0
  Max PV                0
  Cur PV                1
  Act PV                1
  VG Size               400.00 GiB
  PE Size               4.00 MiB
  Total PE              102399
  Alloc PE / Size       76800 / 300.00 GiB
  Free  PE / Size       25599 / 100.00 GiB
  VG UUID               HAZlL3-gDD2-C5Aq-VGB9-L650-itjF-JLsMZ6

  --- Volume group ---
  VG Name               cl
  System ID
  Format                lvm2
  Metadata Areas        1
  Metadata Sequence No  4
  VG Access             read/write
  VG Status             resizable
  MAX LV                0
  Cur LV                3
  Open LV               3
  Max PV                0
  Cur PV                1
  Act PV                1
  VG Size               557.37 GiB
  PE Size               4.00 MiB
  Total PE              142687
  Alloc PE / Size       142687 / 557.37 GiB
  Free  PE / Size       0 / 0
  VG UUID               ffGBDH-BKvB-L32I-0ioE-7hcW-Im3G-NjhDMl

I was able to create a 300GB volume from Horizon. Neither from the CLI nor from Horizon is this space usable.

In /etc/cinder/api.log I see this gibberish here:

2017-05-03 18:31:03.378 26645 ERROR oslo_service.periodic_task [req-3ede9e74-e183-426c-9b45-75a27d85327b - - - - -] Error during VolumeManager._report_driver_status
2017-05-03 18:31:03.378 26645 ERROR oslo_service.periodic_task Traceback (most recent call last):
2017-05-03 18:31:03.378 26645 ERROR oslo_service.periodic_task   File "/usr/lib/python2.7/site-packages/oslo_service/periodic_task.py", line 220, in run_periodic_tasks
2017-05-03 18:31:03.378 26645 ERROR oslo_service.periodic_task     task(self, context)
2017-05-03 18:31:03.378 26645 ERROR oslo_service.periodic_task   File "/usr/lib/python2.7/site-packages/cinder/volume/manager.py", line 2053, in _report_driver_status
2017-05-03 18:31:03.378 26645 ERROR oslo_service.periodic_task     volume_stats = self.driver.get_volume_stats(refresh=True)
2017-05-03 18:31:03.378 26645 ERROR oslo_service.periodic_task   File "/usr/lib/python2.7/site-packages/cinder/volume/drivers/lvm.py", line 587, in get_volume_stats
2017-05-03 18:31:03.378 26645 ERROR oslo_service.periodic_task     self._update_volume_stats()
2017-05-03 18:31:03.378 26645 ERROR oslo_service.periodic_task   File "/usr/lib/python2.7/site-packages/cinder/volume/drivers/lvm.py", line 211, in _update_volume_stats
2017-05-03 18:31:03.378 26645 ...
(more)
edit retag flag offensive close merge delete

Comments

"I was able to create a 300GB volume from Horizon. Neither from the CLI nor from Horizon is this space usable." This statement is a bit unclear. So you did create a Cinder volume. What does "not usable" mean?

Bernd Bausch gravatar imageBernd Bausch ( 2017-05-03 21:05:59 -0600 )edit

"cinder-volumes" not found comes from the vgs command three lines further up. Run this command as root and see what happens. Also run vgs without parameters to see if cinder-volumes is listed. You could also set use_syslog=True in /etc/cinder/rootwrap.conf and check the syslog next time.

Bernd Bausch gravatar imageBernd Bausch ( 2017-05-03 21:13:03 -0600 )edit

Under Project->Compute->Volumes I have a 300GB volume. When I run 'pvdisplay' cinder-volumes is there, with 102399 PE (400GB) and it reflects the fact that 300GB of it is allocated. My objective is to be able to create a VM from Horizon, m1.medium is fine, using this space.

tiger gravatar imagetiger ( 2017-05-04 08:32:49 -0600 )edit

My objective is just to be able to create a VM (m1.medium) from Horizon, without the hijinks of "block device mapping invalid" nor "disk filter returns zero hosts" in nova-scheduler.log. I want OpenStack to use the 300GB volume for VM creation, is all

tiger gravatar imagetiger ( 2017-05-04 08:34:06 -0600 )edit

Misconfigurations can lead to failures. If you are not willing to troubleshoot your setup, leave it.

Bernd Bausch gravatar imageBernd Bausch ( 2017-05-04 10:08:16 -0600 )edit