AskOverflow.Dev

AskOverflow.Dev Logo AskOverflow.Dev Logo

AskOverflow.Dev Navigation

  • 主页
  • 系统&网络
  • Ubuntu
  • Unix
  • DBA
  • Computer
  • Coding
  • LangChain

Mobile menu

Close
  • 主页
  • 系统&网络
    • 最新
    • 热门
    • 标签
  • Ubuntu
    • 最新
    • 热门
    • 标签
  • Unix
    • 最新
    • 标签
  • DBA
    • 最新
    • 标签
  • Computer
    • 最新
    • 标签
  • Coding
    • 最新
    • 标签
主页 / ubuntu / 问题 / 978428
Accepted
Sss
Sss
Asked: 2017-11-21 06:26:33 +0800 CST2017-11-21 06:26:33 +0800 CST 2017-11-21 06:26:33 +0800 CST

无法安装 gns3,Err 502 bad gateway

  • 772

我有 Ubuntu 17.04,我正在尝试使用以下命令安装 gns3:

sudo add-apt-repository ppa:gns3/ppa

输出:

 PPA for GNS3 and Supporting Packages. Please see http://www.gns3.com for more details
 More info: https://launchpad.net/~gns3/+archive/ubuntu/ppa
Press [ENTER] to continue or ctrl-c to cancel adding it

gpg: keybox '/tmp/tmpji7mkxvk/pubring.gpg' created
Error: retrieving gpg key timed out.

然后:

sudo apt-get update
sudo apt-get install gns3-gui

输出:

Reading package lists... Done
Building dependency tree       
Reading state information... Done
The following packages were automatically installed and are no longer required:
  linux-headers-4.10.0-37 linux-headers-4.10.0-37-generic
  linux-image-4.10.0-37-generic linux-image-extra-4.10.0-37-generic
  linux-signed-image-4.10.0-37-generic
Use 'sudo apt autoremove' to remove them.
The following additional packages will be installed:
  augeas-lenses bridge-utils cpu-checker cpulimit dmeventd dns-root-data
  dnsmasq-base dynamips ebtables gns3-server ipxe-qemu libaio1 libaugeas0
  libboost-random1.62.0 libdevmapper-event1.02.1 libfdt1 libiscsi7
  liblvm2app2.2 liblvm2cmd2.02 libnetcf1 libqt5websockets5 librados2 librbd1
  libreadline5 libspice-server1 libvirt-bin libvirt-clients libvirt-daemon
  libvirt-daemon-system libvirt0 libvncserver1 libxen-4.8 libxenstore3.0
  libxml2-utils lvm2 msr-tools python3-pyqt5.qtsvg python3-pyqt5.qtwebsockets
  qemu-block-extra qemu-kvm qemu-system-arm qemu-system-common qemu-system-x86
  qemu-utils seabios sharutils ubridge vpcs x11vnc x11vnc-data xvfb
Suggested packages:
  augeas-doc gns3 augeas-tools numad radvd auditd systemtap nfs-common
  zfsutils pm-utils thin-provisioning-tools samba vde2 qemu-efi sgabios ovmf
  debootstrap sharutils-doc bsd-mailx | mailx
The following NEW packages will be installed:
  augeas-lenses bridge-utils cpu-checker cpulimit dmeventd dns-root-data
  dnsmasq-base dynamips ebtables gns3-gui gns3-server ipxe-qemu libaio1
  libaugeas0 libboost-random1.62.0 libdevmapper-event1.02.1 libfdt1 libiscsi7
  liblvm2app2.2 liblvm2cmd2.02 libnetcf1 libqt5websockets5 librados2 librbd1
  libreadline5 libspice-server1 libvirt-bin libvirt-clients libvirt-daemon
  libvirt-daemon-system libvirt0 libvncserver1 libxen-4.8 libxenstore3.0
  libxml2-utils lvm2 msr-tools python3-pyqt5.qtsvg python3-pyqt5.qtwebsockets
  qemu-block-extra qemu-kvm qemu-system-arm qemu-system-common qemu-system-x86
  qemu-utils seabios sharutils ubridge vpcs x11vnc x11vnc-data xvfb
0 upgraded, 52 newly installed, 0 to remove and 0 not upgraded.
Need to get 384 kB/42.9 MB of archives.
After this operation, 170 MB of additional disk space will be used.
Do you want to continue? [Y/n] y
Get:1 http://us.archive.ubuntu.com/ubuntu zesty-updates/main amd64 libxenstore3.0 amd64 4.8.0-1ubuntu2.4 [19.8 kB]
Err:2 http://us.archive.ubuntu.com/ubuntu zesty/main amd64 libnetcf1 amd64 1:0.2.8-1ubuntu2
  502  Bad Gateway [IP: ...]
Get:3 http://us.archive.ubuntu.com/ubuntu zesty-updates/main amd64 qemu-block-extra amd64 1:2.8+dfsg-3ubuntu2.7 [38.1 kB]
Err:4 http://us.archive.ubuntu.com/ubuntu zesty/universe amd64 python3-pyqt5.qtwebsockets amd64 5.7+dfsg-5
  502  Bad Gateway [IP: ...]
Get:5 http://us.archive.ubuntu.com/ubuntu zesty-updates/main amd64 qemu-kvm amd64 1:2.8+dfsg-3ubuntu2.7 [13.2 kB]
Err:6 http://us.archive.ubuntu.com/ubuntu zesty/main amd64 libvncserver1 amd64 0.9.11+dfsg-1
  502  Bad Gateway [IP: ...]
Get:7 http://us.archive.ubuntu.com/ubuntu zesty/main amd64 cpu-checker amd64 0.7-0ubuntu7 [6,862 B]
Ign:8 http://us.archive.ubuntu.com/ubuntu zesty/main amd64 dns-root-data all 2015052300+h+1
Get:9 http://us.archive.ubuntu.com/ubuntu zesty/main amd64 libreadline5 amd64 5.2+dfsg-3build1 [99.5 kB]
Err:8 http://us.archive.ubuntu.com/ubuntu zesty/main i386 dns-root-data all 2015052300+h+1
  502  Bad Gateway [IP: ...]
Fetched 177 kB in 1min 10s (2,525 B/s)                                         
E: Failed to fetch http://us.archive.ubuntu.com/ubuntu/pool/main/n/netcf/libnetcf1_0.2.8-1ubuntu2_amd64.deb  502  Bad Gateway [IP: ...]
E: Failed to fetch http://us.archive.ubuntu.com/ubuntu/pool/universe/p/pyqt5/python3-pyqt5.qtwebsockets_5.7+dfsg-5_amd64.deb  502  Bad Gateway [IP: ...]
E: Failed to fetch http://us.archive.ubuntu.com/ubuntu/pool/main/libv/libvncserver/libvncserver1_0.9.11+dfsg-1_amd64.deb  502  Bad Gateway [IP: ...]
E: Failed to fetch http://us.archive.ubuntu.com/ubuntu/pool/main/d/dns-root-data/dns-root-data_2015052300+h+1_all.deb  502  Bad Gateway [IP: ...]
E: Unable to fetch some archives, maybe run apt-get update or try with --fix-missing?

请注意:我尝试通过这些命令多次安装它。
上面输出的最后一行说:运行apt-get update或尝试--fix-missing 我多次更新和升级系统,然后我尝试再次安装gns3,但它没有工作。而且我不知道怎么跑--fix-missing。
输出--fix-missing:

--fix-missing: command not found

这些命令使用基于 Ubuntu 的发行版:

sudo add-apt-repository ppa:gns3/ppa
sudo apt-get update
sudo apt-get install gns3-gui

当我无法以这种方式安装它时,我决定使用以下命令安装它:
基于 Debian 的发行版:

deb http://ppa.launchpad.net/gns3/ppa/ubuntu trusty main
deb-src http://ppa.launchpad.net/gns3/ppa/ubuntu trusty main

然后

将以下行添加到您的 /etc/apt/sources.list 中:

deb http://ppa.launchpad.net/gns3/ppa/ubuntu trusty main
deb-src http://ppa.launchpad.net/gns3/ppa/ubuntu trusty main

然后在终端中运行以下命令:

sudo apt-key adv --keyserver keyserver.ubuntu.com --recv-keys F88F6D313016330404F710FC9A2FD067A2E3EF7B
sudo apt-get update
sudo apt-get install gns3-gui

我无法再次安装它

错误:502 网关错误

在这些之后,我在终端中输入了 gns3,输出:

The program 'gns3' is currently not installed. You can install it by typing:
sudo apt install gns3

所以我尝试使用上面的命令安装它:

sudo apt install gns3

输出:

Reading package lists... Done
Building dependency tree       
Reading state information... Done
The following additional packages will be installed:
  dynamips libqt4-designer libqt4-help libqt4-scripttools libqt4-svg
  libqt4-test libqtassistantclient4 libxdo3 python-qt4 python-sip xdotool
Suggested packages:
  python-qt4-dbg
The following NEW packages will be installed:
  dynamips gns3 libqt4-designer libqt4-help libqt4-scripttools libqt4-svg
  libqt4-test libqtassistantclient4 libxdo3 python-qt4 python-sip xdotool
0 upgraded, 12 newly installed, 0 to remove and 0 not upgraded.
Need to get 438 kB/10.2 MB of archives.
After this operation, 50.1 MB of additional disk space will be used.
Do you want to continue? [Y/n] y
Get:1 http://us.archive.ubuntu.com/ubuntu zesty/main amd64 libqt4-help amd64 4:4.8.7+dfsg-7ubuntu1 [207 kB]
Err:2 http://us.archive.ubuntu.com/ubuntu zesty/main amd64 libqt4-svg amd64 4:4.8.7+dfsg-7ubuntu1
  502  Bad Gateway [IP: ...]
Get:3 http://us.archive.ubuntu.com/ubuntu zesty/universe amd64 python-sip amd64 4.18.1+dfsg-1 [71.8 kB]
Err:4 http://us.archive.ubuntu.com/ubuntu zesty/universe amd64 libxdo3 amd64 1:3.20160805.1-3
  502  Bad Gateway [IP: ...]
Fetched 279 kB in 1min 4s (4,290 B/s)                                          
E: Failed to fetch http://us.archive.ubuntu.com/ubuntu/pool/main/q/qt4-x11/libqt4-svg_4.8.7+dfsg-7ubuntu1_amd64.deb  502  Bad Gateway [IP: 91.189.91.23 80]
E: Failed to fetch http://us.archive.ubuntu.com/ubuntu/pool/universe/x/xdotool/libxdo3_3.20160805.1-3_amd64.deb  502  Bad Gateway    Reading package lists... Done
Building dependency tree       
Reading state information... Done
The following additional packages will be installed:
  dynamips libqt4-designer libqt4-help libqt4-scripttools libqt4-svg
  libqt4-test libqtassistantclient4 libxdo3 python-qt4 python-sip xdotool
Suggested packages:
  python-qt4-dbg
The following NEW packages will be installed:
  dynamips gns3 libqt4-designer libqt4-help libqt4-scripttools libqt4-svg
  libqt4-test libqtassistantclient4 libxdo3 python-qt4 python-sip xdotool
0 upgraded, 12 newly installed, 0 to remove and 0 not upgraded.
Need to get 438 kB/10.2 MB of archives.
After this operation, 50.1 MB of additional disk space will be used.
Do you want to continue? [Y/n] y
Get:1 http://us.archive.ubuntu.com/ubuntu zesty/main amd64 libqt4-help amd64 4:4.8.7+dfsg-7ubuntu1 [207 kB]
Err:2 http://us.archive.ubuntu.com/ubuntu zesty/main amd64 libqt4-svg amd64 4:4.8.7+dfsg-7ubuntu1
  502  Bad Gateway [IP: ...]
