Linux - SoftwareThis forum is for Software issues.
Having a problem installing a new program? Want to know which application is best for the job? Post your question in this forum.
Notices
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
hi all i've setup an ftp server that has the custom port of 666 but i can get curl to upload a file but if i remove the custom port number and set it to 21 curl will upload the file... have i got the command right?
won't work (couldn't connect to host):
Quote:
for f in *; do curl -T $f -u username:pass ftp://ip:666; done
works:
Quote:
for f in *; do curl -T $f -u username:pass ftp://ip; done
p.s. the ftp server is setup right and has been tested
Last edited by steve51184; 08-19-2009 at 05:02 AM.
wait what? the custom port is one i've set in the config and i've tested that it works but it wont work with curl as i think i've got the iport bit wrong
How could it be wrong? a url is a url... you know what a hyperlink looks like, and it's nothing to do with the application you're using it with. Unless something is redirecting or blocking traffic or something, it's not listening on that port.
How could it be wrong? a url is a url... you know what a hyperlink looks like, and it's nothing to do with the application you're using it with. Unless something is redirecting or blocking traffic or something, it's not listening on that port.
it is on that port and like i've said i've tested it on other things and it does work but curl wont take the :port bit!
yes it does. As above, a URL is a URL, a program isn't allowed to treat them differently. mind you you've not shown any debug output, or even normal output from the curl command at all...
$ for f in *; do curl -T $f -u username:pass ftp://ip:666; done
% Total % Received % Xferd Average Speed Time Time Time Current
Dload Upload Total Spent Left Speed
0 0 0 0 0 0 0 0 --:--:-- 0:01:33 --:--:-- 0
curl: (7) couldn't connect to host
Well that isn't debugging so you can't explicitly see it's interpretation of the url, but still, I don't know how many more times I can tell you that the command is working just fine. try, for example, running nmap against the box, and seeing what ports are open.
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.