PDA

View Full Version : [kubuntu] Help me set a static network on pan0?



kooldino
September 1st, 2009, 03:29 PM
I currently have a single network device in the machine, and it is listed as pan0. I'm not sure why it's listed as such, as I'd prefer it to be eth0, but whatever.

I need it to be set to a specific static IP, so I edited /etc/network/interfaces and added the following lines:

iface pan0 inet static
address 192.168.161.50

So my interfaces file now appears as such:

auto lo
#blah
iface lo inet loopback
#blah
#blah
#blah
#blah
iface pan0 inet static
address 192.168.161.50

Upon reboot, when I do an ifconfig -a, the interface is listed without an IP address.

Help?

Krupski
September 1st, 2009, 03:41 PM
I currently have a single network device in the machine, and it is listed as pan0. I'm not sure why it's listed as such, as I'd prefer it to be eth0, but whatever.

I need it to be set to a specific static IP, so I edited /etc/network/interfaces and added the following lines:

iface pan0 inet static
address 192.168.161.50

So my interfaces file now appears as such:

auto lo
#blah
iface lo inet loopback
#blah
#blah
#blah
#blah
iface pan0 inet static
address 192.168.161.50

Upon reboot, when I do an ifconfig -a, the interface is listed without an IP address.

Help?

Try this: Edit "/etc/network/interfaces"



iface eth0 inet static
address 192.168.161.50
netmask 255.255.255.0
gateway 192.168.161.1 <-- whatever - your router's address



Then, go into "/etc/udev/rules.d"

Edit the file "70-persistent-net.rules"

