summaryrefslogtreecommitdiffstats
path: root/tests/basic/mount-nfs-auth.t
Commit message (Collapse)AuthorAgeFilesLines
* tests: make mount-nfs-auth.t more stableNiels de Vos2015-11-091-15/+11
| | | | | | | | | | | | | | | | | | mount-nfs-auth.t has a funky way of restarting the Gluster/NFS service. It is a little racy and does not always work. Disabling and enabling the nfs.disable volume option triggers a restart of the Gluster/NFS service too, and is much simpler. Also adding a little more EXPECT_WITHIN statements to prevent the occasional failures. Change-Id: I6765e9f021abbe995dfac00fbfc67298e2ec769c BUG: 1278476 Signed-off-by: Niels de Vos <ndevos@redhat.com> Reviewed-on: http://review.gluster.org/12542 Tested-by: NetBSD Build System <jenkins@build.gluster.org> Tested-by: Gluster Build System <jenkins@build.gluster.com> Reviewed-by: Jeff Darcy <jdarcy@redhat.com>
* tests: fix timeout in mount-nfs-auth.tJeff Darcy2015-10-271-11/+16
| | | | | | | | | | | | | | | | | | | | | The mount timeout was too short. The normal configuration-change path (construct graph, call reconfigure) and the auth-refresh path might in effect run serially. Therefore we have to wait for the *sum* of those two intervals. As with all too-short-timeout problems, the result was that the test would run fine most of the time. However, it has caused spurious failures on my own patches a half dozen times, and I have a half dozen other emails about it nuking other people's as well (most often but not always on NetBSD). The fix, obviously, is to calculate and use the right timeout value for NFS mount actions. Other actions and timeouts have been left alone. Change-Id: Ic8f013c8c830e33c48bcc6d1b603d6d22a8ba3c5 Signed-off-by: Jeff Darcy <jdarcy@redhat.com> Reviewed-on: http://review.gluster.org/12396 Tested-by: NetBSD Build System <jenkins@build.gluster.org> Tested-by: Gluster Build System <jenkins@build.gluster.com> Reviewed-by: Kaleb KEITHLEY <kkeithle@redhat.com>
* tests : workaround for the spurious failure in mount-nfs-auth.tJiffin Tony Thottan2015-08-311-2/+6
| | | | | | | | | | Change-Id: I459a0c60743291a2e164a5e0a76a7e2577afdae0 BUG: 1256352 Signed-off-by: Jiffin Tony Thottan <jthottan@redhat.com> Reviewed-on: http://review.gluster.org/12006 Reviewed-by: Niels de Vos <ndevos@redhat.com> Tested-by: NetBSD Build System <jenkins@build.gluster.org> Tested-by: Gluster Build System <jenkins@build.gluster.com>
* tests: use single-brick volume for mount-nfs-auth.tNiels de Vos2015-06-281-4/+5
| | | | | | | | | | | | | | When running with the replica-3 volume, the "big_write" test sometimes becomes unresponsive. This seems to be an issue (bug 1226941) in the RPC/socket-layer, and not related to the NFS test itself. BUG: 1163543 Change-Id: I51115e4b68d45f3ef7902b4f7a8535518d09408f Signed-off-by: Niels de Vos <ndevos@redhat.com> Reviewed-on: http://review.gluster.org/11085 Tested-by: NetBSD Build System <jenkins@build.gluster.org> Tested-by: Gluster Build System <jenkins@build.gluster.com> Reviewed-by: Kaleb KEITHLEY <kkeithle@redhat.com>
* Tests: fix spurrious failure in mount-nfs-auth.tEmmanuel Dreyfus2015-04-111-2/+2
| | | | | | | | | | | | Work around a timing-caused spurious error introduced by http://review.gluster.org/10047 BUG: 1129939 Change-Id: I0597377799f2464d9516fe710fa6e39c1f67a858 Signed-off-by: Emmanuel Dreyfus <manu@netbsd.org> Signed-off-by: Jiffin Tony Thottan <jthottan@redhat.com> Reviewed-on: http://review.gluster.org/10182 Tested-by: Gluster Build System <jenkins@build.gluster.com>
* tests : modifcation in mount-auth-nfs.tJiffin Tony Thottan2015-04-091-67/+64
| | | | | | | | | | | | | In the previous test script, for every change in export/netgroup file the volume is restarted to accodomate those changes. New changes will avoid those restarts. Change-Id: I2a6052075637f8e833096c6b3fcc01139dea85e4 BUG: 1143880 Signed-off-by: Jiffin Tony Thottan <jthottan@redhat.com> Reviewed-on: http://review.gluster.org/10047 Reviewed-by: Niels de Vos <ndevos@redhat.com> Tested-by: Gluster Build System <jenkins@build.gluster.com>
* Tests: portability fixesEmmanuel Dreyfus2015-03-301-20/+31
| | | | | | | | | | | | | | | | | | | | | | | | | | | Fix various portability problems in mount-nfs-auth.t, quota-ancestry-building.t and trash.t: - dd bs=1M is not portable, use dd bs=1024k instead - dd bs=1MB is not portable iether, use dd bs=1000000 instead - After restarting NFS service, wait for it to become available - After killing a process, wait for it to terminate - BSD awk does not accept a=b="", use a=""; b="" instead - NetBSD displays the original program name in paenthesis at the end of ps output. Strip it using sed 's/ *([^()]*)$//' is we want just the command - Do no use umount $N0, which leads to many troubles solved by EXPECT_WITHIN $UMOUNT_TIMEOUT "Y" umount_nfs $N0 - The -p option for mkdir must be before the directory name - du -b is not portable. Use ls -l instead. BUG: 1129939 Change-Id: I3d44a10a37d47ebb6a263c206566487e3ffb85d8 Signed-off-by: Emmanuel Dreyfus <manu@netbsd.org> Reviewed-on: http://review.gluster.org/10033 Reviewed-by: Krishnan Parthasarathi <kparthas@redhat.com> Reviewed-by: Anoop C S <achiraya@redhat.com> Tested-by: Gluster Build System <jenkins@build.gluster.com> Reviewed-by: Kaleb KEITHLEY <kkeithle@redhat.com>
* Tests: do not hardcode NFS state directoryEmmanuel Dreyfus2015-03-181-8/+13
| | | | | | | | | | | | | | | | | | | | tests/basic/mount-nfs-auth.t hardcoded /var/lib/glusterd/nfs/ as the NFS state directory, cuasing failures if glusterfs was configured with state in another location. Fix this by obtaning the directory through a gluster volume get command. The nfs.mount-rmtab key gives us a file inside the directory we are looking for. This fixes tests/basic/mount-nfs-auth.t regression on NetBSD. BUG: 1129939 Change-Id: I19184859c03faf5b9aeb95d080cf90fa581be380 Signed-off-by: Emmanuel Dreyfus <manu@netbsd.org> Reviewed-on: http://review.gluster.org/9896 Tested-by: Gluster Build System <jenkins@build.gluster.com> Reviewed-by: Kaleb KEITHLEY <kkeithle@redhat.com> Reviewed-by: Vijay Bellur <vbellur@redhat.com>
* glusterd: add new NFS options for exports/netgroups and related cachingNiels de Vos2015-03-181-6/+160
| | | | | | | | | | | | | | | | | The following options for the Gluster/NFS server are added : - nfs.exports-auth-enable - nfs.auth-refresh-interval-sec - nfs.auth-cache-ttl-sec BUG: 1143880 Change-Id: I37a73966c4ed27cd0f8c77200ef68a0d12b385b8 Original-author: Shreyas Siravara <shreyas.siravara@gmail.com> CC: Richard Wareing <rwareing@fb.com> CC: Jiffin Tony Thottan <jthottan@redhat.com> Signed-off-by: Niels de Vos <ndevos@redhat.com> Reviewed-on: http://review.gluster.org/9364 Tested-by: Gluster Build System <jenkins@build.gluster.com> Reviewed-by: Vijay Bellur <vbellur@redhat.com>
* gNFS: Export / Netgroup authentication on Gluster NFS mountNiels de Vos2015-03-151-0/+148
* Parses linux style export file/netgroups file into a structure that can be lookedup. * This parser turns each line into a structure called an "export directory". Each of these has a dictionary of hosts and netgroups which can be looked up during the mount authentication process. (See Change-Id Ic060aac and I7e6aa6bc) * A string beginning withan '@' is treated as a netgroup and a string beginning without an @ is a host. (See Change-Id Ie04800d) * This parser does not currently support all the options in the man page ('man exports'), but we can easily add them. BUG: 1143880 URL: http://www.gluster.org/community/documentation/index.php/Features/Exports_Netgroups_Authentication Change-Id: I181e8c1814d6ef3cae5b4d88353622734f0c0f0b Original-author: Shreyas Siravara <shreyas.siravara@gmail.com> CC: Richard Wareing <rwareing@fb.com> CC: Jiffin Tony Thottan <jthottan@redhat.com> Signed-off-by: Niels de Vos <ndevos@redhat.com> Reviewed-on: http://review.gluster.org/8758 Tested-by: Gluster Build System <jenkins@build.gluster.com> Reviewed-by: Vijay Bellur <vbellur@redhat.com>