From: rpeterso@sourceware.org <rpeterso@sourceware.org>
To: cluster-devel.redhat.com
Subject: [Cluster-devel] cluster gfs-kernel/src/gfs/mount.c gfs-kernel/ ...
Date: 14 Oct 2006 20:16:20 -0000 [thread overview]
Message-ID: <20061014201620.29818.qmail@sourceware.org> (raw)
CVSROOT: /cvs/cluster
Module name: cluster
Changes by: rpeterso at sourceware.org 2006-10-14 20:16:19
Modified files:
gfs-kernel/src/gfs: mount.c ops_super.c
gfs2/mount : mount.gfs2.c util.c
Log message:
This is the fix for bugzilla bug 210369: acls are not enabled
after remount. The problem was a combination of things, but
mainly due to the gfs mount helper mount.gfs2 not passing the
mount parameters on in the extras string during a remount.
The mount helper was also incorrectly putting some messages
into stdout.
Patches:
http://sourceware.org/cgi-bin/cvsweb.cgi/cluster/gfs-kernel/src/gfs/mount.c.diff?cvsroot=cluster&r1=1.14&r2=1.15
http://sourceware.org/cgi-bin/cvsweb.cgi/cluster/gfs-kernel/src/gfs/ops_super.c.diff?cvsroot=cluster&r1=1.22&r2=1.23
http://sourceware.org/cgi-bin/cvsweb.cgi/cluster/gfs2/mount/mount.gfs2.c.diff?cvsroot=cluster&r1=1.18&r2=1.19
http://sourceware.org/cgi-bin/cvsweb.cgi/cluster/gfs2/mount/util.c.diff?cvsroot=cluster&r1=1.15&r2=1.16
--- cluster/gfs-kernel/src/gfs/mount.c 2006/07/18 20:48:20 1.14
+++ cluster/gfs-kernel/src/gfs/mount.c 2006/10/14 20:16:15 1.15
@@ -42,7 +42,7 @@
/* If someone preloaded options, use those instead */
spin_lock(&gfs_proc_margs_lock);
- if (gfs_proc_margs) {
+ if (!remount && gfs_proc_margs) {
data = gfs_proc_margs;
gfs_proc_margs = NULL;
}
--- cluster/gfs-kernel/src/gfs/ops_super.c 2006/07/18 20:48:20 1.22
+++ cluster/gfs-kernel/src/gfs/ops_super.c 2006/10/14 20:16:15 1.23
@@ -331,7 +331,7 @@
if (!args)
return -ENOMEM;
- error = gfs_make_args(data, args, FALSE);
+ error = gfs_make_args(data, args, TRUE);
if (error) {
printk("GFS: can't parse remount arguments\n");
goto out;
--- cluster/gfs2/mount/mount.gfs2.c 2006/10/13 20:01:19 1.18
+++ cluster/gfs2/mount/mount.gfs2.c 2006/10/14 20:16:19 1.19
@@ -120,8 +120,10 @@
int rv = 0;
if (!strcmp(proto, "lock_dlm")) {
- if (mo->flags & MS_REMOUNT)
+ if (mo->flags & MS_REMOUNT) {
rv = lock_dlm_remount(mo, sb);
+ strncpy(mo->extra_plus, mo->extra, PATH_MAX);
+ }
else
rv = lock_dlm_join(mo, sb);
} else
--- cluster/gfs2/mount/util.c 2006/10/13 22:01:40 1.15
+++ cluster/gfs2/mount/util.c 2006/10/14 20:16:19 1.16
@@ -11,7 +11,7 @@
extern char *prog_name;
extern char *fsname;
extern int verbose;
-static int gfs_controld_fd;
+static int gfs_controld_fd = -1;
#define LOCK_DLM_SOCK_PATH "gfs_controld_sock" /* FIXME: use a header */
#define MAXLINE 256 /* size of messages with gfs_controld */
@@ -385,11 +385,11 @@
i = 0;
do {
fd = gfs_controld_connect();
- if (fd < 0) {
+ if (fd <= 0) {
warn("waiting for gfs_controld to start");
sleep(1);
}
- } while (fd < 0 && ++i < 10);
+ } while (fd <= 0 && ++i < 10);
/* FIXME: should we start the daemon here? */
if (fd < 0) {
@@ -521,6 +521,8 @@
int rv;
char buf[MAXLINE];
+ if(gfs_controld_fd <= 0) /* if we didn't do the lock_dlm_join */
+ return; /* forget the rest */
memset(buf, 0, sizeof(buf));
rv = snprintf(buf, MAXLINE, "mount_result %s %s %d", mo->dir, fsname,
result);
@@ -548,13 +550,13 @@
i = 0;
do {
fd = gfs_controld_connect();
- if (fd < 0) {
+ if (fd <= 0) {
warn("waiting for gfs_controld to start");
sleep(1);
}
- } while (!fd && ++i < 10);
+ } while (fd <= 0 && ++i < 10);
- if (fd < 0) {
+ if (fd <= 0) {
warn("gfs_controld not running");
rv = -1;
goto out;
@@ -627,13 +629,14 @@
i = 0;
do {
- sleep(1);
fd = gfs_controld_connect();
- if (!fd)
+ if (fd <= 0) {
warn("waiting for gfs_controld to start");
- } while (!fd && ++i < 10);
+ sleep(1);
+ }
+ } while (fd <= 0 && ++i < 10);
- if (!fd) {
+ if (fd <= 0) {
warn("gfs_controld not running");
rv = -1;
goto out;
reply other threads:[~2006-10-14 20:16 UTC|newest]
Thread overview: [no followups] expand[flat|nested] mbox.gz Atom feed
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20061014201620.29818.qmail@sourceware.org \
--to=rpeterso@sourceware.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.