Page 1 of 2 12 LastLast
Results 1 to 10 of 11

Thread: How do I disable a wireless interface from the terminal, permanently?

  1. #1
    Join Date
    Feb 2007
    Location
    Topeka, Kansas
    Beans
    2,317
    Distro
    Ubuntu 13.10 Saucy Salamander

    How do I disable a wireless interface from the terminal, permanently?

    I have a small computer (Zotac Mag Mini All-in-One Giant) that has a built in wireless adapter that barely works (poor signal), so I'm using an external USB adapter instead, which performs far better by comparison. I would like to disable the adapter inside the PC so that in the future the computer doesn't try to reconnect to the network using the "wrong" interface.

    Is there a way to disable a networking interface (Ethernet or Wireless for that matter) from terminal in such a way so that it will remain "off" or ignored after rebooting?

  2. #2
    Join Date
    Mar 2008
    Location
    Indore, India
    Beans
    233
    Distro
    Ubuntu 10.04 Lucid Lynx

    Re: How do I disable a wireless interface from the terminal, permanently?

    yes you can do it

    ifconfig wifi0 down

    or whatever the internet name is.

  3. #3
    Join Date
    Feb 2007
    Location
    Topeka, Kansas
    Beans
    2,317
    Distro
    Ubuntu 13.10 Saucy Salamander

    Re: How do I disable a wireless interface from the terminal, permanently?

    Quote Originally Posted by sj1410 View Post
    yes you can do it

    ifconfig wifi0 down

    or whatever the internet name is.
    Tried this. All it does is take the interface down for the current session, but after rebooting the system, it comes right back. This is not what I was looking for.

    I want the interface to remain down after reboot; to not even attempt to connect to anything.

  4. #4
    Rebelli0us is offline Extra Foam Sugar Free Ubuntu
    Join Date
    Feb 2008
    Beans
    722

    Re: How do I disable a wireless interface from the terminal, permanently?

    Zotac? Disable wireless through the BIOS or even remove the mini card.

  5. #5
    Join Date
    Mar 2006
    Location
    Kitakyushu Japan
    Beans
    9,362
    Distro
    Ubuntu 11.04 Natty Narwhal

    Re: How do I disable a wireless interface from the terminal, permanently?

    Quote Originally Posted by diablo75 View Post
    Is there a way to disable a networking interface (Ethernet or Wireless for that matter) from terminal in such a way so that it will remain "off" or ignored after rebooting?
    I have a computer with the same problem so I found a solution.

    According to: /usr/share/doc/network-manager/README.Debian
    Only devices that are not listed in /etc/network/interfaces or which have been configured "auto" and "dhcp" (with no other options) are managed by NM.
    So you just need to edit /etc/network/interfaces and add a non-auto entry for your weak network adapter like so (where wlan0 is your weak adapter):
    Code:
    auto lo
    iface lo inet loopback
    
    iface wlan0 inet manual
    Edit:
    Humm, this has some problems. I had to delete all of the configs in ./gconf and then nm-applet only shows up if I restart network-manager.

    Edit 2:
    Seems the above was only a problem with one machine.
    Last edited by dmizer; June 4th, 2011 at 01:55 AM.

  6. #6
    Join Date
    Apr 2009
    Location
    Germany
    Beans
    178
    Distro
    Ubuntu 10.04 Lucid Lynx

    Re: How do I disable a wireless interface from the terminal, permanently?

    Hello,
    why not just disable the module permanently (blacklist)?

    Hardware and loaded Modules?
    Code:
    lspci -nnk | grep -i net -A2
    lsusb
    lsmod

  7. #7
    Join Date
    Jan 2009
    Beans
    54

    Re: How do I disable a wireless interface from the terminal, permanently?

    Curious as well. I dont use wi-fi but I can't disable it either.

    I'd like to just have the device powered off unless I needed it for a particular session.

    Help please!

  8. #8
    Join Date
    Mar 2006
    Location
    Kitakyushu Japan
    Beans
    9,362
    Distro
    Ubuntu 11.04 Natty Narwhal

    Re: How do I disable a wireless interface from the terminal, permanently?

    Quote Originally Posted by grants View Post
    Curious as well. I dont use wi-fi but I can't disable it either.

    I'd like to just have the device powered off unless I needed it for a particular session.

    Help please!
    It's usually possible to do this via a few ways:
    1. Disable the card in BIOS. (This may or may not be possible)
    2. Use the on/off switch to disable it. Check your computer's users manual for the correct key combination.
    3. Use the edit I suggested above in post #5.
    4. Blacklist the module driving the card as suggested in post #6

  9. #9
    Join Date
    Nov 2010
    Location
    NM
    Beans
    1,121
    Distro
    Lubuntu Development Release

    Re: How do I disable a wireless interface from the terminal, permanently?

    Quote Originally Posted by flash63 View Post
    Hello,
    why not just disable the module permanently (blacklist)?

    Hardware and loaded Modules?
    Code:
    lspci -nnk | grep -i net -A2
    lsusb
    lsmod
    +1 I like that idea flash it is elegant. Find the driver or module and blacklist it.
    Boot Info Script
    Ubuntu User number is # 32763
    Linux User number is # 527179

  10. #10
    Join Date
    Mar 2006
    Location
    Kitakyushu Japan
    Beans
    9,362
    Distro
    Ubuntu 11.04 Natty Narwhal

    Re: How do I disable a wireless interface from the terminal, permanently?

    Quote Originally Posted by nm_geo View Post
    +1 I like that idea flash it is elegant. Find the driver or module and blacklist it.
    Yes and no. This could cause problems if both your wireless and your wired network cards are Broadcom. It could also cause problems because many different cards share the same modules, so it's possible that (in a situation where you want to use a wireless card other than the factory card) both the factory card and your spare card may use the same module.

Page 1 of 2 12 LastLast

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •