Opened 7 years ago

Closed 6 years ago

#626 closed defect (fixed)

nfs mount fails at mondorestore

Reported by: vicgat Owned by: bruno
Priority: high Milestone: 3.0.4
Component: mondo Version: 3.0.3
Severity: critical Keywords: nfs, restore, mindi
Cc: vaida.dan@…

Description

From SLES 11 64bits, I mondoarchived on a NFS share.

When I booted on mondorescue.iso and ran nuke, mondorestore tried to mount the NFS share but failed (see attached).

I checked mondorestore.c, and I see lines 3135 and 3138 :

"mount %s@%s -o nolock,ro /tmp/isodir"

I recommend as a solution to add to that mount the option "-t nfs", because otherwise the NFS mount fails.

Attachments (9)

1 failed to find config.jpg (130.4 KB) - added by vicgat 7 years ago.
the error
mount essais.jpg (186.8 KB) - added by vicgat 7 years ago.
manual try to mount fail too
mount-vvv.jpg (181.8 KB) - added by vicgat 7 years ago.
mount debug through -vvv options
les mount.jpg (188.1 KB) - added by vicgat 7 years ago.
Test with sbin/mount.nfs and the list of the mount commands
vers 3.jpg (176.9 KB) - added by vicgat 7 years ago.
nfs vers3 test with nolock (-vvv result)
vers 3 sans nolock.jpg (178.4 KB) - added by vicgat 7 years ago.
nfs vers3 test without nolock (-vvv result)
lsmod-grep-nfs.jpg (44.5 KB) - added by vicgat 7 years ago.
Checked nfs modules loaded (lsmod | grep nfs)
solution fsid.jpg (90.5 KB) - added by vicgat 7 years ago.
mount succeeds with fsid=0 despite a modprobe ipv6.ko module error
solution fsid verbose.jpg (146.2 KB) - added by vicgat 7 years ago.
mount (verbose) succeeds with fsid=0 despite a modprobe ipv6.ko module error

Download all attachments as: .zip

Change History (20)

Changed 7 years ago by vicgat

the error

comment:1 Changed 7 years ago by vicgat

In mondorestore.log I see:

[Main] mondorestore.c->main#3122: Mounting remote nfs dir
running: mount 15.129.19.157:/media/backup -o nolock,ro /tmp/isodir > //mondo.tmp.oqQydg/mondo-run-prog-thing.tmp 2> //mondo.tmp.oqQydg/mondo-run-prog-thing.err
--------------------------------start of output-----------------------------
mount.nfs: Protocol not supported
--------------------------------end of output------------------------------

I switched to a shell through Alt-F2, and I tried to mount manually with the option "-t nfs", but it didn't worked neither, I still get "mount.nfs: Protocol not supported".

Changed 7 years ago by vicgat

manual try to mount fail too

comment:2 Changed 7 years ago by vicgat

I did some verbose tests (see attached).

Something seems to miss in the backup for NFS, maybe a module (see attached the list).

It seems to be a SLES 11 bug...some tracks :

http://lists.opensuse.org/opensuse-bugs/2011-02/msg02757.html

http://web.archiveorange.com/archive/v/wmeLDAR6ZmoOyqa6zYjh

https://bugzilla.novell.com/show_bug.cgi?id=672172

Changed 7 years ago by vicgat

mount debug through -vvv options

Changed 7 years ago by vicgat

Test with sbin/mount.nfs and the list of the mount commands

Changed 7 years ago by vicgat

nfs vers3 test with nolock (-vvv result)

Changed 7 years ago by vicgat

nfs vers3 test without nolock (-vvv result)

Changed 7 years ago by vicgat

Checked nfs modules loaded (lsmod | grep nfs)

comment:3 Changed 7 years ago by vicgat

Solution

With fsid=0 in /etc/exports the manual mount from the mindi-busybox shell succeeds with "15.129.19.157:/"

NFS server :

# cat /etc/exports
/media/backup *(rw,fsid=0)

NFS client :

mount -t nfs4 15.129.19.157:/  /tmp/isodir -o ro,nolock

comment:4 Changed 7 years ago by vicgat

When the mount occurs, we see a FATAL error concerning the opening of module ipv6.ko, but the mount succeeds (see screenshots "solution fsid.jpg" and "solution fsid verbose.jpg").

Changed 7 years ago by vicgat

