... | @@ -13,7 +13,16 @@ mv ifcfg-eth0 ifcfg-ethctrl |
... | @@ -13,7 +13,16 @@ mv ifcfg-eth0 ifcfg-ethctrl |
|
sed -i 's/eth0/ethctrl/' ifcfg-ethctrl
|
|
sed -i 's/eth0/ethctrl/' ifcfg-ethctrl
|
|
mv ifcfg-eth1 ifcfg-ethdata
|
|
mv ifcfg-eth1 ifcfg-ethdata
|
|
sed -i 's/eth1/ethdata/' ifcfg-ethdata
|
|
sed -i 's/eth1/ethdata/' ifcfg-ethdata
|
|
|
|
|
|
|
|
# change grub
|
|
|
|
line=$(cat /etc/default/grub | grep "GRUB_CMDLINE_LINUX")
|
|
|
|
linenew=$(echo ${line::-1}" net.ifnames=0\"")
|
|
|
|
echo "please change if not correct:"
|
|
|
|
echo $linenew
|
|
|
|
linenew=$(echo $linenew | sed 's/\//\\\//g')
|
|
|
|
sed 's/GRUB_CMDLINE_LINUX.*$/'"${linenew}"'/' /etc/default/grub
|
|
```
|
|
```
|
|
|
|
|
|
2. Tell udev to rewrite. Create `/etc/udev/rules.d/70-persistent-net.rules` with:
|
|
2. Tell udev to rewrite. Create `/etc/udev/rules.d/70-persistent-net.rules` with:
|
|
|
|
|
|
```
|
|
```
|
... | | ... | |