Ganesha driver generate many invalid configuration files
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
OpenStack Shared File Systems Service (Manila) |
Fix Released
|
Undecided
|
jiaopengju |
Bug Description
I'm using ganesha driver with manila. In my test environment, it generated many invalid configuration files like::
1.conf.djkfjkd
2.conf.djfkdjl
3.conf.kllsjdk
.....
These files are the temp file which were generated in creating ganesha export configuration files.
def _write_file(self, path, data):
"""Write data to path atomically."""
dirpath, fname = (getattr(os.path, q + "name")(path) for q in
tmpf = self.execute(
'sh', '-c',
'echo %s > %s' % (pipes.quote(data), pipes.quote(tmpf)),
In ganesha driver, we use two 'ssh' operations to generate a valid export configuration file. But some times the second 'ssh' operation may execute failed. In this case, ganesha driver will generate invalid files (the tmpf file). IMO, we should add try catch block on second ssh operation to avoid it happen.
Changed in manila: | |
assignee: | nobody → jiaopengju (pj-jiao) |
status: | New → In Progress |
Fix proposed to branch: master /review. openstack. org/503886
Review: https:/