#1679 Issue closed
: /sbin directory not backing completely while taking rear locally..¶
Labels: support / question
, fixed / solved / done
Ram4Linux opened issue at 2018-01-05 07:03:¶
Relax-and-Recover (ReaR) Issue Template¶
Fill in the following items before submitting a new issue
(quick response is not guaranteed with free support):
-
rear version (/usr/sbin/rear -V):Relax-and-Recover 2.2
-
OS version (cat /etc/rear/os.conf or lsb_release -a): SUSE 11 SP4
-
rear configuration files (cat /etc/rear/site.conf or cat /etc/rear/local.conf):
OUTPUT=ISO
BACKUP=NETFS
#NETFS_URL=nfs://rearserver.apps.mars/rear/backup
#ONLY_INCLUDE_VG=( vg00 )
#BACKUP_URL=file:///rearBKP/
#NETFS_URL=nfs://rearserver.apps.mars/rear/backup
BACKUP_URL=nfs://isxl1041/rear/backup
ONLY_INCLUDE_VG=( vg00 ) -
Are you using legacy BIOS or UEFI boot?
BIOS -
Brief description of the issue: I am trying to take the rear locally and restore through remote server by source of NFS. But I am not able to mount the file systems while running rear recover because of wrong fstype and umount helper was not found. I have searched in /sbin directory and I did not find mount.nfs and umount.nfs in the rear iso taken locally. But I am able to find those in the rear iso taken in to remote server through nfs. Please let me know how can we fix this.
-
Work-around, if any: as of now NOthing from my side.
Ram4Linux commented at 2018-01-05 07:05:¶
RESCUE isxl1042:/etc/rear # rear recover Relax-and-Recover 2.2 / 2017-07-20 Using log file: /var/log/rear/rear-isxl1042.log Running workflow recover within the ReaR rescue/recovery system Using backup archive '/rearBKP//isxl1042/backup.tar.gz' Will do driver migration (recreating initramfs/initrd) ERROR: Backup archive 'backup.tar.gz' not found. Aborting due to an error, check /var/log/rear/rear-isxl1042.log for details Terminated mount: wrong fs type, bad option, bad superblock on isxl1041.dc.mars:/rear/backup, missing codepage or helper program, or other error (for several filesystems (e.g. nfs, cifs) you might need a /sbin/mount.helper program) In some cases useful info is found in syslog - try dmesg | tail or so
gdha commented at 2018-01-05 08:12:¶
@Ram4Linux According the error message "Using backup archive
'/rearBKP//isxl1042/backup.tar.gz'" the
followingBACKUP_URL=file:///rearBKP/
was in use, but somewhat later it
seems to have used BACKUP_URL=nfs://isxl1041/rear/backup
according the
mount problem? Were you mixing 2 BACKUP_URL settings?
As the NFS mount failed I guess the file:// setting was the actual
setting used during the rear mkbackup
I would say please retry with a consistent local.conf
- thanks.
Ram4Linux commented at 2018-01-05 08:29:¶
HI Gdha,
Thanks for the reply. I am sorry for the wrong out put given above.
Please find the correct output as below.
Step 1:
I am taking rear backup locally under /rearBKP.
Step2:
Copying the all rear files under /rearBKP folder
to isxl1041 server /rear/backup.
Step3:
changing the rear configuration in local.conf
(commenting Backup_URL-file:///rearBKP/ and
uncommenting BACKUP_URL=nfs://isxl1041/rear/backup)
so that recovery will try to access the isxl1041 server.
Error as below
RESCUE isxl1042:/etc/rear # rear recover Relax-and-Recover 2.2 / 2017-07-20 Using log file: /var/log/rear/rear-isxl1042.log Running workflow recover within the ReaR rescue/recovery system Starting required daemons for NFS: RPC portmapper (portmap or rpcbind) and rpc.statd if available. Started RPC portmapper 'rpcbind'. RPC portmapper 'rpcbind' available. Started rpc.statd. RPC status rpc.statd available. ERROR: Mount command 'mount -v -t nfs -o rw,noatime isxl1041.dc.mars:/rear/backup /tmp/rear.CkzOKS1doRZ3Vrq/outputfs' failed. Aborting due to an error, check /var/log/rear/rear-isxl1042.log for details Terminated 2018-01-05 03:19:08.449192904 Including verify/NETFS/default/060_mount_NETFS_path.sh mkdir: created directory `/tmp/rear.CkzOKS1doRZ3Vrq/outputfs' 2018-01-05 03:19:08.455037095 Mounting with 'mount -v -t nfs -o rw,noatime isxl1041.dc.mars:/rear/backup /tmp/rear.CkzOKS1doRZ3Vrq/outputfs' mount: wrong fs type, bad option, bad superblock on isxl1041.dc.mars:/rear/backup, missing codepage or helper program, or other error (for several filesystems (e.g. nfs, cifs) you might need a /sbin/mount.helper program) In some cases useful info is found in syslog - try dmesg | tail or so
I have tried another rear backup copying to a remote server directly and compared to local rear . I found mount.nfs and umount.nfs were missing in rear taken locally. only these two are missing and every other are copied to iso. Below are the details.
Rear to remote server through NFS
RESCUE isxl1042:/sbin # ls -lrt | grep mount -rwxr-xr-x 1 root root 111272 Apr 22 2015 umount.nfs -rwxr-xr-x 1 root root 19456 Apr 22 2015 showmount -rwxr-xr-x 1 root root 111272 Apr 22 2015 mount.nfs -rwsr-xr-x 1 root root 69240 Jun 9 2015 umount -rwsr-xr-x 1 root root 94808 Jun 9 2015 mount RESCUE isxl1042:/sbin # ls -lrt | wc -l 250
IN rear taken locally
RESCUE isxl1042:/sbin # ls -lrt | grep mount -rwxr-xr-x 1 root root 19456 Apr 22 2015 showmount -rwsr-xr-x 1 root root 69240 Jun 9 2015 umount -rwsr-xr-x 1 root root 94808 Jun 9 2015 mount RESCUE isxl1042:/sbin # ls -lrt | wc -l 248
Sorry i am missing anything. Please forgive the mistakes
and help in fixing the problem
jsmeix commented at 2018-01-05 09:59:¶
@Ram4Linux
what gets automatically included in the ReaR recovery system
depends in various ways on the settings in /etc/rear/local.conf
In general the ReaR recovery system is minimal.
In this case it means with BACKUP_URL=file:///...
while you run "rear mkrescue/mkbackup"
stuff for NFS mounting is not needed
so that this or that is not automatically
included in the ReaR recovery system.
For special use cases as yours you can specify anything
what you need in addition to what is automatically included
in the ReaR recovery system via the config variables
COPY_AS_IS REQUIRED_PROGS LIBS MODULES MODULES_LOAD FIRMWARE_FILES
See usr/share/rear/conf/default.conf
gdha commented at 2018-01-05 11:23:¶
@Ram4Linux You could include the following in your local.conf
file:
PROGS=( "${PROGS[@]}" showmount mount.nfs umount.nfs )
MODULES=( "${MODULES[@]}" nfs )
PRE_RECOVERY_SCRIPT="systemctl start rpcbind.target"
Then, you will always have the required binaries and daemons present for using NFS (anywhere)
jsmeix commented at 2018-01-05 11:34:¶
I think any kind of systemctl
does not work on "SUSE 11 SP4"
but the general idea of using a PRE_RECOVERY_SCRIPT
is right.
Furthermore MODULES=( "${MODULES[@]}" nfs )
alone
might be insufficient, see my MODULES description
in default.conf in particular the therein mentioned issue
https://github.com/rear/rear/issues/1355
and my own experience with mounting an ISO
from within a default ReaR recovery system in
https://github.com/rear/rear/issues/1202
[Export of Github issue for rear/rear.]