Bug 1260982 - gdeploy: ENOTEMPTY errors when gdeploy fails
gdeploy: ENOTEMPTY errors when gdeploy fails
Status: CLOSED ERRATA
Product: Red Hat Gluster Storage
Classification: Red Hat
Component: gdeploy (Show other bugs)
3.1
Unspecified Unspecified
unspecified Severity high
: ---
: RHGS 3.1.1
Assigned To: Nandaja Varma
Anush Shetty
: ZStream
Depends On:
Blocks:
  Show dependency treegraph
 
Reported: 2015-09-08 07:00 EDT by Anush Shetty
Modified: 2016-07-03 21:12 EDT (History)
3 users (show)

See Also:
Fixed In Version: gdeploy-1.0-10
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Environment:
Last Closed: 2015-10-05 03:25:54 EDT
Type: Bug
Regression: ---
Mount Type: ---
Documentation: ---
CRM:
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---


Attachments (Terms of Use)

  None (edit)
Description Anush Shetty 2015-09-08 07:00:18 EDT
Description of problem: gdeploy fails with an ENOTEMPTY when it fails (eg. error in config file) .

Version-Release number of selected component (if applicable): gdeploy-1.0-9.el6rhs.noarch


How reproducible: Always

Steps to Reproduce:
1. Create a config file for setting up bricks:
 
gdeploy config: gluster.conf

[hosts]
rhshdp03.lab.eng.blr.redhat.com
rhshdp04.lab.eng.blr.redhat.com
rhshdp05.lab.eng.blr.redhat.com
rhshdp06.lab.eng.blr.redhat.com

[devices]
/dev/vdb

[mountpoints]
/gluster1/brick1/

[brick_dirs]
/gluster1/brick1/s1 

[peer]
manage=probe

[volume]
action=create
volname=gluster_vol1
replica=yes
replica_count=2

2. Run gdeploy: gdeploy -c gluster.conf

Actual results:

Fails with the following message:

# gdeploy -k -c /opt/gluster.conf
/usr/lib/python2.6/site-packages/argparse.py:1575: DeprecationWarning: The "version" argument to ArgumentParser is deprecated. Please use "add_argument(..., action='version', version="N", ...)" instead
  """instead""", DeprecationWarning)
Error: brick_dirs should be relative to the mountpoint.
Looks like you have provided an absolute path. Exiting!
Traceback (most recent call last):
  File "/usr/bin/gdeploy", line 130, in <module>
    GlusterDeploy()
  File "/usr/bin/gdeploy", line 47, in __init__
    PlaybookGen(config_file)
  File "/usr/lib/python2.6/site-packages/glusterlib/playbook_gen.py", line 54, in __init__
    }[self.var_file]()
  File "/usr/lib/python2.6/site-packages/glusterlib/playbook_gen.py", line 144, in group_vars_gen
    self.var_file)
  File "/usr/lib/python2.6/site-packages/glusterlib/yaml_writer.py", line 48, in __init__
    self.write_sections()
  File "/usr/lib/python2.6/site-packages/glusterlib/yaml_writer.py", line 70, in write_sections
    self.modify_mountpoints()
  File "/usr/lib/python2.6/site-packages/glusterlib/yaml_writer.py", line 117, in modify_mountpoints
    self.cleanup_and_quit()
  File "/usr/lib/python2.6/site-packages/glusterlib/helpers.py", line 63, in cleanup_and_quit
    os.removedirs(Global.base_dir)
  File "/usr/lib64/python2.6/os.py", line 170, in removedirs
    rmdir(name)
OSError: [Errno 39] Directory not empty: '/tmp/tmpNw_62L'
Comment 2 Nandaja Varma 2015-09-08 08:23:55 EDT
Fixed in commit https://github.com/gluster/gdeploy/commit/63167ac4bd710c18e76bd26ff690254a87171f07

Will be available with next build.
Comment 4 Anush Shetty 2015-09-09 08:15:36 EDT
Verified with gdeploy-1.0-10.el6rhs.noarch
Comment 6 errata-xmlrpc 2015-10-05 03:25:54 EDT
Since the problem described in this bug report should be
resolved in a recent advisory, it has been closed with a
resolution of ERRATA.

For information on the advisory, and where to find the updated
files, follow the link below.

If the solution does not work for you, open a new bug report.

https://rhn.redhat.com/errata/RHSA-2015-1845.html

Note You need to log in before you can comment on or make changes to this bug.