한 번의 설치에서 dnf
커널이 성공적으로 업그레이드되었습니다. 최신 시스템(오늘 설치 및 업그레이드됨)에서는 실패합니다. 왜 그런지 모르겠어……
전체 실행은 다음과 같습니다.
; sudo dnf upgrade -y
Last metadata expiration check: 5:42:13 ago on Wed 06 Mar 2019 10:56:30 GMT.
Dependencies resolved.
Problem 1: cannot install both kernel-3.10.0-957.5.1.el7.x86_64 and kernel-3.10.0-957.5.1.el7.x86_64
- cannot install the best update candidate for package kernel-3.10.0-957.5.1.el7.x86_64
- cannot install the best update candidate for package kernel-3.10.0-957.el7.x86_64
Problem 2: cannot install both kernel-devel-3.10.0-957.5.1.el7.x86_64 and kernel-devel-3.10.0-957.5.1.el7.x86_64
- cannot install the best update candidate for package kernel-devel-3.10.0-957.5.1.el7.x86_64
- cannot install the best update candidate for package kernel-devel-3.10.0-957.el7.x86_64
================================================================================
Package Arch Version Repository Size
================================================================================
Reinstalling:
kernel x86_64 3.10.0-957.5.1.el7 updates 48 M
kernel-devel x86_64 3.10.0-957.5.1.el7 updates 17 M
replacing kernel-devel.x86_64 3.10.0-957.5.1.el7
Transaction Summary
================================================================================
Total size: 65 M
Downloading Packages:
[SKIPPED] kernel-3.10.0-957.5.1.el7.x86_64.rpm: Already downloaded
[SKIPPED] kernel-devel-3.10.0-957.5.1.el7.x86_64.rpm: Already downloaded
Running transaction check
Transaction check succeeded.
Running transaction test
Transaction test succeeded.
Running transaction
Preparing : 1/1
Reinstalling : kernel-devel-3.10.0-957.5.1.el7.x86_64 1/4
Running scriptlet: kernel-devel-3.10.0-957.5.1.el7.x86_64 1/4
Reinstalling : kernel-3.10.0-957.5.1.el7.x86_64 2/4
Running scriptlet: kernel-3.10.0-957.5.1.el7.x86_64 2/4
Obsoleting : kernel-devel-3.10.0-957.5.1.el7.x86_64 3/4
Running scriptlet: kernel-3.10.0-957.5.1.el7.x86_64 4/4
Cleanup : kernel-3.10.0-957.5.1.el7.x86_64 4/4
Running scriptlet: kernel-3.10.0-957.5.1.el7.x86_64 4/4
Verifying : kernel-3.10.0-957.5.1.el7.x86_64 1/5
Verifying : kernel-3.10.0-957.5.1.el7.x86_64 2/5
Verifying : kernel-devel-3.10.0-957.5.1.el7.x86_64 3/5
Verifying : kernel-devel-3.10.0-957.el7.x86_64 4/5
Verifying : kernel-devel-3.10.0-957.5.1.el7.x86_64 5/5
The downloaded packages were saved in cache until the next successful transaction.
You can remove cached packages by executing 'dnf clean packages'.
Traceback (most recent call last):
File "/bin/dnf", line 58, in <module>
main.user_main(sys.argv[1:], exit_code=True)
File "/usr/lib/python2.7/site-packages/dnf/cli/main.py", line 179, in user_main
errcode = main(args)
File "/usr/lib/python2.7/site-packages/dnf/cli/main.py", line 64, in main
return _main(base, args, cli_class, option_parser_class)
File "/usr/lib/python2.7/site-packages/dnf/cli/main.py", line 99, in _main
return cli_run(cli, base)
File "/usr/lib/python2.7/site-packages/dnf/cli/main.py", line 123, in cli_run
ret = resolving(cli, base)
File "/usr/lib/python2.7/site-packages/dnf/cli/main.py", line 154, in resolving
base.do_transaction(display=displays)
File "/usr/lib/python2.7/site-packages/dnf/cli/cli.py", line 240, in do_transaction
tid = super(BaseCli, self).do_transaction(display)
File "/usr/lib/python2.7/site-packages/dnf/base.py", line 872, in do_transaction
tid = self._run_transaction(cb=cb)
File "/usr/lib/python2.7/site-packages/dnf/base.py", line 1021, in _run_transaction
self._verify_transaction(cb.verify_tsi_package)
File "/usr/lib/python2.7/site-packages/dnf/base.py", line 1059, in _verify_transaction
self.history.end(rpmdbv, 0)
File "/usr/lib/python2.7/site-packages/dnf/db/history.py", line 504, in end
bool(return_code)
File "/usr/lib64/python2.7/site-packages/libdnf/transaction.py", line 758, in endTransaction
return _transaction.Swdb_endTransaction(self, dtEnd, rpmdbVersionEnd, state)
RuntimeError: TransactionItem state is not set: kernel-devel-3.10.0-957.el7.x86_64
댓글 작성자의 요청에 따라:
; dnf repolist
Extra Packages for Enterprise Linux 7 - x86_64 3.6 MB/s | 16 MB 00:04
CentOS-7 - Base 5.6 MB/s | 10 MB 00:01
CentOS-7 - Updates 4.1 MB/s | 5.2 MB 00:01
IUS Community Packages for Enterprise Linux 7 - 3.9 MB/s | 941 kB 00:00
slack 29 kB/s | 33 kB 00:01
CentOS-7 - Extras 1.2 MB/s | 339 kB 00:00
repo id repo name status
base CentOS-7 - Base 10,019
*epel Extra Packages for Enterprise Linux 7 - x86_64 13,008
extras CentOS-7 - Extras 382
ius IUS Community Packages for Enterprise Linux 7 - x86_64 570
slack slack 47
updates CentOS-7 - Updates 1,457
그리고
; dnf repolist -v | grep "^Repo-filename" | awk '{print $2}' | sort ; ls /etc/yum.repos.d
/etc/yum.repos.d/CentOS-Base.repo
/etc/yum.repos.d/CentOS-Base.repo
/etc/yum.repos.d/CentOS-Base.repo
/etc/yum.repos.d/epel.repo
/etc/yum.repos.d/ius.repo
/etc/yum.repos.d/slack.repo
total 60K
4.0K CentOS-Base.repo 8.0K CentOS-Vault.repo 4.0K ius-archive.repo
4.0K CentOS-CR.repo 4.0K CentOS-fasttrack.repo 4.0K ius-dev.repo
4.0K CentOS-Debuginfo.repo 4.0K epel.repo 4.0K ius-testing.repo
4.0K CentOS-Media.repo 4.0K epel-testing.repo 4.0K slack.repo
4.0K CentOS-Sources.repo 4.0K ius.repo
답변1
Sardathrion과 제가 아는 한, 우리는 각 EL7 배포판의 현재 출시된 버전에서 dnf 손상을 집단적으로 경험하고 있습니다. Sardathrion은 Python 역추적을 얻고 나도 하나 얻습니다 basic_string::_S_construct null not valid, ignoring this repo
(dnf 코드에 넣을 수 없음). 두 경우 모두 dnf가 cannot install both <kernel> and <same-kernel>
메시지와 혼동하여 예상치 못한 일을 하는 것을 볼 수 있습니다.
제 경우에는 dnf를 다운그레이드했더니 증상이 사라졌습니다.
dnf downgrade --allowerasing dnf
이렇게 하면 Scientific Linux 7.6의 dnf가 4.0.9에서 2.7.5로 줄어듭니다. CentOS 저장소에 동일한 SRPM이 있는데, 이는 CentOS 사용자가 동일한 작업을 수행할 수 있어야 함을 의미합니다.
dnf 4.1.0이 출시된 Fedora 29에서는 그러한 문제를 관찰하지 못했기 때문에 첫 번째 후속 조치는 libdnf 관리자에게 ping을 보내기 전에 배포 관리자에게 문의하는 것입니다.
편집하다:TUV는 오래된 커널을 다시 설치하기 위한 dnf 제안과 관련된 문제를 알고 있습니다.. 비활성화된 저장소 문제는 해결되지 않았 sl
으며 Sardathrion의 큰 역추적도 해결되었는지 모르겠습니다.