Bug 1546492

Summary: do not add mount details into /etc/fstab when mounting for performance tests which is temporary
Product: [Red Hat Storage] Red Hat Gluster Storage Reporter: Nag Pavan Chilakam <nchilaka>
Component: gluster-colonizerAssignee: Dustin Black <dblack>
Status: CLOSED ERRATA QA Contact: Rahul Hinduja <rhinduja>
Severity: medium Docs Contact:
Priority: unspecified    
Version: rhgs-3.3CC: rcyriac, rhs-bugs, rreddy, sankarshan
Target Milestone: ---Keywords: ZStream
Target Release: RHGS 3.3.1 Async   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: gluster-colonizer-1.1-2.el7rhgs.noarch.rpm Doc Type: If docs needed, set a value
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2018-05-03 08:27:12 UTC Type: Bug
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:
Bug Depends On:    
Bug Blocks: 1560066, 1564133    
Attachments:
Description Flags
on_qa validation screenshot none

Description Nag Pavan Chilakam 2018-02-18 09:34:43 UTC
Description of problem:
------------------------
as part of perf tests we need to mount the volume to run fio test.
While we are unmounting the volume post perf tests, however we are not removing entries from /etc/fstab

In the first place, we don't actually need to make entries in /etc/fstab for perf tests as it is a one time test.


/etc/fstab entry
172.18.178.65:gluster1 /mnt glusterfs _netdev 0 0


Version-Release number of selected component (if applicable):
==========================================
[root@g1-1 glusterfs]# rpm -qa|grep gluster
glusterfs-ganesha-3.8.4-52.el7rhgs.x86_64
libvirt-daemon-driver-storage-gluster-3.2.0-14.el7_4.5.x86_64
glusterfs-cli-3.8.4-52.el7rhgs.x86_64
glusterfs-api-3.8.4-52.el7rhgs.x86_64
glusterfs-rdma-3.8.4-52.el7rhgs.x86_64
nfs-ganesha-gluster-2.4.4-17.el7rhgs.x86_64
gluster-zeroconf-avahi-0.1.0-2.el7rhgs.noarch
glusterfs-3.8.4-52.el7rhgs.x86_64
glusterfs-libs-3.8.4-52.el7rhgs.x86_64
gluster-nagios-addons-0.2.10-2.el7rhgs.x86_64
glusterfs-server-3.8.4-52.el7rhgs.x86_64
python-gluster-zeroconf-0.1.0-2.el7rhgs.noarch
gluster-colonizer-1.0.1-2.el7rhgs.noarch
glusterfs-geo-replication-3.8.4-52.el7rhgs.x86_64
vdsm-gluster-4.17.33-1.2.el7rhgs.noarch
python-gluster-3.8.4-52.el7rhgs.noarch
samba-vfs-glusterfs-4.6.3-9.el7rhgs.x86_64
glusterfs-client-xlators-3.8.4-52.el7rhgs.x86_64
gluster-nagios-common-0.2.4-1.el7rhgs.noarch
glusterfs-fuse-3.8.4-52.el7rhgs.x86_64





How reproducible:
============
always

Steps to Reproduce:
1.run colonizer to setup gluster, choose any flavor and mount
2.choose to run the perf test
3.check out /etc/fstab and mount command

Actual results:
======
can be seen that the volume mount for perf tests job is also being entered into /etc/fstab

Comment 2 Dustin Black 2018-03-02 19:13:03 UTC
This seems to be a quirk of the ansible mount module. Selecting a state of 'mounted' in the play both mounts the volume _and_ creates the fstab entry.

    - name: Mount default Gluster volume
      mount:
        path: /mnt
        src: "{{ play_hosts[0] }}:{{ default_volname }}"
        fstype: glusterfs
        opts: _netdev
        state: mounted

In the tear-down plays, the 'unmounted' state is passed to the mount module, but this _only_ unmounts and does not destroy the fstab entry.

    - name: Unmount Gluster default volume
      mount:
        path: /mnt
        state: unmounted

I would argue that the ansible mount module is behaving incorrectly, but we can easily remedy the problem here by adding a play to remove the fstab entries.

Comment 3 Dustin Black 2018-03-02 19:48:33 UTC
Fix added in upstream merge commit https://github.com/gluster/gluster-colonizer/commit/e8cac3f9fb043bbb35ee612eae0818a6ead03157

Comment 5 Nag Pavan Chilakam 2018-04-09 07:18:14 UTC
on_qa validation:
While I see we are still making a entry to /etc/fstab, which I feel is unnecessary for a temporary performance test, However, We are now making sure we are deleting this entry at the end of perf tests.

Hence moving to verified.

See attached screenshot, where /etc/fstab entries were listed down while perf test was in progress and at the end of perf test.

testversion:gluster-colonizer-1.1-2.el7rhgs.noarch.rpm
on rhl7.4+gluster-3.8.4-52

Comment 6 Nag Pavan Chilakam 2018-04-09 07:23:00 UTC
Created attachment 1419131 [details]
on_qa validation screenshot

Comment 9 errata-xmlrpc 2018-05-03 08:27:12 UTC
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://access.redhat.com/errata/RHEA-2018:1317