A small LAN between Linux machines usually needs three things: working network connectivity, correct IP addressing, and a way to share or access services between machines.
Check IP addresses
ip addr
Machines on the same LAN are usually in the same IP range, such as 192.168.1.x, depending on the router or DHCP server.
Test connectivity
ping 192.168.1.10
Replace the IP address with the address of the other Linux machine.
Access another machine
ssh user@192.168.1.10
For file transfer, use scp, rsync, Samba/CIFS, NFS or SSHFS depending on the use case.
When troubleshooting, check the cable or Wi-Fi connection, IP address, firewall rules and whether the target service is actually running.