0

If my file something.txt is on a local client and I am ssh'd into a remote server, can I not:

cat /path/on/local/client/something.txt >> /path/on/server

I was able to do what I wanted via:

cat something.txt | ssh username@server "cat > /path/on/server"

But that was outside of server on client. Would like to have remained in server. Is scp required first to get the file onto the server?

2
  • "can I not..." -- No, you cannot. You need a NFS mount to do something like that, instead of a remote login.
    – sawdust
    Sep 15, 2017 at 0:09
  • Yes SCP is required to transfer the file as you have already seen. That is the "file transfer" portion of SSH. Sep 15, 2017 at 0:17

0

You must log in to answer this question.

Browse other questions tagged .