Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Missing backup in recovery iso for IBM PowerVM LPAR #697

Closed
TobiasKarnat opened this issue Nov 13, 2015 · 13 comments
Closed

Missing backup in recovery iso for IBM PowerVM LPAR #697

TobiasKarnat opened this issue Nov 13, 2015 · 13 comments

Comments

@TobiasKarnat
Copy link

Environment: LPAR on IBM Power7 with PowerVM
OS: SUSE Linux Enterprise Server 11 SP3
Rear 1.17.2

local.conf

BACKUP=NETFS
BACKUP_URL=iso://backup
OUTPUT_URL=null
ISO_DIR=/mnt/TSM/rear
ISO_MAX_SIZE=4500
BACKUP_PROG_EXCLUDE=( '/install/*' '/tmp/*' '/dev/shm/*' $VAR_DIR/output/\* )
AUTOEXCLUDE_MULTIPATH=n
AUTOEXCLUDE_AUTOFS=y
AUTOEXCLUDE_PATH=( /media /tsm1 )
BOOT_OVER_SAN=y
TMPDIR="/mnt/TSM/rear"
export TMPDIR

'rear -v mkbackup' runs successfully and creates the bootable iso and the backup.tar.gz file.

But the backup.tar.gz file is not included in the final iso image.
I had to modify the following script to include it, but haven't tried a restore yet.

diff -urN a/usr/share/rear/output/ISO/Linux-ppc64/80_create_isofs.sh b/usr/share/rear/output/ISO/Linux-ppc64/80_create_isofs.sh
--- a/usr/share/rear/output/ISO/Linux-ppc64/80_create_isofs.sh   2015-11-13 16:28:29.000000000 +0100
+++ b/usr/share/rear/output/ISO/Linux-ppc64/80_create_isofs.sh   2015-11-13 17:38:20.000000000 +0100
@@ -26,9 +26,9 @@
cp -pL $v $KERNEL_FILE $TMP_DIR/kernel >&2

if [[ "$SUSE_STYLE" ]]; then
-  ISO_FILES=( ${ISO_FILES[@]} $TMP_DIR/kernel initrd.cgz yaboot)
+  ISO_FILES=( ${ISO_FILES[@]} $TMP_DIR/kernel initrd.cgz yaboot $TMP_DIR/isofs)
else
-  ISO_FILES=( ${ISO_FILES[@]} $TMP_DIR/kernel initrd.cgz)
+  ISO_FILES=( ${ISO_FILES[@]} $TMP_DIR/kernel initrd.cgz $TMP_DIR/isofs)
fi
Log "Starting '$ISO_MKISOFS_BIN'"
LogPrint "Making ISO image"
@TobiasKarnat
Copy link
Author

The 81_prepare_multiple_iso.sh script is missing for Linux-ppc64 so ISO_MAX_SIZE should not be used?

@gdha gdha self-assigned this Nov 17, 2015
@gdha
Copy link
Member

gdha commented Nov 17, 2015

@TobiasKarnat If you add $TMP_DIR/isofs to the array ISO_FILES then you will always add the backups to the ISO image even when you do not want to do this. Please have a look at the Linux-i386 sub-directory. You have to do similar steps (except for the efi stuff).

@gdha
Copy link
Member

gdha commented Dec 10, 2015

@TobiasKarnat Is your question answered? Do you still need further assistance?

@TobiasKarnat
Copy link
Author

Sorry about the late response. We do actually always want to add the backup to the ISO image.
As the system is now productive, I only have limited access and can not test any more.

I opened this issue to inform the developer that there is a bug and for others which might need the same workaround.

Thank you.

@gdha gdha added the needs sponsorship This issue will not get solved on a voluntary base by ReaR upstream. label Dec 12, 2015
@gdha
Copy link
Member

gdha commented Dec 12, 2015

