File sharing with the CLI

Brian ad44 at cityscape.co.uk
Sat Feb 20 20:32:29 UTC 2010


On Fri 12 Feb 2010 at 13:09:47 +0100, Knapp wrote:

> Hello,  I have a computer that I think has networking set up, (linux).
> I have a second small laptop that is CLI from the rescue CD remix. I
> want to send a file from the laptop to the main computer. They are
> both on the same router. How do I do this? What must I do to the
> laptop to make this work? THanks!

On the computer which has the file to send:

brian at laptop:~$ cat <file> | nc -l -p 1000

On the computer which is receiving the file:

brian at laptop:~$ nc 192.168.0.20 1000 > <file>

nc is netcat. You might even have it installed already. ssh is overkill
for the job.




More information about the ubuntu-users mailing list