Ubuntu: How to install network-manager without internet access?


I have been trying to install some kind of network indicator to show my current bandwidth usage on the panel on top of the screen so I decided to install https://launchpad.net/ubuntu/+source/indicator-network

But just after I have put sudo apt-get install indicator-network I have uninstalled a bunch of vital ubuntu applications e.g. network manager - which was my fault because Ubuntu warned me about it but hey! - why would it mark these applications to remove while installing just an indicator ?

Now I am unable to connect to the internet with that machine on Ubuntu. How can I install network manager back or install it from the USB boot drive with 12.04 that I have ?


You don't need NetworkManager to connect to a network. Assuming you're using automatic configuration (probably you are) you just need to sudo dhclient eth0 to get an IP address (replace eth0 with your network device if that's the case).


sudo apt-get install network-manager  

Will fail. Note what dependencies are needed to install the package. Mine were-

The following NEW packages will be installed:    iputils-arping libnl-route-3-200 modemmanager network-manager network-manager-gnome usb-modeswitch usb-modeswitch-data wpasupplicant  

The download will fail obviously with error:

Failed to fetch  http://us.archive.ubuntu.com/ubuntu/pool/main/libn/libnl3/libnl-route-3-200_3.2.3-2ubuntu2_amd64.deb  Could not resolve 'us.archive.ubuntu.com  

Download all such links which gives above error including network-manager by some other system. I downloaded the following links-

http://us.archive.ubuntu.com/ubuntu/pool/main/libn/libnl3/libnl-route-3-200_3.2.3-2ubuntu2_amd64.deb  http://us.archive.ubuntu.com/ubuntu/pool/main/w/wpasupplicant/wpasupplicant_0.7.3-6ubuntu2.2_amd64.deb  http://us.archive.ubuntu.com/ubuntu/pool/main/i/iputils/iputils-arping_20101006-1ubuntu1_amd64.deb  http://us.archive.ubuntu.com/ubuntu/pool/main/u/usb-modeswitch-data/usb-modeswitch-data_20120120-0ubuntu1_all.deb  http://us.archive.ubuntu.com/ubuntu/pool/main/u/usb-modeswitch/usb-modeswitch_1.2.3+repack0-1ubuntu2_amd64.deb  http://us.archive.ubuntu.com/ubuntu/pool/main/m/modemmanager/modemmanager_0.5.2.0-0ubuntu2_amd64.deb  http://us.archive.ubuntu.com/ubuntu/pool/main/n/network-manager-applet/network-manager-gnome_0.9.4.1-0ubuntu2.3_amd64.deb  

The links above does not contain the link of network-manager itself. You can download it from here; from a software mirror close to you. Take care to choose the appropriate architecture (amd64 for 64-bit, i386 for 32-bit), and release version of your installed OS.

Now copy the deb files to /var/cache/apt/archives/

Run sudo-apt-get install network-manager in terminal. Now it will pick up deb files from cache and will not prompt to download them. If all goes well network-manager will be installed.

Finally reboot the system.


I had the same issue. I managed to connect to wireless like this for WPA APs

wpa_passphrase networkname password > foo.conf  killall -9 wpa_supplicant  sudo wpa_supplicant -Dwext -i wlan0 -c foo.conf  

If you're using WEP then than you can do it with

iwconfig wlan0 essid network  iwconfig wlan0 key password  

Note:If u also have question or solution just comment us below or mail us on toontricks1994@gmail.com
Next Post »