1. 27 11月, 2007 1 次提交
    • R
      NFS: mount failure causes bad page state · f16c9603
      Russell King 提交于
      While testing a kernel based upon ecd744ee
      (with wrong boot arguments), I got the following bad page state entry while
      NFS was trying to mount it's rootfs:
      
      IP-Config: Complete:
            device=eth0, addr=192.168.1.101, mask=255.255.255.0, gw=255.255.255.255,
           host=192.168.1.101, domain=, nis-domain=(none),
           bootserver=192.168.1.100, rootserver=192.168.1.100, rootpath=
      Looking up port of RPC 100003/2 on 192.168.1.100
      rpcbind: server 192.168.1.100 not responding, timed out
      Root-NFS: Unable to get nfsd port number from server, using default
      Looking up port of RPC 100005/1 on 192.168.1.100
      rpcbind: server 192.168.1.100 not responding, timed out
      Root-NFS: Unable to get mountd port number from server, using default
      mount: server 192.168.1.100 not responding, timed out
      Root-NFS: Server returned error -5 while mounting /nfs/rootfs/
      VFS: Unable to mount root fs via NFS, trying floppy.
      Bad page state in process 'swapper'
      page:c02b1260 flags:0x00000400 mapping:00000000 mapcount:0 count:0
      Trying to fix it up, but a reboot is needed
      Backtrace:
      [<c0023e34>] (dump_stack+0x0/0x14) from [<c0062570>] (bad_page+0x70/0xac)
      [<c0062500>] (bad_page+0x0/0xac) from [<c0064914>] (free_hot_cold_page+0x80/0x178)
      [<c0064894>] (free_hot_cold_page+0x0/0x178) from [<c0064a74>] (free_hot_page+0x14/0x18)
      [<c0064a60>] (free_hot_page+0x0/0x18) from [<c0067078>] (put_page+0xf8/0x154)
      [<c0066f80>] (put_page+0x0/0x154) from [<c007dbc8>] (kfree+0xc8/0xd0)
      [<c007db00>] (kfree+0x0/0xd0) from [<c00cbb54>] (nfs_get_sb+0x230/0x710)
      [<c00cb924>] (nfs_get_sb+0x0/0x710) from [<c0084334>] (vfs_kern_mount+0x58/0xac)[<c00842dc>] (vfs_kern_mount+0x0/0xac) from [<c00843c0>] (do_kern_mount+0x38/0xf4)
      [<c0084388>] (do_kern_mount+0x0/0xf4) from [<c0099c7c>] (do_mount+0x1e8/0x614)
      ...
      
      This seems to be caused by use of an uninitialised structure due to NULL
      options being passed to nfs_validate_mount_data().  Ensure that the
      parsed mount data is always initialised.
      Signed-off-by: NRussell King <rmk+kernel@arm.linux.org.uk>
           (Trond: added fix for the same bug in nfs4_validate_mount_data()).
      Signed-off-by: NTrond Myklebust <Trond.Myklebust@netapp.com>
      f16c9603
  2. 18 11月, 2007 2 次提交
    • N
      kernel BUG at fs/nfs/namespace.c:108! - can be triggered by bad server · 4c1fe2f7
      Neil Brown 提交于
      
      Hi Trond,
      
      I have discovered that the BUG_ON in nfs_follow_mountpoint:
      
      	BUG_ON(IS_ROOT(dentry));
      
      can be triggered by a misbehaving server.
      
      What happens is the client does a lookup and discoveres that the named
      directory has a different fsid, so it initiates a mount.
      It then performs a GETATTR on the mounted directory and gets a
      different fsid again (due to a bug in the NFS server).
      This causes nfs_follow_mountpoint to be called on the newly mounted
      root, which triggers the BUG_ON.
      
      To duplicate this, have a directory which contains some mountpoints,
      and export that directory with the "crossmnt" flag using nfs-utils
      1.1.1 (or 1.1.0 I think)
      
      The GETATTR on the root of the mounted filesystem will return the
      information for the top exportpoint, while a lookup will return the
      correct information.  This difference causes the NFS client to BUG.
      
      I think the best way to fix this is to trap this possibility early, so
      just before completing the mount in the NFS client, check that it isn't
      going to use nfs_mountpoint_inode_operations.
      As long as i_op will never change once set (is that true?), this
      should be adequately safe.
      
      The following patch shows a possible approach, and it works for me.
      i.e. when the NFS server is misbehaving, I get ESTALE on those
      mountpoints, while when the NFS server is working correctly, I get
      correct behaviour on the client.
      
      NeilBrown
      Signed-off-by: NNeil Brown <neilb@suse.de>
      Signed-off-by: NTrond Myklebust <Trond.Myklebust@netapp.com>
      4c1fe2f7
    • T
      NFS: Fix the ustat() regression · b09b9417
      Trond Myklebust 提交于
      Since 2.6.18, the superblock sb->s_root has been a dummy dentry with a
      dummy inode. This breaks ustat(), which actually uses sb->s_root in a
      vfstat() call.
      
      Fix this by making the s_root a dummy alias to the directory inode that was
      used when creating the superblock.
      Signed-off-by: NTrond Myklebust <Trond.Myklebust@netapp.com>
      b09b9417
  3. 15 11月, 2007 12 次提交
  4. 14 11月, 2007 1 次提交
    • L
      Revert "ext2/ext3/ext4: add block bitmap validation" · 0b832a4b
      Linus Torvalds 提交于
      This reverts commit 7c9e69fa, fixing up
      conflicts in fs/ext4/balloc.c manually.
      
      The cost of doing the bitmap validation on each lookup - even when the
      bitmap is cached - is absolutely prohibitive.  We could, and probably
      should, do it only when adding the bitmap to the buffer cache.  However,
      right now we are better off just reverting it.
      
      Peter Zijlstra measured the cost of this extra validation as a 85%
      decrease in cached iozone, and while I had a patch that took it down to
      just 17% by not being _quite_ so stupid in the validation, it was still
      a big slowdown that could have been avoided by just doing it right.
      
      Cc: Peter Zijlstra <a.p.zijlstra@chello.nl>
      Cc: Andrew Morton <akpm@linux-foundation.org>
      Cc: Aneesh Kumar <aneesh.kumar@linux.vnet.ibm.com>
      Cc: Andreas Dilger <adilger@clusterfs.com>
      Cc: Mingming Cao <cmm@us.ibm.com>
      Signed-off-by: NLinus Torvalds <torvalds@linux-foundation.org>
      0b832a4b
  5. 13 11月, 2007 5 次提交
  6. 10 11月, 2007 1 次提交
    • J
      [CIFS] fix oops on second mount to same server when null auth is used · 9b8f5f57
      Jeff Layton 提交于
      When a share is mounted using no username, cifs_mount sets
      volume_info.username as a NULL pointer, and the sesInfo userName as an
      empty string. The volume_info.username is passed to a couple of other
      functions to see if there is an existing unc or tcp connection that can
      be used. These functions assume that the username will be a valid
      string that can be passed to strncmp. If the pointer is NULL, then the
      kernel will oops if there's an existing session to which the string
      can be compared.
      
      This patch changes cifs_mount to set volume_info.username to an empty
      string in this situation, which prevents the oops and should make it
      so that the comparison to other null auth sessions match.
      Signed-off-by: NJeff Layton <jlayton@redhat.com>
      Signed-off-by: NSteve French <sfrench@us.ibm.com>
      9b8f5f57
  7. 09 11月, 2007 4 次提交
  8. 07 11月, 2007 11 次提交
  9. 06 11月, 2007 3 次提交