Take the 2-minute tour ×

I have installed Ubuntu 11.04 on 2 of my desktops PC's. I have not installed any addon packages or anything related to network. Please guide my on how to set up a LAN between these two machines. is there any GUI program to do this instead of Terminal? Because I am completely new to linux and am not very familiar with Terminal usage. I have the ethernet cable connected to a router which inturn is connected to my DSL modem to provide internet access to both my pc's.

Thanking you

share|improve this question
Ok, first things first: is internet working for both? Can both browse webpages, etc? Is your only issue on how to share folders and/or printers with each other? –  MestreLion May 29 '11 at 10:38
What exactly do you want to use the LAN for? What you described already places the computers in a LAN. –  Oxwivi May 29 '11 at 11:48
Your router may also be set up to not let the machines talk to each other. Usually that's only with wireless, but make sure the machines are able to ping each other. You can do that from the System -> Administration -> Network Tools menu. –  Broam Jun 14 '11 at 20:27
add comment

2 Answers

up vote 5 down vote accepted

If both are directly connected to the router and can access internet, then they already are in LAN. Maybe you want to share files and folders, right?

If so, its easy: right-click any folder you want to share, go to "Sharing Options", check the "Share this folder" box, choose a share name, and youre basically done.

If Samba support is not already installed by default, Ubuntu will offer you to install it on-the-fly. Just accept it. Oh, by the way: "Samba" is what enables Ubuntu (and other Linux distros) to share folders and files in a LAN, using the same protocol used by Windows. Meaning any folders you share will also be accessible by Windows machines in your LAN (if there is any)

share|improve this answer
Thank you for the help. Does both the computers need to have samba installed? like comp1 shares file to comp2, i do your suggestion in comp1, do i have to perform the same on comp2 just to access comp1's files? Note: comp2 need not share files to comp1. –  newforubuntulinux Jun 21 '11 at 11:55
@newforubuntulinux: Youre welcome. If comp2 will only access comp1's shared files, then no, no further setup is necessary. In File Manager (Nautilus is the proper name) just click Network in the left panel and browse till comp1's files. –  MestreLion Jun 22 '11 at 15:05
add comment

I'm a little unsure how far you want the guide to go. But if you simply want Internet connection / local file sharing:

With the computer you are connecting to your router:

Click on your network indicator (top right of your screen...) and select 'Edit Connections'. In the wired tab hit the button 'Add'. Give the connection a helpful name, and under the 'IPv4 Settings' tab choose "Shared to other computers" in the drop down 'Method' box. Save the chances and close the connection editor. Connected this computer to the Internet.

Connected up the second machine. On the first 'internet'ed' machine just make sure (using the network indicator) that the Wired Connection you've just created is chosen.

This GUI method should be able to cope with most more-complex setups too.

share|improve this answer
As I have understood, both computers are directly connected to the router. So no need to share the wired connection, as they are probaly already "internet'ed" by the router. I think this is only a matter of SaMBa-sharing folders. –  MestreLion May 29 '11 at 10:42
indeed - i think a little bit of confirmation is needed @newforubuntulinux please... –  thomas michael wallace May 29 '11 at 10:50
Yes both Computers are able to browse internet web pages. I want to share folders between the 2 machines. Thanks everyone for the effort to answer my question. –  newforubuntulinux May 30 '11 at 7:52
@newforubuntulinux: if any of the answers solved your issue, please choose one as the accepted answer. If not, feel free to edit your question and add more information on why they didnt work, and we well be pleased to help you further. –  MestreLion Jun 2 '11 at 7:06
add comment

Your Answer


