Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
Something has renamed eth0 to some random sequence!
View unanswered posts
View posts from last 24 hours

 
Reply to topic    Gentoo Forums Forum Index Networking & Security
View previous topic :: View next topic  
Author Message
kbzium
Tux's lil' helper
Tux's lil' helper


Joined: 31 Jul 2012
Posts: 146

PostPosted: Sat Apr 13, 2013 3:19 pm    Post subject: Something has renamed eth0 to some random sequence! Reply with quote

Hello,

my internet connection works but the thing is I'd like to have ip assigned, not run dhcp all over again (it gives me same address every time anyways... and it takes up to 15 seconds on boot!) output of ifconfig -a

Code:
kboom-wst kboom # ifconfig -a
dummy0: flags=195<UP,BROADCAST,RUNNING,NOARP>  mtu 1500
        inet6 fe80::4491:d9ff:fe18:d182  prefixlen 64  scopeid 0x20<link>
        ether 46:91:d9:18:d1:82  txqueuelen 0  (Ethernet)
        RX packets 0  bytes 0 (0.0 B)
        RX errors 0  dropped 0  overruns 0  frame 0
        TX packets 33  bytes 11370 (11.1 KiB)
        TX errors 0  dropped 0 overruns 0  carrier 0  collisions 0

enp5s0: flags=4163<UP,BROADCAST,RUNNING,MULTICAST>  mtu 1500
        inet 192.168.1.167  netmask 255.255.255.0  broadcast 192.168.1.255
        inet6 fe80::be5f:f4ff:fe37:f472  prefixlen 64  scopeid 0x20<link>
        ether bc:5f:f4:37:f4:72  txqueuelen 1000  (Ethernet)
        RX packets 19195  bytes 17232743 (16.4 MiB)
        RX errors 0  dropped 1  overruns 0  frame 0
        TX packets 14646  bytes 2397829 (2.2 MiB)
        TX errors 0  dropped 0 overruns 0  carrier 0  collisions 0

lo: flags=73<UP,LOOPBACK,RUNNING>  mtu 65536
        inet 127.0.0.1  netmask 255.0.0.0
        inet6 ::1  prefixlen 128  scopeid 0x10<host>
        loop  txqueuelen 0  (Local Loopback)
        RX packets 1674  bytes 121039 (118.2 KiB)
        RX errors 0  dropped 0  overruns 0  frame 0
        TX packets 1674  bytes 121039 (118.2 KiB)
        TX errors 0  dropped 0 overruns 0  carrier 0  collisions 0


Do you happen to know what did this with my eth0? I suppose it would suffice to put
Code:
# This blank configuration will automatically use DHCP for any net.*
# scripts in /etc/init.d.  To create a more complete configuration,
# please review /usr/share/doc/openrc*/net.example* and save your configuration
# in /etc/conf.d/net (this file :]!).
config_eth0 = "192.168.1.167 netmask 255.255.255.0 brd 192.168.1.254"
#routes_eth0="default via 192.168.0.1"
#config_eth0="dhcp"
dns_domain_lo="WORKGROUP"

into /etc/init.d/net then. But first, there must be eth0 interface...
Back to top
View user's profile Send private message
ulenrich
Veteran
Veteran


Joined: 10 Oct 2010
Posts: 1239

PostPosted: Sat Apr 13, 2013 3:52 pm    Post subject: Reply with quote

ln -s /dev/null /etc/udev/rules.d/90-network.rules

... read the news!
_________________
fun2gen2
Back to top
View user's profile Send private message
NeddySeagoon
Administrator
Administrator


Joined: 05 Jul 2003
Posts: 33209
Location: 56N 3W

PostPosted: Sat Apr 13, 2013 3:54 pm    Post subject: Reply with quote

kbzium,

Welcome to udev-200

You are suffering from 'permanent' interface naming. You missed the warning from the udev update and the news item from the Gentoo devs.

Your enp5s0 interface is based on the PCI slot and function number. If the interface is on the motherboard, it won't change again ... at least, not until udev changes again.
If the interface is a plug in card, it will change if you move the card to a different slot.
_________________
Regards,

NeddySeagoon

Computer users fall into two groups:-
those that do backups
those that have never had a hard drive fail.
Back to top
View user's profile Send private message
kbzium
Tux's lil' helper
Tux's lil' helper


Joined: 31 Jul 2012
Posts: 146

PostPosted: Sat Apr 13, 2013 4:03 pm    Post subject: Reply with quote

I see. But how to make this:
Code:
config_enp5s0 = "192.168.1.167 netmask 255.255.255.0 brd 192.168.1.254"

work? It doesn't recognize this interface.
Back to top
View user's profile Send private message
mv
Advocate
Advocate


Joined: 20 Apr 2005
Posts: 4635

PostPosted: Sat Apr 13, 2013 4:12 pm    Post subject: Reply with quote

kbzium wrote:
It doesn't recognize this interface.

I bet you forgot to rename the /etc/init.d/net.eth0 symlink.
Back to top
View user's profile Send private message
albright
Advocate
Advocate


Joined: 16 Nov 2003
Posts: 2170
Location: Near Toronto

PostPosted: Sat Apr 13, 2013 4:19 pm    Post subject: Reply with quote

Quote:
it won't change again ... at least, not until udev changes again.


:lol:
_________________
.... there is nothing - absolutely nothing - half so much worth
doing as simply messing about with Linux ...
(apologies to Kenneth Graeme)
Back to top
View user's profile Send private message
kbzium
Tux's lil' helper
Tux's lil' helper


Joined: 31 Jul 2012
Posts: 146

PostPosted: Sat Apr 13, 2013 4:42 pm    Post subject: Reply with quote

mv wrote:
kbzium wrote:
It doesn't recognize this interface.

I bet you forgot to rename the /etc/init.d/net.eth0 symlink.


You're right :lol: . Sorry :oops:
Back to top
View user's profile Send private message
krinn
Advocate
Advocate


Joined: 02 May 2003
Posts: 4685

PostPosted: Sat Apr 13, 2013 9:47 pm    Post subject: Reply with quote

Quote:
it won't change again ... at least, not until udev changes again.

:lol:
Back to top
View user's profile Send private message
direwolf
Tux's lil' helper
Tux's lil' helper


Joined: 11 Jun 2003
Posts: 91
Location: Richmond, VA

PostPosted: Sun Apr 14, 2013 4:39 pm    Post subject: Reply with quote

krinn wrote:
Quote:
it won't change again ... at least, not until udev changes again.

:lol:


Right. From http://blog.flameeyes.eu/2013/03/predictable-persistently-non-mnemonic-names :

Quote:

Speaking about which, one of the things that appears obvious even from Lennart’s comment to the previous post, is that there is no real assurance that the names are set in stone — he says that an udev upgrade won’t change them, but I guess most people would be sceptic, remembering the track record that udev and systemd has had over the past few months alone. In this situation my personal, informed opinion is that all this work on “predictable” names is a huge waste of time for almost everybody.

...

All in all, I think this is just an useless nice trick, that will only cause more headaches than it can possibly solve. Bahumbug!

_________________
========================================================
"Somebody has to do something, and it's just incredibly pathetic that it has to be us."
- Jerry Garcia
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic    Gentoo Forums Forum Index Networking & Security All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum