how to print date using ftp commands


 
Thread Tools Search this Thread
Top Forums Shell Programming and Scripting how to print date using ftp commands
# 1  
Old 05-07-2008
Question how to print date using ftp commands

Hi friends


sftpCmd.txt
-----------------

!echo "Getting files from sftp"
!echo "----------------"
cd /home/msgGoogle/PLATFORM/PROD/MIMUS/outbound/ARCHIVE/invsnap
!echo "folder created"
!date
mget ???050108*.txt output
!echo "------------------"
!echo "Completed : "
!echo "--------------"
bye


here !date command is not working please any one tell me how to get date using ftp commands

Thanks in advacne

Krish.
# 2  
Old 05-07-2008
By "not working", do you mean you get an error message, or that it prints the wrong output? These look like you are actually using shell escapes to execute shell commands within your ftp script, but without information about which ftp client you are using, this is guesswork.
# 3  
Old 05-07-2008
Iam running these ftp commands using txt file
except date command eveything is working fine

I dont know to place date command in the script.

Do you have idea on this. Please suggest me how to use these commands
# 4  
Old 05-07-2008
By "not working", do you mean you get an error message, or that it prints the wrong output? Or nothing at all?

Without information about which ftp client you are using, this is guesswork. Could you please tell what ftp client you are using?
Login or Register to Ask a Question

Previous Thread | Next Thread

10 More Discussions You Might Find Interesting

1. UNIX for Dummies Questions & Answers

Print start date to end date, given $1 & $2 in ksh

Dear all, I have an user passing 2 parameter 31/03/2015 and 02/04/2015 to a ksh script. How to print the start date to end date. Expected output is : 31/03/2015 01/04/2015 02/04/2015 Note : 1. Im using aix and ksh 2. I have tried to convert the given input into a date, didnt... (0 Replies)
Discussion started by: mr.rajaravi
0 Replies

2. UNIX for Dummies Questions & Answers

Ftp login commands

Hello, I am using ftp on command line. The problem is getting bumped off after 15 minutes of no activity.. I have two options: quit ftp and use the command history of my shell, or stay in ftp and use 'open' command, where I can use the command history saved in the ftp program. Either option... (1 Reply)
Discussion started by: Allasso
1 Replies

3. UNIX for Dummies Questions & Answers

Parsing linux commands through FTP

Hi Techies, I have made a shell script which stores the output of it in a text file. then i wanted to fetch that text file using windows scheduler in my windows xp desktop which i did successfully using the below mentioned ftp .bat file : @echo off @echo ftp_user>ftp_test.scr @echo... (0 Replies)
Discussion started by: gemnian.g
0 Replies

4. Shell Programming and Scripting

executing commands through FTP session

Dears, i want to execute unix commands through FTP session those commands like grep XXXXX file name > new file tar new file ..... etc Please let me know how to so thank you (3 Replies)
Discussion started by: faiz
3 Replies

5. Windows & DOS: Issues & Discussions

Can't login to Unix using ftp commands

Hi. I have this issue with an ftp command that I can run successfully using command prompt in Windows but when using a file to run the script unix will always return log in error messages. Here is what I'm doing: In command prompt I'm running this: > ftp -s:c:\load_test_file.scr And my... (4 Replies)
Discussion started by: teposelo
4 Replies

6. HP-UX

not able to upload the pjl commands thru ftp

Hi , By status requests to the printer using the PJL commands like status_read_back there is no answer. The printer itself is functioning well and is printing all requests. Ping, lpstat -t, nslookup is functioning well. The printer model is HP LJ 4200. The printer has been configured as network... (1 Reply)
Discussion started by: amit kul
1 Replies

7. UNIX for Advanced & Expert Users

FTP commands in SFTP

Hi, I am in the process of migrating all my FTP data flows into SFTP to make data more secure... I have used many quote site commands in our FTP sesssion. In SFTP i found that there is no option to do such commands. Does any body here know to overcome the current situation. Regards,... (2 Replies)
Discussion started by: Astra
2 Replies

8. Shell Programming and Scripting

script for ftp commands

Hi I need to setup a script to ftp a file from one unix box to another. I have modified the.netrc file, thus I can ftp into another box without being prompted for password. The question I have is, how can I setup a script which would after ftp, will change a directory, issue the bin command, then... (8 Replies)
Discussion started by: ali.merchant
8 Replies

9. UNIX for Dummies Questions & Answers

Lp Print commands

How do you forward page while printing a report in Unix? Example: I notice the print was misaligned on pages 100-120, How can I forward the printer to start printing at pages 100 and end at 120? (1 Reply)
Discussion started by: ddameron
1 Replies

10. UNIX for Dummies Questions & Answers

FTP - Executing Commands

I have written a script to ftp a file from Unix to an NT machine to authenticate ftp login I have added the information into the .netrc file when logged in using ftp the commands are not executed. Does anybody know how to make the command execute once username and password have been provided using... (2 Replies)
Discussion started by: hesmas
2 Replies
Login or Register to Ask a Question