Issues related to configuring your network
- Posts: 4
- Joined: 2018/10/24 04:50:26
i created script to configure my Network. A command can be
Code: Select all
The problem i currently have, is that the Name of the Network Card changes, depending on the environment i use. In my local virtualbox, the file is called "ifcfg-enp0s3", in our company internal cloud system it is called "ifcfg-eth0". How do is CentOS defining the names of the cards? Is there a script pattern to find out what is the right name? Or is there a list of known network-card-names?
- Posts: 1552
- Joined: 2015/02/17 15:14:33
- Location: Bulgaria
The network naming was modified to be more consistent and it is created based on the location of the NIC on the server.
If you use KVM host for virtualization, with virtio NICs, all your interfaces will use the old naming convention.
As per my opinion, you can use
to get the device list and then using nmcli to set your connections.
Another option is to use %post-install section of a kickstart in order to easily build and configure your machines.