[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: Re: Transferring files over SSH in the console



> I can have as many open connections as I want, it's on the LAN. But I
> would _prefer_ just one terminal window for both commands (SSH) and
> file transfers.


You might like to try this.

1) Add to ~/.ssh/config
ControlMaster auto
ControlPath /tmp/%h%p%r
(man ssh_config for explanation).

2) Fire up sftp
sftp user@machine:/path

3) Within sftp, login to a shell on the remote system
!ssh user@machine
Exit the shell to return to the sftp prompt.

4) Use sftp's history to recall the ssh command as desired.

Note that by using the control socket, the shell login uses the same
connection as sftp. Consequently you don't have to enter the password
again.

Allow me to make a plug for the lftp package which I find more
friendly and flexible than sftp (filename completion, get/put multiple
files, and much more). 
At (2) enter
lftp sftp://user@machine/path
then carry on as before.

I hope this helps.

-- 
Cheers,
Clive


Reply to: