Thanks.
On Dec 13, 2010, at 10:39 AM, Jean-Louis Martineau wrote:
The amdump log file is corrupted.
The attached patch fix it for newer log.
Jean-Louis
Jack O'Connell wrote:
Hello,
After upgrading to v3.2.0, amstatus intermittently generates the
following warning messages followed by a status report that is not
consistent with amreport or amoverview reports of successful
competion.
** (process:26492): WARNING **: Use of uninitialized value in hash
element at /usr/sbin/amstatus line 507, <AMDUMP> line 3956.
** (process:26492): WARNING **: Use of uninitialized value in hash
element at /usr/sbin/amstatus line 508, <AMDUMP> line 3956.
** (process:26492): WARNING **: Use of uninitialized value in hash
element at /usr/sbin/amstatus line 509, <AMDUMP> line 3956.
** (process:26492): WARNING **: Use of uninitialized value in
subtraction (-) at /usr/sbin/amstatus line 509, <AMDUMP> line 3956.
** (process:26492): WARNING **: Use of uninitialized value in hash
element at /usr/sbin/amstatus line 511, <AMDUMP> line 3956.
** (process:26492): WARNING **: Use of uninitialized value in hash
element at /usr/sbin/amstatus line 512, <AMDUMP> line 3956.
** (process:26492): WARNING **: Use of uninitialized value in hash
element at /usr/sbin/amstatus line 538, <AMDUMP> line 3962.
** (process:26492): WARNING **: Use of uninitialized value in hash
element at /usr/sbin/amstatus line 540, <AMDUMP> line 3962.
** (process:26492): WARNING **: Use of uninitialized value in hash
element at /usr/sbin/amstatus line 544, <AMDUMP> line 3962.
** (process:26492): WARNING **: Use of uninitialized value in
subtraction (-) at /usr/sbin/amstatus line 544, <AMDUMP> line 3962.
** (process:26492): WARNING **: Use of uninitialized value in hash
element at /usr/sbin/amstatus line 546, <AMDUMP> line 3962.
** (process:26492): WARNING **: Use of uninitialized value in hash
element at /usr/sbin/amstatus line 551, <AMDUMP> line 3962.
** (process:26492): WARNING **: Use of uninitialized value in hash
element at /usr/sbin/amstatus line 552, <AMDUMP> line 3962.
Thanks,
Jack O'Connell
ALCF - Storage
(630)252-3610
joco...@alcf.anl.gov <mailto:joco...@alcf.anl.gov>
Index: ChangeLog
===================================================================
--- ChangeLog (revision 3576)
+++ ChangeLog (revision 3580)
@@ -1,3 +1,9 @@
+2010-10-29 Jean-Louis Martineau <martin...@zmanda.com>
+ * server-src/amflush.c: Open 'amflush' log file in append mode.
+
+2010-10-29 Jean-Louis Martineau <martin...@zmanda.com>
+ * server-src/amdump.pl: Open 'amdump' log file in append mode.
+
2010-10-28 Jean-Louis Martineau <martin...@zmanda.com>
* common-src/conffile.c: Fix quoting in recovery-limit output.
* server-src/amadmin.c (disklist_one): Print recovery-limit.
Index: server-src/amflush.c
===================================================================
--- server-src/amflush.c (revision 3576)
+++ server-src/amflush.c (revision 3580)
@@ -681,7 +681,7 @@
fflush(stdout); fflush(stderr);
errfile = vstralloc(conf_logdir, "/amflush", NULL);
- if((fderr = open(errfile, O_WRONLY| O_CREAT | O_TRUNC, 0600))
== -1) {
+ if((fderr = open(errfile, O_WRONLY| O_APPEND | O_CREAT |
O_TRUNC, 0600)) == -1) {
error(_("could not open %s: %s"), errfile, strerror(errno));
/*NOTREACHED*/
}
Index: server-src/amdump.pl
===================================================================
--- server-src/amdump.pl (revision 3576)
+++ server-src/amdump.pl (revision 3580)
@@ -192,7 +192,8 @@
# undef first.. stupid perl.
debug("beginning amdump log");
$amdump_log = undef;
- open($amdump_log, ">", $amdump_log_filename)
+ # Must be opened in append so that all subprocess can write to
it.
+ open($amdump_log, ">>", $amdump_log_filename)
or die("could not open amdump log file '$amdump_log_filename': $!");
}
Thanks,
Jack O'Connell
ALCF - Storage
(630)252-3610
joco...@alcf.anl.gov