It is a tricky problem. I'll comment on the ticket.
Post by Kyle RamesI am glad you got it figured out!
It looks like we are specifically thwarting you attempts to find out this
information by catching the Net::SSH::AuthenticationFailed exception here
https://github.com/fog/fog/blob/master/lib/fog/compute/models/server.rb#L72
To answer your question, I believe you could have updated line 76 to
include a :verbose => :debug which would have probably gotten some
better debug information from the SSH library.
server.setup(:key_data => [spot_request.private_key], :verbose => :debug
)
I think this is very unintuitive and I can see this issue cropping up for
other developers. To that end, I created a github issue to get this fixed.
https://github.com/fog/fog/issues/2273.
Kyle
Post by Sylvain KalacheThanks Kyle for your answer.
So actually the issue was coming from line 76 with server.setup(
:key_data => [spot_request.private_key])
My bad, I was specifying the wrong private key.
Is there anyway that I could have debug this in a easier/faster way?
Post by Kyle RamesHmmmm.
wait_for just reloads the server state and then calls the ready? method
to determine if the server is ready for usage. Looking at the
implementation of the ready? method, it seems to check to see if it is in
the 'running' state. It could be that this implementation needs to be
revised.
https://github.com/fog/fog/**blob/master/lib/fog/aws/**
models/compute/server.rb#L133-**L135<https://github.com/fog/fog/blob/master/lib/fog/aws/models/compute/server.rb#L133-L135>
Can you run your script again and prefix it with EXCON_DEBUG=true. That
will print out the request/response coming from aws.
Kyle
Post by Sylvain KalacheThanks for your answer.
Unfortunately that did not make the trick. What is weird is that the
spot instance is in a running state and I can SSH to it, but it's still
timing out on server.wait_for { ready? }
I'll dive deeper in this wait_for method.
Post by geemus (Wesley Beary)By default timeout is 600 seconds (10 minutes). Which is usually
sufficient. If you are running into issues like this regularly you can bump
https://github.com/fog/**fog/blob/master/lib/fog/core/**timeout.rb<https://github.com/fog/fog/blob/master/lib/fog/core/timeout.rb>
Hope that helps, that should be the easiest way to accommodate for
the timeouts I believe.
On Mon, Oct 14, 2013 at 7:48 PM, Sylvain Kalache <
Post by Sylvain KalacheHello,
I'm launching AWS spot instance with the
fog.spot_requests.bootstrap() method.
Sometime it works, sometime it timeout on line 75 of the file
spot_requests.rb
https://github.com/fog/fog/**blob/master/lib/fog/aws/**
models/compute/spot_requests.**rb<https://github.com/fog/fog/blob/master/lib/fog/aws/models/compute/spot_requests.rb>
However the spot instance is actually launched, running state. Any
idea of what I can do to avoid that?
Cheers!
--
You received this message because you are subscribed to the Google
Groups "ruby-fog" group.
To unsubscribe from this group and stop receiving emails from it,
For more options, visit https://groups.google.com/**groups/opt_out<https://groups.google.com/groups/opt_out>
.
--
You received this message because you are subscribed to the Google Groups
"ruby-fog" group.
To unsubscribe from this group and stop receiving emails from it, send an
For more options, visit https://groups.google.com/groups/opt_out.