首先第一步了解系统的一些基本信息如:系统版本号(方便根据不同版本选择不同的源列表)
[root@database mysql]# cat /etc/issue
Ubuntu 14.04.3 LTS \n \l
备份原装源列表:
[root@database mysql]# cp /etc/apt/sources.list /etc/apt/sources.list.bak
[root@database mysql]# cp /etc/apt/sources.list.d/* /etc/apt/sources.list.d_bak/*
[root@database mysql]# rm -fr /etc/apt/sources.list.d/*
[root@database mysql]# vi /etc/apt/sources.list -------删除原有的源列表
添加以下的源列表之一:
官方欧洲源列表:
deb http://archive.ubuntu.com/ubuntu/ trusty main restricted universe multiverse
deb http://archive.ubuntu.com/ubuntu/ trusty-security main restricted universe multiverse
deb http://archive.ubuntu.com/ubuntu/ trusty-updates main restricted universe multiverse
deb http://archive.ubuntu.com/ubuntu/ trusty-proposed main restricted universe multiverse
deb http://archive.ubuntu.com/ubuntu/ trusty-backports main restricted universe multiverse
deb-src http://archive.ubuntu.com/ubuntu/ trusty main restricted universe multiverse
deb-src http://archive.ubuntu.com/ubuntu/ trusty-security main restricted universe multiverse
deb-src http://archive.ubuntu.com/ubuntu/ trusty-updates main restricted universe multiverse
deb-src http://archive.ubuntu.com/ubuntu/ trusty-proposed main restricted universe multiverse
deb-src http://archive.ubuntu.com/ubuntu/ trusty-backports main restricted universe multiverse
国内阿里源列表(我使用的):
deb http://mirrors.aliyun.com/ubuntu/ trusty main restricted universe multiverse
deb http://mirrors.aliyun.com/ubuntu/ trusty-security main restricted universe multiverse
deb http://mirrors.aliyun.com/ubuntu/ trusty-updates main restricted universe multiverse
deb http://mirrors.aliyun.com/ubuntu/ trusty-proposed main restricted universe multiverse
deb http://mirrors.aliyun.com/ubuntu/ trusty-backports main restricted universe multiverse
deb-src http://mirrors.aliyun.com/ubuntu/ trusty main restricted universe multiverse
deb-src http://mirrors.aliyun.com/ubuntu/ trusty-security main restricted universe multiverse
deb-src http://mirrors.aliyun.com/ubuntu/ trusty-updates main restricted universe multiverse
deb-src http://mirrors.aliyun.com/ubuntu/ trusty-proposed main restricted universe multiverse
deb-src http://mirrors.aliyun.com/ubuntu/ trusty-backports main restricted universe multiverse
网易163源列表:
deb http://mirrors.163.com/ubuntu/ trusty-security main restricted universe multiverse
deb http://mirrors.163.com/ubuntu/ trusty-updates main restricted universe multiverse
deb http://mirrors.163.com/ubuntu/ trusty-proposed main restricted universe multiverse
deb http://mirrors.163.com/ubuntu/ trusty-backports main restricted universe multiverse
deb-src http://mirrors.163.com/ubuntu/ trusty main restricted universe multiverse
deb-src http://mirrors.163.com/ubuntu/ trusty-security main restricted universe multiverse
deb-src http://mirrors.163.com/ubuntu/ trusty-updates main restricted universe multiverse
deb-src http://mirrors.163.com/ubuntu/ trusty-proposed main restricted universe multiverse
deb-src http://mirrors.163.com/ubuntu/ trusty-backports main restricted universe multiverse
[root@database mysql]# apt-get update
[11:40:00] Ign http://mirrors.aliyun.com trusty/main Translation-en_US
[11:40:00] Ign http://mirrors.aliyun.com trusty/multiverse Translation-en_US
[11:40:00] Ign http://mirrors.aliyun.com trusty/restricted Translation-en_US
[11:40:00] Ign http://mirrors.aliyun.com trusty/universe Translation-en_US
[11:40:26] Ign http://repo.mysql.com trusty/mysql-5.6 Translation-en_US
[11:40:27] Ign http://repo.mysql.com trusty/mysql-5.6 Translation-en
[11:40:28] Ign http://repo.mysql.com trusty/mysql-apt-config Translation-en_US
[11:40:28] Ign http://repo.mysql.com trusty/mysql-apt-config Translation-en
[11:40:29] Ign http://repo.mysql.com trusty/mysql-tools Translation-en_US
[11:40:29] Ign http://repo.mysql.com trusty/mysql-tools Translation-en
[11:40:31] Reading package lists... Done
[11:40:31] W: Duplicate sources.list entry http://mirrors.aliyun.com/ubuntu/ trusty/main amd64 Packages (/var/lib/apt/lists/mirrors.aliyun.com_ubuntu_dists_trusty_main_binary-amd64_Packages)
[11:40:31] W: Duplicate sources.list entry http://mirrors.aliyun.com/ubuntu/ trusty/restricted amd64 Packages (/var/lib/apt/lists/mirrors.aliyun.com_ubuntu_dists_trusty_restricted_binary-amd64_Packages)
[11:40:32] W: Duplicate sources.list entry http://mirrors.aliyun.com/ubuntu/ trusty-backports/restricted i386 Packages (/var/lib/apt/lists/mirrors.aliyun.com_ubuntu_dists_trusty-backports_restricted_binary-i386_Packages)
[11:40:32] W: Duplicate sources.list entry http://mirrors.aliyun.com/ubuntu/ trusty-backports/universe i386 Packages (/var/lib/apt/lists/mirrors.aliyun.com_ubuntu_dists_trusty-backports_universe_binary-i386_Packages)
[11:40:32] W: Duplicate sources.list entry http://mirrors.aliyun.com/ubuntu/ trusty-backports/multiverse i386 Packages (/var/lib/apt/lists/mirrors.aliyun.com_ubuntu_dists_trusty-backports_multiverse_binary-i386_Packages)
[11:40:32] W: You may want to run apt-get update to correct these problems
[root@database /etc/apt/sources.list.d]# apt-get upgrade
[11:42:46] Reading package lists... Done
[11:42:46] Building dependency tree
[11:42:46] Reading state information... Done
[11:42:46] You might want to run 'apt-get -f install' to correct these.
[11:42:46] The following packages have unmet dependencies:
[11:42:46] mysql-community-server : Depends: mysql-client (= 5.6.42-1ubuntu14.04)
[11:42:46] E: Unmet dependencies. Try using -f.
[root@database /etc/apt/sources.list.d]# ls
mysqlbak.list ubuntu.list
[root@database /etc/apt/sources.list.d]# vi mysqlbak.list
### THIS FILE IS AUTOMATICALLY CONFIGURED ###
# You may comment out entries below, but any other modifications may be lost.
# Use command 'dpkg-reconfigure mysql-apt-config' as root for modifications.
deb http://repo.mysql.com/apt/ubuntu/ trusty mysql-apt-config
deb http://repo.mysql.com/apt/ubuntu/ trusty mysql-5.6
deb http://repo.mysql.com/apt/ubuntu/ trusty mysql-tools
#deb http://repo.mysql.com/apt/ubuntu/ trusty mysql-tools-preview
deb-src http://repo.mysql.com/apt/ubuntu/ trusty mysql-5.6
[root@database /etc/apt/sources.list.d]# rm -fr ./*
[root@database /etc/apt/sources.list.d]# apt-get update
[11:56:50] Ign http://mirrors.aliyun.com trusty InRelease
[11:56:50] Hit http://mirrors.aliyun.com trusty-security InRelease
。。。。。。
[11:56:51] Ign http://mirrors.aliyun.com trusty/universe Translation-en_US
[11:56:57] Reading package lists... Done
[root@database /etc/apt/sources.list.d]# apt-get upgrade
[11:57:42] Reading package lists... Done
[11:57:43] Building dependency tree
[11:57:43] Reading state information... Done
[11:57:43] You might want to run 'apt-get -f install' to correct these.
[11:57:43] The following packages have unmet dependencies:
[11:57:43] mysql-community-server : Depends: mysql-client (= 5.6.42-1ubuntu14.04)
[11:57:43] E: Unmet dependencies. Try using -f.
[root@database /etc/apt]# cp sources.list sources.list.bak
[root@database /etc/apt]# vi sources.list
[11:59:33] deb http://mirrors.aliyun.com/ubuntu/ trusty main restricted universe multiverse
[11:59:33] deb http://mirrors.aliyun.com/ubuntu/ trusty-security main restricted universe multiverse
[11:59:33] deb http://mirrors.aliyun.com/ubuntu/ trusty-updates main restricted universe multiverse
[11:59:33] deb http://mirrors.aliyun.com/ubuntu/ trusty-proposed main restricted universe multiverse
[11:59:33] deb http://mirrors.aliyun.com/ubuntu/ trusty-backports main restricted universe multiverse
[11:59:33] deb-src http://mirrors.aliyun.com/ubuntu/ trusty main restricted universe multiverse
[11:59:33] deb-src http://mirrors.aliyun.com/ubuntu/ trusty-security main restricted universe multiverse
[11:59:33] deb-src http://mirrors.aliyun.com/ubuntu/ trusty-updates main restricted universe multiverse
[11:59:33] deb-src http://mirrors.aliyun.com/ubuntu/ trusty-proposed main restricted universe multiverse
[11:59:33] deb-src http://mirrors.aliyun.com/ubuntu/ trusty-backports main restricted universe multiverse
[root@database /etc/apt]# apt-get install vim
[12:03:38] Reading package lists... Done
[12:03:39] Building dependency tree
[12:03:39] Reading state information... Done
[12:03:39] You might want to run 'apt-get -f install' to correct these:
[12:03:39] The following packages have unmet dependencies:
[12:03:39] mysql-community-server : Depends: mysql-client (= 5.6.42-1ubuntu14.04)
[12:03:39] vim : Depends: vim-common (= 2:7.4.052-1ubuntu3.1) but 2:7.4.052-1ubuntu3 is to be installed
[12:03:39] Depends: vim-runtime (= 2:7.4.052-1ubuntu3.1) but it is not going to be installed
[12:03:39] E: Unmet dependencies. Try 'apt-get -f install' with no packages (or specify a solution).
[root@database /etc/apt]# apt-get upgrade
[12:22:49] Reading package lists... Done
[12:22:49] Building dependency tree
[12:22:49] Reading state information... Done
[12:22:49] You might want to run 'apt-get -f install' to correct these.
[12:22:49] The following packages have unmet dependencies:
[12:22:49] mysql-community-server : Depends: mysql-client (= 5.6.42-1ubuntu14.04)
[12:22:49] E: Unmet dependencies. Try using -f.
[root@database /etc/apt]# apt --fix-broken install ------之前安装mysql时通过deb安装未正常结束
[12:27:49] Reading package lists... Done
[12:27:50] Building dependency tree
[12:27:50] Reading state information... Done
[12:27:50] Correcting dependencies... Done
[12:27:50] The following packages will be REMOVED:
[12:27:50] mysql-community-server
[12:27:50] 0 upgraded, 0 newly installed, 1 to remove and 541 not upgraded.
[12:27:50] 2 not fully installed or removed.
[12:27:50] After this operation, 80.1 MB disk space will be freed.
[12:28:05] Do you want to continue? [Y/n] Y
[12:28:05]
[12:28:05] (Reading database ... 170482 files and directories currently installed.)
[12:28:05] Removing mysql-community-server (5.6.42-1ubuntu14.04) ...ges
[12:28:05] Progress: [ 0%] [................................................................................] update-alternatives: warning: alternative /etc/mysql/my.cnf.fallback (part of link group my.cnf) doesn't exist; removing from list of alternativestc/mysql/my.cnf.fallback (part of link group my.cnf) doesn't[12:28:05] update-alternatives: warning: /etc/alternatives/my.cnf is dangling; it will be updated with best choicepdate-alternatives: warning: /etc/alternatives/my.cnf is dangling; it will be updated with best choic[12:28:05] Processing triggers for man-db (2.6.7.1-1ubuntu1) ...f is dangling; it will be updated with best choic[12:28:06] Setting up mysql-common (5.6.42-1ubuntu14.04) ... ...f is dangling; it will be updated with best choic[12:28:06] update-alternatives: error: alternative path /etc/mysql/my.cnf.fallback doesn't existd with best choic[12:28:06] update-alternatives: error: alternative path /etc/mysql/my.cnf.fallback doesn't existd with best choic[12:28:06] E: Sub-process /usr/bin/dpkg returned an error code (1)
处理方法:
[root@database /etc/apt]# sudo mv /var/lib/dpkg/info /var/lib/dpkg/info_old -----------现将info文件夹更名
[root@database /etc/apt]# mkdir /var/lib/dpkg/info -------------再新建一个新的info文件夹
[root@database /etc/apt]# apt-get update
[root@database /etc/apt]# apt-get -f install
[root@database /etc/apt]# sudo mv /var/lib/dpkg/info/* /var/lib/dpkg/info_old ------------------执行完上一步操作后会在新的info文件夹下生成一些文件,现将这些文件全部移到info_old文件夹下
[root@database /etc/apt]# sudo rm -rf /var/lib/dpkg/info ------------把自己新建的info文件夹删掉
[root@database /etc/apt]# sudo mv /var/lib/dpkg/info_old /var/lib/dpkg/info ----------把以前的info文件夹重新改回名字
apt-get update
[12:29:28] Ign http://mirrors.aliyun.com trusty InRelease
[12:29:29] Hit http://mirrors.aliyun.com trusty/restricted i386 Packages
[12:29:30] Ign http://mirrors.aliyun.com trusty/main Translation-en_US
[12:29:30] Ign http://mirrors.aliyun.com trusty/multiverse Translation-en_US
[12:29:30] Ign http://mirrors.aliyun.com trusty/restricted Translation-en_US
[12:29:30] Ign http://mirrors.aliyun.com trusty/universe Translation-en_US
[12:29:35] Reading package lists... Done
[root@database /etc/apt]# apt-get upgrade
[12:29:42] Reading package lists... Done
[12:29:42] Building dependency tree
[12:29:42] Reading state information... Done
[12:29:43] Calculating upgrade... Done
[12:29:43] The following packages were automatically installed and are no longer required:
[12:29:43] libdbusmenu-gtk4 libntdb1 python-ntdb
[12:29:43] Use 'apt-get autoremove' to remove them.
[12:29:43] The following packages have been kept back:
[12:29:43] cups-filters cups-filters-core-drivers liboxideqt-qmlplugin liboxideqtcore0
[12:29:43] liboxideqtquick0 linux-generic-lts-vivid linux-headers-generic-lts-vivid
.............................
[12:34:49] Setting up ubuntu-desktop (1.325.1) ...
[12:34:49] Processing triggers for libc-bin (2.19-0ubuntu6.14) ...
[12:34:49] Processing triggers for initramfs-tools (0.103ubuntu4.11) ...
[12:34:49] update-initramfs: Generating /boot/initrd.img-3.19.0-25-generic
[12:34:58] Processing triggers for ca-certificates (20170717~14.04.1) ...
[12:35:01] Updating certificates in /etc/ssl/certs... WARNING: Skipping duplicate certificate UbuntuOne-Go_Daddy_Class_2_CA.pem
[12:35:01] WARNING: Skipping duplicate certificate UbuntuOne-Go_Daddy_Class_2_CA.pem
[12:35:01] 32 added, 57 removed; done.
[12:35:01] Running hooks in /etc/ca-certificates/update.d....done.
[12:35:01] Processing triggers for bamfdaemon (0.5.1+14.04.20140409-0ubuntu1) ...
[12:35:01] Rebuilding /usr/share/applications/bamf-2.index...
[12:35:01] Processing triggers for libreoffice-common (1:4.2.8-0ubuntu5.3) ...
[12:35:01] Errors were encountered while processing:
[12:35:01] mysql-common
[12:35:01] E: Sub-process /usr/bin/dpkg returned an error code (1)
[root@database mysql]# apt-get vim
[12:35:59] E: Invalid operation vim
[root@database mysql]# apt-get install
[12:37:27] Reading package lists... Done
[12:37:27] Building dependency tree
[12:37:27] Reading state information... Done
[12:37:28] The following packages were automatically installed and are no longer required:
[12:37:28] libdbusmenu-gtk4 libntdb1 python-ntdb
[12:37:28] Use 'apt-get autoremove' to remove them.
[12:37:28] 0 upgraded, 0 newly installed, 0 to remove and 19 not upgraded.
[12:37:28] 1 not fully installed or removed.
[12:37:28] After this operation, 0 B of additional disk space will be used.
[12:37:28] Setting up mysql-common (5.6.42-1ubuntu14.04) ...
[12:37:28] update-alternatives: error: alternative path /etc/mysql/my.cnf.fallback doesn't exist
[12:37:28] dpkg: error processing package mysql-common (--configure):
[12:37:28] subprocess installed post-installation script returned error exit status 2
[12:37:28] E: Sub-process /usr/bin/dpkg returned an error code (1)
[root@database mysql]# cd /var/lib/dpkg/info
[root@database /var/lib/dpkg/info/]# ls
[12:39:40] account-plugin-aim.list
[12:39:40] account-plugin-aim.md5sums
[12:39:40] account-plugin-facebook.conffiles
[root@database /var/lib/dpkg/info/]# apt-get update
[12:29:28] Ign http://mirrors.aliyun.com trusty InRelease
[12:29:29] Hit http://mirrors.aliyun.com trusty/restricted i386 Packages
[12:29:30] Ign http://mirrors.aliyun.com trusty/main Translation-en_US
[12:29:30] Ign http://mirrors.aliyun.com trusty/multiverse Translation-en_US
[12:29:30] Ign http://mirrors.aliyun.com trusty/restricted Translation-en_US
[12:29:30] Ign http://mirrors.aliyun.com trusty/universe Translation-en_US
[12:29:35] Reading package lists... Done
[root@database /var/lib/dpkg/info/]# apt-get upgrade
[12:29:42] Reading package lists... Done
[12:29:42] Building dependency tree
[12:29:42] Reading state information... Done
[12:29:43] Calculating upgrade... Done
[12:29:43] The following packages were automatically installed and are no longer required:
[12:29:43] libdbusmenu-gtk4 libntdb1 python-ntdb
[12:29:43] Use 'apt-get autoremove' to remove them.
[12:29:43] The following packages have been kept back:
[12:29:43] cups-filters cups-filters-core-drivers liboxideqt-qmlplugin liboxideqtcore0
[12:29:43] liboxideqtquick0 linux-generic-lts-vivid linux-headers-generic-lts-vivid
.............................
[12:34:49] Setting up ubuntu-desktop (1.325.1) ...
[12:34:49] Processing triggers for libc-bin (2.19-0ubuntu6.14) ...
[12:34:49] Processing triggers for initramfs-tools (0.103ubuntu4.11) ...
[12:34:49] update-initramfs: Generating /boot/initrd.img-3.19.0-25-generic
[12:34:58] Processing triggers for ca-certificates (20170717~14.04.1) ...
[12:35:01] Updating certificates in /etc/ssl/certs... WARNING: Skipping duplicate certificate UbuntuOne-Go_Daddy_Class_2_CA.pem
[12:35:01] WARNING: Skipping duplicate certificate UbuntuOne-Go_Daddy_Class_2_CA.pem
[12:35:01] 32 added, 57 removed; done.
[12:35:01] Running hooks in /etc/ca-certificates/update.d....done.
[12:35:01] Processing triggers for bamfdaemon (0.5.1+14.04.20140409-0ubuntu1) ...
[12:35:01] Rebuilding /usr/share/applications/bamf-2.index...
[12:35:01] Processing triggers for libreoffice-common (1:4.2.8-0ubuntu5.3) ...
[12:35:01] Errors were encountered while processing:
[12:35:01] mysql-common
[12:35:01] E: Sub-process /usr/bin/dpkg returned an error code (1)
[root@database /var/lib/dpkg/info/]# apt-get install
[12:37:27] Reading package lists... Done
[12:37:27] Building dependency tree
[12:37:27] Reading state information... Done
[12:37:28] The following packages were automatically installed and are no longer required:
[12:37:28] libdbusmenu-gtk4 libntdb1 python-ntdb
[12:37:28] Use 'apt-get autoremove' to remove them.
[12:37:28] 0 upgraded, 0 newly installed, 0 to remove and 19 not upgraded.
[12:37:28] 1 not fully installed or removed.
[12:37:28] After this operation, 0 B of additional disk space will be used.
[12:37:28] Setting up mysql-common (5.6.42-1ubuntu14.04) ...
[12:37:28] update-alternatives: error: alternative path /etc/mysql/my.cnf.fallback doesn't exist
[12:37:28] dpkg: error processing package mysql-common (--configure):
[12:37:28] subprocess installed post-installation script returned error exit status 2
[12:37:28] E: Sub-process /usr/bin/dpkg returned an error code (1)
[root@database /var/lib/dpkg/info/]# cd /var/lib/dpkg/info
[root@database /var/lib/dpkg/info]# ls
[12:39:40] account-plugin-aim.list
[12:39:40] account-plugin-aim.md5sums
[12:39:40] account-plugin-facebook.conffiles
...........................
[12:39:42] zlib1g:amd64.postrm
[12:39:42] zlib1g:amd64.shlibs
[12:39:42] zlib1g:amd64.symbols
[root@database /var/lib/dpkg/info/]# ls
[12:39:52] alternatives available cmethopt diversions-old lock statoverride status-old updates
[12:39:52] arch available-old diversions info parts status triggers
[root@database /var/lib/dpkg/info/]# mv info info_old
[root@database /var/lib/dpkg/info/]# mkdir info
[root@database /var/lib/dpkg/info/]# ls
alternatives available cmethopt diversions-old info_old parts status triggersarch available-old diversions info lock statoverride status-old updates
[root@database /var/lib/dpkg/info/]# apt-get update
[12:40:38] Ign http://mirrors.aliyun.com trusty InRelease
[12:40:38] Hit http://mirrors.aliyun.com trusty-security InRelease
[12:40:40] Ign http://mirrors.aliyun.com trusty/universe Translation-en_US
[12:40:44] Reading package lists... Done
[root@database /var/lib/dpkg/info/]# apt-get -f install
[12:41:23] Reading package lists... Done
[12:41:23] Building dependency tree
[12:41:23] Reading state information... Done
[12:41:23] The following packages were automatically installed and are no longer required:
[12:41:23] libdbusmenu-gtk4 libntdb1 python-ntdb
[12:41:23] Use 'apt-get autoremove' to remove them.
[12:41:23] 0 upgraded, 0 newly installed, 0 to remove and 19 not upgraded.
[12:41:23] 1 not fully installed or removed.
[12:41:23] After this operation, 0 B of additional disk space will be used.
[12:41:24] Setting up mysql-common (5.6.42-1ubuntu14.04) ...
[root@database /var/lib/dpkg/info/]# apt-get autoremove mysql-common
[12:42:13] Reading package lists... Done
[12:42:13] Building dependency tree
[12:42:13] Reading state information... Done
[12:42:13] The following packages will be REMOVED:
[12:42:13] libdbusmenu-gtk4 libmysqlclient-dev libmysqlclient18 libmysqld-dev libntdb1
[12:42:13] mysql-common python-ntdb
[12:42:13] 0 upgraded, 0 newly installed, 7 to remove and 19 not upgraded.
[12:42:13] After this operation, 86.1 MB disk space will be freed.
[12:42:17] Do you want to continue? [Y/n] Y
[12:42:17] dpkg: warning: files list file for package 'gnome-power-manager' missing; assuming package has no files currently installed
[12:42:17] dpkg: warning: files list file for package 'qtdeclarative5-qtfeedback-plugin:amd64' missing; assuming package has no files currently installed
.............
[12:42:21] dpkg: warning: files list file for package 'libexempi3:amd64' missing; assuming package has no files currently installed
[12:42:21] (Reading database ... 78 files and directories currently installed.)
[12:42:21] Removing libdbusmenu-gtk4:amd64 (12.10.3+14.04.20140612-0ubuntu1) ...
[12:42:21] Removing libmysqld-dev (5.6.42-1ubuntu14.04) ...
[12:42:21] Removing libmysqlclient-dev (5.6.42-1ubuntu14.04) ...
[12:42:21] Removing libmysqlclient18:amd64 (5.6.42-1ubuntu14.04) ...
[12:42:21] Removing python-ntdb (1.0-2ubuntu1) ...
[12:42:21] Removing libntdb1:amd64 (1.0-2ubuntu1) ...
[12:42:21] Removing mysql-common (5.6.42-1ubuntu14.04) ...
[root@database /var/lib/dpkg/info/]# cd info
[root@database /var/lib/dpkg/info/]# ls
[12:42:43] format mysql-common.list
[root@database /var/lib/dpkg/info/]# rm -fr mysql-common.list
[root@database /var/lib/dpkg/info/]# ls
[12:43:03] format
[root@database /var/lib/dpkg/info/]# cd ..
[root@database /var/lib/dpkg/info/]# apt-get update
[12:43:30] Ign http://mirrors.aliyun.com trusty InRelease
[12:43:36] Reading package lists... Done
[root@database /var/lib/dpkg/info/]# apt-get -f install
[12:46:52] Reading package lists... Done
[12:46:52] Building dependency tree
[12:46:52] Reading state information... Done
[12:46:52] 0 upgraded, 0 newly installed, 0 to remove and 19 not upgraded.
[root@database /var/lib/dpkg/info/]# ls
[12:47:32] alternatives available cmethopt diversions-old info_old parts status triggers
[12:47:32] arch available-old diversions info lock statoverride status-old updates
[root@database /var/lib/dpkg]# cd info
[root@database /var/lib/dpkg/info]# ls
[12:47:40] format
[root@database /var/lib/dpkg/info]# mv format ../info_old
[root@database /var/lib/dpkg/info]# cd ..
[root@database /var/lib/dpkg/info]# ls
[12:49:02] alternatives available cmethopt diversions-old info_old parts status triggers
[12:49:02] arch available-old diversions info lock statoverride status-old updates
[root@database /var/lib/dpkg]# rm -r info
[root@database /var/lib/dpkg]# ls
[12:49:14] alternatives available cmethopt diversions-old lock statoverride status-old updates
[12:49:14] arch available-old diversions info_old parts status triggers
[root@database /var/lib/dpkg]# mv info_old info
[root@database /var/lib/dpkg]# ls
[12:49:25] alternatives available cmethopt diversions-old lock statoverride status-old updates
[12:49:25] arch available-old diversions info parts status triggers
[root@database /var/lib/dpkg]# cd info/
[root@database /var/lib/dpkg]# ls
[12:49:29] account-plugin-aim.list
[12:49:29] account-plugin-aim.md5sums
[12:49:29] account-plugin-facebook.conffiles
[12:49:32] zlib1g:amd64.symbols
[root@database /var/lib/dpkg/info]# apt-get install vim
[12:52:24] Reading package lists... Done
[12:52:25] Building dependency tree
[12:52:25] Reading state information... Done
[12:52:25] The following extra packages will be installed:
[12:52:25] vim-runtime
[12:52:25] Suggested packages:
[12:52:25] ctags vim-doc vim-scripts
[12:52:25] The following NEW packages will be installed:
[12:52:25] vim vim-runtime
[12:52:25] 0 upgraded, 2 newly installed, 0 to remove and 19 not upgraded.
[12:52:25] Need to get 5,838 kB of archives.
[12:52:25] After this operation, 28.0 MB of additional disk space will be used.
[12:52:30] Do you want to continue? [Y/n] Y
[12:52:30] Get:1 http://mirrors.aliyun.com/ubuntu/ trusty-security/main vim-runtime all 2:7.4.052-1ubuntu3.1 [4,882 kB]
[12:52:31] Get:2 http://mirrors.aliyun.com/ubuntu/ trusty-security/main vim amd64 2:7.4.052-1ubuntu3.1 [955 kB]
[12:52:31] Fetched 5,838 kB in 0s (18.7 MB/s)
[12:52:31] Selecting previously unselected package vim-runtime.
[12:52:31] (Reading database ... 170283 files and directories currently installed.)
[12:52:31] Preparing to unpack .../vim-runtime_2%3a7.4.052-1ubuntu3.1_all.deb ...
[12:52:31] Adding 'diversion of /usr/share/vim/vim74/doc/help.txt to /usr/share/vim/vim74/doc/help.txt.vim-tiny by vim-runtime'
[12:52:31] Adding 'diversion of /usr/share/vim/vim74/doc/tags to /usr/share/vim/vim74/doc/tags.vim-tiny by vim-runtime'
[12:52:31] Unpacking vim-runtime (2:7.4.052-1ubuntu3.1) ...
[12:52:32] Selecting previously unselected package vim.
[12:52:32] Preparing to unpack .../vim_2%3a7.4.052-1ubuntu3.1_amd64.deb ...
[12:52:32] Unpacking vim (2:7.4.052-1ubuntu3.1) ...
[12:52:32] Processing triggers for man-db (2.6.7.1-1ubuntu1) ...
[12:52:33] Setting up vim-runtime (2:7.4.052-1ubuntu3.1) ...
[12:52:33] Processing /usr/share/vim/addons/doc
[12:52:33] Setting up vim (2:7.4.052-1ubuntu3.1) ...
[12:52:33] update-alternatives: using /usr/bin/vim.basic to provide /usr/bin/vim (vim) in auto mode
[12:52:33] update-alternatives: using /usr/bin/vim.basic to provide /usr/bin/vimdiff (vimdiff) in auto mode
[12:52:33] update-alternatives: using /usr/bin/vim.basic to provide /usr/bin/rvim (rvim) in auto mode
[12:52:33] update-alternatives: using /usr/bin/vim.basic to provide /usr/bin/rview (rview) in auto mode
[12:52:33] update-alternatives: using /usr/bin/vim.basic to provide /usr/bin/vi (vi) in auto mode
[12:52:33] update-alternatives: using /usr/bin/vim.basic to provide /usr/bin/view (view) in auto mode
[12:52:33] update-alternatives: using /usr/bin/vim.basic to provide /usr/bin/ex (ex) in auto mode
[root@database /var/lib/dpkg/info]# mysql -u root -p
[12:52:54] Enter password:
[12:52:54] ERROR 1045 (28000): Access denied for user 'root'@'localhost' (using password: YES)
[root@database /var/lib/dpkg/info]# apt-get install vim
[12:53:16] Reading package lists... Done
[12:53:16] Building dependency tree
[12:53:16] Reading state information... Done
[12:53:17] vim is already the newest version.
[12:53:17] 0 upgraded, 0 newly installed, 0 to remove and 19 not upgraded.
[12:55:26] [2018-11-17 12:55:26] End log -----------