To be precise, when cleaning up resources, jclouds also cleans up any orphaned 
key pairs. However, when it cleans up the keypairs, it validates the key pair 
name against the DNS validator. The key pairs are controlled using a key pair 
extension, so jclouds validates these values before it executes the clean up 
call. Unfortunately this means once keypairs have specific names, the cleanup 
process breaks.

To get the actual key pair name, you can directly use the extension. 
Additionally, as a workaround, after deleting the server, you could delete the 
key pair yourself. The extension is part of the Nova Apis I believe.

Of course, the proper fix is to make sure the DNS validator is not used when 
cleaning up key pairs...
________________________________
From: Daniel Widdis [wid...@gmail.com]
Sent: Thursday, August 14, 2014 3:43 PM
To: user@jclouds.apache.org
Subject: Re: IllegalArgumentException when deleting node on Rackspace

Chris,

I tried again with a dns-compliant key name... same exception.  I don't think 
the name given to keys matters; the "error" is somewhere where the 
(non-compliant) server name is associated with the key (and, it's cleaning up 
resources after the very last server deletion.)

Dan

On 8/14/14, 12:50 PM, Chris Custine wrote:
If that is still being evaluated against the DnsNameValidator, it is probably 
now failing because of the underscore.  Try “dan-widdis” and see if that works. 
 Either way, this is an interesting type of issue that has come up several 
times recently so we should probably noodle this a bit and figure out if we can 
selectively relax some of these validations.

Thanks,
Chris
--
Chris Custine



On August 14, 2014 at 11:16:15 AM, Daniel Widdis 
(wid...@gmail.com<mailto:wid...@gmail.com>) wrote:

Zack,

I re-uploaded the key, giving it a lowercase name in Rackspace
(dan_widdis) and also all lowercase in my uploaded public key.

But the exception has returned. So I don't think it matters what the
key is named: what matters is the name of the server to which the key is
associated.

Dan

On 8/14/14, 9:37 AM, Zack Shoylev wrote:
> The key data is stored using name-key pairs. My guess is that the problematic 
> string is the "Dan Widdis" one, but I am still testing.
> -Zack
>
> ________________________________________
> From: Daniel Widdis [wid...@gmail.com<mailto:wid...@gmail.com>]
> Sent: Thursday, August 14, 2014 10:56 AM
> To: user@jclouds.apache.org<mailto:user@jclouds.apache.org>
> Subject: Re: IllegalArgumentException when deleting node on Rackspace
>
> Or, possibly the name I just gave was just a Rackspace-friendly name.
> The one actually in the uploaded key is:
>
> danielwiddis@Daniel-Widdiss-MacBook-Pro.local<mailto:danielwiddis@Daniel-Widdiss-MacBook-Pro.local>
>
> On 8/14/14, 7:10 AM, Zack Shoylev wrote:
>> Hi Dan,
>>
>> If you go to your myclouds.rackspace.com panel, then go to Servers, under 
>> the SSH keys tab, what SSH key names do you have?
>> I suspect jclouds expects the SSH key names to have DNS-valid names. Please 
>> let me know.
>>
>> Thanks!


Reply via email to