mount succeeds with fsid=0 despite a modprobe ipv6.ko module error

Changed 7 years ago by vicgat

mount (verbose) succeeds with fsid=0 despite a modprobe ipv6.ko module error

comment:5 Changed 7 years ago by vicgat

I solved this mondorestore NFS mount issue by using fsid=0 on the NFS server side, and by using "mount -t nfs4 ipaddress:/" instead of "mount -t nfs ipaddress:/the/path".

So mondorestore.c should be modified to use that mount syntax, and the NFS server config with fsid=0 should be documented in mondorescue NFS (and things related to NFS : PXE etc) documentation.

For info

I found that someone else solved his mondorestore NFS mount problem that way :

After I recompiled busybox with support for system UID and system GID, I
also gave a try again to nfs : nfs mount works !

>> Support for SUID/SGID handling (FEATURE_SUID) [N/y/?] -> MUST BE Y
>> Runtime SUID/SGID configuration via /etc/busybox.conf
>> (FEATURE_SUID_CONFIG) [Y/n/?] (NEW) -> I PUT NO

I found it there : http://mondorescue-mailing-list.679749.n3.nabble.com/Mondo-devel-PXE-NFS-or-PXE-sshfs-does-not-work-with-Debian-Squeeze-td3261202.html

Last edited 7 years ago by vicgat (previous) (diff)

comment:6 Changed 7 years ago by vicgat

I saw that, in /bin, the only executables present were : mount, busybox + the links to it ; bash was not present in /bin, nor other executables listed in minimal.conf (gawk, etc.).

So I rebooted on mondorescue.iso again, after having changed on the NFS server exports to: /media/backup *(rw,no_root_squash)

and now the NFS mount by mondorestore is ok, bash and other executables (listed in minimal.conf) are now present in /bin, keyboard mapping is ok too.

So mondorestore.c is ok.

comment:7 Changed 7 years ago by vicgat

  • Resolution set to fixed
  • Status changed from new to closed

comment:8 Changed 6 years ago by dan

  • Cc vaida.dan@… added
  • Keywords nfs restore mindi added
  • Milestone changed from 3.0.3 to 3.0.4
  • Resolution fixed deleted
  • Severity changed from major to critical
  • Status changed from closed to reopened
  • Version changed from 3.0.2 to 3.0.3

Please see http://trac.mondorescue.org/ticket/699

Tested on Debian 6.0.7 and it works great but for some reason it doesn't work with Ubuntu. Plus, I tried recompiling Busybox as indicated without any luck.

comment:9 Changed 6 years ago by vicgat

Dan, Do you use no_root_squash option in /etc/exports mondo iso directory option?

comment:10 Changed 6 years ago by vicgat

Dan added the following libnss path to deplist.txt file, and that solved the problem :

/lib/x86_64-linux-gnu/libnss_compat-2.15.so
/lib/x86_64-linux-gnu/libnss_compat.so.2
/lib/x86_64-linux-gnu/libnss_dns-2.15.so
/lib/x86_64-linux-gnu/libnss_dns.so.2
/lib/x86_64-linux-gnu/libnss_files-2.15.so
/lib/x86_64-linux-gnu/libnss_files.so.2
/lib/x86_64-linux-gnu/libnss_hesiod-2.15.so
/lib/x86_64-linux-gnu/libnss_hesiod.so.2
/lib/x86_64-linux-gnu/libnss_nis-2.15.so
/lib/x86_64-linux-gnu/libnss_nis.so.2
/lib/x86_64-linux-gnu/libnss_nisplus-2.15.so
/lib/x86_64-linux-gnu/libnss_nisplus.so.2
/usr/lib/x86_64-linux-gnu/libnss_compat.so
/usr/lib/x86_64-linux-gnu/libnss_dns.so
/usr/lib/x86_64-linux-gnu/libnss_files.so
/usr/lib/x86_64-linux-gnu/libnss_hesiod.so
/usr/lib/x86_64-linux-gnu/libnss_nis.so
/usr/lib/x86_64-linux-gnu/libnss_nisplus.so

More informations

comment:11 Changed 6 years ago by bruno

  • Resolution set to fixed
  • Status changed from reopened to closed

Please follow this thread in #699. This bug report for *SLES* is really closed :-) Only reopen for the original case not being fixed really.

Note: See TracTickets for help on using tickets.