Page 1 of 3 123 LastLast
Results 1 to 10 of 28

Thread: Ubuntu 2 Ubuntu via Ethernet while still using WiFi?

  1. #1
    Join Date
    May 2008
    Beans
    2,526

    Ubuntu 2 Ubuntu via Ethernet while still using WiFi?

    I'm wondering if this is even possible. I've searched high and low and have yet to find and answer to this particular setup.

    The setup:
    Router is in another building.
    Desktop connected by WiFi
    Laptop connected by WiFi
    Both the Desktop and the Laptop are in the same building together. About 5' apart.

    SSH server is setup on Desktop
    FreeNX client is setup on Laptop

    So they can connect just fine via WiFi for remote desktop control of the Desktop from the Laptop (so SSH and FreeNX are working).

    All is good so far, so here's the questions.

    Is it possible to connect the 2 pc's directly to each other by Ethernet cable AND transfer files between them by Ethernet while still being connected to the Internet by WiFi on them both?

    Or would the WiFi have to be disabled while using the Ethernet connection?

    Neither has a Gigabit Ethernet NIC so I know it would at least require a crossover cable or another router to connect the 2 by Ethernet cable.

    The idea behind all this is to be able to transfer files between computers quickly by Ethernet while the computers are still busy doing other things on the Internet by WiFi.

    I know I have other options for how to do the transfer via Ethernet like FileZilla and vsftpd. But the question still remains, can it be done.

    I'm suspecting that this can't be done.

    Thanks in advance.
    Ultimate Edition Links

  2. #2
    Join Date
    Jul 2007
    Location
    Atlanta, GA
    Beans
    668
    Distro
    Ubuntu 16.04 Xenial Xerus

    Re: Ubuntu 2 Ubuntu via Ethernet while still using WiFi?

    Sure it can be done. This is actually pretty easy.

    First choose an IP subnet that is different from what you are getting on your wireless network (i.e. 10.10.10.0).
    On each system, edit the Wired network connection through NetworkManager and assign a static IP address to each one (laptop uses 10.10.10.1 and desktop uses 10.10.10.2 for example).
    Set the subnet mask to 255.255.255.0 on both.

    Do NOT set a gateway on either system. This is important. By not setting a gateway you allow the default Internet gateway on the Wireless network to still work.

    Once you have each system setup, connect your crossover cable between them. You should now be able to communicate between the systems (ping, ssh, file shares, etc). Be sure to use the 10.10.10.x address to connect to the target system and it will use the wired connection.

    Make sense?

    Cheers!

  3. #3
    Join Date
    May 2008
    Beans
    2,526

    Re: Ubuntu 2 Ubuntu via Ethernet while still using WiFi?

    Quote Originally Posted by Fire_Chief View Post
    Sure it can be done. This is actually pretty easy.

    First choose an IP subnet that is different from what you are getting on your wireless network (i.e. 10.10.10.0).
    On each system, edit the Wired network connection through NetworkManager and assign a static IP address to each one (laptop uses 10.10.10.1 and desktop uses 10.10.10.2 for example).
    Set the subnet mask to 255.255.255.0 on both.

    Do NOT set a gateway on either system. This is important. By not setting a gateway you allow the default Internet gateway on the Wireless network to still work.

    Once you have each system setup, connect your crossover cable between them. You should now be able to communicate between the systems (ping, ssh, file shares, etc). Be sure to use the 10.10.10.x address to connect to the target system and it will use the wired connection.

    Make sense?

    Cheers!
    Thanks Fire_Chief

    That was the way I was looking at doing it but since I don't have a crossover cable right now I wanted to find out if it would work before getting one.

    I'll stop by Unclaimed Baggage tomorrow and pick one up for a couple bucks.
    Ultimate Edition Links

  4. #4
    Join Date
    Jan 2006
    Location
    Not heaven... Iowa
    Beans
    Hidden!
    Distro
    Ubuntu

    Re: Ubuntu 2 Ubuntu via Ethernet while still using WiFi?

    You could use a hub/switch and a couple of straight cables, but for a couple of bucks, the crossover would make more sense.
    Linux User #415691 Ubuntu User #8629
    Iowa Team (LoCo): [Wiki] [Launchpad]
    IRC channel: #ubuntu-us-ia on irc.freenode.net

  5. #5
    Join Date
    May 2008
    Beans
    2,526

    Re: Ubuntu 2 Ubuntu via Ethernet while still using WiFi?

    Quote Originally Posted by Iowan View Post
    You could use a hub/switch and a couple of straight cables, but for a couple of bucks, the crossover would make more sense.
    The single crossover also has the advantages of only 1 more cable as opposed to 2 and a hub/switch with power supply being added to all the cables, cords and everything I already have running everywhere. Don't really want anymore stuff to plug in....
    Ultimate Edition Links

  6. #6
    Join Date
    May 2008
    Beans
    2,526

    Re: Ubuntu 2 Ubuntu via Ethernet while still using WiFi?

    Looks like it wont work after all. I was able to ping, connect by ssh and freenx via the crossover cable but the wiwfi wouldn't work at the same time.

    Guess it's either one or the other but not both at the same time.

    I'll keep playing with things but there are only so many settings. Looks lie the only way to do file transfers AND Internet at the same time is to use another router as a bridge and plug both computers in by Ethernet.

    Bummer
    Ultimate Edition Links

  7. #7
    Join Date
    Jan 2006
    Location
    Not heaven... Iowa
    Beans
    Hidden!
    Distro
    Ubuntu

    Re: Ubuntu 2 Ubuntu via Ethernet while still using WiFi?

    Your setup via Network Manager or /etc/network/interfaces? NM usually only activates one interface at a time.
    Linux User #415691 Ubuntu User #8629
    Iowa Team (LoCo): [Wiki] [Launchpad]
    IRC channel: #ubuntu-us-ia on irc.freenode.net

  8. #8
    Join Date
    May 2008
    Beans
    2,526

    Re: Ubuntu 2 Ubuntu via Ethernet while still using WiFi?

    Quote Originally Posted by Iowan View Post
    Your setup via Network Manager or /etc/network/interfaces? NM usually only activates one interface at a time.
    Tried it both ways.
    Just using System > Administration > Network
    And using just the Network Manager Applet on the top panel

    I did get it to actually show IP addresses (Using ifconfig) for both the eth0's and wlan0 & wlan1 (respectively server & client) at the same time with the Network Manager Applet.

    That was not the case using the setting of
    System > Administration > Network
    where it would show either a eth0 or wlan0/wlan1 IP address using ifconfig. But not both eth & wlan at the same time.

    Hope that makes sense. I would think it would be the other way around like what you're saying.

    EDIT: If you mean did I edit /etc/network/interfaces then the answer is no.
    I'm not sure how to format the information when adding it to the file since all that is in the file of the client right now is:
    auto lo
    iface lo inet loopback
    A few more lines in there and I could probably figure out the required formatting.

    I messed around until I had to reset the network settings back to square 1....

    It's still good though since I just had to delete all the settings I had put in and re-enter the settings for the WiFi. Shouldn't play with the routers configuration at the same time as working on other network configurations...
    SSH & FreeNX still work fine.

    I'm thinking it would be something like:
    managed eth0
    iface eth0 IP=10.10.10.1 sub=255.255.255.0
    But I'm just guessing.
    Last edited by 2hot6ft2; January 28th, 2010 at 04:17 AM.
    Ultimate Edition Links

  9. #9
    Join Date
    Jan 2006
    Location
    Not heaven... Iowa
    Beans
    Hidden!
    Distro
    Ubuntu

    Re: Ubuntu 2 Ubuntu via Ethernet while still using WiFi?

    Perhaps you should try /etc/network/interfaces Edit the file to look something like:
    Code:
    auto lo
    iface lo inet loopback 
    
    iface eth0 inet static
    address 192.168.1.2
    netmask 255.255.255.0
    network 192.168.1.0
    broadcast 192.168.1.255
    The last two lines may be unnecessary. You'll want a different address on each machine (of course) and it will probably work better if the subnet (network) is different than the WiFi.
    Linux User #415691 Ubuntu User #8629
    Iowa Team (LoCo): [Wiki] [Launchpad]
    IRC channel: #ubuntu-us-ia on irc.freenode.net

  10. #10
    Join Date
    May 2008
    Beans
    2,526

    Re: Ubuntu 2 Ubuntu via Ethernet while still using WiFi?

    Ok, I think I'll try it with something like this:

    auto lo
    iface lo inet loopback

    iface eth0 inet static
    address 10.10.1.2
    netmask 255.255.250.0
    network 10.10.1.0
    broadcast 10.10.1.255
    Since my WiFi is using
    inet addr:192.168.1.xxx Bcast:192.168.1.255 Mask:255.255.255.0
    I want to stay away from those.

    Now to go hard reset the router and load my backup config for it.
    I changed something and it's not responding like it should.

    Been messing around with PuTTy and stuff trying to get it to where I can SSH in with FreeNX from outside the LAN. Something is still off. I have DD-WRT on the router and a DynDNS address since the IP from my ISP is dynamic.

    Forwarded a port to the SSH server but that's another project that I have going.

    I can PuTTy in to the router now so I have made some progress there.

    By the way I appreciate your help.
    Ultimate Edition Links

Page 1 of 3 123 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
  •