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.

I would like to make a Virtual Router on Ubuntu 12.04

but i am getting this error message when i run the last terminal command

Configuration file: hostapd.conf
nl80211: Could not configure driver mode
nl80211 driver initialization failed.
hostapd_free_hapd_data: Interface wlan0 wasn't started
share|improve this question
1  
Are you using 14.04? There is an open bug for hostapd with these error message. Launchpad bug #1289047 hostapd package is broken –  bain May 28 at 13:49

2 Answers 2

As @bain has rightly pointed out, there is a bug raised in launchpad for this very purpose. This workaround suggested there works perfectly for me:

sudo nmcli nm wifi off
sudo rfkill unblock wlan

sudo ifconfig wlan0 10.15.0.1/24 up
sleep 1
sudo service isc-dhcp-server restart
sudo service hostapd restart

The first two lines stop wlan from network manager, and then unblocks the interface, so ifconfig can work.

The next commands uses ifconfig to bring up wlan and allows a second's delay, then restart the dhcp server (though I did not need this restart in my setup), and finally start the hostapd service.

It should now start w/o any issues.

share|improve this answer

Try this:

  1. Click the network icon
  2. Select "Create wireless network"
  3. Choose a name, encryption type and password
  4. Click create
  5. Make sure you're connected to the internet.
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.