Remove any references to an ethernet interface (see example below - remove anything that looks like what's in blue) - leave only the comment header.



# This file was automatically generated by the /lib/udev/write_net_rules
# program, run by the persistent-net-generator.rules rules file.
#
# You can modify it, as long as you keep each rule on a single
# line, and change only the value of the NAME= key.

# PCI device 0x8086:0x10de (e1000e)
SUBSYSTEM=="net", ACTION=="add", DRIVERS=="?*", ATTR{address}=="00:00:00:00:00:00", ATTR{type}=="1", KERNEL=="eth*", NAME="eth0"


Then, reboot. You should come up with a working network interface, called "eth0" and with the static IP address you want.

Good luck!

-- Roger

kooldino
September 1st, 2009, 08:49 PM
Did exactly as you said, but it came up as pan0 with no IP. :(

Krupski
September 2nd, 2009, 12:25 AM
Did exactly as you said, but it came up as pan0 with no IP. :(

Well, "PAN" is "Personal Area Network"... a Bluetooth networking protocol.

It seems as if your network card isn't being found and a Bluetooth adapter is being setup as your "network".

Is your network card built into the motherboard, or is it a separate card?

Can you tell me the model number (or better, the chipset) of the network card?

If it's built into the motherboard, what brand and model motherboard do you have?

Which version of Ubuntu / Linux / Whatever are you using?

What is your Internet connection? A cable modem or DSL modem? Do you have a router?

The more info I have, the better chance I have of figuring out what your problem is.

Let me know.

-- Roger

kooldino
September 2nd, 2009, 10:39 PM
Well, "PAN" is "Personal Area Network"... a Bluetooth networking protocol.

It seems as if your network card isn't being found and a Bluetooth adapter is being setup as your "network".

Is your network card built into the motherboard, or is it a separate card?

Separate card. And the PC is about 7 years old - definitely doesn't have bluetooth built in.

I should note that the "70-persistent-net.rules" file is still empty with the exception of the comment header.


Can you tell me the model number (or better, the chipset) of the network card?

Here are all the markings I can find on the card:
On the back, there's a CNet stamp.

On what appears to be the main chip...
Davicom DM9102AF
0216S
MF0SH6

Then on another chip...
GTS
FC-515LS
2K221C2



Which version of Ubuntu / Linux / Whatever are you using?

The latest and greatest Kubuntu (9.04) running KDE4.


What is your Internet connection? A cable modem or DSL modem? Do you have a router?

Well, this computer isn't going to be running on the net, it's only going to be communicating with a single other machine on a private network.

Thanks in advance!

Iowan
September 2nd, 2009, 11:13 PM
Post results of lshw -C network.

Krupski
September 3rd, 2009, 02:06 AM
On what appears to be the main chip...
Davicom DM9102AF


That is a 10/100 network card with a PCI interface.

A Google search shows that a lot of people have problem with that card in Windows and Linux.

I would suggest zipping out to your local electronics store and buy yourself a newer network card. A 10/100 card should be dirt cheap (probably $10 to $20).

But first, check out the Ubuntu hardware comparability list to be sure the card you buy is supported (most are).

Here's the HCL for network cards -> LINK (https://wiki.ubuntu.com/HardwareSupportComponentsWiredNetworkCards)

Good luck.

-- Roger

kooldino
September 3rd, 2009, 02:15 PM
Post results of lshw -C network.

Will do, as soon as I get this card plugged back in.

kooldino
September 3rd, 2009, 02:17 PM
That is a 10/100 network card with a PCI interface.

A Google search shows that a lot of people have problem with that card in Windows and Linux.

I would suggest zipping out to your local electronics store and buy yourself a newer network card. A 10/100 card should be dirt cheap (probably $10 to $20).

But first, check out the Ubuntu hardware comparability list to be sure the card you buy is supported (most are).

Here's the HCL for network cards -> LINK (https://wiki.ubuntu.com/HardwareSupportComponentsWiredNetworkCards)

Good luck.

-- Roger

Well, I have an extra card lying around that's in that list (sort of).

It's a Netgear FA311 Rev-D2. It looks like the numbers on the main chip are:
VS242ADC4
DP83816AVNG

Give it a shot?

Krupski
September 6th, 2009, 05:50 AM
Well, I have an extra card lying around that's in that list (sort of).

It's a Netgear FA311 Rev-D2. It looks like the numbers on the main chip are:
VS242ADC4
DP83816AVNG

Give it a shot?

Yes... in fact I *KNOW* that card will work because I have one which I used a while back to install 8.10 on a machine with an Intel 82567 NIC (8.10 doesn't have the driver built in for that NIC).

So, I use the Netgear card, install 8.10, then download the Intel driver source, compile it and then remove the Netgear card.

-- Roger

(by the way, if you had clicked on the link I gave you, you would have seen that card listed as "Works -yes" and "Autodetected -yes").

kooldino
September 10th, 2009, 02:05 PM
Yes... in fact I *KNOW* that card will work because I have one which I used a while back to install 8.10 on a machine with an Intel 82567 NIC (8.10 doesn't have the driver built in for that NIC).

So, I use the Netgear card, install 8.10, then download the Intel driver source, compile it and then remove the Netgear card.

-- Roger

(by the way, if you had clicked on the link I gave you, you would have seen that card listed as "Works -yes" and "Autodetected -yes").

Yep, I saw the card in the list, but I didn't know if mine was different because it was the Rev D2.

kooldino
September 10th, 2009, 09:15 PM
Ok, WTH, I installed the Netgear card and I'm still getting the same issue.

For starters, it doesn't auto up, I have to do it manually. Then, when it does come up, rather than taking the IP and network info I specified in /etc/network/interfaces, it has some hexadecimal IPV6 address.

Is there some kind of conlfict with KDE here or something?

kooldino
September 11th, 2009, 06:55 PM
Bump

kooldino
September 14th, 2009, 08:38 PM
Anyone?

Iowan
September 14th, 2009, 10:44 PM
Results of ifconfig -a? Also, what is in /etc/network/interfaces?

p1t0u
September 15th, 2009, 02:37 PM
Anyone?

You are missing auto pan0 in your /etc/network/interfaces to tell the system to bring this
interface up automatically.

mo0nykit
September 17th, 2009, 02:11 PM
@kooldino
I take it that you want to use eth0 (ethernet) instead of pan0 (bluetooth, Personal Area Network). Try looking at your /etc/udev/rules.d/70-persistent-net.rules file. I think it would help if you had a line similar to this

# PCI device 0x8086:0x10de (e1000e)
SUBSYSTEM=="net", ACTION=="add", DRIVERS=="?*", ATTR{address}=="00:00:00:00:00:00", ATTR{type}=="1", KERNEL=="eth*", NAME="eth0" I'm not sure what most of the fields and codes mean (though I somehow understand ATTR{address}= and NAME=)
Since your rules file is empty as you had mentioned, I don't know where you can copy and paste some of the fields. Try looking into man udev.

I ran into a similar problem. It had something to do with the renaming of eth1 to eth2 just because I replaced my NIC with a different one (which means it had a different MAC address). And this udev rules file was where I got it fixed.

I hope this helps :)

kooldino
September 18th, 2009, 09:56 PM
Ok, just wanted to post some files up here for you guys. These are all the most current:

70-persistent-net.rules.txt -


# This file maintains persistent names for network interfaces.
# See udev(7) for syntax.
#
# Entries are automatically added by the 75-persistent-net-generator.rules
# file; however you are also free to add your own entries.

# PCI device 0x100b:0x0020 (natsemi)
SUBSYSTEM=="net", ACTION=="add", DRIVERS=="?*", ATTR{address}=="00:09:5b:1f:dc:56", ATTR{type}=="1", KERNEL=="eth*", NAME="eth0"


/etc/network/interfaces -


auto lo
iface lo inet loopback

iface eth0 inet static
address 192.168.161.50
netmask 255.255.255.248
network 192.168.161.48
broadcast 192.168.161.55
gateway 192.168.161.49



Output of ifconfig -a after a fresh bootup -


eth0 Link encap:Ethernet HWaddr 00:09:5b:1f:dc:56
BROADCAST MULTICAST MTU:1500 Metric:1
RX packets:0 errors:0 dropped:0 overruns:0 frame:0
TX packets:0 errors:0 dropped:0 overruns:0 carrier:0
collisions:0 txqueuelen:1000
RX bytes:0 (0.0 B) TX bytes:0 (0.0 B)
Interrupt:21 Base address:0x2000

lo Link encap:Local Loopback
inet addr:127.0.0.1 Mask:255.0.0.0
inet6 addr: ::1/128 Scope:Host
UP LOOPBACK RUNNING MTU:16436 Metric:1
RX packets:60 errors:0 dropped:0 overruns:0 frame:0
TX packets:60 errors:0 dropped:0 overruns:0 carrier:0
collisions:0 txqueuelen:0
RX bytes:3936 (3.9 KB) TX bytes:3936 (3.9 KB)

pan0 Link encap:Ethernet HWaddr f2:ad:f6:89:81:20
BROADCAST MULTICAST MTU:1500 Metric:1
RX packets:0 errors:0 dropped:0 overruns:0 frame:0
TX packets:0 errors:0 dropped:0 overruns:0 carrier:0
collisions:0 txqueuelen:0
RX bytes:0 (0.0 B) TX bytes:0 (0.0 B)




Output of ifconfig -a after manually using ifconfig to assign an IP address to eth0 -


eth0 Link encap:Ethernet HWaddr 00:09:5b:1f:dc:56
inet addr:192.168.161.50 Bcast:192.168.161.255 Mask:255.255.255.0
inet6 addr: fe80::209:5bff:fe1f:dc56/64 Scope:Link
UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1
RX packets:0 errors:0 dropped:0 overruns:0 frame:0
TX packets:17 errors:0 dropped:0 overruns:0 carrier:0
collisions:0 txqueuelen:1000
RX bytes:0 (0.0 B) TX bytes:3201 (3.2 KB)
Interrupt:21

lo Link encap:Local Loopback
inet addr:127.0.0.1 Mask:255.0.0.0
inet6 addr: ::1/128 Scope:Host
UP LOOPBACK RUNNING MTU:16436 Metric:1
RX packets:276 errors:0 dropped:0 overruns:0 frame:0
TX packets:276 errors:0 dropped:0 overruns:0 carrier:0
collisions:0 txqueuelen:0
RX bytes:21208 (21.2 KB) TX bytes:21208 (21.2 KB)

pan0 Link encap:Ethernet HWaddr 6a:18:8d:19:b9:e1
BROADCAST MULTICAST MTU:1500 Metric:1
RX packets:0 errors:0 dropped:0 overruns:0 frame:0
TX packets:0 errors:0 dropped:0 overruns:0 carrier:0
collisions:0 txqueuelen:0
RX bytes:0 (0.0 B) TX bytes:0 (0.0 B)

Iowan
September 21st, 2009, 12:03 AM
Add "auto eth0" to /etc/network/interfaces and restart networking (/etc/init.d/networking restart).