Get:3 http://us.archive.ubuntu.com/ubuntu zesty/universe amd64 python-sip amd64 4.18.1+dfsg-1 [71.8 kB]
Err:4 http://us.archive.ubuntu.com/ubuntu zesty/universe amd64 libxdo3 amd64 1:3.20160805.1-3
  502  Bad Gateway [IP: ...]
Fetched 279 kB in 1min 4s (4,290 B/s)                                          
E: Failed to fetch http://us.archive.ubuntu.com/ubuntu/pool/main/q/qt4-x11/libqt4-svg_4.8.7+dfsg-7ubuntu1_amd64.deb  502  Bad Gateway [IP: ...]
E: Failed to fetch http://us.archive.ubuntu.com/ubuntu/pool/universe/x/xdotool/libxdo3_3.20160805.1-3_amd64.deb  502  Bad Gateway [IP: ...]
E: Unable to fetch some archives, maybe run apt-get update or try with --fix-missing? [IP:...]
E: Unable to fetch some archives, maybe run apt-get update or try with --fix-missing?

现在,我该怎么办?

networking
  • 1 1 个回答
  • 1160 Views

1 个回答

  • Voted
  1. Best Answer
    Sss
    2017-11-21T09:56:28+08:002017-11-21T09:56:28+08:00

    我设法安装了它...
    我需要将服务器从软件中心从美国更改为我所在地区最好的服务器
    然后:

    sudo add-apt-repository ppa:gns3/ppa
    sudo apt-get update
    sudo apt-get install gns3
    

    不是这个:

    sudo apt-get install gns3-gui
    
    • 2

相关问题

  • 如何设置 VLAN 转发?

  • 如何将主机 Ubuntu 上的 VPN (tun0) 网络适配器映射到 VirtualBox 来宾 Windows?

  • 如何限制下载/上传带宽?

  • 如何通过 Windows 网络共享文件?

  • 面板小程序以文本形式显示当前网络流量?

Sidebar

Stats

  • 问题 205573
  • 回答 270741
  • 最佳答案 135370
  • 用户 68524
  • 热门
  • 回答
  • Marko Smith

    如何运行 .sh 脚本?

    • 16 个回答
  • Marko Smith

    如何安装 .tar.gz(或 .tar.bz2)文件?

    • 14 个回答
  • Marko Smith

    如何列出所有已安装的软件包

    • 24 个回答
  • Marko Smith

    无法锁定管理目录 (/var/lib/dpkg/) 是另一个进程在使用它吗?

    • 25 个回答
  • Martin Hope
    Flimm 如何在没有 sudo 的情况下使用 docker? 2014-06-07 00:17:43 +0800 CST
  • Martin Hope
    Ivan 如何列出所有已安装的软件包 2010-12-17 18:08:49 +0800 CST
  • Martin Hope
    La Ode Adam Saputra 无法锁定管理目录 (/var/lib/dpkg/) 是另一个进程在使用它吗? 2010-11-30 18:12:48 +0800 CST
  • Martin Hope
    David Barry 如何从命令行确定目录(文件夹)的总大小? 2010-08-06 10:20:23 +0800 CST
  • Martin Hope
    jfoucher “以下软件包已被保留:”为什么以及如何解决? 2010-08-01 13:59:22 +0800 CST
  • Martin Hope
    David Ashford 如何删除 PPA? 2010-07-30 01:09:42 +0800 CST

热门标签

10.10 10.04 gnome networking server command-line package-management software-recommendation sound xorg

Explore

  • 主页
  • 问题
    • 最新
    • 热门
  • 标签
  • 帮助

Footer

AskOverflow.Dev

关于我们

  • 关于我们
  • 联系我们

Legal Stuff

  • Privacy Policy

Language

  • Pt
  • Server
  • Unix

© 2023 AskOverflow.DEV All Rights Reserve