#998 Issue closed: NFS support missing...

Labels: support / question, fixed / solved / done

toomaskiisk opened issue at 2016-09-15 19:04:

Relax-and-Recover 1.17.2 / Git
OS_VENDOR=OracleServer
OS_VERSION=6
AUTOEXCLUDE_MULTIPATH=
KERNEL_CMDLINE="cat /proc/cmdline | sed -e 's/\(.*\)\(root=UUID=[a-z0-9-]*\)\(.*\)/\1\3/'"
OUTPUT=ISO
BACKUP=NETFS
BACKUP_URL=file:///backup/OS
BACKUP_PROG_COMPRESS_OPTIONS=""
BACKUP_PROG_COMPRESS_SUFFIX=""
BACKUP_PROG_EXCLUDE=( '/u01/app/oraadm/diag/' '/tmp/' '/dev/shm/' '/u01/app/oraadm/admin' '/u01/data/' '/u01/app/oraadm/product/11.2.0/*/rdbms/audit' )

I need to recover system over NFS. ISO boots fine, but "rear recover" gives error. Logs indicate there is no NFS support built in. What options do I have now. Can I copy NFS support binaries from elsewhere or something like that? I cannot add hardware to server.

toomaskiisk commented at 2016-09-15 19:08:

Can I use some other net prtocol for restore like FTP or SCP?

gozora commented at 2016-09-15 19:23:

Hi,

Logs indicate there is no NFS support built in

Can you post these logs (or relevant parts at least)?

toomaskiisk commented at 2016-09-15 19:31:

Cant copy logs form there since it is on console. Error happens on step 06_mount_NETFS_path.sh and command mount -v -t nfs -o rw,noatime complains about wrong options. Error is acutally few lines long, and in the end there is hint that some filesystem types may require /sbin/mount. helpers. When checking, I see no mount helpers under /sbin indeed.

gozora commented at 2016-09-15 19:31:

hmm, now I realized ...
BACKUP_URL=file:///backup/OS
can be the problem.
Just a guess, but didn't you manually mounted NFS share to /backup/OS ?
If so, try to scp rear tarball from NFS server to /backup/OS on your clent and start rear recover

This is just guess, so no guarantees.

toomaskiisk commented at 2016-09-15 19:40:

Yes, I made backup on local filesystem assuming I can recover them later over NFS. This used to work before, when I tested recovery palns, but not today when I actually need it. This is bad, I believe it should be fixed.
But I got idea, since I have access to storage array, I create+mount new filesstem there, scp my tarball (all 33GB of it) and then try to restore.

gozora commented at 2016-09-15 19:51:

This part of ReaR code is really not my domain, so maybe I'm wrong ...
In 05_check_NETFS_requirements.sh I've found some code that looks to decide what binaries to copy depending on url_scheme (file:// in your case), so this might be reason why you are missing nfs binaries.

In any case, if you use NFS server for backups you should change your config to:
BACKUP_URL=nfs://<nfs_server>/<path>

Good luck with your restore!

toomaskiisk commented at 2016-09-15 21:31:

Thanks, I got my problem solved and our main database server is fully functional again. I can even sleep few hours tonight, really didnt hope so. Please consider making more restore methods available by default. This is because when things go wrong ,they often go multiple things at once, and you never know in advance what parts of infrastructure will be available.

jsmeix commented at 2016-09-16 07:37:

@gozora
many thanks for your help!

@toomaskiisk
you may have a look at the usr/share/rear/conf/examples/ files
that are included in current rear versions (perhaps not yet
in your 1.17.2 - I didn't check that) the current ones are at
https://github.com/rear/rear/tree/master/usr/share/rear/conf/examples
FYI:
I always do backup and restore via NFS and I always use

OUTPUT=ISO
BACKUP=NETFS
BACKUP_OPTIONS="nfsvers=3,nolock"
BACKUP_URL=nfs://your.NFS.server.IP/path/to/your/rear/backup

which always worked and works for me.

Regarding "rear recover gives error" see the section
"Debugging issues with Relax-and-Recover (rear)" in
https://en.opensuse.org/SDB:Disaster_Recovery

According to https://github.com/rear/rear/issues/998#issuecomment-247461450 "problem solved" I close this issue.


[Export of Github issue for rear/rear.]