How can I change the priority of network interfaces?
Clash Royale CLAN TAG#URR8PPP
Sorry for the complicated scenario.
OS is: CentOS 7
Currently what happens:
- Server boots.
- Not accessible through it's static IP.
- Can connect to it through a local area IP (br160 192.168.160.27) on another server.
- Once connected, I login through webmin, go to network interfaces, select the interface with the static ip assigned to the server (eno2 10.242.182.111), and click "save & apply".
- The server can now access internet and I can connect to it directly through the eno2 IP (which is still on a closed VPN network, but that's how it should be).
So every time it boots I need to go and sort of reactivate eno2. It seems like it gets activated at boot (I checked), but maybe the priority is wrong?
ifconfig -a & route -n available here:
https://pastebin.com/vBcuw4Vt
cat /etc/sysconfig/network-scripts/ifcfg-eno2 :
https://pastebin.com/XJ9rhak8
I went from someone managing my server to that person leaving and me taking over. I can handle basic linux but not advanced networking.
EDIT: I am also seeing the boot routing as follows:
- Any Interface to 192.168.160.11
- eth0 to 10.242.182.1
Should I switch the order?
network-interface
add a comment |
Sorry for the complicated scenario.
OS is: CentOS 7
Currently what happens:
- Server boots.
- Not accessible through it's static IP.
- Can connect to it through a local area IP (br160 192.168.160.27) on another server.
- Once connected, I login through webmin, go to network interfaces, select the interface with the static ip assigned to the server (eno2 10.242.182.111), and click "save & apply".
- The server can now access internet and I can connect to it directly through the eno2 IP (which is still on a closed VPN network, but that's how it should be).
So every time it boots I need to go and sort of reactivate eno2. It seems like it gets activated at boot (I checked), but maybe the priority is wrong?
ifconfig -a & route -n available here:
https://pastebin.com/vBcuw4Vt
cat /etc/sysconfig/network-scripts/ifcfg-eno2 :
https://pastebin.com/XJ9rhak8
I went from someone managing my server to that person leaving and me taking over. I can handle basic linux but not advanced networking.
EDIT: I am also seeing the boot routing as follows:
- Any Interface to 192.168.160.11
- eth0 to 10.242.182.1
Should I switch the order?
network-interface
Can you add the content of/etc/sysconfig/network-scripts/ifcfg-eno2
? In particular, that should have a lineONBOOT=
which might be set tono
for you?
– Ulrich Schwarz
Aug 13 '17 at 14:39
Was just looking at it, I edited the post and put it here pastebin.com/XJ9rhak8 looks like onboot is on.
– AdrianP.
Aug 13 '17 at 14:42
add a comment |
Sorry for the complicated scenario.
OS is: CentOS 7
Currently what happens:
- Server boots.
- Not accessible through it's static IP.
- Can connect to it through a local area IP (br160 192.168.160.27) on another server.
- Once connected, I login through webmin, go to network interfaces, select the interface with the static ip assigned to the server (eno2 10.242.182.111), and click "save & apply".
- The server can now access internet and I can connect to it directly through the eno2 IP (which is still on a closed VPN network, but that's how it should be).
So every time it boots I need to go and sort of reactivate eno2. It seems like it gets activated at boot (I checked), but maybe the priority is wrong?
ifconfig -a & route -n available here:
https://pastebin.com/vBcuw4Vt
cat /etc/sysconfig/network-scripts/ifcfg-eno2 :
https://pastebin.com/XJ9rhak8
I went from someone managing my server to that person leaving and me taking over. I can handle basic linux but not advanced networking.
EDIT: I am also seeing the boot routing as follows:
- Any Interface to 192.168.160.11
- eth0 to 10.242.182.1
Should I switch the order?
network-interface
Sorry for the complicated scenario.
OS is: CentOS 7
Currently what happens:
- Server boots.
- Not accessible through it's static IP.
- Can connect to it through a local area IP (br160 192.168.160.27) on another server.
- Once connected, I login through webmin, go to network interfaces, select the interface with the static ip assigned to the server (eno2 10.242.182.111), and click "save & apply".
- The server can now access internet and I can connect to it directly through the eno2 IP (which is still on a closed VPN network, but that's how it should be).
So every time it boots I need to go and sort of reactivate eno2. It seems like it gets activated at boot (I checked), but maybe the priority is wrong?
ifconfig -a & route -n available here:
https://pastebin.com/vBcuw4Vt
cat /etc/sysconfig/network-scripts/ifcfg-eno2 :
https://pastebin.com/XJ9rhak8
I went from someone managing my server to that person leaving and me taking over. I can handle basic linux but not advanced networking.
EDIT: I am also seeing the boot routing as follows:
- Any Interface to 192.168.160.11
- eth0 to 10.242.182.1
Should I switch the order?
network-interface
network-interface
edited Aug 13 '17 at 15:13
AdrianP.
asked Aug 13 '17 at 14:34
AdrianP.AdrianP.
64
64
Can you add the content of/etc/sysconfig/network-scripts/ifcfg-eno2
? In particular, that should have a lineONBOOT=
which might be set tono
for you?
– Ulrich Schwarz
Aug 13 '17 at 14:39
Was just looking at it, I edited the post and put it here pastebin.com/XJ9rhak8 looks like onboot is on.
– AdrianP.
Aug 13 '17 at 14:42
add a comment |
Can you add the content of/etc/sysconfig/network-scripts/ifcfg-eno2
? In particular, that should have a lineONBOOT=
which might be set tono
for you?
– Ulrich Schwarz
Aug 13 '17 at 14:39
Was just looking at it, I edited the post and put it here pastebin.com/XJ9rhak8 looks like onboot is on.
– AdrianP.
Aug 13 '17 at 14:42
Can you add the content of
/etc/sysconfig/network-scripts/ifcfg-eno2
? In particular, that should have a line ONBOOT=
which might be set to no
for you?– Ulrich Schwarz
Aug 13 '17 at 14:39
Can you add the content of
/etc/sysconfig/network-scripts/ifcfg-eno2
? In particular, that should have a line ONBOOT=
which might be set to no
for you?– Ulrich Schwarz
Aug 13 '17 at 14:39
Was just looking at it, I edited the post and put it here pastebin.com/XJ9rhak8 looks like onboot is on.
– AdrianP.
Aug 13 '17 at 14:42
Was just looking at it, I edited the post and put it here pastebin.com/XJ9rhak8 looks like onboot is on.
– AdrianP.
Aug 13 '17 at 14:42
add a comment |
1 Answer
1
active
oldest
votes
Renumber the interface numbers by MAC-address. It looks like something goes wrong when givining eno0, eno1 and eno2 an IP address. You can assign another name to a MAC-address by placing a config file i say /etc/udev/rules.d/10-persistent-net-rules
. Make a line for each interface with the desired MAC-address en device name (eno0
):
SUBSYSTEM=="net", ACTION=="add", DRIVERS=="?*", ATTRaddress=="00:11:22:33:44:55", ATTRdev_id=="0x0", ATTRtype=="1", KERNEL=="eno*", NAME="eno0"
Thanks! Would something like this work? pastebin.com/Ltwg6BRV
– AdrianP.
Aug 13 '17 at 14:57
@AdrianP. that would be overkill. you only needudev
rules for the actual physical interfaces,eno0
,eno1
, andeno2
. Thebr*
,virbr*
,docker*
etc interfaces are all based on (and defined relative to) the actual NICs (and are generally assigned to the correct parent interface when created by docker or whatever). Also remember that most or all of those bridge interfaces are created dynamically when a container is created and may not be given the same name the next time an instance of that container is started. a udev rule to rename it will just confuse docker.
– cas
Aug 14 '17 at 5:04
add a comment |
Your Answer
StackExchange.ready(function()
var channelOptions =
tags: "".split(" "),
id: "106"
;
initTagRenderer("".split(" "), "".split(" "), channelOptions);
StackExchange.using("externalEditor", function()
// Have to fire editor after snippets, if snippets enabled
if (StackExchange.settings.snippets.snippetsEnabled)
StackExchange.using("snippets", function()
createEditor();
);
else
createEditor();
);
function createEditor()
StackExchange.prepareEditor(
heartbeatType: 'answer',
autoActivateHeartbeat: false,
convertImagesToLinks: false,
noModals: true,
showLowRepImageUploadWarning: true,
reputationToPostImages: null,
bindNavPrevention: true,
postfix: "",
imageUploader:
brandingHtml: "Powered by u003ca class="icon-imgur-white" href="https://imgur.com/"u003eu003c/au003e",
contentPolicyHtml: "User contributions licensed under u003ca href="https://creativecommons.org/licenses/by-sa/3.0/"u003ecc by-sa 3.0 with attribution requiredu003c/au003e u003ca href="https://stackoverflow.com/legal/content-policy"u003e(content policy)u003c/au003e",
allowUrls: true
,
onDemand: true,
discardSelector: ".discard-answer"
,immediatelyShowMarkdownHelp:true
);
);
Sign up or log in
StackExchange.ready(function ()
StackExchange.helpers.onClickDraftSave('#login-link');
);
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
StackExchange.ready(
function ()
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2funix.stackexchange.com%2fquestions%2f385846%2fhow-can-i-change-the-priority-of-network-interfaces%23new-answer', 'question_page');
);
Post as a guest
Required, but never shown
1 Answer
1
active
oldest
votes
1 Answer
1
active
oldest
votes
active
oldest
votes
active
oldest
votes
Renumber the interface numbers by MAC-address. It looks like something goes wrong when givining eno0, eno1 and eno2 an IP address. You can assign another name to a MAC-address by placing a config file i say /etc/udev/rules.d/10-persistent-net-rules
. Make a line for each interface with the desired MAC-address en device name (eno0
):
SUBSYSTEM=="net", ACTION=="add", DRIVERS=="?*", ATTRaddress=="00:11:22:33:44:55", ATTRdev_id=="0x0", ATTRtype=="1", KERNEL=="eno*", NAME="eno0"
Thanks! Would something like this work? pastebin.com/Ltwg6BRV
– AdrianP.
Aug 13 '17 at 14:57
@AdrianP. that would be overkill. you only needudev
rules for the actual physical interfaces,eno0
,eno1
, andeno2
. Thebr*
,virbr*
,docker*
etc interfaces are all based on (and defined relative to) the actual NICs (and are generally assigned to the correct parent interface when created by docker or whatever). Also remember that most or all of those bridge interfaces are created dynamically when a container is created and may not be given the same name the next time an instance of that container is started. a udev rule to rename it will just confuse docker.
– cas
Aug 14 '17 at 5:04
add a comment |
Renumber the interface numbers by MAC-address. It looks like something goes wrong when givining eno0, eno1 and eno2 an IP address. You can assign another name to a MAC-address by placing a config file i say /etc/udev/rules.d/10-persistent-net-rules
. Make a line for each interface with the desired MAC-address en device name (eno0
):
SUBSYSTEM=="net", ACTION=="add", DRIVERS=="?*", ATTRaddress=="00:11:22:33:44:55", ATTRdev_id=="0x0", ATTRtype=="1", KERNEL=="eno*", NAME="eno0"
Thanks! Would something like this work? pastebin.com/Ltwg6BRV
– AdrianP.
Aug 13 '17 at 14:57
@AdrianP. that would be overkill. you only needudev
rules for the actual physical interfaces,eno0
,eno1
, andeno2
. Thebr*
,virbr*
,docker*
etc interfaces are all based on (and defined relative to) the actual NICs (and are generally assigned to the correct parent interface when created by docker or whatever). Also remember that most or all of those bridge interfaces are created dynamically when a container is created and may not be given the same name the next time an instance of that container is started. a udev rule to rename it will just confuse docker.
– cas
Aug 14 '17 at 5:04
add a comment |
Renumber the interface numbers by MAC-address. It looks like something goes wrong when givining eno0, eno1 and eno2 an IP address. You can assign another name to a MAC-address by placing a config file i say /etc/udev/rules.d/10-persistent-net-rules
. Make a line for each interface with the desired MAC-address en device name (eno0
):
SUBSYSTEM=="net", ACTION=="add", DRIVERS=="?*", ATTRaddress=="00:11:22:33:44:55", ATTRdev_id=="0x0", ATTRtype=="1", KERNEL=="eno*", NAME="eno0"
Renumber the interface numbers by MAC-address. It looks like something goes wrong when givining eno0, eno1 and eno2 an IP address. You can assign another name to a MAC-address by placing a config file i say /etc/udev/rules.d/10-persistent-net-rules
. Make a line for each interface with the desired MAC-address en device name (eno0
):
SUBSYSTEM=="net", ACTION=="add", DRIVERS=="?*", ATTRaddress=="00:11:22:33:44:55", ATTRdev_id=="0x0", ATTRtype=="1", KERNEL=="eno*", NAME="eno0"
answered Aug 13 '17 at 14:51
hschouhschou
2,206612
2,206612
Thanks! Would something like this work? pastebin.com/Ltwg6BRV
– AdrianP.
Aug 13 '17 at 14:57
@AdrianP. that would be overkill. you only needudev
rules for the actual physical interfaces,eno0
,eno1
, andeno2
. Thebr*
,virbr*
,docker*
etc interfaces are all based on (and defined relative to) the actual NICs (and are generally assigned to the correct parent interface when created by docker or whatever). Also remember that most or all of those bridge interfaces are created dynamically when a container is created and may not be given the same name the next time an instance of that container is started. a udev rule to rename it will just confuse docker.
– cas
Aug 14 '17 at 5:04
add a comment |
Thanks! Would something like this work? pastebin.com/Ltwg6BRV
– AdrianP.
Aug 13 '17 at 14:57
@AdrianP. that would be overkill. you only needudev
rules for the actual physical interfaces,eno0
,eno1
, andeno2
. Thebr*
,virbr*
,docker*
etc interfaces are all based on (and defined relative to) the actual NICs (and are generally assigned to the correct parent interface when created by docker or whatever). Also remember that most or all of those bridge interfaces are created dynamically when a container is created and may not be given the same name the next time an instance of that container is started. a udev rule to rename it will just confuse docker.
– cas
Aug 14 '17 at 5:04
Thanks! Would something like this work? pastebin.com/Ltwg6BRV
– AdrianP.
Aug 13 '17 at 14:57
Thanks! Would something like this work? pastebin.com/Ltwg6BRV
– AdrianP.
Aug 13 '17 at 14:57
@AdrianP. that would be overkill. you only need
udev
rules for the actual physical interfaces, eno0
, eno1
, and eno2
. The br*
, virbr*
, docker*
etc interfaces are all based on (and defined relative to) the actual NICs (and are generally assigned to the correct parent interface when created by docker or whatever). Also remember that most or all of those bridge interfaces are created dynamically when a container is created and may not be given the same name the next time an instance of that container is started. a udev rule to rename it will just confuse docker.– cas
Aug 14 '17 at 5:04
@AdrianP. that would be overkill. you only need
udev
rules for the actual physical interfaces, eno0
, eno1
, and eno2
. The br*
, virbr*
, docker*
etc interfaces are all based on (and defined relative to) the actual NICs (and are generally assigned to the correct parent interface when created by docker or whatever). Also remember that most or all of those bridge interfaces are created dynamically when a container is created and may not be given the same name the next time an instance of that container is started. a udev rule to rename it will just confuse docker.– cas
Aug 14 '17 at 5:04
add a comment |
Thanks for contributing an answer to Unix & Linux Stack Exchange!
- Please be sure to answer the question. Provide details and share your research!
But avoid …
- Asking for help, clarification, or responding to other answers.
- Making statements based on opinion; back them up with references or personal experience.
To learn more, see our tips on writing great answers.
Sign up or log in
StackExchange.ready(function ()
StackExchange.helpers.onClickDraftSave('#login-link');
);
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
StackExchange.ready(
function ()
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2funix.stackexchange.com%2fquestions%2f385846%2fhow-can-i-change-the-priority-of-network-interfaces%23new-answer', 'question_page');
);
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function ()
StackExchange.helpers.onClickDraftSave('#login-link');
);
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function ()
StackExchange.helpers.onClickDraftSave('#login-link');
);
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function ()
StackExchange.helpers.onClickDraftSave('#login-link');
);
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Can you add the content of
/etc/sysconfig/network-scripts/ifcfg-eno2
? In particular, that should have a lineONBOOT=
which might be set tono
for you?– Ulrich Schwarz
Aug 13 '17 at 14:39
Was just looking at it, I edited the post and put it here pastebin.com/XJ9rhak8 looks like onboot is on.
– AdrianP.
Aug 13 '17 at 14:42