Sponsored Content
Top Forums Shell Programming and Scripting Return all sub directories on ftp server Post 302357821 by thriftinkid on Wednesday 30th of September 2009 05:28:29 PM
Old 09-30-2009
You're correct. But when I ran the following script, I got the following return:

Code:
set theScript to "USER=username
PASSWD=XXXXX
HOST=ftp.mywebsite.com
ftp $HOST <<EOF
user $USER
$PASSWD
ls
quit
EOF
exit 0"
do shell script theScript

obviously, I put in my info. I double checked it to make sure I didn't misspell anything

Returned:

"Name (ftp.mywebsite.com:HOME): Login incorrect.
?Invalid command.
Please login with USER and PASS
Please login with USER and PASS
Please login with USER and PASS
Please login with USER and PASS"

Is that something that might be an issue with the applescript command or the shell?
 

10 More Discussions You Might Find Interesting

1. UNIX for Advanced & Expert Users

FTP return value

Hi guys, I am having a problem to determine if the FTP request I had was successful or not... Here is what I do: In a shell script I call another shell script to do the FTP like: #!/bin/ksh echo "Hello..." ... # call do_ftp.sh do_ftp.sh $SERVER $USR $PASS $FILE.... status=$? if ; then ... (7 Replies)
Discussion started by: Shaz
7 Replies

2. Shell Programming and Scripting

return ftp status

Hello, I still have problems when trying to figure out if the status of an ftp was successful. I ftp to different types (nt, vax, unix, etc...) of machines. I am trying to write a universal script that will ftp a file and then check to see if the ftp was successful. I have tried the... (12 Replies)
Discussion started by: blt123
12 Replies

3. UNIX for Dummies Questions & Answers

FTP Return Code

Hi All, I have a problem to identify the error code thrown by FTP Server while uploading files. The message is : ftp return 32. I couldn't find out what is the meaning of that. :confused: OS is Sun Solaris 2.10. Anyone can help? Thanks a lot (1 Reply)
Discussion started by: wilsonSurya
1 Replies

4. IP Networking

FTP Return 32

Dear All, I have problem when uploading files the FTP Server threw message like this : ftp return 32. Files not get uploaded. OS is Sun Soalaris 2.10 Please help what is the meaning of that message... Thanks (3 Replies)
Discussion started by: wilsonSurya
3 Replies

5. UNIX for Dummies Questions & Answers

Any way to grep a string in directories and return the result with diskusage aswell?

What Im basically trying to do is this: I have a small script that can grep any parameter entered into a search string, then print to the screen the name of each file the parameter appears in as well as the file path, ie the directory. The code Im using just for this is.... Directory... (3 Replies)
Discussion started by: Eddeh
3 Replies

6. Shell Programming and Scripting

Return Value from a FTP shell script

Hello folks,,, I am calling a Unix shell script from java. The unix script is transferring a file through FTP. I wonder how can I confirm whether the script has been executed properly without any error. Is there any way to find the return value from the script. My FTP script is given below ... (3 Replies)
Discussion started by: dinesh1985
3 Replies

7. Red Hat

Implement FTP server on RHEL server without using FTP client

We have RHEL 5.8 in our environment, I had a query whether we can implement an FTP server using vsftpd package and Linux configurations like setsebool without using any external FTP clients like FileZilla etc. I am very confused on this. The FTP functionalities that should be present are download &... (3 Replies)
Discussion started by: RHCE
3 Replies

8. UNIX for Dummies Questions & Answers

Sort directories in 'D' on FTP server

Hello, There are 3 directories on FTP server with format yyyymmddhhmiss. Can someone please let tell me how do I sort these directories in descending order. I only have get the files from the latest directory on FTP server. ftp>ls -l 20150707011229 20150707061229 20150707131225 ... (2 Replies)
Discussion started by: pavan_test
2 Replies

9. Shell Programming and Scripting

Clear contents of specified directories, then return exit status

Hello, this is my first post here. I'm attempting to write a bash shell script to rm the contents of a directory without deleting the directory, specifically in OS X 10.10 . Here's what I have: function clear() { USER="$USER" DIR=$1 rm -rfv /Users/"$USER"/library/$DIR/* } clear... (6 Replies)
Discussion started by: YouNicks
6 Replies

10. Shell Programming and Scripting

Recurse directories and return random file

I have a nice program to change the background but I want it to operate on subdirectories as well. # Script to randomly set Background from files in a directory while true;do # Directory Containing Pictures DIR="/home/pc/Pictures" # Internal Field Separator set to newline, so file names... (4 Replies)
Discussion started by: triplemaya
4 Replies
ftp::geturl(n)							    ftp client							    ftp::geturl(n)

__________________________________________________________________________________________________________________________________________________

NAME
ftp::geturl - Uri handler for ftp urls SYNOPSIS
package require Tcl 8.2 package require ftp::geturl ?0.2.1? ::ftp::geturl url _________________________________________________________________ DESCRIPTION
This package provides a command which wraps around the client side of the ftp protocol provided by package ftp to allow the retrieval of urls using the ftp schema. API
::ftp::geturl url This command can be used by the generic command ::uri::geturl (See package uri) to retrieve the contents of ftp urls. Internally it uses the commands of the package ftp to fulfill the request. The contents of a ftp url are defined as follows: file The contents of the specified file itself. directory A listing of the contents of the directory in key value notation where the file name is the key and its attributes the asso- ciated value. link The attributes of the link, including the path it refers to. BUGS, IDEAS, FEEDBACK This document, and the package it describes, will undoubtedly contain bugs and other problems. Please report such in the category ftp of the Tcllib SF Trackers [http://sourceforge.net/tracker/?group_id=12883]. Please also report any ideas for enhancements you may have for either package and/or documentation. SEE ALSO
ftpd, mime, pop3, smtp KEYWORDS
ftp, internet, net, rfc 959 CATEGORY
Networking ftp 0.2.1 ftp::geturl(n)
All times are GMT -4. The time now is 03:15 PM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy