You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@jclouds.apache.org by Jai M <ja...@gmail.com> on 2014/02/24 21:57:14 UTC
AWS root device nam change
Hi,
I need to register an AMI from snapshot in AWS. I am using the
registerUnixImageBackedByEbsInRegion method in the AMClient.
I need to be able to specify the root deviceName. The default is
/dev/sda1 . I need to override this to /dev/sda
In the RegisterImageBackedByEbsOptions , I do not see any option to do this.
Reaching out to forum if someone has done this before or know how to do it ?
I am on 1.6.0 jclouds version.
Thanks
Jai
Re: AWS root device nam change
Posted by Andrew Phillips <an...@apache.org>.
> Thanks for confirming, Andrew I haven't done a pull request before.
> Let me see if I can do that, otherwise, I'll raise a Jira case.
Thanks! If you have any questions about contributing, feel free to ask
on IRC or send an email to the dev@ list..?
ap
Re: AWS root device nam change
Posted by Jai M <ja...@gmail.com>.
Thanks for confirming, Andrew I haven't done a pull request before.
Let me see if I can do that, otherwise, I'll raise a Jira case.
You are right, the addBlockDeviceFromSnapshot ends up adding another
block device with the specified device name.
However, In my case, I want to change the root device.
Thanks
Jai
On Mon, Feb 24, 2014 at 4:48 PM, Andrew Phillips <an...@apache.org> wrote:
>> In the RegisterImageBackedByEbsOptions , I do not see any option to do
>> this.
>
>
> Based on the Javadocs, I unfortunately don't see an option to do this
> either. In the relevant section of the code [1], the value '/dev/sda1' is
> hardcoded - you would need to create a modified version of the file to
> change this.
>
> Since the Amazon APIs *do* allow you to specify this value [2], it should be
> possible to add this to jclouds. Please create a JIRA ticket or, even
> better, a pull request [3] ;-)
>
> Thinking just in terms of workarounds, would it be possible to simply add
> *another* device (via addBlockDeviceFromSnapshot [4]) with the required
> device name?
>
> Regards
>
> ap
>
> [1]
> https://github.com/jclouds/jclouds/blob/master/apis/ec2/src/main/java/org/jclouds/ec2/features/AMIApi.java#L247
> [2]
> http://docs.aws.amazon.com/AWSEC2/latest/APIReference/ApiReference-query-RegisterImage.html
> [3] https://wiki.apache.org/jclouds/How%20to%20Contribute
> [4]
> http://demobox.github.io/jclouds-maven-site-1.6.3/1.6.3/jclouds/apidocs/org/jclouds/ec2/options/RegisterImageBackedByEbsOptions.html#addBlockDeviceFromSnapshot(java.lang.String,
> java.lang.String, java.lang.String)
Re: AWS root device nam change
Posted by Andrew Phillips <an...@apache.org>.
> In the RegisterImageBackedByEbsOptions , I do not see any option to do this.
Based on the Javadocs, I unfortunately don't see an option to do this
either. In the relevant section of the code [1], the value '/dev/sda1'
is hardcoded - you would need to create a modified version of the file
to change this.
Since the Amazon APIs *do* allow you to specify this value [2], it
should be possible to add this to jclouds. Please create a JIRA ticket
or, even better, a pull request [3] ;-)
Thinking just in terms of workarounds, would it be possible to simply
add *another* device (via addBlockDeviceFromSnapshot [4]) with the
required device name?
Regards
ap
[1]
https://github.com/jclouds/jclouds/blob/master/apis/ec2/src/main/java/org/jclouds/ec2/features/AMIApi.java#L247
[2]
http://docs.aws.amazon.com/AWSEC2/latest/APIReference/ApiReference-query-RegisterImage.html
[3] https://wiki.apache.org/jclouds/How%20to%20Contribute
[4]
http://demobox.github.io/jclouds-maven-site-1.6.3/1.6.3/jclouds/apidocs/org/jclouds/ec2/options/RegisterImageBackedByEbsOptions.html#addBlockDeviceFromSnapshot(java.lang.String, java.lang.String,
java.lang.String)