質問をすることでしか得られない、回答やアドバイスがある。

15分調べてもわからないことは、質問しよう!

新規登録して質問してみよう
ただいま回答率
85.31%
CentOS

CentOSは、主にRed Hat Enterprise Linux(RHEL)をベースにした、フリーのソフトウェアオペレーティングシステムです。

Q&A

解決済

1回答

837閲覧

CentOS7.9からAlmalinuxへのマイグレーション時にERRORが発生する。

Hal.

総合スコア9

CentOS

CentOSは、主にRed Hat Enterprise Linux(RHEL)をベースにした、フリーのソフトウェアオペレーティングシステムです。

0グッド

1クリップ

投稿2024/08/19 08:08

実現したいこと

CentOS7.9からAlmalinuxへのマイグレーションを行いたいと思っております。

発生している問題・分からないこと

CentOS7.9からAlmalinuxへのマイグレーションを行う為に・・・

https://cloud5.jp/centos-to-almalinux/
https://cartrip.blog/dp/oschange/
https://www.cybertrust.co.jp/blog/linux-learning/centos7-migration-with-elevate.html
https://tech.012grp.co.jp/entry/centos7-migration

・・・などを参照して

#leapp preupgrade

までは進んだのですが、ここで次のようなERRORが発生しました。

エラーメッセージ

error

1コンソール出力されたメッセージは下記です。 2----- 3============================================================ 4 REPORT OVERVIEW 5============================================================ 6 7Reports summary: 8 Errors: 1 9 Inhibitors: 0 10 HIGH severity reports: 0 11 MEDIUM severity reports: 0 12 LOW severity reports: 0 13 INFO severity reports: 0 14 15Before continuing consult the full report: 16 A report has been generated at /var/log/leapp/leapp-report.json 17 A report has been generated at /var/log/leapp/leapp-report.txt 18 19============================================================ 20 END OF REPORT OVERVIEW 21============================================================ 22 23Answerfile has been generated at /var/log/leapp/answerfile 24----- 25 26/var/log/leapp/leapp-report.txt 27の内容は下記です 28----- 29Risk Factor: high (error) 30Title: Actor vsftpd_config_read unexpectedly terminated with exit code: 1 31Summary: Traceback (most recent call last): 32 File "/usr/lib/python2.7/site-packages/leapp/repository/actor_definition.py", line 74, in _do_run 33 actor_instance.run(*args, **kwargs) 34 File "/usr/lib/python2.7/site-packages/leapp/actors/__init__.py", line 289, in run 35 self.process(*args) 36 File "/usr/share/leapp-repository/repositories/system_upgrade/el7toel8/actors/vsftpdconfigread/actor.py", line 20, in process 37 self.produce(vsftpdconfigread.get_vsftpd_facts()) 38 File "/usr/share/leapp-repository/repositories/system_upgrade/el7toel8/actors/vsftpdconfigread/libraries/vsftpdconfigread.py", line 41, in get_vsftpd_facts 39 config_hash = utils.get_default_config_hash(read_func=read_func) 40 File "/usr/share/leapp-repository/repositories/system_upgrade/el7toel8/libraries/vsftpdutils.py", line 49, in get_default_config_hash 41 content = content.encode(encoding='utf-8') 42UnicodeDecodeError: 'ascii' codec can't decode byte 0xe3 in position 3736: ordinal not in range(128) 43 44Key: c013908d65b553be09c486e7f6ddd543b738f4a4 45---------------------------------------- 46----- 47 48 49/var/log/leapp/leapp-report.json 50の内容は下記です 51----- 52{ 53 "leapp_run_id": "b6043ea9-6ef4-45b4-9989-3872fd916be6", 54 "entries": [ 55 { 56 "title": "Actor vsftpd_config_read unexpectedly terminated with exit code: 1", 57 "timeStamp": "2024-08-19T07:55:28.958710Z", 58 "hostname": "feelkind.com", 59 "actor": "vsftpd_config_read", 60 "summary": "Traceback (most recent call last):\n File \"/usr/lib/python2.7/site-packages/leapp/repository/actor_definition.py\", line 74, in _do_run\n actor_instance.run(*args, **kwargs)\n File \"/usr/lib/python2.7/site-packages/leapp/actors/__init__.py\", line 289, in run\n self.process(*args)\n File \"/usr/share/leapp-repository/repositories/system_upgrade/el7toel8/actors/vsftpdconfigread/actor.py\", line 20, in process\n self.produce(vsftpdconfigread.get_vsftpd_facts())\n File \"/usr/share/leapp-repository/repositories/system_upgrade/el7toel8/actors/vsftpdconfigread/libraries/vsftpdconfigread.py\", line 41, in get_vsftpd_facts\n config_hash = utils.get_default_config_hash(read_func=read_func)\n File \"/usr/share/leapp-repository/repositories/system_upgrade/el7toel8/libraries/vsftpdutils.py\", line 49, in get_default_config_hash\n content = content.encode(encoding='utf-8')\nUnicodeDecodeError: 'ascii' codec can't decode byte 0xe3 in position 3736: ordinal not in range(128)\n", 61 "audience": "sysadmin", 62 "flags": [], 63 "key": "c013908d65b553be09c486e7f6ddd543b738f4a4", 64 "id": "d729e5da2e12764fc3855c632c25a62823191a714dba9f6fd09cb1f89bd71152", 65 "tags": [], 66 "severity": "high" 67 } 68 ] 69} 70----- 71

該当のソースコード

特になし

試したこと・調べたこと

  • teratailやGoogle等で検索した
  • ソースコードを自分なりに変更した
  • 知人に聞いた
  • その他
上記の詳細・結果

自分は英語が不得意な事もありエラーメッセージの内容で検索したりしても解決策と思われるページやサイトにたどり着けませんでした。

このエラーを解消するための手法をご教示戴きたくお願い致します。

補足

特になし

気になる質問をクリップする

クリップした質問は、後からいつでもMYページで確認できます。

またクリップした質問に回答があった際、通知やメールを受け取ることができます。

バッドをするには、ログインかつ

こちらの条件を満たす必要があります。

guest

回答1

0

ベストアンサー

Title: Actor vsftpd_config_read
UnicodeDecodeError: 'ascii' codec can't decode byte 0xe3 in position 3736: ordinal not in range(128)

エラーの内容を見ると、vsftpdのコンフィグファイルにasciiでない文字、たぶん日本語、が含まれているのが原因っぽいですね。
vsftpdのコンフィグ(たぶん /etc/vfstpd.conf)を修正してみてはいかがでしょうか。

投稿2024/08/19 08:32

TakaiY

総合スコア14261

バッドをするには、ログインかつ

こちらの条件を満たす必要があります。

Hal.

2024/08/19 12:27

/etc/vsftpd/vsftpd.conf の中に含まれている日本語コメントを全て削除して #leapp preupgrade を実行したところ、コンソールメッセージが下記のように変わりました。 Errors:は0になりましたが、 Inhibitors:が3に増えました。 ----- ============================================================ REPORT OVERVIEW ============================================================ Upgrade has been inhibited due to the following problems: 1. Multiple devel kernels installed 2. Upgrade requires links in root directory to be relative 3. Missing required answers in the answer file HIGH and MEDIUM severity reports: 1. BIND configuration issues found 2. Difference in Python versions and support in RHEL 8 3. GRUB2 core will be automatically updated during the upgrade 4. Packages not signed by Red Hat found on the system 5. Leapp detected loaded kernel drivers which are no longer maintained in RHEL 8. 6. spamc no longer allows specifying the TLS version and no longer supports SSLv3 7. spamd no longer allows specifying the TLS version and no longer supports SSLv3 8. The type of the spamassassin systemd service has changed Reports summary: Errors: 0 Inhibitors: 3 HIGH severity reports: 5 MEDIUM severity reports: 3 LOW severity reports: 7 INFO severity reports: 2 Before continuing consult the full report: A report has been generated at /var/log/leapp/leapp-report.json A report has been generated at /var/log/leapp/leapp-report.txt ============================================================ END OF REPORT OVERVIEW ============================================================ Answerfile has been generated at /var/log/leapp/answerfile ----- そして、/var/log/leapp/leapp-report.txt に沢山のRisk Factor: high (inhibitor)が出力されています。 Remediation: [command]の行を実行していけば良いのでしょうか? /var/log/leapp/leapp-report.txtの内容が下記です。 ----- Risk Factor: high (inhibitor) Title: Multiple devel kernels installed Summary: DNF cannot produce a valid upgrade transaction when multiple kernel-devel packages are installed. Remediation: [hint] Remove all but one kernel-devel packages before running Leapp again. [command] yum -y remove kernel-devel-3.10.0-1160.119.1.el7 kernel-devel-3.10.0-1160.105.1.el7 kernel-devel-3.10.0-1160.118.1.el7 kernel-devel-3.10.0-1160.108.1.el7 Key: 8ceea81afbbb1a329b7d82ca7212b21509e5b256 ---------------------------------------- Risk Factor: high (inhibitor) Title: Upgrade requires links in root directory to be relative Summary: After rebooting, parts of the upgrade process can fail if symbolic links in / point to absolute paths. Please change these links to relative ones. Remediation: [command] sh -c ln -snf var/lib/snapd/snap /snap Key: 3d895ad37ceaf4157864d439edb6bd75562061fa ---------------------------------------- Risk Factor: high (inhibitor) Title: Missing required answers in the answer file Summary: One or more sections in answerfile are missing user choices: remove_pam_pkcs11_module_check.confirm For more information consult https://red.ht/leapp-dialogs. Remediation: [hint] Please register user choices with leapp answer cli command or by manually editing the answerfile. [command] leapp answer --section remove_pam_pkcs11_module_check.confirm=True Key: d35f6c6b1b1fa6924ef442e3670d90fa92f0d54b ---------------------------------------- Risk Factor: high Title: BIND configuration issues found Summary: Default value of listen-on-v6 have changed, but it is not present in configuration. named service will now listen on INET6 sockets also. Key: 45608d77dbf0f5b3c0903831a3130c641eb60889 ---------------------------------------- Risk Factor: high Title: Difference in Python versions and support in RHEL 8 Summary: In RHEL 8, there is no 'python' command. Python 3 (backward incompatible) is the primary Python version and Python 2 is available with limited support and limited set of packages. If you no longer require Python 2 packages following the upgrade, please remove them. Read more here: https://red.ht/rhel-8-python Remediation: [hint] Please run "alternatives --set python /usr/bin/python3" after upgrade Key: 0c98585b1d8d252eb540bf61560094f3495351f5 ---------------------------------------- Risk Factor: high Title: GRUB2 core will be automatically updated during the upgrade Summary: On legacy (BIOS) systems, GRUB2 core (located in the gap between the MBR and the first partition) cannot be updated during the rpm transaction and Leapp has to initiate the update running "grub2-install" after the transaction. No action is needed before the upgrade. After the upgrade, it is recommended to check the GRUB configuration. Key: ac7030e05d2ee248d34f08a9fa040b352bc410a3 ---------------------------------------- Risk Factor: high Title: Packages not signed by Red Hat found on the system Summary: The following packages have not been signed by Red Hat and may be removed during the upgrade process in case Red Hat-signed packages to be removed during the upgrade depend on them: - MariaDB-client - MariaDB-common - MariaDB-compat - MariaDB-server - denyhosts - elrepo-release - galera-4 - gd3php - git - git-core - git-core-doc - ius-release - kernel-ml - kernel-ml-tools - kernel-ml-tools-libs - libgsf - libmilter-client - libmilter-client-devel - libmilter-core - libmilter-core-devel - libmilter-server - libmilter-server-devel - libwebp7 - lux-release - maldetect - mod_ruid2 - oniguruma5php - perl-Git - perl-Net-DNS - perl-Net-DNS-Nameserver - perl-Net-Server - php - php-cli - php-common - php-devel - php-fedora-autoloader - php-gd - php-imap - php-json - php-mbstring - php-mysqlnd - php-opcache - php-pdo - php-pear - php-pecl-mcrypt - php-process - php-sodium - php-xml - rar - remi-release - rpmforge-release - socat - unrar - webmin Key: 13f0791ae5f19f50e7d0d606fb6501f91b1efb2c ---------------------------------------- Risk Factor: high Title: Leapp detected loaded kernel drivers which are no longer maintained in RHEL 8. Summary: The following RHEL 7 device drivers are no longer maintained RHEL 8: - e1000 - e1000 Key: 0ff2413fd3cb0358736bf9be597f4dbdf58f2c4d ---------------------------------------- Risk Factor: medium Title: spamc no longer allows specifying the TLS version and no longer supports SSLv3 Summary: spamc no longer allows using the "--ssl" option with an argument specifying the TLS version - the option can only be used without an argument. Also, spamc no longer supports SSLv3. Remediation: [hint] Please update your scripts and configuration, if there are any. Key: 2c9706965164a658b1f1443d5d24b1fe3e9ec4d2 ---------------------------------------- Risk Factor: medium Title: spamd no longer allows specifying the TLS version and no longer supports SSLv3 Summary: spamd no longer accepts the --ssl-version option and no longer supports SSLv3. Remediation: [hint] Please update your scripts and configuration, if there are any. Key: 174eb9ad0aed3013f829e892ee753967058f51d5 ---------------------------------------- Risk Factor: medium Title: The type of the spamassassin systemd service has changed Summary: The type of spamassassin.service has been changed from "forking" to "simple". The spamassassin sysconfig file will be updated. Key: 3ed08dd692315c1f736daf2a0f533f6ebca70cc4 ---------------------------------------- Risk Factor: low Title: Some enabled RPM repositories are unknown to Leapp Summary: The following repositories with Red Hat-signed packages are unknown to Leapp: - elevate - centos-sclo-rh And the following packages installed from those repositories may not be upgraded: - python27-python-babel - leapp-upgrade-el7toel8-deps - leapp-data-almalinux - python27-python-sphinx - python27-python-tools - leapp-upgrade-el7toel8 - python27-python-virtualenv - python27-python-werkzeug - python27-python-markupsafe - python27-runtime - python2-leapp - python27-python-devel - python27-python-sqlalchemy - python27 - python27-python-pygments - python27-python-pip - python27-python-jinja2 - python27-python-docutils - python27-tkinter - python27-python-simplejson - leapp - python27-python-nose - python27-python-libs - leapp-deps - python27-python-wheel - python27-python - python27-python-setuptools Remediation: [hint] You can file a request to add this repository to the scope of in-place upgrades by filing a support ticket Key: 8e89e20c645cea600b240156071d81c64daab7ad ---------------------------------------- Risk Factor: low Title: Grep has incompatible changes in the next major version Summary: If a file contains data improperly encoded for the current locale, and this is discovered before any of the file's contents are output, grep now treats the file as binary. The 'grep -P' no longer reports an error and exits when given invalid UTF-8 data. Instead, it considers the data to be non-matching. In locales with multibyte character encodings other than UTF-8, grep -P now reports an error and exits instead of misbehaving. When searching binary data, grep now may treat non-text bytes as line terminators. This can boost performance significantly. The 'grep -z' no longer automatically treats the byte '\200' as binary data. Context no longer excludes selected lines omitted because of -m. For example, 'grep "^" -m1 -A1' now outputs the first two input lines, not just the first line. Remediation: [hint] Please update your scripts to be compatible with the changes. Key: 94665a499e2eeee35eca3e7093a7abe183384b16 ---------------------------------------- Risk Factor: low Title: sa-update no longer supports SHA1 validation Summary: sa-update no longer supports SHA1 validation of filtering rules, SHA256/SHA512 validation is done instead. This may affect you if you are using an alternative update channel (sa-update used with option --channel or --channelfile), or if you install filtering rule updates directly from files (sa-update --install). Key: 5f94c35aab24e5ce2033c8bec5b83902caedecc3 ---------------------------------------- Risk Factor: low Title: Dosfstools incompatible -----
TakaiY

