-
Notifications
You must be signed in to change notification settings - Fork 1.1k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
CloudWatchLogs request errors #238
Comments
This actually looks like an TLS issue (error code 35). Can you turn on the verbose line in the curl client so I can see the TLS handshake output? |
Sure; do you mean these two lines? |
Just the verbose line. Sent from my iPhone
|
Here is the output from several attempts to connect. It's mostly this "Illegar parameter" error, but there is 1 Decrypt error instead.
|
Ah... I think you are using the wrong libcurl. You need the one linked and compiled against OpenSSL. GnuTLS isn't compatible with our load balancers. Sent from my iPhone
|
My curl --version is outputting Do you have a suggestion for how to install curl? I tried this repository https://github.com/curl/curl but I get compile issues when I try to build the aws library afterwards. |
Ok, I was able to get this working. I was originally getting the following errors when building: aws-sdk-cpp/aws-cpp-sdk-core/source/http/curl/CurlHandleContainer.cpp:123:5: error: invalid conversion from ‘void*’ to ‘CURL* {aka Curl_easy*}’ [-fpermissive] After adding the casts, I was able to build and it worked. Could we add these casts to the library? |
We don't get those errors when we build, so to evaluate this I need to know versions of the library and header files you are using. curl --version is a fully built and linked binary. This is very much different from what you've actually built and linked against. There are multiple variants of the libcurl header files, some which use openssl, some gnutls, and some that use other dependencies. I am certain, assuming the verbose output you showed is correct, that you were building against the gnutls variant. It may work against some of our load balancers, but it is also known widely to not work in most cases, so you shouldn't use it. |
I am using the current version of https://github.com/curl/curl, building as follows: autoreconf -i |
Hi, Piggybacking on this issue, I too am getting:
I've curl compiled w/ openssl
|
Since I have to make this edit every time I update my version of the library, I've been looking at this file some more; CURL* seems to be used already in several other places in the file. In fact, both instances of this function being called in this file pass a CURL*, and it isn't called from anywhere else. |
@jimmyt857 @ambasta Hello, it seems you have fixed the original problem after compiling curl with openssl. Is the casting problem still exists? |
…aws#238) * Windows high performance counter precision fix; crt init/shutdown fix * Submodule update
When calling CreateLogGroup, CreateLogStream, DeleteLogStream, or PutLogEvents, I am getting curl error 35 (ssl connect error). Any of the first 3 will just fail after ~10 attempts, but for some reason PutLogEvents always succeeds on the 7th attempt. Here is an example log trace:
[INFO] 2016-07-15 03:29:18 CurlHandleContainer [139736288929792] Initializing CurlHandleContainer with size 25
[TRACE] 2016-07-15 03:29:18 AWSClient [139736288929792] Found body, but content-length has not been set, attempting to compute content-length
[DEBUG] 2016-07-15 03:29:18 AWSAuthV4Signer [139736288929792] Calculated sha256 ed5df988d44e451e18fedf10d89327e33aa4ec818bf5eac665b2679d77c22dee for payload.
[DEBUG] 2016-07-15 03:29:18 AWSAuthV4Signer [139736288929792] Canonical Header String: content-length:31
content-type:application/x-amz-json-1.1
host:logs.us-west-2.amazonaws.com
user-agent:aws-sdk-cpp/0.13.4 Linux/3.13.0-74-generic x86_64
x-amz-content-sha256:ed5df988d44e451e18fedf10d89327e33aa4ec818bf5eac665b2679d77c22dee
x-amz-date:20160715T032918Z
x-amz-target:Logs_20140328.CreateLogGroup
[DEBUG] 2016-07-15 03:29:18 AWSAuthV4Signer [139736288929792] Signed Headers value:content-length;content-type;host;user-agent;x-amz-content-sha256;x-amz-date;x-amz-target
[DEBUG] 2016-07-15 03:29:18 AWSAuthV4Signer [139736288929792] Canonical Request String: POST
/
content-length:31
content-type:application/x-amz-json-1.1
host:logs.us-west-2.amazonaws.com
user-agent:aws-sdk-cpp/0.13.4 Linux/3.13.0-74-generic x86_64
x-amz-content-sha256:ed5df988d44e451e18fedf10d89327e33aa4ec818bf5eac665b2679d77c22dee
x-amz-date:20160715T032918Z
x-amz-target:Logs_20140328.CreateLogGroup
content-length;content-type;host;user-agent;x-amz-content-sha256;x-amz-date;x-amz-target
ed5df988d44e451e18fedf10d89327e33aa4ec818bf5eac665b2679d77c22dee
[DEBUG] 2016-07-15 03:29:18 AWSAuthV4Signer [139736288929792] Final String to sign: AWS4-HMAC-SHA256
20160715T032918Z
20160715/us-west-2/logs/aws4_request
6bde1138796478370ca249eb333f7dc6fb618b90cb07f5874081196b130dd249
[DEBUG] 2016-07-15 03:29:18 AWSAuthV4Signer [139736288929792] Final computed signing hash: ca9443049e51356c14eba7fb8025aa0ebc589d4c7b4324df833df4f8c4300651
[DEBUG] 2016-07-15 03:29:18 AWSAuthV4Signer [139736288929792] Signing request with: AWS4-HMAC-SHA256 Credential=AKIAIMTDWTMSLPNECNJA/20160715/us-west-2/logs/aws4_request, SignedHeaders=content-length;content-type;host;user-agent;x-amz-content-sha256;x-amz-date;x-amz-target, Signature=ca9443049e51356c14eba7fb8025aa0ebc589d4c7b4324df833df4f8c4300651
[DEBUG] 2016-07-15 03:29:18 AWSClient [139736288929792] Request Successfully signed
[TRACE] 2016-07-15 03:29:18 CurlHttpClient [139736288929792] Making request to https://logs.us-west-2.amazonaws.com
[TRACE] 2016-07-15 03:29:18 CurlHttpClient [139736288929792] Including headers:
[TRACE] 2016-07-15 03:29:18 CurlHttpClient [139736288929792] authorization: AWS4-HMAC-SHA256 Credential=AKIAIMTDWTMSLPNECNJA/20160715/us-west-2/logs/aws4_request, SignedHeaders=content-length;content-type;host;user-agent;x-amz-content-sha256;x-amz-date;x-amz-target, Signature=ca9443049e51356c14eba7fb8025aa0ebc589d4c7b4324df833df4f8c4300651
[TRACE] 2016-07-15 03:29:18 CurlHttpClient [139736288929792] content-length: 31
[TRACE] 2016-07-15 03:29:18 CurlHttpClient [139736288929792] content-type: application/x-amz-json-1.1
[TRACE] 2016-07-15 03:29:18 CurlHttpClient [139736288929792] host: logs.us-west-2.amazonaws.com
[TRACE] 2016-07-15 03:29:18 CurlHttpClient [139736288929792] user-agent: aws-sdk-cpp/0.13.4 Linux/3.13.0-74-generic x86_64
[TRACE] 2016-07-15 03:29:18 CurlHttpClient [139736288929792] x-amz-content-sha256: ed5df988d44e451e18fedf10d89327e33aa4ec818bf5eac665b2679d77c22dee
[TRACE] 2016-07-15 03:29:18 CurlHttpClient [139736288929792] x-amz-date: 20160715T032918Z
[TRACE] 2016-07-15 03:29:18 CurlHttpClient [139736288929792] x-amz-target: Logs_20140328.CreateLogGroup
[DEBUG] 2016-07-15 03:29:18 CurlHandleContainer [139736288929792] Attempting to acquire curl connection.
[DEBUG] 2016-07-15 03:29:18 CurlHandleContainer [139736288929792] No current connections available in pool. Attempting to create new connections.
[DEBUG] 2016-07-15 03:29:18 CurlHandleContainer [139736288929792] attempting to grow pool size by 2
[INFO] 2016-07-15 03:29:18 CurlHandleContainer [139736288929792] Pool successfully grown by 2
[DEBUG] 2016-07-15 03:29:18 CurlHandleContainer [139736288929792] Returning connection handle 0x42746a0
[DEBUG] 2016-07-15 03:29:18 CurlHttpClient [139736288929792] Obtained connection handle 0x42746a0
[ERROR] 2016-07-15 03:29:18 CurlHttpClient [139736288929792] Curl returned error code 35
[DEBUG] 2016-07-15 03:29:18 CurlHandleContainer [139736288929792] Releasing curl handle 0x42746a0
[DEBUG] 2016-07-15 03:29:18 CurlHandleContainer [139736288929792] Notifying waiting threads.
[DEBUG] 2016-07-15 03:29:18 AWSClient [139736288929792] Request returned error. Attempting to generate appropriate error codes from response
[WARN] 2016-07-15 03:29:18 AWSClient [139736288929792] Request failed, now waiting 0 ms before attempting again.
The text was updated successfully, but these errors were encountered: