FreeBSD only assigning inet6 addresses to ndis0

Reply

Join Date: Apr 2004
Posts: 113
Reputation: liliafan is on a distinguished road 
Solved Threads: 2
liliafan's Avatar
liliafan liliafan is offline Offline
Junior Poster

FreeBSD only assigning inet6 addresses to ndis0

 
0
  #1
May 23rd, 2004
Hi

I managed to get freebsd 5.2-Current up and running which is cool I managed to get project evil up and running, however, I can't assign and ipv4 address assigned to the card:

ifconfig ndis0 inet 192.168.1.50 netmask 255.255.255.0 ssid default wepmode on wepkey 0x(key)

when I do an ifconfig ndis0 the inet address is missing but the inet6 address is there.

I just tried to assign an ipv4 address to another card (ethernet) and it did the same thing, but if I set rc.conf to assign an address to the ethernet card during boot it works fine, this would be an option for ndis0 if i could only figure out how to assign ssid and wep stuff during boot too.

Any ideas why there would be a problem with ipv4 addresses?

Thanks

Ben
Application development, webhosting, and much more: www.webcentric-hosting.com
Reply With Quote Quick reply to this message  
Join Date: Dec 2003
Posts: 2,414
Reputation: alc6379 has a spectacular aura about alc6379 has a spectacular aura about alc6379 has a spectacular aura about 
Solved Threads: 123
Team Colleague
alc6379's Avatar
alc6379 alc6379 is offline Offline
Cookie... That's it

Re: FreeBSD only assigning inet6 addresses to ndis0

 
0
  #2
May 23rd, 2004
Boy, this is an odd one. I think I ran into it myself, though.

There are a couple of things you need to do, I think. When you set the ip address, I think you may need to add an up statement to the command:

ifconfig ndis0 inet 192.168.1.50 netmask 255.255.255.0 ssid default wepmode on wepkey 0x(key) up


Does your console say anything when you run the command? It should perk up and display something when you run the command to initialize the device. Additionally, you might want to email the freebsd-portables mailing list for suggestions-- they seem to be the major forum of discussion for Project Evil. Additionally, you could ask Bill Paul, the author of NDISulator. If you go this route, you need to do a few things:

Give a copy of your dmesg output with the card installed. Give the exact syntax command you use to load the module, and to intialize the card (eg, kldload, then ifconfig). Also, indicate exactly which version of driver you're using-- downloaded from the website, from the driver CD. If possible, attach a copy of the driver you're using. Also, indicate the exact model of the card, and which chipset it is that the card uses. Most importantly-- don't do your work in X-- do all of it at the command line, so you can get the messages that are provided.

If you provide even the most minute of details, you will get a great amount of help. Just don't waste his time by giving the "gist" of anything-- tell him exactly what the steps you took were,exactly what your hardware is, and how you're using it.
Alex Cavnar, aka alc6379
Reply With Quote Quick reply to this message  
Join Date: Apr 2004
Posts: 113
Reputation: liliafan is on a distinguished road 
Solved Threads: 2
liliafan's Avatar
liliafan liliafan is offline Offline
Junior Poster

Re: FreeBSD only assigning inet6 addresses to ndis0

 
0
  #3
May 23rd, 2004
alc6379 - I actually also tried the up statement on the ifconfig command (I tried about 10 variations).

I am thinking perhaps it is something to do with the rc files, strange as that may sound, since during boot up there seems no problem assigning ipv4 addresses to nic cards (I have 3 cards in this machine 2 ethernet 1 wireless), the first nic card gets an address assigned at boot time it works perfectly, the 2nd nic card doesn't get anything assigned I am using this as a control card, the third nic I attempt to assign an address to after boot (it is the wireless card), if I attempt to assign an address to the 2nd card after boot it will only assign an ipv6 address same with the third card, additionally if I bring the first card down and reassign an address to it, it will only get an ipv6 address assigned.

To me this implies that somehow the inet module is loading at boot for the boot assignment but somehow being unloaded after boot but being kept in memory for the existing card? So I figure a good solution would be to somehow assign everything to the wireless card during boot, so I am looking for some kind of pointer as to how to I can assign ssid and wep during boot?

I know in the long term I need to get a better solution and for this I will take your advice and contact both the freebsd mail list and the author but for the short term I was hoping to have a temporary solution in place by the end of today.

By the way my experience with *nix systems mostly encompasses linux, and solaris my experience of BSD is limited to installing doing what I want and doing crappy kernel builds, so if anyone can give advice please be as detailed as you can :-)

Thanks

Ben
Application development, webhosting, and much more: www.webcentric-hosting.com
Reply With Quote Quick reply to this message  
Join Date: Apr 2004
Posts: 113
Reputation: liliafan is on a distinguished road 
Solved Threads: 2
liliafan's Avatar
liliafan liliafan is offline Offline
Junior Poster

Re: FreeBSD only assigning inet6 addresses to ndis0

 
0
  #4
May 23rd, 2004
Okay I managed to figure it all out, I will still contact the author to get a better long term solution for a fix I have the following:

cp /sys/modules/ndis.ko /boot/modules
cp /sys/modules/if_ndis/if_ndis.ko /boot/modules

echo ndis_load="yes" >> /boot/loader.conf
echo if_ndis_load="yes" >> /boot/loader.conf
echo hw.ndis0.SSID="default" >> /boot/loader.conf

vi /etc/rc.conf

(add:

ifconfig_ste0="inet 192.168.0.1 netmask 255.255.255.0"
ifconfig_ndis0="inet 192.168.1.50 netmask 255.255.255.0"

)

Upon reboot both cards have valid ipv4 inet addresses assigned along with inet6 addresses, both card can be accessed without a problem.

If I attempt to assign the 3rd nic card an address in rc.conf the whole thing breaks but this isn't really a problem considering that card is there purely as a backup if ste0 breaks xl0 can be assigned the address.

I hope this solution can help someone in the future, I managed to figure it out after re-reading my last post it is amazing what you can figure out when you get a chance to lay out your thoughts in text lol.

Thanks for the help alc6379 :-) when I find out a permanent solution I will also post that here.

Ben
Application development, webhosting, and much more: www.webcentric-hosting.com
Reply With Quote Quick reply to this message  
Reply

This thread is more than three months old.
Perhaps start a new thread instead?
Message:



Similar Threads
Other Threads in the *nix Software Forum
Thread Tools Search this Thread



About Us | Contact Us | Advertise | DaniWeb | Acceptable Use Policy | RSS Feed

©2003 - 2009 DaniWeb® LLC