fixed the error when mounting a lvm snapshot in which filesystem inconsistencies exist
when we create a lvm snapshot with mode mysql, as no sync commands will be performed, so probably the filesystem of the lvm snapshot is inconsistant. We need to use mount options ro and norecovery to omit inconsistency errors in filesystem. Change-Id: I16abcb7f3c828b454495f3dc94b904ca91943aa7 Closes-Bug:1874421
This commit is contained in:
parent
5effc13828
commit
3333855de2
|
@ -155,7 +155,7 @@ def lvm_snap(backup_opt_dict):
|
|||
filesys_type = get_vol_fs_type(backup_opt_dict.lvm_srcvol)
|
||||
mount_options = '-o {}'.format(backup_opt_dict.lvm_snapperm)
|
||||
if 'xfs' == filesys_type:
|
||||
mount_options = ' -onouuid '
|
||||
mount_options = ' -onouuid,ro,norecovery '
|
||||
# Mount the newly created snapshot to dir_mount
|
||||
abs_snap_name = '/dev/{0}/{1}'.format(
|
||||
backup_opt_dict.lvm_volgroup,
|
||||
|
|
Loading…
Reference in New Issue