亚马逊EC2如何在一个CentOS 7实例上安装ixgbevf? [英] Amazon EC2 how to install ixgbevf on a Centos 7 instance?

查看:977
本文介绍了亚马逊EC2如何在一个CentOS 7实例上安装ixgbevf?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我试图在亚马逊EC2 CentOS7实例上安装ixgbevf。这些步骤看起来不错,但每次当我运行在一个增强的网络启用的类型,如M4.xlarge实例,网络似乎失败(启动后无法连接到该实例)。

I'm trying to install the ixgbevf on a Amazon EC2 CentOS7 instance. The steps looks good, but everytime when I run the instance in a Enhanced Networking enabled type, such as M4.xlarge, the network seems fail(I can not connect to the instance after startup).

下面是我所做的:

wget http://elrepo.org/linux/elrepo/el7/x86_64/RPMS/kmod-ixgbevf-2.16.1-1.el7.elrepo.x86_64.rpm
rpm -ivh kmod-ixgbevf-2.16.1-1.el7.elrepo.x86_64.rpm
cp -p /boot/initramfs-$(uname -r).img /boot/initramfs-$(uname -r).img.bak
dracut -f

然后关机的情况下,并设置SRIOV

Then shutdown the instance, and set the sriov

ec2-modify-instance-attribute instance_id --sriov simple

这一切。每当类型(如T2.micro)不支持增强的网络,该实例工作正常。但是,如果我将类型更改为增强网络启用(如M4.xlarge),实例根本无法访问。任何人对此有任何想法?我错过了什么?

That all. Whenever the type(such as T2.micro) doesn't support Enhanced Networking, the instance works fine. But if I change the type to Enhanced Networking enabled(such as M4.xlarge), the instance simply can't be accessed. Anyone have any idea about this? Did I miss something?

推荐答案

,答案就埋藏到本节中的原始文件的:

The answer lies buried into this section of the original documentation:

<一个href="http://docs.aws.amazon.com/AWSEC2/latest/UserGuide/enhanced-networking.html#enhanced-networking-linux" rel="nofollow">http://docs.aws.amazon.com/AWSEC2/latest/UserGuide/enhanced-networking.html#enhanced-networking-linux

在简单地说,CentOS的7艘已经与ixgbevf模块,虽然没有采用最新的版本,但是这是很难的一个问题。是什么造成了我的情况下是无法访问后,重新启动是在predictable网络接口,默认情况下启用。

In a nutshell, CentOS 7 already ships with the ixgbevf module, although not with the latest version, but this is hardly a problem. What was causing my instance to be unreachable after a reboot were the "predictable network interfaces", enabled by default.

要禁用它们,只需访问该链接,跳转的直接步骤6号和类型:

To disable them, simply visit that link, jump straight to step number 6 and type:

$转-qa | grep的-e'^ systemd- [0-9] \ + \ | ^ udev- [0-9] \ + $ sudo的sed的-i'/ ^ GRUB \ _CMDLINE \ _linux / S / \$ / \网络\ .ifnames \ = 0 \/的/ etc /默认/平头 $ sudo的GRUB2-mkconfig -o /boot/grub2/grub.cfg

$ rpm -qa | grep -e '^systemd-[0-9]\+\|^udev-[0-9]\+' $ sudo sed -i '/^GRUB\_CMDLINE\_LINUX/s/\"$/\ net\.ifnames\=0\"/' /etc/default/grub $ sudo grub2-mkconfig -o /boot/grub2/grub.cfg

之后:

  1. 停止实例
  2. 通过AWS CLI启用增强的网络
  3. 重新启动

您现在应该能够登录!

这篇关于亚马逊EC2如何在一个CentOS 7实例上安装ixgbevf?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