#author("2018-08-21T16:34:56+09:00","","") [[CentOS7]] *仮想インタフェースを作成する [#l2db6d87] |BGCOLOR(black):COLOR(white):|c |[root@localhost ~]# cd /etc/sysconfig/network-scripts/| |[root@localhost network-scripts]# cp ifcfg-eth0 ifcfg-eth0:1 &color(lime){←設定ファイルをコピー};| |[root@localhost network-scripts]# vi ifcfg-eth0:1| |DEVICE=&color(lime){eth0:1}; &br; ONBOOT=yes &br; IPADDR=xxx.xxx.xxx.xxx &br; NETMASK=255.255.255.0 &br; NETWORK=xxx.xxx.xxx.0 &br; GATEWAY=xxx.xxx.xxx.xxx &br; BOOTPROTO=none &br; USERCTL=no| |[root@localhost network-scripts]# cd| |[root@localhost ~]# ifup eth0:1 &color(lime){←仮想インタフェースをUP};| |[root@localhost ~]# ifconfig &color(lime){←仮想インターフェースの状態を確認};|