rabbitmq安装 虚拟ip_步骤4:配置IPv6地址

自动配置IPv6地址

ecs-util-ipv6能为已分配IPv6地址的ECS实例一键配置IPv6地址,或者为没有分配IPv6地址的ECS实例一键清理IPv6配置。

ecs-util-ipv6工具下载地址如下所示。

系列

发行版

下载地址

RHEL

CentOS 5/6/7/8

Red Hat 5/6/7

Debian

Ubuntu 14/16

Debian/8/9

SLES

SUSE 11/12

OpenSUSE 42

CoreOS

CoreOS 14/17

FreeBSD

FreeBSD 11

使用限制如下:

ecs-util-ipv6工具仅适用于VPC类型实例,依赖实例元数据服务,使用前请勿将网络禁用或者将相关出口IP端口(100.100.100.200:80)禁用。详情请参见

ecs-util-ipv6工具运行时会自动重启网卡、网络服务,短时间内网络可能会不可用,请慎重执行。

下载对应系统版本工具到目标系统,赋予执行权限后使用管理员权限执行: chmod +x ./ecs-utils-ipv6

./ecs-utils-ipv6

如果当前ECS已绑定IPv6地址,则会自动配置;否则会自动清理原有IPv6地址配置。

命令行参数: ecs-utils-ipv6 --help # show usage

ecs-utils-ipv6 --version # show version

ecs-utils-ipv6 # auto config all dev ipv6

ecs-utils-ipv6 --static [dev] [ip6s] [prefix_len] [gw6] # config dev static ipv6

e.g. ecs-utils-ipv6 --static eth0

ecs-utils-ipv6 --static eth0 xxx::x1 64 xxx::x0

ecs-utils-ipv6 --static eth0 "xxx::x1 xxx:x2 xxx:x3" 64 xxx::x0

ecs-utils-ipv6 --enable # enable ipv6

ecs-utils-ipv6 --disable # disable ipv6

可以开启、禁用、手动配置、自动配置(默认)IPv6。 ./ecs-utils-ipv6 #默认可不带参数,自动配置多网卡多IPv6

./ecs-utils-ipv6 --enable #开启IPv6

./ecs-utils-ipv6 --disable #禁用IPv6

./ecs-utils-ipv6 --static #自动配置网卡IPv6

./ecs-utils-ipv6 --static #手动配置网卡IPv6,支持多IPv6,请用""包含,多个IPv6用空格隔开

对于需要自动化配置IPv6实例的需求,例如大批量配置,建议您使用云助手或者实例自定义数据配合脚本的方式来调用。详情请参见#!/bin/sh

install_dir=/usr/sbin

install_path="$install_dir"/ecs-utils-ipv6

if [ ! -f "$install_path" ]; then

tool_url="http://ecs-image-utils.oss-cn-hangzhou.aliyuncs.com/ipv6/rhel/ecs-utils-ipv6"

# download the tool

if ! wget "$tool_url" -O "$install_path"; then

echo "[Error] download tool failed, code $?"

exit "$?"

fi

fi

# chmod the tool

if ! chmod +x "$install_path"; then

echo "[Error] chmod tool failed, code $?"

exit "$?"

fi

# run the tool

"$install_path"

你可能感兴趣的:(rabbitmq安装,虚拟ip)