hi everyone,
i am using ftp in my batch files.
Wonder if i can change to use sftp cos my unix team mention is not safe.
can i use sftp in batch file?
Moderator: DosItHelp
Re: can i use sftp in batch file?
Do you have a command line sftp client that can be scripted.
-
- Posts: 43
- Joined: 08 Mar 2013 11:23
Re: can i use sftp in batch file?
Squashman wrote:Do you have a command line sftp client that can be scripted.
Didn't really get u.
To use ftp on the command line one would just ftp <ip> and it will prompt u further for the user & password.
I tried
Sftp -b batchfile.txt unsucessfully.
The batch file contain the logins details cos need to run it without any interaction.
The batchfile(located in a win machine, via a .bat) needs to acess some unix server and mget a log.
Please further advice.
Re: can i use sftp in batch file?
flaskvacuum wrote:Squashman wrote:I tried
Sftp -b batchfile.txt unsucessfully.
What error message did you get?
Re: can i use sftp in batch file?
flaskvacuum wrote:Squashman wrote:Do you have a command line sftp client that can be scripted.
Didn't really get u.
To use ftp on the command line one would just ftp <ip> and it will prompt u further for the user & password.
I tried
Sftp -b batchfile.txt unsucessfully.
The batch file contain the logins details cos need to run it without any interaction.
The batchfile(located in a win machine, via a .bat) needs to acess some unix server and mget a log.
Please further advice.
What don't you understand about client/server technology?
If you want to transfer files using FTP, you need a FTP Server and to connect to that server you need to use a FTP client. Same goes for using SFTP. You need a SFTP server and a SFTP client.
Windows has a native FTP client. Windows does not have a native SFTP client.
-
- Posts: 43
- Joined: 08 Mar 2013 11:23
Re: can i use sftp in batch file?
Squashman wrote:flaskvacuum wrote:Squashman wrote:Do you have a command line sftp client that can be scripted.
What don't you understand about client/server technology?
If you want to transfer files using FTP, you need a FTP Server and to connect to that server you need to use a FTP client. Same goes for using SFTP. You need a SFTP server and a SFTP client.
Windows has a native FTP client. Windows does not have a native SFTP client.
tks for the kick start. still trying on the downloaded putty psftp client.