Page 2 of 2 FirstFirst 12
Results 11 to 20 of 20

Thread: Wire(eth0) and wireless(wlan0) cannot work at the same time

  1. #11
    Join Date
    Feb 2010
    Location
    Texas, USA
    Beans
    63
    Distro
    Ubuntu 10.04 Lucid Lynx

    Re: Wire(eth0) and wireless(wlan0) cannot work at the same time

    Quote Originally Posted by wacky_sung View Post
    That's why i find Ubuntu lack of this feature in which you have to manually disable it from wireless to wire or wire to wireless ,plus through a reboot.

    I am trying to find a way in which it work like a charm as Window OS by unplug a cable and get connected to wireless without any configuration.



    I going use it at home when i have guest coming to my house when i am wire and get wireless with my laptop mobile within an instant unplug the ethernet cable.
    Ubuntu does not lack the feature to switch between wireless and wired. I used wired and wireless to connect to my router and Ubuntu automatically uses wired if plugged in (which is preferable) and wireless if not plugged in.
    Help yourself: Use the forum search
    Help us help you: Use descriptive titles and detailed posts.
    Help others: Mark threads as [Solved] once it is.
    Twitter Facebook Blog

  2. #12
    Join Date
    Feb 2009
    Location
    Baja Oklahoma
    Beans
    1,652

    Re: Wire(eth0) and wireless(wlan0) cannot work at the same time

    Right-click on the network manager icon in the panel, select Edit Connections, and edit the wireless connection you want to use. Make sure the box at the top left, which says "Connect Automatically" is checked, and that the box at the bottom, "Available to all users", is checked. You should then get an automatic wireless connection when you remove the ethernet.

    @theozzlives: He doesn't want them to work at the same time, he wants to connect wirelessly, automatically, when the ethernet connection is removed. I suspect the OP is not a native English speaker, as is most of the world, and he just put a title on the thread that isn't quite correct.
    Asus EEE 900 with Linux Mint Debian Edition
    Linux user 497460

  3. #13
    Join Date
    May 2010
    Beans
    462
    Distro
    Ubuntu Development Release

    Re: Wire(eth0) and wireless(wlan0) cannot work at the same time

    Quote Originally Posted by sgosnell View Post
    Right-click on the network manager icon in the panel, select Edit Connections, and edit the wireless connection you want to use. Make sure the box at the top left, which says "Connect Automatically" is checked, and that the box at the bottom, "Available to all users", is checked. You should then get an automatic wireless connection when you remove the ethernet.

    @theozzlives: He doesn't want them to work at the same time, he wants to connect wirelessly, automatically, when the ethernet connection is removed. I suspect the OP is not a native English speaker, as is most of the world, and he just put a title on the thread that isn't quite correct.
    Why this is not correct?Well,look into my /etc/network/interfaces file which i loaded iptables and get connected.

    I have no doubt this can be done through network manager without much effort.

    If you can find solution to it will be much appreciated rather than make a cynical remark.

  4. #14
    Join Date
    Feb 2009
    Location
    Baja Oklahoma
    Beans
    1,652

    Re: Wire(eth0) and wireless(wlan0) cannot work at the same time

    I didn't mean to make a cynical remark. My understanding is that you don't actually want to use both wired and wireless connections at the same time, as indicated in the thread title, but just want to connect automatically by wireless when the wired connection is disabled. Is this not correct? The solution is what I posted in the first paragraph.

    Your problem may be in the use of iptables. Why are you using this on a desktop machine?
    Asus EEE 900 with Linux Mint Debian Edition
    Linux user 497460

  5. #15
    Join Date
    May 2010
    Beans
    462
    Distro
    Ubuntu Development Release

    Re: Wire(eth0) and wireless(wlan0) cannot work at the same time

    Quote Originally Posted by sgosnell View Post
    I didn't mean to make a cynical remark. My understanding is that you don't actually want to use both wired and wireless connections at the same time, as indicated in the thread title, but just want to connect automatically by wireless when the wired connection is disabled. Is this not correct? The solution is what I posted in the first paragraph.

    Your problem may be in the use of iptables. Why are you using this on a desktop machine?
    Yes what you have posted in the first paragraph is using network manager in which i already know the solution.What i requested is auto load iptables during the reboot while running wired / wireless.Which mean that i am not using network manager at all.

    If you think my iptables has a problem and i am very doubtful about it.

    Iptables for IPv4
    Code:
    Chain INPUT (policy DROP 0 packets, 0 bytes)
     pkts bytes target     prot opt in     out     source               destination         
        0     0 DROP       all  --  *      *       0.0.0.0/0            0.0.0.0/0           recent: UPDATE seconds: 86400 name: lastmeasure side: source 
        0     0 DROP       tcp  --  *      *       0.0.0.0/0            0.0.0.0/0           state NEW recent: UPDATE seconds: 60 name: DEFAULT side: source 
        4   200 ACCEPT     all  --  lo     *       0.0.0.0/0            0.0.0.0/0           
        0     0 DROP       all  --  *      *       0.0.0.0/0            0.0.0.0/0           state INVALID 
     1155  964K ACCEPT     all  --  *      *       0.0.0.0/0            0.0.0.0/0           state RELATED,ESTABLISHED 
        0     0 DROP       tcp  --  *      *       0.0.0.0/0            0.0.0.0/0           tcp flags:0x17/0x02 
        0     0 DROP       tcp  --  *      *       0.0.0.0/0            0.0.0.0/0           tcp flags:0x3F/0x3F 
        0     0 DROP       tcp  --  *      *       0.0.0.0/0            0.0.0.0/0           tcp flags:0x3F/0x00 
        0     0 ACCEPT     tcp  --  *      *       0.0.0.0/0            0.0.0.0/0           tcp flags:0x17/0x02 limit: avg 1/sec burst 5 
        0     0 DROP       tcp  --  *      *       0.0.0.0/0            0.0.0.0/0           tcp flags:0x11/0x01 
        0     0 DROP       tcp  --  *      *       0.0.0.0/0            0.0.0.0/0           tcp flags:0x18/0x08 
        0     0 DROP       tcp  --  *      *       0.0.0.0/0            0.0.0.0/0           tcp flags:0x30/0x20 
        0     0 DROP       tcp  --  *      *       0.0.0.0/0            0.0.0.0/0           tcp flags:0x05/0x05 
        0     0 DROP       tcp  --  *      *       0.0.0.0/0            0.0.0.0/0           tcp flags:0x03/0x03 
        0     0 DROP       tcp  --  *      *       0.0.0.0/0            0.0.0.0/0           tcp flags:0x06/0x06 
        0     0 DROP       tcp  --  *      *       0.0.0.0/0            0.0.0.0/0           tcp flags:0x3F/0x3F 
        0     0 DROP       tcp  --  *      *       0.0.0.0/0            0.0.0.0/0           tcp flags:0x3F/0x00 
        0     0 DROP       tcp  --  *      *       0.0.0.0/0            0.0.0.0/0           tcp flags:0x3F/0x29 
        0     0 DROP       tcp  --  *      *       0.0.0.0/0            0.0.0.0/0           tcp flags:0x3F/0x2B 
        0     0 DROP       tcp  --  *      *       0.0.0.0/0            0.0.0.0/0           tcp flags:0x3F/0x37 
        0     0 ACCEPT     tcp  --  *      *       0.0.0.0/0            0.0.0.0/0           tcp flags:0x04/0x04 limit: avg 2/sec burst 2 
       10  2253 DROP       udp  --  *      *       0.0.0.0/0            0.0.0.0/0           limit: avg 1/sec burst 2 
        0     0 DROP       icmp --  *      *       0.0.0.0/0            0.0.0.0/0           icmp type 8 limit: avg 1/sec burst 5 
        0     0 DROP       icmp --  *      *       0.0.0.0/0            0.0.0.0/0           icmp type 17 
        0     0 DROP       icmp --  *      *       0.0.0.0/0            0.0.0.0/0           icmp type 13 
        0     0 DROP       icmp --  *      *       0.0.0.0/0            0.0.0.0/0           icmp type 8 
        0     0 DROP       icmp --  *      *       0.0.0.0/0            0.0.0.0/0           icmp type 0 
        0     0 DROP       icmp --  *      *       0.0.0.0/0            0.0.0.0/0           icmp type 3 
        0     0 DROP       icmp --  *      *       0.0.0.0/0            0.0.0.0/0           icmp type 11 
        0     0 DROP       icmp --  *      *       0.0.0.0/0            0.0.0.0/0           
        0     0 DROP       all  -f  *      *       0.0.0.0/0            0.0.0.0/0           
        0     0 DROP       udp  --  eth0   *       0.0.0.0/0            0.0.0.0/0           udp dpt:53 recent: UPDATE seconds: 660 hit_count: 7 name: DEFAULT side: source 
        8  2276 DROP       all  --  *      *       0.0.0.0/0            224.0.0.0/24        
        0     0 DROP       all  --  *      *       0.0.0.0/0            127.0.0.0/8         
        0     0 DROP       all  --  *      *       0.0.0.0/0            10.0.0.0/8          
        0     0 DROP       all  --  *      *       0.0.0.0/0            172.16.0.0/12       
        0     0 DROP       all  --  *      *       0.0.0.0/0            192.168.0.0/16      
        0     0 DROP       all  --  *      *       0.0.0.0/0            224.0.0.0/3         
    
    Chain FORWARD (policy DROP 0 packets, 0 bytes)
     pkts bytes target     prot opt in     out     source               destination         
        0     0 DROP       all  --  *      *       0.0.0.0/0            0.0.0.0/0           state INVALID 
    
    Chain OUTPUT (policy DROP 0 packets, 0 bytes)
     pkts bytes target     prot opt in     out     source               destination         
        4   200 ACCEPT     all  --  *      lo      0.0.0.0/0            0.0.0.0/0           
        0     0 DROP       all  --  *      *       0.0.0.0/0            0.0.0.0/0           state INVALID 
     1130  172K ACCEPT     all  --  *      *       0.0.0.0/0            0.0.0.0/0           state NEW,RELATED,ESTABLISHED 
        0     0 DROP       all  -f  *      *       0.0.0.0/0            0.0.0.0/0           
        0     0 DROP       tcp  --  *      *       0.0.0.0/0            0.0.0.0/0           tcp dpt:631 
        0     0 DROP       udp  --  *      *       0.0.0.0/0            0.0.0.0/0           udp dpt:631 
        0     0 DROP       2    --  *      *       0.0.0.0/0            0.0.0.0/0
    Iptables for IPv6
    Code:
    Chain INPUT (policy DROP 0 packets, 0 bytes)
     pkts bytes target     prot opt in     out     source               destination         
        0     0 DROP       all      *      *       ::/0                 ::/0                recent: UPDATE seconds: 86400 name: lastmeasure side: source 
        0     0 DROP       tcp      *      *       ::/0                 ::/0                state NEW recent: UPDATE seconds: 60 name: DEFAULT side: source 
        4   280 ACCEPT     all      lo     *       ::/0                 ::/0                
        0     0 DROP       all      *      *       ::/0                 ::/0                state INVALID 
        0     0 ACCEPT     all      *      *       ::/0                 ::/0                state RELATED,ESTABLISHED 
        0     0 DROP       tcp      *      *       ::/0                 ::/0                tcp flags:0x17/0x02 
        0     0 DROP       tcp      *      *       ::/0                 ::/0                tcp flags:0x3F/0x3F 
        0     0 DROP       tcp      *      *       ::/0                 ::/0                tcp flags:0x3F/0x00 
        0     0 ACCEPT     tcp      *      *       ::/0                 ::/0                tcp flags:0x17/0x02 limit: avg 1/sec burst 5 
        0     0 DROP       tcp      *      *       ::/0                 ::/0                tcp flags:0x11/0x01 
        0     0 DROP       tcp      *      *       ::/0                 ::/0                tcp flags:0x18/0x08 
        0     0 DROP       tcp      *      *       ::/0                 ::/0                tcp flags:0x30/0x20 
        0     0 DROP       tcp      *      *       ::/0                 ::/0                tcp flags:0x05/0x05 
        0     0 DROP       tcp      *      *       ::/0                 ::/0                tcp flags:0x03/0x03 
        0     0 DROP       tcp      *      *       ::/0                 ::/0                tcp flags:0x06/0x06 
        0     0 DROP       tcp      *      *       ::/0                 ::/0                tcp flags:0x3F/0x3F 
        0     0 DROP       tcp      *      *       ::/0                 ::/0                tcp flags:0x3F/0x00 
        0     0 DROP       tcp      *      *       ::/0                 ::/0                tcp flags:0x3F/0x29 
        0     0 DROP       tcp      *      *       ::/0                 ::/0                tcp flags:0x3F/0x2B 
        0     0 DROP       tcp      *      *       ::/0                 ::/0                tcp flags:0x3F/0x37 
        0     0 ACCEPT     tcp      *      *       ::/0                 ::/0                tcp flags:0x04/0x04 limit: avg 2/sec burst 2 
        0     0 DROP       udp      *      *       ::/0                 ::/0                limit: avg 1/sec burst 2 
        0     0 DROP       all      *      *       ::/0                 ::/0                frag ids:100:200 first 
        0     0 DROP       udp      eth0   *       ::/0                 ::/0                udp dpt:53 recent: UPDATE seconds: 660 hit_count: 7 name: DEFAULT side: source 
        0     0 ACCEPT     icmpv6    *      *       ::/0                 ::/0                ipv6-icmp type 128 limit: avg 30/min burst 5 
    
    Chain FORWARD (policy DROP 0 packets, 0 bytes)
     pkts bytes target     prot opt in     out     source               destination         
        0     0 DROP       all      *      *       ::/0                 ::/0                state INVALID 
    
    Chain OUTPUT (policy DROP 6 packets, 384 bytes)
     pkts bytes target     prot opt in     out     source               destination         
        4   280 ACCEPT     all      *      lo      ::/0                 ::/0                
        0     0 DROP       all      *      *       ::/0                 ::/0                state INVALID 
        0     0 ACCEPT     all      *      *       ::/0                 ::/0                state NEW,RELATED,ESTABLISHED 
        0     0 DROP       tcp      *      *       ::/0                 ::/0                tcp dpt:631 
        0     0 DROP       udp      *      *       ::/0                 ::/0                udp dpt:631 
        0     0 DROP       all      *      *       ::/0                 ::/0                frag ids:100:200 first

  6. #16
    Join Date
    Feb 2009
    Location
    Baja Oklahoma
    Beans
    1,652

    Re: Wire(eth0) and wireless(wlan0) cannot work at the same time

    Using network manager, the wireless connection is automatic. I have no suggestions for using iptables.
    Asus EEE 900 with Linux Mint Debian Edition
    Linux user 497460

  7. #17
    Join Date
    Mar 2006
    Location
    Williams Lake
    Beans
    Hidden!
    Distro
    Ubuntu Development Release

    Re: Wire(eth0) and wireless(wlan0) cannot work at the same time

    I'm using the UNE, When I plug in the wired cable, the system uses the wired connection, when I disconnect the cable the system automagically connects using wireless.

    If you want to do this without using Network-Manager, have a look at arno-iptables-firewall script, I used to use the script for connection sharing as well as a firewall. The script is in the repositories.

  8. #18
    Join Date
    Jun 2010
    Location
    London, England
    Beans
    7,475
    Distro
    Ubuntu Development Release

    Re: Wire(eth0) and wireless(wlan0) cannot work at the same time

    I have just read your post. I was connected to the router by wire. I pulled the cable out of the router and left clicked the network connection manager icon. I selected my wireless network from the list (networks of neighbours are also detected). And now I am writing this comment using wireless connection to the router. I do not think that this is so difficult to do. I suspect that a better way would be to disable networking before pulling out the cable. Enabling networking would then instruct the wireless part of network manager to use wireless to connect to the router, especially if set up to connect automatically.

    regards

  9. #19
    Join Date
    May 2010
    Beans
    462
    Distro
    Ubuntu Development Release

    Re: Wire(eth0) and wireless(wlan0) cannot work at the same time

    Thank you all for all the responses and appreciated your time and effort to guide to find an alternative solution to it.I do understand all the methods which you guys suggested worked but what i requested is auto load my customize iptables firewall and work as connection i have requested.I do understand network manager and iptables work on the opposite direction which mean that network manager will keep trying to connect to any available connection while iptables resisted it.

    Code:
    Configuration on startup
    WARNING: Iptables and NetworkManager seem to have a conflict. However NetworkManager is still in Beta. If you are concerned enough about security to install a firewall you might not want to trust NetworkManager to manage it yet. Also note NetworkManager and iptables have opposite aims. Iptables aims to keep any questionable network traffic out. NetworkManager aims to keep you connected at all times. Therefore if you want security all the time, run iptables at boot time. If you want security some of the time then NetworkManager might be the right choice.
    
    WARNING: If you use NetworkManager (installed by default on Feisty and later) these steps will leave you unable to use NetworkManager for the interfaces you modify. Please follow the steps in the next section instead.
    
    NOTE: It appears on Hardy, NetworkManager has an issue with properly on saving and restoring the iptable rules when using the method in the next section. Using this first method appears to work. If you find otherwise, please update this note.
    https://help.ubuntu.com/community/IptablesHowTo

  10. #20
    Join Date
    Feb 2009
    Location
    Baja Oklahoma
    Beans
    1,652

    Re: Wire(eth0) and wireless(wlan0) cannot work at the same time

    Just out of curiousity, why are you using iptables?
    Asus EEE 900 with Linux Mint Debian Edition
    Linux user 497460

Page 2 of 2 FirstFirst 12

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
  •