【ubuntu】1404 安装ssh-server时出现错误

前端之家收集整理的这篇文章主要介绍了【ubuntu】1404 安装ssh-server时出现错误前端之家小编觉得挺不错的,现在分享给大家,也给大家做个参考。

刚安装完Ubuntu14.04 后, 想先安装ssh, 但是出现了以下错误

wt@wt-vm:~$ sudo apt-get install openssh-server
Reading package lists... Done
Building dependency tree       
Reading state information... Done
Some packages could not be installed. This may mean that you have
requested an impossible situation or if you are using the unstable
distribution that some required packages have not yet been created
or been moved out of Incoming.
The following information may help to resolve the situation:

The following packages have unmet dependencies:
 libcogl15 : Depends: libegl1-mesa-drivers
 openssh-server : Depends: openssh-client (= 1:6.6p1-2ubuntu1)
E: Error,pkgProblemResolver::Resolve generated breaks,this may be caused by held packages.

解决办法如下:

1、 先安装openssh-server 依指定定版本的 openssh-client

wt@wt-vm:~$ sudo apt-get install openssh-client=1:6.6p1-2ubuntu1
Reading package lists... Done
Building dependency tree       
Reading state information... Done
Suggested packages:
  libpam-ssh keychain monkeysphere
The following packages will be DOWNGRADED:
  openssh-client
0 upgraded,0 newly installed,1 downgraded,0 to remove and 0 not upgraded.
Need to get 566 kB of archives.
After this operation,0 B of additional disk space will be used.
Do you want to continue? [Y/n] y
Get:1 http://cn.archive.ubuntu.com/ubuntu/ trusty/main openssh-client amd64 1:6.6p1-2ubuntu1 [566 kB]
Fetched 566 kB in 0s (780 kB/s)        
dpkg: warning: downgrading openssh-client from 1:6.6p1-2ubuntu2.7 to 1:6.6p1-2ubuntu1
(Reading database ... 167741 files and directories currently installed.)
Preparing to unpack .../openssh-client_1%3a6.6p1-2ubuntu1_amd64.deb ...
Unpacking openssh-client (1:6.6p1-2ubuntu1) over (1:6.6p1-2ubuntu2.7) ...
Processing triggers for man-db (2.6.7.1-1ubuntu1) ...
Setting up openssh-client (1:6.6p1-2ubuntu1) ...

2、在重新安装openssh-server
wt@wt-vm:~$ sudo apt-get install openssh-server
Reading package lists... Done
Building dependency tree       
Reading state information... Done
The following extra packages will be installed:
  libck-connector0 ncurses-term openssh-sftp-server ssh-import-id
Suggested packages:
  RSSh molly-guard monkeysphere
The following NEW packages will be installed:
  libck-connector0 ncurses-term openssh-server openssh-sftp-server
  ssh-import-id
0 upgraded,5 newly installed,0 to remove and 0 not upgraded.
Need to get 616 kB of archives.
After this operation,3,420 kB of additional disk space will be used.
Do you want to continue? [Y/n] y
Get:1 http://cn.archive.ubuntu.com/ubuntu/ trusty/main libck-connector0 amd64 0.4.5-3.1ubuntu2 [10.5 kB]
Get:2 http://cn.archive.ubuntu.com/ubuntu/ trusty/main ncurses-term all 5.9+20140118-1ubuntu1 [243 kB]
Get:3 http://cn.archive.ubuntu.com/ubuntu/ trusty/main openssh-sftp-server amd64 1:6.6p1-2ubuntu1 [34.1 kB]
Get:4 http://cn.archive.ubuntu.com/ubuntu/ trusty/main openssh-server amd64 1:6.6p1-2ubuntu1 [319 kB]
Get:5 http://cn.archive.ubuntu.com/ubuntu/ trusty/main ssh-import-id all 3.21-0ubuntu1 [9,624 B]
Fetched 616 kB in 0s (746 kB/s)            
Preconfiguring packages ...
Selecting prevIoUsly unselected package libck-connector0:amd64.
(Reading database ... 167741 files and directories currently installed.)
Preparing to unpack .../libck-connector0_0.4.5-3.1ubuntu2_amd64.deb ...
Unpacking libck-connector0:amd64 (0.4.5-3.1ubuntu2) ...
Selecting prevIoUsly unselected package ncurses-term.
Preparing to unpack .../ncurses-term_5.9+20140118-1ubuntu1_all.deb ...
Unpacking ncurses-term (5.9+20140118-1ubuntu1) ...
Selecting prevIoUsly unselected package openssh-sftp-server.
Preparing to unpack .../openssh-sftp-server_1%3a6.6p1-2ubuntu1_amd64.deb ...
Unpacking openssh-sftp-server (1:6.6p1-2ubuntu1) ...
Selecting prevIoUsly unselected package openssh-server.
Preparing to unpack .../openssh-server_1%3a6.6p1-2ubuntu1_amd64.deb ...
Unpacking openssh-server (1:6.6p1-2ubuntu1) ...
Selecting prevIoUsly unselected package ssh-import-id.
Preparing to unpack .../ssh-import-id_3.21-0ubuntu1_all.deb ...
Unpacking ssh-import-id (3.21-0ubuntu1) ...
Processing triggers for man-db (2.6.7.1-1ubuntu1) ...
Processing triggers for ureadahead (0.100.0-16) ...
ureadahead will be reprofiled on next reboot
Processing triggers for ufw (0.34~rc-0ubuntu2) ...
Setting up libck-connector0:amd64 (0.4.5-3.1ubuntu2) ...
Setting up ncurses-term (5.9+20140118-1ubuntu1) ...
Setting up openssh-sftp-server (1:6.6p1-2ubuntu1) ...
Setting up openssh-server (1:6.6p1-2ubuntu1) ...
Creating SSH2 RSA key; this may take some time ...
Creating SSH2 DSA key; this may take some time ...
Creating SSH2 ECDSA key; this may take some time ...
Creating SSH2 ED25519 key; this may take some time ...
ssh start/running,process 4429
Setting up ssh-import-id (3.21-0ubuntu1) ...
Processing triggers for libc-bin (2.19-0ubuntu6.9) ...
Processing triggers for ureadahead (0.100.0-16) ...
Processing triggers for ufw (0.34~rc-0ubuntu2) ...
原文链接:https://www.f2er.com/ubuntu/352748.html

猜你在找的Ubuntu相关文章