View previous topic :: View next topic |
Author |
Message |
sk3l Tux's lil' helper
Joined: 14 Jul 2012 Posts: 78 Location: CT USA
|
Posted: Tue Jan 15, 2013 8:34 pm Post subject: How Is It Possible My Wireless NIC Is Assigned 2 IP's? |
|
|
I have a TPILINK external USB wireless adapter hooked up to my desktop. It is the only active adapter. I'm using Network Manager to control all of my net interfaces. I have set up a connection for the TPLINK to my home wireless network that utilizes DHCP. I provision IPs for all the machines on my network using static DHCP reservations in my router, and I have one set up for my TPLINK.
HOWEVER,
- In the client map of my router's admin page, I see another IP associated with my TPLINK other than than the one I have set up for the TLINK via DHCP reservation.
- I can ping this ghost address from other machines in my network.
- Network Manager doesn't show the ghost address.
- ifconfig doesn't show it either.
- Net.lo is the only manual interface, and everything in /etc/conf.d/net is commented out.
What the heck happened??
-sk3l |
|
Back to top |
|
|
_______0 Guru
Joined: 15 Oct 2012 Posts: 521
|
Posted: Wed Jan 16, 2013 1:50 pm Post subject: |
|
|
NICs do store more than one IP address. I am not an expert on this matters but I discovered this once I needed to change an IP when the NIC already had one. Upon deleting it ifconfig did NOT show an empty ip address but the old ip.
I assumed assigning a new IP address would 'overwrite' the old IP, effectively destroying it.
They must be stored somewhere. To completely cleanse ALL nic info unload the module and re-load it. This way you can start fresh without hidden stuff laying around. |
|
Back to top |
|
|
sk3l Tux's lil' helper
Joined: 14 Jul 2012 Posts: 78 Location: CT USA
|
Posted: Wed Jan 16, 2013 3:42 pm Post subject: |
|
|
_______0 wrote: | NICs do store more than one IP address. I am not an expert on this matters but I discovered this once I needed to change an IP when the NIC already had one. Upon deleting it ifconfig did NOT show an empty ip address but the old ip.
I assumed assigning a new IP address would 'overwrite' the old IP, effectively destroying it.
They must be stored somewhere. To completely cleanse ALL nic info unload the module and re-load it. This way you can start fresh without hidden stuff laying around. |
Sorry, I'm not sure what you mean by "unloading" the module. Do you mean "ifconfig <NIC> down" then "ifconfig <NIC> up"? Do you mean resetting the NIC's ID in udev and letting it get rediscovered? Surely you don't mean reloading a kernel module.
This condition has persisted across reboots, unplugging the adapter, removing & re-entering the NetworkManager profile, etc. |
|
Back to top |
|
|
krinn Watchman
Joined: 02 May 2003 Posts: 7470
|
Posted: Wed Jan 16, 2013 4:11 pm Post subject: |
|
|
many usb wireless allow the adapter to work as an access point (in order for other wireless to "plug" with it and access the network the device is connect with).
so if your adapter is an AP, it could have two IP. |
|
Back to top |
|
|
sk3l Tux's lil' helper
Joined: 14 Jul 2012 Posts: 78 Location: CT USA
|
Posted: Wed Jan 16, 2013 6:51 pm Post subject: |
|
|
krinn wrote: | many usb wireless allow the adapter to work as an access point (in order for other wireless to "plug" with it and access the network the device is connect with).
so if your adapter is an AP, it could have two IP. |
That is certainly so. However, I only saw this phenomenon happen once I switched to Network Manager. I ran wpa_supplicant, and wicd, and this did not occur with those tools. It's almost like another service is running in parallel with NM and obtaining that IP via DHCP (w/o static reservation). Wicd has been unmerged, and I don't understand how wpa_supplicant could do anything if there are no manual interface defined (i.e. net.wifi0).
Just for my edification, is it true that NM is merely a front end tool that relies on dhcpcd and wpa_supplicant on the back end? |
|
Back to top |
|
|
Mad Merlin Veteran
Joined: 09 May 2005 Posts: 1155
|
|
Back to top |
|
|
sk3l Tux's lil' helper
Joined: 14 Jul 2012 Posts: 78 Location: CT USA
|
Posted: Fri Jan 18, 2013 11:59 am Post subject: |
|
|
Awesome! I didn't know their was such a tool. Sure enough, there is the "alias" IP. Now that I can see it, how do I stop the NIC from requesting it?
Code: |
CHEETAH ~ # ip addr
1: lo: <LOOPBACK,UP,LOWER_UP> mtu 16436 qdisc noqueue state UNKNOWN
link/loopback 00:00:00:00:00:00 brd 00:00:00:00:00:00
inet 127.0.0.1/8 scope host lo
inet6 ::1/128 scope host
valid_lft forever preferred_lft forever
2: eth_realtek: <NO-CARRIER,BROADCAST,MULTICAST,UP> mtu 1500 qdisc pfifo_fast state DOWN qlen 1000
link/ether 00:1f:bc:0d:c9:9b brd ff:ff:ff:ff:ff:ff
3: sit0: <NOARP> mtu 1480 qdisc noop state DOWN
link/sit 0.0.0.0 brd 0.0.0.0
4: wlan_tplink: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc mq state UP qlen 1000
link/ether 64:70:02:17:24:60 brd ff:ff:ff:ff:ff:ff
inet 192.168.1.15/24 brd 192.168.1.255 scope global wlan_tplink
inet 192.168.1.115/24 brd 192.168.1.255 scope global secondary wlan_tplink
inet6 fe80::6670:2ff:fe17:2460/64 scope link
valid_lft forever preferred_lft forever
5: virbr0: <NO-CARRIER,BROADCAST,MULTICAST,UP> mtu 1500 qdisc noqueue state DOWN
link/ether 52:54:00:1d:d8:3f brd ff:ff:ff:ff:ff:ff
inet 192.168.100.1/24 brd 192.168.100.255 scope global virbr0
6: virbr0-nic: <BROADCAST,MULTICAST> mtu 1500 qdisc pfifo_fast master virbr0 state DOWN qlen 500
link/ether 52:54:00:1d:d8:3f brd ff:ff:ff:ff:ff:ff
|
|
|
Back to top |
|
|
sk3l Tux's lil' helper
Joined: 14 Jul 2012 Posts: 78 Location: CT USA
|
Posted: Fri Jan 18, 2013 12:15 pm Post subject: |
|
|
So, I decided to look at some of the NetworkManager conf files in /etc, and lo and behold, this is what I found in the IPv4 Adress section:
Code: |
[ipv4]
method=auto
dns=192.168.1.1;
#addresses1=192.168.1.115;24;192.168.1.1;
dhcp-client-id=CHEETAH
may-fail=false |
I added the hash to comment out the secondary address, and boom, the NIC now has only the address I set up using DHCP. Cool.
Note that when I was looking at the network config in the NM GUI, I never saw the entry for the 192.168.1.115 static address, so this seems to be some type of bug. |
|
Back to top |
|
|
|