mdadm/mdadm-3.0-mdmon-dev-.mdadm.patch
Doug Ledford c8f603e0a8 - New upstream release 3.0.3 (bz523320, bz527281)
- Update a couple internal patches
- Drop a patch in that was in Neil's tree for 3.0.3 that we had pulled for
    immediate use to resolve a bug
- Drop the endian patch because it no longer applied cleanly and all
    attempts to reproduce the original problem as reported in bz510605
    failed, even up to and including downloading the specific package that
    was reported as failing in that bug and trying to reproduce with it on
    both ppc and ppc64 hardware and with both ppc and ppc64 versions on the
    64bit hardware. Without a reproducer, it is impossible to determine if
    a rehashed patch to apply to this code would actually solve the
    problem, so remove the patch entirely since the original problem, as
    reported, was an easy to detect DOA issue where installing to a raid
    array was bound to fail on reboot and so we should be able to quickly
    and definitively tell if the problem resurfaces.
- Update the mdmonitor init script for LSB compliance (bz527957)
- Link from mdadm.static man page to mdadm man page (bz529314)
- Fix a problem in the raid-check script (bz523000)
- Fix the intel superblock handler so we can test on non-scsi block devices
2009-11-05 21:34:56 +00:00

82 lines
2.4 KiB
Diff

--- mdadm-3.0.3/mdmon.c.mdmon 2009-10-21 20:13:13.000000000 -0400
+++ mdadm-3.0.3/mdmon.c 2009-11-04 13:00:26.924089288 -0500
@@ -118,7 +118,7 @@ static int test_pidfile(char *devname)
char path[100];
struct stat st;
- sprintf(path, "/var/run/mdadm/%s.pid", devname);
+ sprintf(path, "/dev/.mdadm/%s.pid", devname);
return stat(path, &st);
}
@@ -132,7 +132,7 @@ int make_pidfile(char *devname, int o_ex
if (sigterm)
return -1;
- sprintf(path, "/var/run/mdadm/%s.pid", devname);
+ sprintf(path, "/dev/.mdadm/%s.pid", devname);
fd = open(path, O_RDWR|O_CREAT|o_excl, 0600);
if (fd < 0)
@@ -163,7 +163,7 @@ pid_t devname2mdmon(char *devname)
pid_t pid = -1;
int fd;
- sprintf(buf, "/var/run/mdadm/%s.pid", devname);
+ sprintf(buf, "/dev/.mdadm/%s.pid", devname);
fd = open(buf, O_RDONLY|O_NOATIME);
if (fd < 0)
return -1;
@@ -217,9 +217,9 @@ void remove_pidfile(char *devname)
if (sigterm)
return;
- sprintf(buf, "/var/run/mdadm/%s.pid", devname);
+ sprintf(buf, "/dev/.mdadm/%s.pid", devname);
unlink(buf);
- sprintf(buf, "/var/run/mdadm/%s.sock", devname);
+ sprintf(buf, "/dev/.mdadm/%s.sock", devname);
unlink(buf);
}
@@ -233,7 +233,7 @@ int make_control_sock(char *devname)
if (sigterm)
return -1;
- sprintf(path, "/var/run/mdadm/%s.sock", devname);
+ sprintf(path, "/dev/.mdadm/%s.sock", devname);
unlink(path);
sfd = socket(PF_LOCAL, SOCK_STREAM, 0);
if (sfd < 0)
--- mdadm-3.0.3/msg.c.mdmon 2009-10-21 20:13:13.000000000 -0400
+++ mdadm-3.0.3/msg.c 2009-11-04 12:12:46.281963910 -0500
@@ -147,7 +147,7 @@ int connect_monitor(char *devname)
int pos;
char *c;
- pos = sprintf(path, "/var/run/mdadm/");
+ pos = sprintf(path, "/dev/.mdadm/");
if (is_subarray(devname)) {
devname++;
c = strchr(devname, '/');
--- mdadm-3.0.3/util.c.mdmon 2009-10-21 21:07:14.000000000 -0400
+++ mdadm-3.0.3/util.c 2009-11-04 12:12:46.282963942 -0500
@@ -1208,7 +1208,7 @@ int mdmon_running(int devnum)
char pid[10];
int fd;
int n;
- sprintf(path, "/var/run/mdadm/%s.pid", devnum2devname(devnum));
+ sprintf(path, "/dev/.mdadm/%s.pid", devnum2devname(devnum));
fd = open(path, O_RDONLY, 0);
if (fd < 0)
@@ -1228,7 +1228,7 @@ int signal_mdmon(int devnum)
char pid[10];
int fd;
int n;
- sprintf(path, "/var/run/mdadm/%s.pid", devnum2devname(devnum));
+ sprintf(path, "/dev/.mdadm/%s.pid", devnum2devname(devnum));
fd = open(path, O_RDONLY, 0);
if (fd < 0)