FAQ Search Today's Posts Mark Forums Read
» Video Reviews

» Linux Archive

Linux-archive is a website aiming to archive linux email lists and to make them easily accessible for linux users/developers.


» Sponsor

» Partners

» Sponsor

Go Back   Linux Archive > Redhat > Device-mapper Development

 
 
LinkBack Thread Tools
 
Old 10-24-2011, 01:46 PM
 
Default multipath-tools/multipathd main.c

CVSROOT: /cvs/dm
Module name: multipath-tools
Branch: RHEL5_FC6
Changes by: bmarzins@sourceware.org 2011-10-24 13:46:54

Modified files:
multipathd : main.c

Log message:
fix for bz #741664. setup_multipath frees the multipath device if it fails,
so check the return value, and don't touch the multipath device, it
setup_multipath() has returned 1.

Patches:
http://sourceware.org/cgi-bin/cvsweb.cgi/multipath-tools/multipathd/main.c.diff?cvsroot=dm&only_with_tag=RHEL5_FC6&r1= 1.69.2.37&r2=1.69.2.38

--- multipath-tools/multipathd/main.c 2011/10/10 04:15:41 1.69.2.37
+++ multipath-tools/multipathd/main.c 2011/10/24 13:46:54 1.69.2.38
@@ -988,7 +988,8 @@
return 1;
}
dm_lib_release();
- setup_multipath(vecs, mpp);
+ if (setup_multipath(vecs, mpp) != 0)
+ return 1;
sync_map_state(mpp);

return 0;

--
dm-devel mailing list
dm-devel@redhat.com
https://www.redhat.com/mailman/listinfo/dm-devel
 
Old 03-22-2012, 05:02 PM
 
Default multipath-tools/multipathd main.c

CVSROOT: /cvs/dm
Module name: multipath-tools
Branch: RHEL5_FC6
Changes by: bmarzins@sourceware.org 2012-03-22 18:02:34

Modified files:
multipathd : main.c

Log message:
Fix for bz803849. applying patch from John Ruemker. multipathd was not
correctly unmounting all unnecessary devices from its private namespace.
Not applicable upstream.

Patches:
http://sourceware.org/cgi-bin/cvsweb.cgi/multipath-tools/multipathd/main.c.diff?cvsroot=dm&only_with_tag=RHEL5_FC6&r1= 1.69.2.39&r2=1.69.2.40

--- multipath-tools/multipathd/main.c 2011/10/27 21:36:20 1.69.2.39
+++ multipath-tools/multipathd/main.c 2012/03/22 18:02:34 1.69.2.40
@@ -1377,17 +1377,27 @@
{
char buf[LINE_MAX];
FILE *file;
+ vector extra_devs;
+ char *slot;
+ int s;

file = fopen("/proc/mounts", "r");
if (!file) {
condlog(0, "couldn't open /proc/mounts : %s", strerror(errno));
return -1;
}
+
+ extra_devs = vector_alloc();
+ if (!extra_devs) {
+ condlog(0, "couldn't allocate vector for extra devs
");
+ return -1;
+ }
+
find_keep_dirs();
while (fgets(buf, LINE_MAX, file)) {
int i;
char *keep;
- char *end, *mnt = strchr(buf, ' ');
+ char *end, *extra, *mnt = strchr(buf, ' ');
if (!mnt)
continue;
mnt++;
@@ -1418,13 +1428,26 @@
strncmp(mnt, "/lib64", 6) == 0 || strncmp(mnt, "/usr/lib64", 10) == 0 ||
strncmp(mnt, "/ram", 4) == 0)
continue;
- if (umount2(mnt, MNT_DETACH) < 0 && errno != ENOENT)
- condlog(0, "failed to umount '%s' (%s). skipping", mnt,
- strerror(errno));
+ if (!vector_alloc_slot(extra_devs)) {
+ condlog(2, "couldn't allocate vector slot for extra dev (%s). "
+ "skipping,", mnt);
+ continue;
+ }
+ extra = strdup(mnt);
+ vector_set_slot(extra_devs, extra);
next:
;
}
fclose(file);
+
+ vector_foreach_slot(extra_devs, slot, s) {
+ if (umount2(slot, MNT_DETACH) < 0 && errno != ENOENT) {
+ condlog(0, "failed to umount '%s' (%s). skipping",
+ slot, strerror(errno));
+ }
+ free(slot);
+ }
+ vector_free(extra_devs);
return 0;
}


--
dm-devel mailing list
dm-devel@redhat.com
https://www.redhat.com/mailman/listinfo/dm-devel
 
Old 08-07-2012, 07:37 PM
 
Default multipath-tools/multipathd main.c

CVSROOT: /cvs/dm
Module name: multipath-tools
Branch: RHEL5_FC6
Changes by: bmarzins@sourceware.org 2012-08-07 19:37:51

Modified files:
multipathd : main.c

Log message:
Fix for bz #843626. Make sure multipathd doesn't remove the
/var/cache/multipathd directory. Not applicable upstream.

Patches:
http://sourceware.org/cgi-bin/cvsweb.cgi/multipath-tools/multipathd/main.c.diff?cvsroot=dm&only_with_tag=RHEL5_FC6&r1= 1.69.2.42&r2=1.69.2.43

--- multipath-tools/multipathd/main.c 2012/07/11 23:03:34 1.69.2.42
+++ multipath-tools/multipathd/main.c 2012/08/07 19:37:51 1.69.2.43
@@ -1427,6 +1427,7 @@
strncmp(mnt, "/dev", 4) == 0 || strncmp(mnt, "/sys", 4) == 0 ||
strcmp(mnt, "/var") == 0 || strcmp(mnt, "/var/lib") == 0 ||
strcmp(mnt, "/var/lib/multipath") == 0 ||
+ strcmp(mnt, CALLOUT_DIR) == 0 ||
strncmp(mnt, "/var/run", 8) == 0 || strncmp(mnt, "/lib", 4) == 0 ||
strncmp(mnt, "/lib64", 6) == 0 || strncmp(mnt, "/usr/lib64", 10) == 0 ||
strncmp(mnt, "/ram", 4) == 0)

--
dm-devel mailing list
dm-devel@redhat.com
https://www.redhat.com/mailman/listinfo/dm-devel
 
Old 08-10-2012, 06:49 PM
 
Default multipath-tools/multipathd main.c

CVSROOT: /cvs/dm
Module name: multipath-tools
Branch: RHEL5_FC6
Changes by: bmarzins@sourceware.org 2012-08-10 18:49:10

Modified files:
multipathd : main.c

Log message:
Fix for bz #833193. Make sure multipathd removes directories named /dev<foo>
Not applicable upstream.

Patches:
http://sourceware.org/cgi-bin/cvsweb.cgi/multipath-tools/multipathd/main.c.diff?cvsroot=dm&only_with_tag=RHEL5_FC6&r1= 1.69.2.43&r2=1.69.2.44

--- multipath-tools/multipathd/main.c 2012/08/07 19:37:51 1.69.2.43
+++ multipath-tools/multipathd/main.c 2012/08/10 18:49:09 1.69.2.44
@@ -1424,10 +1424,10 @@
strcmp(mnt, "/bin") == 0 || strcmp(mnt, "/tmp") == 0 ||
strcmp(mnt, "/usr") == 0 || strncmp(mnt, "/usr/lib", 8) == 0 ||
strcmp(mnt, "/etc") == 0 || strncmp(mnt, "/proc", 5) == 0 ||
- strncmp(mnt, "/dev", 4) == 0 || strncmp(mnt, "/sys", 4) == 0 ||
+ strcmp(mnt, "/dev") == 0 || strncmp(mnt, "/sys", 4) == 0 ||
strcmp(mnt, "/var") == 0 || strcmp(mnt, "/var/lib") == 0 ||
strcmp(mnt, "/var/lib/multipath") == 0 ||
- strcmp(mnt, CALLOUT_DIR) == 0 ||
+ strncmp(mnt, "/dev/", 5) == 0 || strcmp(mnt, CALLOUT_DIR) == 0 ||
strncmp(mnt, "/var/run", 8) == 0 || strncmp(mnt, "/lib", 4) == 0 ||
strncmp(mnt, "/lib64", 6) == 0 || strncmp(mnt, "/usr/lib64", 10) == 0 ||
strncmp(mnt, "/ram", 4) == 0)

--
dm-devel mailing list
dm-devel@redhat.com
https://www.redhat.com/mailman/listinfo/dm-devel
 

Thread Tools




All times are GMT. The time now is 07:30 AM.

VBulletin, Copyright ©2000 - 2014, Jelsoft Enterprises Ltd.
Content Relevant URLs by vBSEO ©2007, Crawlability, Inc.
Copyright 2007 - 2008, www.linux-archive.org