Using Ubuntu Mate 22.04 [NOT UBUNTU 22.04, IVE TRIED TO ADAPT THOSE DIRECTION AND FAILED]
How do I activate a LAN and how do I share directories and files to make them available on a wired LAN.
Where can I find written step-by-step instructions.
[new to LAN, not new to Mate]
The question will need more specifics. Mostly, a LAN, whether wired or wireless will be set up automatically by NetworkManager using a DHCP server. If you have a LAN, and it connects to the internet, you should have only a SINGLE point of connection, with a firewall at that location.
Sharing files is a totally different thing. Samba or NFS? What OSs are on the various hosts on the network? How much access control do you need? Do you need read-write access? And dozens of other questions. There is no step by step without more details.
You can create a public dir, configure samba to share that dir with every system in the LAN. In /etc/samba/smb.conf
[public]
path = some location
writable = yes
guest ok = yes
sudo systemctl restart smbd
you can access files via smb://um22/public
or smb://192.168.5.10/public
Since you withheld all details regarding your network, I will presume a regular ADSL setup.
That means computer -> 4ports modem/router -> internet.
That also means that you are not new to LAN. You are already using it.
I will also presume that you want this setup for a home situation and not for a company/enterprise setting.
Your questions:
How do I activate a LAN
Your LAN is already active otherwise you wouldn't be able to reach your modem/router and therefore not able to post any messages here.
how do I share directories and files to make them available on a wired LAN
I presume that you want a secure and standards compliant solution so here are the steps to set it up.
In my example I assume that you have two computers connected to your router/modem.
-
Login to the first computer.
Install 'sshd' :sudo apt-get install openssh-server
-
Do the same on the other computer.
ready
Both computers can now read files and directories from each other.
How to use:
- open caja
- type in the addressbar: sftp://username@ipaddress/
(username and ip address are the usename you have on the other computer and the ip address of the other computer) - it will ask for the password so honour that request.
ready
This will work with ANY connected computer regardless operating system (except MS-windows ofcourse because MS-Windows is the only one that is not standards compliant)
If you want MS-windows to also be able to share, install 'winscp' on MS-windows.
In the very unlucky case that you want to be "compatible" with that horrible MS-Windows filesharing system because 'every windows refugee is using it', forget all the above, read up on SaMBa for filesharing and stock up on a family pack anti-depressants.
Thanks for the help.
Which ip do I use? [public/private] [sftp://username@ipaddress/]
On terminal how do I get a clear one address to use?
If the other computer is on the same lan, I always use the host name of the other computer for the ip address. Saves me from having to net scan for numerical address or having to set up a static ip address or go to the other computer and find out what address was assigned. I'm lazy.
You might give that a go.
If what @mdd12 wrote works for you, you should do that.
if not, read on:
Which ip do I use?
The ip-address of the computer you want to contact.
On terminal how do I get a clear one address to use?
type ip addr
on the computer you want to contact.
Alternatively, you can click on the networkicon in the systemtray and select 'connection information'