Hi All,
I am connecting to Unix host from Windows and using SFTP connection. I am able to connect and do put & get. But I need to do even more. I want to write a function to which I will pass the command and that commands needs to be executed. Command could be anything, like listing of directories & files, or doing put or get, etc. I am not finding solution for this. If anyone could help me I would really appreciate. Its bit urgent, hence please reply fast.

Thanks,
Vijay K.

Have you looked at Net::SFTP or Net::SFTP::Util ?

With Net::SSH::Perl you can execute commands remotely.

katharnakh.

Have you looked at Net::SFTP or Net::SFTP::Util ?

I have looked into that, but I am not able to understand. I would appreciate if you could give me a sample piece of code of executing command. I can use only SFTP connection but not SSH directly.

Sorry, I have never used them.

Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.