Created attachment 110 [details] rdsosreport.txt Description of problem: 从centos7.7/centos7.9 升级到 Anolis8 ,lvm2-cluster-7导致升级失败 Version-Release number of selected component (if applicable): How reproducible: Steps to Reproduce: wget https://gitee.com/anolis/leapp/repository/archive/master.zip unzip master.zip cd leapp-master # 执行部署脚本安装leapp组件 sh leapp-install.sh sh leapp-repository-install.sh leapp answer --section remove_pam_pkcs11_module_check.confirm=True sed -i 's/#PermitRootLogin yes/PermitRootLogin yes/' /etc/ssh/sshd_config leapp preupgrade --no-rhsm leapp upgrade --no-rhsm #重启机器 reboot Actual results: [ 738.280367] upgrade[565]: Failed: [ 738.280602] upgrade[565]: lvm2-cluster-7:2.02.187-6.el7.x86_64 [ 738.280817] upgrade[565]: STDERR: [ 738.281142] upgrade[565]: No matches found for the following disable plugin patterns: subscription-manager [ 738.281356] upgrade[565]: Invalid configuration value: failovermethod=priority in /etc/yum.repos.d/epel.repo; Configuration: OptionBinding with id "failovermethod" does not exist [ 738.281601] upgrade[565]: Invalid configuration value: failovermethod=priority in /etc/yum.repos.d/epel.repo; Configuration: OptionBinding with id "failovermethod" does not exist [ 738.281818] upgrade[565]: Invalid configuration value: failovermethod=priority in /etc/yum.repos.d/epel.repo; Configuration: OptionBinding with id "failovermethod" does not exist [ 738.282135] upgrade[565]: Invalid configuration value: failovermethod=priority in /etc/yum.repos.d/epel-testing.repo; Configuration: OptionBinding with id "failovermethod" does not exist [ 738.282350] upgrade[565]: Invalid configuration value: failovermethod=priority in /etc/yum.repos.d/epel-testing.repo; Configuration: OptionBinding with id "failovermethod" does not exist [ 738.282587] upgrade[565]: Invalid configuration value: failovermethod=priority in /etc/yum.repos.d/epel-testing.repo; Configuration: OptionBinding with id "failovermethod" does not exist [ 738.282820] upgrade[565]: Warning: Packages marked by Leapp for install not found in repositories metadata: glassfish-fastinfoset-javadoc python3-pki 389-ds-base-legacy-tools jackson-jaxrs-providers-datatypes glassfish-jaxb-codemodel-parent xsom-javadoc stax-ex-javadoc parfait-javadoc glassfish-jaxb-external-parent parfait-examples python3-custodia jackson-module-jaxb-annotations python3-javapackages glassfish-jaxb-api-javadoc python3-kdcproxy python3-ipaserver jackson-core slf4j-ext uom-lib-javadoc slf4j-jdk14 uom-systems-javadoc si-units-javadoc glassfish-jaxb-runtime-parent jackson-databind glassfish-jaxb-parent python3-nss jackson-jaxrs-json-provider pcp-parfait-agent glassfish-jaxb-bom ldns-utils slf4j-jcl glassfish-jaxb-rngom unit-api-javadoc glassfish-jaxb-txw2 log4j-over-slf4j log4j12 glassfish-jaxb-core glassfish-jaxb-runtime jackson-jaxrs-providers slf4j-log4j12 easymock glassfish-jaxb-bom-ext jackson-annotations glassfish-jaxb-codemodel-annotation-compiler glassfish-jaxb-codemodel ivy-local jul-to-slf4j uom-se-javadoc glassfish-jaxb-txw-parent resteasy [ 738.283243] upgrade[565]: Error in PREUN scriptlet in rpm package lvm2-cluster [ 738.283455] upgrade[565]: Error: Transaction failed [ 738.310374] upgrade[565]: ============================================================ [ 738.310664] upgrade[565]: END OF ERRORS [ 738.310895] upgrade[565]: ============================================================ [ 738.311248] upgrade[565]: Debug output written to /var/log/leapp/leapp-upgrade.log [ 738.311484] upgrade[565]: ============================================================ [ 738.311688] upgrade[565]: REPORT [ 738.311907] upgrade[565]: ============================================================ [ 738.312145] upgrade[565]: A report has been generated at /var/log/leapp/leapp-report.json [ 738.312357] upgrade[565]: A report has been generated at /var/log/leapp/leapp-report.txt [ 738.312573] upgrade[565]: ============================================================ [ 738.312788] upgrade[565]: END OF REPORT [ 738.313139] upgrade[565]: ============================================================ [ 738.313460] upgrade[565]: Answerfile has been generated at /var/log/leapp/answerfile [ 738.313693] upgrade[565]: Container sysroot failed with error code 1. [ 738.313910] upgrade[565]: writing logs to disk and rebooting [ 738.314144] upgrade[565]: Spawning container sysroot on /sysroot. [ 738.314349] upgrade[565]: Press ^] three times within 1s to kill container. [ 738.314566] upgrade[565]: Container sysroot exited successfully. [ 738.314792] upgrade[565]: /bin/upgrade: line 19: /sysroot/var/tmp/system-upgrade.state: Read-only file system Starting Setup Virtual Console... [ OK ] Stopped target System Upgrade. [ OK ] Stopped target Basic System. [ OK ] Stopped target Paths. [ OK ] Stopped target Slices. [ OK ] Stopped target Sockets. [ OK ] Stopped target System Initialization. Stopping Journal Service... Stopping udev Kernel Device Manager... [ OK ] Stopped target Local Encrypted Volumes. [ OK ] Stopped Dispatch Password Requests to Console Directory Watch. [ OK ] Stopped target Swap. [ OK ] Stopped Apply Kernel Variables. [ OK ] Stopped Create Volatile Files and Directories. [ OK ] Stopped target Local File Systems. Unmounting /sysroot... [ OK ] Stopped dracut cmdline hook. Stopping iSCSI UserSpace I/O driver... [ OK ] Closed Open-iSCSI iscsid Socket. [ OK ] Stopped Journal Service. [ OK ] Stopped iSCSI UserSpace I/O driver. [ OK ] Stopped udev Kernel Device Manager. [ OK ] Started Setup Virtual Console. Starting Journal Service... [ OK ] Started Emergency Shell. [ OK ] Reached target Emergency Mode. [ OK ] Closed Open-iSCSI iscsiuio Socket. [ OK ] Started Journal Service. [ OK ] Unmounted /sysroot. [ OK ] Stopped File System Check on /dev/d…e934b-e59e-4f70-9409-3382fdbec3bc. [ OK ] Stopped target Local File Systems (Pre). Stopping Device-Mapper Multipath Device Controller... [ OK ] Stopped Create Static Device Nodes in /dev. [ OK ] Stopped Create list of required sta…vice nodes for the current kernel. [ OK ] Stopped Device-Mapper Multipath Device Controller. [ OK ] Stopped udev Wait for Complete Device Initialization. [ OK ] Stopped udev Coldplug all Devices. [ OK ] Closed udev Kernel Socket. [ OK ] Closed udev Control Socket. Generating "/run/initramfs/rdsosreport.txt" Entering emergency mode. Exit the shell to continue. Type "journalctl" to view system logs. You might want to save "/run/initramfs/rdsosreport.txt" to a USB stick or /boot after mounting them and attach it to a bug report. :/# Expected results: successful Additional info:
迁移前的安装列表给一下
Created attachment 115 [details] 7.9 x86_64 rpmlist
[ 432.777180] localhost upgrade[565]: Running scriptlet: lvm2-cluster-7:2.02.187-6.el7.x86_64 2083/4077 [ 432.777180] localhost upgrade[565]: cp: cannot stat '/etc/lvm/.lvmconf-tmp.tmp': No such file or directory [ 432.777180] localhost upgrade[565]: failed to copy new config file into place, check /etc/lvm/lvm.conf is still OK [ 432.777180] localhost upgrade[565]: error: %preun(lvm2-cluster-7:2.02.187-6.el7.x86_64) scriptlet failed, exit status 3 [ 432.777180] localhost upgrade[565]: Erasing : java-1.7.0-openjdk-1:1.7.0.261-2.6.22.2.el7_8. 2084/4077 [ 432.777180] localhost upgrade[565]: error: lvm2-cluster-7:2.02.187-6.el7.x86_64: erase failed [ 432.777180] localhost upgrade[565]: Running scriptlet: java-1.7.0-openjdk-1:1.7.0.261-2.6.22.2.el7_8. 2084/4077 从报错信息看,lvm2-cluster卸载失败。 解决方案: 1、对lvm2-cluster做个特殊处理,/etc/leapp/transaction/to_keep中添加lvm2-cluster,查看能否迁移成功 2、上述方法不生效的话,只能添加检测,在评估阶段,检测如果安装了lvm2-cluster,就给出提示,需要卸载后才能确保迁移成功。
1.尝试了,lvm2-cluster添加到,/etc/leapp/transaction/to_keep中,升级未成功。 2.尝试了,升级前,卸载了lvm2-cluster,升级成功。 另外不管是centos8 还是anolis8 的repo里,都未提供lvm2-cluster包,可能针对lvm的这个功能有所改变。
增加lvm2-cluster检测,如果已经安装则提示需要先卸载并阻止迁移