yahoo-eng-team team mailing list archive
-
yahoo-eng-team team
-
Mailing list archive
-
Message #16777
[Bug 1336238] [NEW] _get_capacity_info fails when using long mount names or large storage due to multi-line df output
Public bug reported:
Glance version = 0.12.0 / 2014.1
In python package /usr/lib/python2.6/site-packages/glance/store/filesystem.py
_get_capacity_info(self, mount_point)
To determine the free space of a store, the python script executes df
with option "--block-size=1", in later version (I noticed), this was
changed into "-k" to work with kbytes, but in both situations, when the
mountpoint name is too long, or the size is to big, the output of df
will be multilined, resulting in an IndexError, because only one line is
being searched for values.
Fix:
When adding the option -P (or in long form --portability), the output is Posix formatted, resulting in one line per filesystem output.
Regards,
Maurice Leeflang
** Affects: glance
Importance: Undecided
Status: New
** Tags: filesystem
--
You received this bug notification because you are a member of Yahoo!
Engineering Team, which is subscribed to Glance.
https://bugs.launchpad.net/bugs/1336238
Title:
_get_capacity_info fails when using long mount names or large storage
due to multi-line df output
Status in OpenStack Image Registry and Delivery Service (Glance):
New
Bug description:
Glance version = 0.12.0 / 2014.1
In python package /usr/lib/python2.6/site-packages/glance/store/filesystem.py
_get_capacity_info(self, mount_point)
To determine the free space of a store, the python script executes df
with option "--block-size=1", in later version (I noticed), this was
changed into "-k" to work with kbytes, but in both situations, when
the mountpoint name is too long, or the size is to big, the output of
df will be multilined, resulting in an IndexError, because only one
line is being searched for values.
Fix:
When adding the option -P (or in long form --portability), the output is Posix formatted, resulting in one line per filesystem output.
Regards,
Maurice Leeflang
To manage notifications about this bug go to:
https://bugs.launchpad.net/glance/+bug/1336238/+subscriptions
Follow ups
References