2024/08/19 12:58

> Inhibitors:が3に増えました。 解析を不能にする要因が無くなったので、ちゃんと解析できるようになったということです。 > Remediation: [command]の行を実行していけば良いのでしょうか? そのとおりやればいいものも、他の対応が必要なものもあるでしょう。 それは指摘されている内容を吟味して検討すべき内容です。その通りにすると最悪必要な機能が失なわれてしまうかもしれません。
Hal.

2024/08/25 07:24

/var/log/leapp/leapp-report.txtのRisk Factor: high (inhibitor)のうち、 Risk Factor: high (inhibitor) Title: Multiple devel kernels installed Risk Factor: high (inhibitor) Title: Missing required answers in the answer file の2つは[command] で表示されている内容を実行すると修正された模様なのですが、 Risk Factor: high (inhibitor) Title: Upgrade requires links in root directory to be relative の修正がトラブっています。 具体的には・・・ ---------------------------------------- Risk Factor: high (inhibitor) Title: Upgrade requires links in root directory to be relative Summary: After rebooting, parts of the upgrade process can fail if symbolic links in / point to absolute paths. Please change these links to relative ones. Remediation: [command] sh -c ln -snf var/lib/snapd/snap /snap Key: 3d895ad37ceaf4157864d439edb6bd75562061fa ---------------------------------------- ・・・のレポートにある 「sh -c ln -snf var/lib/snapd/snap /snap」 を実行するとエラーが出力されてしまいます。 ----- # sh -c ln -snf var/lib/snapd/snap /snap ln: ファイルオペランドがありません Try 'ln --help' for more information. # ----- この解決法をご教示戴きたくお願い致します。
Hal.

2024/08/30 06:28 編集

師匠にヘルプをお願いしたところ、本件は下記のコマンドで解決しました。 コメントいただきありがとうございました。 ---- cd / sudo rm /snap sudo ln -snf var/lib/snapd/snap snap ----
guest

あなたの回答

tips

太字

斜体

打ち消し線

見出し

引用テキストの挿入

コードの挿入

リンクの挿入

リストの挿入

番号リストの挿入

表の挿入

水平線の挿入

プレビュー

15分調べてもわからないことは
teratailで質問しよう!

ただいまの回答率
85.31%

質問をまとめることで
思考を整理して素早く解決

テンプレート機能で
簡単に質問をまとめる

質問する

関連した質問