The UNIX and Linux Forums  

Go Back   The UNIX and Linux Forums > Top Forums > UNIX for Dummies Questions & Answers
Google UNIX.COM


UNIX for Dummies Questions & Answers If you're not sure where to post a UNIX or Linux question, post it here. All UNIX and Linux newbies welcome !!

More UNIX and Linux Forum Topics You Might Find Helpful
Thread Thread Starter Forum Replies Last Post
Passwordless sftp from UNIX to windows site konark Shell Programming and Scripting 2 03-24-2008 10:36 AM
how to get multiple files using sftp from a windows server ramky79 SUN Solaris 0 03-02-2008 10:15 AM
SFTP from windows E:/ to unix server pranavagarwal Shell Programming and Scripting 12 11-28-2007 06:58 AM
Mount a windows drive on unix ejbrever UNIX for Dummies Questions & Answers 4 10-11-2006 02:35 AM
SFTP from UNIX (AIX) to Windows 2000 server reddymails Shell Programming and Scripting 0 03-09-2006 05:15 AM

Reply
 
LinkBack Thread Tools Display Modes
  #1 (permalink)  
Old 11-23-2007
Registered User
 

Join Date: Oct 2007
Location: India
Posts: 24
Exclamation SFTP files from windows drive E: to unix

Hello friends,

I was doing this test script which would take a file from my own E: drive to the unix server which i access from a putty.

I tried

Code:
sftp <osuser>@<ipaddress>
but it didn't work.

does the windows client have to be a server installation?

i was trying on win xp from solaris 5.10 tty

Another thing,

I need to understand the syntax of a crontab command.
e.g.,
Code:
10 2-10 * * * ksh /home/check2run.ksh /home/test.done "home/test_sftp.ksh sftp" 2>> logs/sftptest.log >& 2
I understand the basic syntax of crontab.
plz tell me, what do the
Code:
/home/test.done
,
Code:
"home/test_sftp.ksh sftp" 2>> logs/sftptest.log
and
Code:
>& 2
parts mean?

will be sincerely grateful for any kind of help that I recieve.
Reply With Quote
Forum Sponsor
  #2 (permalink)  
Old 11-23-2007
sysgate's Avatar
Unix based
 

Join Date: Nov 2006
Location: /root
Posts: 1,128
For windows use psftp client instead.
The crontab syntax (this is ksh, which I'm not really good at, correct me if I'm wrong) generally indicates scripts invocation and sending the output in log file.
Reply With Quote
  #3 (permalink)  
Old 11-24-2007
Registered User
 

Join Date: Nov 2007
Posts: 1
cron line explanation

You should better try WinSCP, it's a lot easier to use.

Code:
10 2-10 * * * ksh /home/check2run.ksh /home/test.done "home/test_sftp.ksh sftp" 2>> logs/sftptest.log >& 2
Your doubts are not cron syntax related, the entire line means:

execute at minute 10 between 2 and 10am everyday the following command:

Code:
ksh /home/check2run.ksh /home/test.done "home/test_sftp.ksh sftp" 2>> logs/sftptest.log >& 2
/home/check2run.ksh is executed with the ksh shell and the following arguments
Code:
/home/test.done "home/test_sftp.ksh sftp"
Redirect standard error output to /logs/sftptest.log
Code:
 2>> logs/sftptest.log
Redirect standard output to the standard error.
Code:
 >& 2
Reply With Quote
  #4 (permalink)  
Old 11-25-2007
Registered User
 

Join Date: Oct 2007
Location: India
Posts: 24
Thumbs up

@Checkoh

Thank you very much my friend.. the explanation is wonderfully clear.

@Sysgate..

Thanks tou you too my frind.. although I'm still doubtful that psftp can solve my problem.
Reply With Quote
  #5 (permalink)  
Old 11-26-2007
sysgate's Avatar
Unix based
 

Join Date: Nov 2006
Location: /root
Posts: 1,128
Why not ? psftp is excellent command line utility for batch ssh transfers, it also can run in non-interactive mode. What exactly is your requirement ?
Reply With Quote
Google UNIX.COM
Reply

Thread Tools
Display Modes




All times are GMT -7. The time now is 01:23 PM.


Powered by: vBulletin, Copyright ©2000 - 2006, Jelsoft Enterprises Limited.
The UNIX and Linux Forums Content Copyright ©1993-2008 The CEP Blog All Rights Reserved -Ad Management by RedTyger Visit The Global Fact Book

Content Relevant URLs by vBSEO 3.2.0