Take the 2-minute tour ×
Ask Ubuntu is a question and answer site for Ubuntu users and developers. It's 100% free, no registration required.

Something strange is happening... I've installed a Wi-Fi card into my Ubuntu Server 11.04 machine.

To configure it I do the following:

sudo vi /etc/network/interfaces

add:

iface wlan0 inet dhcp
wpa-driver wext
wpa-ssid "Sweet Home"
wpa-ap-scan 1
wpa-proto WPA
wpa-pairwise TKIP
wpa-group TKIP
wpa-key-mgmt WPA-PSK
wpa-psk <A KEY>
auto wlan0

then:

$ sudo /etc/init.d/networking restart
 * Running /etc/init.d/networking restart is deprecated because it may not enable again some interfaces
 * Reconfiguring network interfaces...                                                                        ssh stop/waiting
ssh start/running, process 1522
ssh stop/waiting
ssh start/running, process 1590

And my machine successfully gets an ip to my wireless adapter.

But after reboot it doesn't get any ip in wireless network. To fix it I run /etc/init.d/networking restart again and all is fine again - it gets an ip.

I understand that I simply should add it to my startup scripts to make it work properly, but maybe there is a better way to configure it?

UPD: I've tried to add it to startup (put a link to restart script into /etc/rcS.d/S80restartwireless but no success... It restarts but i still have to restart network manually to make it work.

share|improve this question
    
This may be a bug.. thats not a common configuration that is tested with each release, so its possible the timing is off. Would you be willing to report it with 'ubuntu-bug ifupdown' ? Respond with the bug # here and I'll make sure the bug gets looked at soon. –  SpamapS Aug 5 '11 at 22:50

1 Answer 1

This certainly looks like a bug as SpamapS says. Report the issue:

https://help.ubuntu.com/community/ReportingBugs

Making note of the fact that it's probably a timing issue and the wifi connection probably needs to make the rest of the networking stack wait.

You might also be interested in using network manager instead of your manual configuration. Network manager would automatically attempt a reconnect and it's what the desktop uses.

http://docs.fedoraproject.org/en-US/Fedora/13/html/User_Guide/sect-User_Guide-Connecting_to_the_Internet-NM_CLI.html

share|improve this answer

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.