Opened 6 years ago

Closed 4 years ago

#836 closed defect (fixed)

grub2 not restored correctly on RHEL 7.3 and upper

Reported by: Bruno Cornec Owned by: Bruno Cornec
Priority: high Milestone: 3.3.0
Component: mondo Version: 3.2.2
Severity: blocker Keywords:
Cc:

Description

When restoring on RHEL 7.3+, at reboot of the VM used to test, grub doesn't find it's boot partition, and thus doesn't boot the restored system.

Change History (11)

comment:1 by Bruno Cornec, 6 years ago

This is similar to a RedHat bug https://bugzilla.redhat.com/show_bug.cgi?id=1399487 and was fixed on ReaR.

Seems that since the CRC feature was activated by default, the only way to recreate the XFS FS is to use the mkfs.xfs command with -m option for UUID, and not use xfs_admin afterwards.

comment:2 by Bruno Cornec, 6 years ago

Summary: grub2 not restoreed correctly on RHEL 7.3 and uppergrub2 not restored correctly on RHEL 7.3 and upper

comment:3 by Bruno Cornec, 6 years ago

Status: newassigned

comment:4 by Bruno Cornec, 6 years ago

Of course, we can not use mkfs.xfs in mr-label-partitions-as-necessary, as this is too late (FS already restored, and we don't want to purge them). Was my first stupid try :-(

Now looking at https://access.redhat.com/solutions/2892771 as it seems there is finally a way afterwards (which is better for us in that script).

If we can't do that we'll have to change format_device in mondoprep.c which is a whole different story :-(

comment:5 by Bruno Cornec, 6 years ago

The reason of the move, and some consequences are described here: https://bugzilla.redhat.com/show_bug.cgi?id=1309498

Seems also that the xfs_db command in RHEL 7.3 doesn't provide the crc command :-( That doesn't help !

comment:6 by Bruno Cornec, 6 years ago

the crc commands has appeared during the 4.8.0 dev of xfsprogs. RHEL 7.3 provides only 4.5.0 and no crc command for sure. Will have to check whether it was backported or added into RHEL 7.4

comment:7 by Bruno Cornec, 6 years ago

On RHEL 7.4 the crc command doesn't exist either :-(

So the easiest workaround for now would be to create the FS without crc enable to check that at least it can be used, and once the commands are available, the user may re-activate crc.

So other possibility would be to use the right command at FS creation time, but that means a complete rewrite of that part of mondorestore, which is not possible at the moment.

comment:8 by Bruno Cornec, 6 years ago

Changing mondo-prep.c to call mkfs.xfs with -m crc=0 seems to workaround the issue. If that doesn't work the tool call std mkfs.xfs afterwards for backward compatibility.

Would be great that people could change afterwards crc to put it back, but that's not available now.

comment:9 by Bruno Cornec, 6 years ago

rev [3701] provides the workaround.

comment:10 by Bruno Cornec, 6 years ago

So that will be the solution for the 3.3 branch. A backport will be required for 3.2.2, if people want to stay with that version.

Version 0, edited 6 years ago by Bruno Cornec (next)

comment:11 by Bruno Cornec, 4 years ago

Resolution: fixed
Status: assignedclosed

My latests tests seem to imply this is now fixed

Note: See TracTickets for help on using tickets.