I don't see it as a bug, it is a missing feature nobody added (yet). You could add it yourself like I explained before, or sponsor the code (BACKUP_URL=iso://backup) to include the backup into the ISO image for the PPC track. However, if you are happy with your hack then that is fine for me, but we will not add it to rear master branch as the code as it is now is doing exactly what it is written for (write an ISO rescue image without including the backup).

@gozora
Copy link
Member

gozora commented Dec 12, 2015

Some time ago, I was thinking of kind of "feature" for ebiso, that would just take finished tar archive and simply add it to bootable iso. But after a while I put it "on hold" as it didn't look to have much of a value for me...
Do you guys think such a feature can be useful in the future?

@gdha
Copy link
Member

gdha commented Feb 5, 2016

Re-open this issue when we found a sponsor to implement this missing feature

@gdha gdha closed this as completed Feb 5, 2016
@gdha
Copy link
Member

gdha commented Apr 21, 2017

@schabrolles Quick question: are you dealing with this item in your tests as well?

@schabrolles
Copy link
Contributor

schabrolles commented Apr 21, 2017

@gdha No ... As you said, ISO image is just a bootable image that allow you to start a recovery, recreate the disk FS structure and start the restoration which is stored from on a separate DISK, Network Serveur (NFS/FTP/SSHFS etc..) or backup server like TSM etc ...

If this function is available for x86, I should have a look ...

@jsmeix
Copy link
Member

jsmeix commented Jun 9, 2017

@gdha regarding your above
#697 (comment)

If you add $TMP_DIR/isofs to the array ISO_FILES
then you will always add the backups to the ISO image
even when you do not want to do this.

I think only with things like BACKUP_URL=iso://backup
the backup becomes stored in $TMP_DIR/isofs/backup
and as far as I see in
output/ISO/Linux-i386/820_create_iso_image.sh
the whole $TMP_DIR/isofs content gets included in the ISO
so that I think it is the right solution to always have
whole $TMP_DIR/isofs content in the ISO, cf.
#1375 (comment)

But I could be wrong - this is only how the code looks to me
on first glance.

@schabrolles
Copy link
Contributor

@jsmeix
It is a bit more complicated as everything seems to be based on isolinux (from syslinux package) which only exists on x86 arch.

I made a simple "prototype" which seems to work.
I add $TMP_DIR/isofs in the ISO_FILES var (only when $TMP_DIR/isofs exists)? But there will be a problem for Large image (splitting iso in multiple files).

@jsmeix
Copy link
Member

jsmeix commented Jun 19, 2017

@schabrolles
I think it is sufficient to only document it when it does not work
with huge ISOs that would need to be splitted into multiple files.

Reason:

ReaR's internal backup methods are not meant
as professional backup solutions and in general
ReaR is neither meant as a backup solution
nor as a backup management tool,
cf. "Relax-and-Recover versus backup and restore" at
https://en.opensuse.org/SDB:Disaster_Recovery

Accordingly there are some limitations what
ReaR's internal backup methods can do.

ReaR is meant to recover the basic (operating) system
(but not to backup/restore tons of user and application data)
and for that purpose the backup of only the files
of the basic system should be only some GiB
that usually can be stored within a single ISO file.
If not, the user must use a professional backup solution.

jsmeix added a commit that referenced this issue Jun 20, 2017
Enhanced and cleaned up making ISO on POWER (ppc64/ppc64le).
Now the backup can be stored in the ISO (via BACKUP_URL=iso...)
and even multiple ISOs work on POWER now,
see #697
and #1383
@jsmeix jsmeix added fixed / solved / done and removed needs sponsorship This issue will not get solved on a voluntary base by ReaR upstream. labels Jun 20, 2017
@jsmeix jsmeix added this to the ReaR v2.2 milestone Jun 20, 2017
@jsmeix
Copy link
Member

jsmeix commented Jun 20, 2017

With #1383 merged
this issuse should be fixed.

@schabrolles
as always many thanks for all your various contributions
and testing that improve ReaR in particular on POWER!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

5 participants