0

I recently installed a headless ubuntu headless server on a microserver I recently got for learning purposes. The main problem I'm having at the moment is connecting to my home network.

I'm currently using a nano wireless usb WiFi adapter that came with a raspberry pi kit to get a connection. The only trouble is my router is failing to pick it up. When I boot the server, network connection will fail and it will generate a link-local ipv6 address. The weird thing is that after about half an hour or so the router then decides to pick up the adapter and assign it an ipv4 address. In this state I can SSH to the server but with download speeds of about 12Mb/sec (I used speedtest package to find this out) though it definitely seems slower when downloading packages in the region of about 100KB a sec.

My adapter can listen and pick up a whole bunch of networks fine when I use the command sudo iwlist wlan0 scan. I've edited the /etc/network/interfaces file to include my wireless adapter and use dhcp to assign an address. It currently looks like this

auto wlan0 
iface wlan0 inet dhcp
wpa-ssid "router ssid" 
wpa-psk "password" 

Anyone any idea why it isnt connecting immediately on boot or why the connection is flaky?

Thanks in advance for your advice/help.

Jos
  • 29,224
Adzo
  • 1

1 Answers1

0

Got it to work by statically assigning the ip address by editing the /etc/network/interfaces file.

auto lo iface lo inet loopback

auto wlan0 iface wlan0 inet static address 192.168.1.150 netmask 255.255.255.0 gateway 192.168.1.1 wpa-ssid wpa-psk dns-nameservers 8.8.8.8 192.168.1.1

For some reason the DHCP discover process from my Wifi adapter is ignored by my router. I had to statically assign it outside of the DHCP scope the router uses and it works straight off the bat from boot.

all credit goes to this link. Ubuntu 14.04 Server - WiFi WPA2 Personal

Adzo
  • 1