Skip to contentSkip to conversation

udev and network devices

DISCUSSION Michel Rode 3 participants 4 messages Nov 15, 2008 – Nov 16, 2008

lore
Share & tools
lore
#0 lore raw

Hello,

i tried to rename my network device - this works, but the symlink are not exists.

This is my rule:
SUBSYSTEM=="net", ACTION=="add", DRIVERS=="?*", ATTR{address}=="00:16:6f:b5:8b:76", ATTR{type}=="1", KERNEL=="eth*", NAME="wlan0", SYMLINK+="eth1"

Now i have the idea, that it could not work because there are not such device in /dev - is it true ?

Thanks, Michel

#1 lore raw
Quoted 6 lines · Michel Rode

i tried to rename my network device - this works, but the symlink are not exists.

This is my rule:
SUBSYSTEM="net", ACTION="add", DRIVERS="?*", ATTR{address}="00:16:6f:b5:8b:76", ATTR{type}="1", KERNEL="eth*", NAME="wlan0", SYMLINK+="eth1"

Now i have the idea, that it could not work because there are not such device in /dev - is it true ?

Right, network interfaces do not have any device nodes. The interface names exist only in the kernel. There is only one name per interface and nothing similar to the concept of symlinks.

Kay

#2 lore raw
In reply to Michel Rode
Quoted 11 lines · Kay Sievers
Quoted 6 lines · Michel Rode

i tried to rename my network device - this works, but the symlink are not exists.

This is my rule:
SUBSYSTEM=="net", ACTION=="add", DRIVERS=="?*", ATTR{address}=="00:16:6f:b5:8b:76", ATTR{type}=="1", KERNEL=="eth*", NAME="wlan0", SYMLINK+="eth1"

Now i have the idea, that it could not work because there are not such device in /dev - is it true ?

Right, network interfaces do not have any device nodes. The interface names exist only in the kernel. There is only one name per interface and nothing similar to the concept of symlinks.

What about aliased interfaces? Or are those really considered separate devices?

Matt

Signature · 7 lines
Matthew Dharm                              Home: [email protected] 
Maintainer, Linux USB Mass Storage Driver

C:  Like the Furby?
DP: He gives me the creeps.  Think the SPCA will take him?
					-- Cobb and Dust Puppy
User Friendly, 1/2/1999
#3 lore raw
In reply to Michel Rode
Quoted 7 lines · Matthew Dharm
Quoted 6 lines · Kay Sievers
Quoted 5 lines · Michel Rode

i tried to rename my network device - this works, but the symlink are not exists.

This is my rule:
SUBSYSTEM="net", ACTION="add", DRIVERS="?*", ATTR{address}="00:16:6f:b5:8b:76", ATTR{type}="1", KERNEL="eth*", NAME="wlan0", SYMLINK+="eth1"

Quoted 8 lines
Quoted 5 lines
Quoted 1 line

Now i have the idea, that it could not work because there are not such device in /dev - is it true ?

Right, network interfaces do not have any device nodes. The interface names exist only in the kernel. There is only one name per interface and nothing similar to the concept of symlinks.

What about aliased interfaces? Or are those really considered separate devices?

It's a bit different. Aliases carry their own information and state, they are usually used to assign different IP addresses to an interface. Symlinks to device nodes have no further meaning as their name, and just point to the "real" device, without any own properties.

Kay