使用 Landscape 管理 Ubuntu 桌面的任何人

使用 Landscape 管理 Ubuntu 桌面的任何人

几年来,我一直在尝试使用 Landscape 来管理 Ubuntu 桌面。问题接踵而至。最新的问题是 Landscape 留下了对其自身的源列表引用。

示例输出。

cat /var/log/aaIT/aait-geue-cleanup_vpn/aait-geue-cleanup_vpn_200910105536.log 
INFO: Logging started for aait-geue-cleanup_vpn at 200910105536
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
INFO: Can dpkg run?
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
INFO: Initiating aait-geue-cleanup_vpn Routine
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++

WARNING: apt does not have a stable CLI interface. Use with caution in scripts.

aait-geue-cert-renew/unknown,now 2019.07.16 all [installed,automatic]

WARNING: apt does not have a stable CLI interface. Use with caution in scripts.

Reading package lists...
Building dependency tree...
Reading state information...
You might want to run 'apt --fix-broken install' to correct these.
The following packages have unmet dependencies:
 landscape-profile-standalone-certificate-renewal-process-20190716 : Depends: aait-geue-cert-renew (= 2019.07.16) but it is not going to be installed
 landscape-profile-standalone-aait-geue-employee-vpn-20200325 : Depends: aait-geue-employee-vpn (= 2020.03.25) but it is not going to be installed
E: Unmet dependencies. Try 'apt --fix-broken install' with no packages (or specify a solution).

WARNING: apt does not have a stable CLI interface. Use with caution in scripts.


WARNING: apt does not have a stable CLI interface. Use with caution in scripts.

landscape-profile-standalone-aait-geue-employee-vpn-20200325/now 1 all [installed,local]

WARNING: apt does not have a stable CLI interface. Use with caution in scripts.

Reading package lists...
Building dependency tree...
Reading state information...
The following packages were automatically installed and are no longer required:
  libdumbnet1 linux-headers-4.15.0-29 linux-headers-4.15.0-29-generic
  linux-image-4.15.0-29-generic linux-modules-4.15.0-29-generic
  linux-modules-extra-4.15.0-29-generic x11proto-dri2-dev x11proto-gl-dev
Use 'sudo apt autoremove' to remove them.
The following NEW packages will be installed:
  aait-geue-employee-vpn
0 upgraded, 1 newly installed, 0 to remove and 0 not upgraded.
1 not fully installed or removed.
Need to get 0 B/22.2 MB of archives.
After this operation, 0 B of additional disk space will be used.
(Reading database ... 194297 files and directories currently installed.)
Preparing to unpack .../aait-geue-employee-vpn_2020.03.25_all.deb ...
+ '[' '!' -f /var/log/aaIT/build/build3.log ']'
++ dmidecode -s system-manufacturer
+ virtual='Dell Inc.'
+ [[ Dell Inc. == \V\M\w\a\r\e\,\ \I\n\c\. ]]
+ SCRIPT_NAME=preinst
+ UPDATE_PACKAGE_NAME=aait-geue-employee-vpn-pre
+ BASE_INSTALL_DIR=/.deploy
+ UPDATE_HOME=/.deploy/auto_update/aait-geue-employee-vpn-pre
+ UPDATE_LOG_DIR=/var/log/aaIT/aait-geue-employee-vpn-pre
+ UPDATE_PACKAGE_STATUS=/var/log/aaIT/aait-geue-employee-vpn-pre/aait-geue-employee-vpn-pre.status
++ /bin/date +%y%m%d%H%M%S
+ UPDATE_ME_TIMESTAMP=200910105540
++ grep VERSION_ID /etc/os-release
++ awk -F '"' '{print $2}'
+ OS_RELEASE=18.04
++ mktemp -t tmp.XXXXXXXXXX
+ SCRATCH=/tmp/tmp.byjAAYTknb
+ start_log
+ echo ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
+ echo 'INFO: Initiating aait-geue-employee-vpn-pre Package Install Routine'
INFO: Initiating aait-geue-employee-vpn-pre Package Install Routine
+ echo ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
+ '[' '!' -d /var/log/aaIT/aait-geue-employee-vpn-pre ']'
+ chmod -R 755 /var/log/aaIT/aait-geue-employee-vpn-pre
+ UPDATE_LOG_FILE=/var/log/aaIT/aait-geue-employee-vpn-pre/aait-geue-employee-vpn-pre_200910105540.log
+ export UPDATE_LOG_FILE
+ exec
+ exec
++ tee -a /var/log/aaIT/aait-geue-employee-vpn-pre/aait-geue-employee-vpn-pre_200910105540.log
++ tee -a /var/log/aaIT/aait-geue-employee-vpn-pre/aait-geue-employee-vpn-pre_200910105540.log
INFO: Logging started for aait-geue-employee-vpn-pre at 200910105540
+ echo 'INFO: Logging started for aait-geue-employee-vpn-pre at 200910105540'
+ sleep 1
+ chmod 755 /var/log/aaIT/aait-geue-employee-vpn-pre/aait-geue-employee-vpn-pre_200910105540.log
+ execute_updates
+ echo 'Removing old packages'
+ rm -f /opt/cisco/anyconnect/profile/raeEmployee.xml
Removing old packages
+ rm -f /opt/cisco/anyconnect/profile/raePartner.xml
+ rm -f /etc/cron.hourly/vpn-cert-enroll
Unpacking aait-geue-employee-vpn (2020.03.25) ...
dpkg: error processing archive /var/cache/apt/archives/aait-geue-employee-vpn_2020.03.25_all.deb (--unpack):
 trying to overwrite '/usr/local/bin/ssl-cert-check.bash', which is also in package aait-geue-cert-renew 2019.07.16
Errors were encountered while processing:
 /var/cache/apt/archives/aait-geue-employee-vpn_2020.03.25_all.deb
E: Sub-process /usr/bin/dpkg returned an error code (1)
root@USFRYLNCNDJMK2G:/home/user# 

有人遇到过这个问题吗?你是如何解决的?

答案1

正如评论中提到的,该软件包已损坏。更具体地说,软件包aait-geue-employee-vpn或软件包aait-geue-cert-renew已损坏。原因是两个软件包都试图修改同一个文件,这是 apt 所不允许的(否则,您可能会根据安装顺序获得不同的结果)。

作为用户,您可以执行以下操作:

  1. 向软件包维护者报告他们制作了一个损坏的软件包以便他们重建它;或者
  2. 在安装另一个包之前删除其中一个包,这样它们就不会同时安装。

作为软件包维护者你应该做的是:

  • 如果两个包中的文件相同,则将其移动到一个aait-geue-common包中,并向Depends: aait-geue-common两个包中添加依赖于它的控制文件。
  • 如果文件相同并且您不想创建额外的包,请Depends在一个包控制文件中添加一个并从该文件包中删除。
  • 如果文件不同且应覆盖旧文件,请使用较新的软件包控制文件中Breaks Replaces的 或Conflicts来确保安装该软件包会删除另一个软件包。它还明确指出两个软件包不能同时安装。

相关内容