I have an vps ,my local pc is in the local area network. When paramiko
installed on my local pc ,i can get file from my vps.
import paramiko
t = paramiko.Transport(("vps ip",22))
t.connect(username = "username", password = "key")
sftp = paramiko.SFTPClient.from_transport(t)
remotepath='/tmp/test
My vps ip is x.y.z.w ,i want to download /etc/passwd from linux server
into my local window disk c: .
import paramiko
host = "x.y.z.w"
port = 22
transport = paramiko.Transport((host, port))
password = "mykey"
username = "root"
transport.connect(username = username, password = password)
sftp = para
It's trying to open the file 'c:', but that's not a file, it's a folder.
Try, say, 'c:/passwd' instead.
It works for me, i tried ,it is ok .
--
https://mail.python.org/mailman/listinfo/python-list
My vps ip is x.y.z.w ,i want to download /etc/passwd from linux server
into my local window disk c: .
import paramiko
host = "x.y.z.w"
port = 22
transport = paramiko.Transport((host, port))
password = "mykey"
username = "root"
transport.connect(username = username, password = password)
sftp