pkg_resources.DistributionNotFound: The 'tinyrpc' distribution was not found and is required by ryu

在 ubuntu 16.04 上安装 ryu

  • python 2.7.12
  • pip 8.1.1

方法一 通过 pip 安装

可能有网速问题。

方法二

通过 git 安装

sudo apt install git
sudo apt install python-pip
git clone http://github.com/osrg/ryu.git
cd ryu
sudo pip install -r tools/pip-requires
sudo python setup.py install

一开始我遇到了 ‘tinyrpc’ distribution was not found 的问题。

找到了这个链接,需要科学上网
https://gist.github.com/olegslavkin/e01ccc1835396402dc2f

指向了解决方案:
http://ryu-devel.narkive.com/AvVCZ4OS/ryu-installation-error-the-ovs-distribution-was-not-found-and-is-required-by-ryu

我先把 pip 恢复到 python-pip 的版本。

然后按照解决方法说的重装了依赖 tools/pip-requires ,
再重新执行 sudo python setup.py install就可以了。

测试

/path/to/ryu # ./run_tests.sh

输出:略。

ryu-manager --version

输出

ryu-manager 4.24

不要随便用 pip –upgrade pip 到 pip 10.x.x ,跟 apt 安装的 pip 可能不兼容。

猜你喜欢

转载自blog.csdn.net/cyz14/article/details/79994548
ryu