I'm trying to create a new user in our SoftLayer account using the SoftLayer python API. Here's the code that I'm running in my python interpreter:
import SoftLayer
client = SoftLayer.create_client_from_env("<user-id>", "<api -key>",SoftLayer.API_PUBLIC_ENDPOINT,240)
client['Account'].getCurrentUser() # This returns some info about the user, showing that I've successfully connected to the SoftLayer public API endpoint.
username="april19csctest1"
first="april19csc"
last="test1"
email="<my-email>"
user_template = {'username': username,'firstName': first,'lastName': last,'email': email,'companyName': '<companyName>','address1': 'my-address','city': '<city>','state': 'ON','country': 'CA','postalCode': '<my-postal-code>','userStatusId': 1001,'timezoneId': 120,'sslVpnAllowedFlag': True,'vpnManualConfig': False,'secondaryPasswordTimeoutDays' : 90}
password="<some-random-password>"
newUser = client['User_Customer'].createObject(user_template,password,password)
After 60 seconds (which is shorter than the timeout I set in SoftLayer.create_client_from_env(...)), that last line prints an error:
Traceback (most recent call last):
File "", line 1, in
File "/usr/local/lib/python2.7/dist-packages/SoftLayer/API.py", line 363, in call_handler
return self(name, *args, **kwargs)
File "/usr/local/lib/python2.7/dist-packages/SoftLayer/API.py", line 331, in call
return self.client.call(self.name, name, *args, **kwargs)
File "/usr/local/lib/python2.7/dist-packages/SoftLayer/API.py", line 227, in call
return self.transport(request)
File "/usr/local/lib/python2.7/dist-packages/SoftLayer/transports.py", line 160, in __call__
raise _ex(ex.faultCode, ex.faultString)
SoftLayer.exceptions.SoftLayerAPIError: SoftLayerAPIError(SoftLayer_Exception_Public): Time out occurred while adding user
Here's the tcpdump output when I run client['User_Customer'].createObject(user_template,password,password). It looks like after 60 seconds, the SoftLayer server replies to my computer saying that there was a timeout. So, it looks to me like my connection to SoftLayer's api endpoint is fine, and the 240-second timeout I set in my API client is fine, but SoftLayer's servers are internally throwing this timeout error:
16:53:02.554555 IP 10.10.8.121.59366 > 78.77.e442.ip4.static.sl-reverse.com.https: Flags [S], seq 1152464108, win 28200, options [mss 1410,sackOK,TS val 755142197 ecr 0,nop,wscale 7], length 0 16:53:02.587518 IP 78.77.e442.ip4.static.sl-reverse.com.https > 10.10.8.121.59366: Flags [S.], seq 2170195113, ack 1152464109, win 8190, options [mss 1360,nop,wscale 4,nop,nop,sackOK], length 0 16:53:02.587618 IP 10.10.8.121.59366 > 78.77.e442.ip4.static.sl-reverse.com.https: Flags [.], ack 1, win 221, length 0 16:53:02.602741 IP 10.10.8.121.59366 > 78.77.e442.ip4.static.sl-reverse.com.https: Flags [P.], seq 1:310, ack 1, win 221, length 309 16:53:02.635693 IP 78.77.e442.ip4.static.sl-reverse.com.https > 10.10.8.121.59366: Flags [P.], seq 1:1361, ack 310, win 2191, length 1360 16:53:02.635730 IP 10.10.8.121.59366 > 78.77.e442.ip4.static.sl-reverse.com.https: Flags [.], ack 1361, win 243, length 0 16:53:02.635743 IP 78.77.e442.ip4.static.sl-reverse.com.https > 10.10.8.121.59366: Flags [P.], seq 1361:2717, ack 310, win 2191, length 1356 16:53:02.635753 IP 10.10.8.121.59366 > 78.77.e442.ip4.static.sl-reverse.com.https: Flags [.], ack 2717, win 265, length 0 16:53:02.655966 IP 78.77.e442.ip4.static.sl-reverse.com.https > 10.10.8.121.59366: Flags [P.], seq 2717:3059, ack 310, win 2191, length 342 16:53:02.656022 IP 10.10.8.121.59366 > 78.77.e442.ip4.static.sl-reverse.com.https: Flags [.], ack 3059, win 286, length 0 16:53:02.657166 IP 10.10.8.121.59366 > 78.77.e442.ip4.static.sl-reverse.com.https: Flags [P.], seq 310:436, ack 3059, win 286, length 126 16:53:02.689966 IP 78.77.e442.ip4.static.sl-reverse.com.https > 10.10.8.121.59366: Flags [.], ack 436, win 2184, length 0 16:53:02.710273 IP 78.77.e442.ip4.static.sl-reverse.com.https > 10.10.8.121.59366: Flags [P.], seq 3059:3110, ack 436, win 2184, length 51 16:53:02.711410 IP 10.10.8.121.59366 > 78.77.e442.ip4.static.sl-reverse.com.https: Flags [P.], seq 436:2672, ack 3110, win 286, length 2236 16:53:02.744620 IP 78.77.e442.ip4.static.sl-reverse.com.https > 10.10.8.121.59366: Flags [.], ack 2672, win 2044, length 0 ## nothing printed for a while. 60 seconds later, the following is printed: 16:54:10.162548 IP 78.77.e442.ip4.static.sl-reverse.com.https > 10.10.8.121.59366: Flags [P.], seq 3110:3626, ack 2672, win 65535, length 516 16:54:10.165530 IP 10.10.8.121.59366 > 78.77.e442.ip4.static.sl-reverse.com.https: Flags [P.], seq 2672:2703, ack 3626, win 307, length 31 16:54:10.167088 IP 10.10.8.121.59366 > 78.77.e442.ip4.static.sl-reverse.com.https: Flags [F.], seq 2703, ack 3626, win 307, length 0 16:54:10.198582 IP 78.77.e442.ip4.static.sl-reverse.com.https > 10.10.8.121.59366: Flags [.], ack 2703, win 2559, length 0 16:54:10.198675 IP 78.77.e442.ip4.static.sl-reverse.com.https > 10.10.8.121.59366: Flags [F.], seq 3626:3657, ack 2703, win 2559, length 31 16:54:10.198723 IP 10.10.8.121.59366 > 78.77.e442.ip4.static.sl-reverse.com.https: Flags [R], seq 1152466811, win 0, length 0
Questions:
- Is this indeed an issue on SoftLayer's side? Or, is there anything I can do to resolve this?
- Is SoftLayer investigating this issue?