Your message dated Sun, 29 Nov 2009 22:00:30 +0000
with message-id <[email protected]>
and subject line Bug#499078: fixed in jfsutils 1.1.12-2.1
has caused the Debian Bug report #499078,
regarding jfsutils: Bus Error when running fsck.jfs on sparc
to be marked as done.
This means that you claim that the problem has been dealt with.
If this is not the case it is now your responsibility to reopen the
Bug report if necessary, and/or fix the problem forthwith.
(NB: If you are a system administrator and have no idea what this
message is talking about, this may indicate a serious mail system
misconfiguration somewhere. Please contact [email protected]
immediately.)
--
499078: http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=499078
Debian Bug Tracking System
Contact [email protected] with problems
--- Begin Message ---
Package: jfsutils
Version: 1.1.11-1
Severity: critical
Tags: patch
Justification: breaks the whole system
I lost power on my server a while back. Fortunately, I am running a journaling
filesystem, JFS, so it shouldn't be a big deal. Unfortunately, fsck.jfs
dies with a bus error when trying to replay the journal on my root filesystem.
I got my system running again, by copying the root FS to an amd64 box (which
doesn't enforce alignment requirements), running fsck.jfs on it, and copying
it back. (I kept a copy of the original filesystem so I could reproduce the
bug.)
I have a patch which fixes the first unaligned access, but there is at least
one more.
Here is the original backtrace (I did apt-get source and compiled with -g):
a...@ypane:~$ gdb ~/deb/jfsutils-1.1.11/fsck/jfs_fsck
GNU gdb 6.4.90-debian
Copyright (C) 2006 Free Software Foundation, Inc.
GDB is free software, covered by the GNU General Public License, and you are
welcome to change it and/or distribute copies of it under certain conditions.
Type "show copying" to see the conditions.
There is absolutely no warranty for GDB. Type "show warranty" for details.
This GDB was configured as "sparc-linux-gnu"...Using host libthread_db library
"/lib/v9/libthread_db.so.1".
(gdb) run md0.orig
Starting program: /home/aij/deb/jfsutils-1.1.11/fsck/jfs_fsck md0.orig
/home/aij/deb/jfsutils-1.1.11/fsck/jfs_fsck version 1.1.11, 05-Jun-2006
processing started: 9/15/2008 18.43.40
Using default parameter: -p
The current device is: md0.orig
Block size in bytes: 4096
Filesystem size in blocks: 1464816
**Phase 0 - Replay Journal Log
Program received signal SIGBUS, Bus error.
0x0005f5f0 in ujfs_swap_superblock (sblk=0xffff232c) at jfs_endian.c:554
554 sblk->s_size = __le64_to_cpu(sblk->s_size);
(gdb) bt
#0 0x0005f5f0 in ujfs_swap_superblock (sblk=0xffff232c) at jfs_endian.c:554
#1 0x00059df0 in ujfs_put_superblk (fp=0x1786c8, sb=0xb4568, is_primary=1)
at super.c:172
#2 0x0005562c in phase0_processing () at xchkdsk.c:1877
#3 0x00050ef0 in main (argc=2, argv=0xffff34f4) at xchkdsk.c:333
(gdb)
The patch to fix that (buf needs proper alignment):
----- cut here -----
--- libfs/super.c.orig 2005-11-22 15:43:55.000000000 -0500
+++ libfs/super.c 2008-09-15 21:03:27.936428396 -0400
@@ -162,14 +162,14 @@
*/
int ujfs_put_superblk(FILE *fp, struct superblock *sb, int16_t is_primary)
{
- char buf[SIZE_OF_SUPER];
+ struct superblock buf[(SIZE_OF_SUPER+sizeof(*sb)-1)/sizeof(*sb)];
int rc;
memset(buf, 0, SIZE_OF_SUPER);
memcpy(buf, sb, sizeof (*sb));
/* swap if on big endian machine */
- ujfs_swap_superblock((struct superblock *) buf);
+ ujfs_swap_superblock(buf);
rc = ujfs_rw_diskblocks(fp, (is_primary ? SUPER1_OFF : SUPER2_OFF),
SIZE_OF_SUPER, buf, PUT);
------ cut here -----
And a new backtrace:
a...@ypane:~$ gdb ~/deb/jfsutils-1.1.11/fsck/jfs_fsck
GNU gdb 6.4.90-debian
Copyright (C) 2006 Free Software Foundation, Inc.
GDB is free software, covered by the GNU General Public License, and you are
welcome to change it and/or distribute copies of it under certain conditions.
Type "show copying" to see the conditions.
There is absolutely no warranty for GDB. Type "show warranty" for details.
This GDB was configured as "sparc-linux-gnu"...Using host libthread_db library
"/usr/lib/debug/libthread_db.so.1".
(gdb) run md0.orig
Starting program: /home/aij/deb/jfsutils-1.1.11/fsck/jfs_fsck md0.orig
/home/aij/deb/jfsutils-1.1.11/fsck/jfs_fsck version 1.1.11, 05-Jun-2006
processing started: 9/15/2008 21.9.54
Using default parameter: -p
The current device is: md0.orig
Block size in bytes: 4096
Filesystem size in blocks: 1464816
**Phase 0 - Replay Journal Log
Program received signal SIGBUS, Bus error.
0x0006a6e8 in updatePage (ld=0xffa6f2c0, logaddr=1572600) at log_work.c:2809
2809 rc =
markImap(&vopen[vol].fsimap_lst,
(gdb) bt
#0 0x0006a6e8 in updatePage (ld=0xffa6f2c0, logaddr=1572600)
at log_work.c:2809
#1 0x00065ae0 in doAfter (ld=0xffa6f2c0, logaddr=1572600) at log_work.c:633
#2 0x00061a98 in jfs_logredo (pathname=0xffa6f5f8 "md0.orig", fp=0x1786c8,
use_2nd_aggSuper=0) at logredo.c:691
#3 0x00055664 in phase0_processing () at xchkdsk.c:1880
#4 0x00050ef0 in main (argc=2, argv=0xffa6f4d4) at xchkdsk.c:333
(gdb) print dip
$1 = (struct dinode *) 0xbe794
(gdb) print &dip->di_ixpxd
$2 = (pxd_t *) 0xbe7a4
(gdb) print sizeof(pxd_t)
$3 = 8
(gdb) x/i 0x0006a6e8
0x6a6e8 <updatePage+4300>: ldd [ %g1 + 0x10 ], %g2
(gdb) print/x $g1
$5 = 0xbe794
(gdb)
Clearly the problem here is that dip is only 4 byte aligned, but it has an
8-byte field, which requires 8-byte alignment.
Fixing that may be as simple as 8-byte aligning afterdata, but I'm yet unsure
about all the other variables dip depends on... I'll be happy to test any
patches for this. ;)
Ivan
-- System Information:
Debian Release: 4.0
APT prefers stable
APT policy: (500, 'stable')
Architecture: sparc (sparc64)
Shell: /bin/sh linked to /bin/bash
Kernel: Linux 2.6.18-6-sparc64
Locale: LANG=en_US.UTF-8, LC_CTYPE=en_US.UTF-8 (charmap=UTF-8)
Versions of packages jfsutils depends on:
ii lib 2.3.6.ds1-13etch7 GNU C Library: Shared libraries
ii lib 1.39+1.40-WIP-2006.11.14+dfsg-2etch1 universally unique id library
jfsutils recommends no packages.
-- no debconf information
--- End Message ---
--- Begin Message ---
Source: jfsutils
Source-Version: 1.1.12-2.1
We believe that the bug you reported is fixed in the latest version of
jfsutils, which is due to be installed in the Debian FTP archive:
jfsutils-udeb_1.1.12-2.1_i386.udeb
to main/j/jfsutils/jfsutils-udeb_1.1.12-2.1_i386.udeb
jfsutils_1.1.12-2.1.diff.gz
to main/j/jfsutils/jfsutils_1.1.12-2.1.diff.gz
jfsutils_1.1.12-2.1.dsc
to main/j/jfsutils/jfsutils_1.1.12-2.1.dsc
jfsutils_1.1.12-2.1_i386.deb
to main/j/jfsutils/jfsutils_1.1.12-2.1_i386.deb
A summary of the changes between this version and the previous one is
attached.
Thank you for reporting the bug, which will now be closed. If you
have further comments please address them to [email protected],
and the maintainer will reopen the bug report if appropriate.
Debian distribution maintenance software
pp.
Steve McIntyre <[email protected]> (supplier of updated jfsutils package)
(This message was generated automatically at their request; if you
believe that there is a problem with it please contact the archive
administrators by mailing [email protected])
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1
Format: 1.8
Date: Sun, 29 Nov 2009 19:16:16 +0000
Source: jfsutils
Binary: jfsutils jfsutils-udeb
Architecture: source i386
Version: 1.1.12-2.1
Distribution: unstable
Urgency: low
Maintainer: Stefan Hornburg (Racke) <[email protected]>
Changed-By: Steve McIntyre <[email protected]>
Description:
jfsutils - utilities for managing the JFS filesystem
jfsutils-udeb - A stripped-down version of jfsutils, for debian-installer
(udeb)
Closes: 499078
Changes:
jfsutils (1.1.12-2.1) unstable; urgency=low
.
* Non-maintainer upload.
* Fix alignment problem causing SIGBUS on sparc. Closes: #499078
Checksums-Sha1:
bcd5aed175df72aca291965424d0bfc1f4e2a6a8 1046 jfsutils_1.1.12-2.1.dsc
b5e97d6e07338d93025ba68ae33ab98b6159f0dd 3932 jfsutils_1.1.12-2.1.diff.gz
d5d3186fd29bd5c21b36c94e1f32c30938665e47 269752 jfsutils_1.1.12-2.1_i386.deb
13edbba3aa25421c65b994ce1e1de779e2a747e9 238544
jfsutils-udeb_1.1.12-2.1_i386.udeb
Checksums-Sha256:
1782395f476441113cab5dbf589ac605f986aca3557b444ddf7393367179b2ea 1046
jfsutils_1.1.12-2.1.dsc
014003361a04d4dccc51a326bd905a8bd34dba52f0e2c5eee54c91304f55e56d 3932
jfsutils_1.1.12-2.1.diff.gz
65cd11018bd642a2a1f488a318d4f2c8257dc2360d746086a921c38e0adcef60 269752
jfsutils_1.1.12-2.1_i386.deb
036b105669e546ca59305a7c93418cc7106be1ce739ec1e8313b6288dd421510 238544
jfsutils-udeb_1.1.12-2.1_i386.udeb
Files:
9673678c1e9039004ee1b907097055dc 1046 admin optional jfsutils_1.1.12-2.1.dsc
8821e19eb927330a813442ecced2c3ed 3932 admin optional
jfsutils_1.1.12-2.1.diff.gz
e40d2acbdffab7cd52e96cbc96e2a757 269752 admin optional
jfsutils_1.1.12-2.1_i386.deb
5bbb30361f1b620c1a89695f75aecd3e 238544 debian-installer optional
jfsutils-udeb_1.1.12-2.1_i386.udeb
Package-Type: udeb
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.9 (GNU/Linux)
iEYEARECAAYFAksSy2YACgkQfDt5cIjHwfevtQCfdI3Cm+NITS5OK/rP8ZdrlXn2
EiQAoIIA9jN+PVi3TEdMx7QZGsiik+zh
=cTYA
-----END PGP SIGNATURE-----
--- End Message ---