Sponsored Content
Full Discussion: CURL syntax
Top Forums Shell Programming and Scripting CURL syntax Post 302957078 by frank_rizzo on Tuesday 6th of October 2015 09:08:11 PM
Old 10-06-2015
Code:
use --connect-timeout TIMEOUT

man curl or curl --help for the usage.
 

10 More Discussions You Might Find Interesting

1. Shell Programming and Scripting

curl

Aren't there any way to download files as below? For example, I want to download all .html files under the root directory of unix.com/ curl -O https://www.unix.com/*.html This won't work, but please tell me the way to do this. Well, the best way is to get the file list of the directory, but i... (6 Replies)
Discussion started by: Euler04
6 Replies

2. AIX

use of curl

Hi guys , need some help I have to transfer a file from my aix box to another server using ftps protocol, how can i achieve this using curl preferably or any other utility. Thanks Sandeep (0 Replies)
Discussion started by: jayawantsandeep
0 Replies

3. Shell Programming and Scripting

use of curl

I have to transfer a file from my aix box to another server using ftps protocol, how can i achieve this using curl preferably or any other utility. Regards Sandeep (0 Replies)
Discussion started by: jayawantsandeep
0 Replies

4. Shell Programming and Scripting

Using curl in commandline

Hi, I am using curl to hit a url using http in solaris 10 using commandline, I want to transfer an attachment(using multipart curl -F) also as a part of the request. If anyone has used kindly help me with the syntax. I am using below command: /usr/local/bin/curl -v... (1 Reply)
Discussion started by: manishmaha
1 Replies

5. UNIX for Advanced & Expert Users

Syntax error /w curl?

Hello all- I'm (hopefully) trying to replace a WS_FTP (Windows program) job with a curl command in a script on UNIX. In short, this process has been in place for some time, and in curl I am getting directory perm issues, which does not seem to be accurate, since this process has been in place... (2 Replies)
Discussion started by: prestonatwork
2 Replies

6. Shell Programming and Scripting

Help with cURL

Hi all; first of all i need to clarify that i am new to apache2 server configuration and for some needs i want to transfer some files using curl to web directory,so please bear with me: following is the command i m running to transfer file to my web directory: curl -T "q"... (4 Replies)
Discussion started by: arien001
4 Replies

7. UNIX for Advanced & Expert Users

Syntax issue in curl for getting a file from http site

Hi All I am using curl in my client environment. We need to pull a file from the libraries site. All the files are having perticular URL which can be used to get the files. Only issue is, when we fire that command , it will take to authentication page 1st. once authentication is succed, it will... (1 Reply)
Discussion started by: prabirkumardhar
1 Replies

8. Shell Programming and Scripting

How to specify a port with curl?

HI Im trying to use curl to send a xml file and im trying to send it over a specific port poes anyone know how to specify a port with curl? the command im using is C:\curl -X POST -d @C:\myfile.xml http://yourAddress.com/XMLInterface.asp (5 Replies)
Discussion started by: Paul Walker
5 Replies

9. Shell Programming and Scripting

Curl -v logs

Hi All, Seeking for your assistance on how to redirect into another files the logs of curl -v i tried this code below but i got 0 logs. curl -v 'http://127.0.0.0.......' >> test.logs Thanks in advance. BR, (2 Replies)
Discussion started by: znesotomayor
2 Replies

10. Shell Programming and Scripting

Curl command

Hi All, I am using below curl commad and getting output data correctly curl -k -u AASSDD:PPOOII -d "output_mode=csv" --data-urlencode search='search source=*/AASSDDFF/PPOOLLKK**/94.0*ASD-RST* "Caused by" OR "Error: LISTENER WILL BE DISABLED" OR java.lang.reflect.InvocationTargetException |... (1 Reply)
Discussion started by: rakeshtomar82
1 Replies
CURLOPT_TIMEOUT_MS(3)					     curl_easy_setopt options					     CURLOPT_TIMEOUT_MS(3)

NAME
CURLOPT_TIMEOUT_MS - set maximum time the request is allowed to take SYNOPSIS
#include <curl/curl.h> CURLcode curl_easy_setopt(CURL *handle, CURLOPT_TIMEOUT_MS, long timeout); DESCRIPTION
Pass a long as parameter containing timeout - the maximum time in milliseconds that you allow the libcurl transfer operation to take. Nor- mally, name lookups can take a considerable time and limiting operations to less than a few minutes risk aborting perfectly normal opera- tions. This option may cause libcurl to use the SIGALRM signal to timeout system calls. If libcurl is built to use the standard system name resolver, that portion of the transfer will still use full-second resolution for time- outs with a minimum timeout allowed of one second. In unix-like systems, this might cause signals to be used unless CURLOPT_NOSIGNAL(3) is set. If both CURLOPT_TIMEOUT(3) and CURLOPT_TIMEOUT_MS(3) are set, the value set last will be used. Since this puts a hard limit for how long time a request is allowed to take, it has limited use in dynamic use cases with varying transfer times. You are then advised to explore CURLOPT_LOW_SPEED_LIMIT(3), CURLOPT_LOW_SPEED_TIME(3) or using CURLOPT_PROGRESSFUNCTION(3) to imple- ment your own timeout logic. DEFAULT
Default timeout is 0 (zero) which means it never times out during transfer. PROTOCOLS
All EXAMPLE
CURL *curl = curl_easy_init(); if(curl) { curl_easy_setopt(curl, CURLOPT_URL, "http://example.com"); /* complete within 20000 milliseconds */ curl_easy_setopt(curl, CURLOPT_TIMEOUT_MS, 20000L); curl_easy_perform(curl); } AVAILABILITY
Always RETURN VALUE
Returns CURLE_OK SEE ALSO
CURLOPT_TIMEOUT(3), CURLOPT_CONNECTTIMEOUT(3), CURLOPT_LOW_SPEED_LIMIT(3), libcurl 7.54.0 February 03, 2016 CURLOPT_TIMEOUT_MS(3)
All times are GMT -4. The time now is 04:33 AM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy