Friday, June 05, 2009

error when bundling OpenSolaris - based AMI on Amazon EC2

I needed a server in the cloud for a project, with Glassfish and MySQL installed. Having found a pre-built AMI (Amazon Machine Image) based on OpenSolaris it seemed to be fit for my purpose.

After kicking its tires I decided to place my customizations and re-bundle an image that would have them on upon reboot.

So I followed along the instruction from the Getting Started guide (http://docs.amazonwebservices.com/AWSEC2/latest/GettingStartedGuide/). Well, no good. The bundling failed with the following error reported by ec2-bundle-vol:


Cloning / into image file /mnt/ptmpimage...
Excluding:
/export/home
/rpool
/export
/
/mnt
/mnt
/mnt/ptmpimage
/mnt/ec2-bundle-workspace
Creating flash archive of file system...
Time: 0.086058s
Time: 0.023259s
Time: 0.229003s
Time: 0.023268s
Time: 0.113336s
Time: 0.023153s
Time: 0.036836s
devfsadm: disk_link: invalid disk device number (2051)
devfsadm: disk_link: invalid disk device number (2051)
devfsadm: disk_link: invalid disk device number (2051)
devfsadm: disk_link: invalid disk device number (2051)
devfsadm: disk_link: invalid disk device number (2051)
devfsadm: disk_link: invalid disk device number (2051)
devfsadm: disk_link: invalid disk device number (2051)
devfsadm: disk_link: invalid disk device number (2051)
devfsadm: disk_link: invalid disk device number (2051)
devfsadm: disk_link: invalid disk device number (2051)
devfsadm: disk_link: invalid disk device number (2051)
devfsadm: disk_link: invalid disk device number (2051)
devfsadm: disk_link: invalid disk device number (2051)
devfsadm: disk_link: invalid disk device number (2051)
devfsadm: disk_link: invalid disk device number (2051)
devfsadm: disk_link: invalid disk device number (2051)
devfsadm: disk_link: invalid disk device number (2051)
devfsadm: disk_link: invalid disk device number (2051)
devfsadm: disk_link: invalid disk device number (2051)
devfsadm: disk_link: invalid disk device number (2051)
devfsadm: disk_link: invalid disk device number (2051)
devfsadm: disk_link: invalid disk device number (2051)
devfsadm: disk_link: invalid disk device number (2051)
devfsadm: disk_link: invalid disk device number (2051)
devfsadm: disk_link: invalid disk device number (2051)
devfsadm: disk_link: invalid disk device number (2051)
devfsadm: disk_link: invalid disk device number (2051)
devfsadm: disk_link: invalid disk device number (2051)
devfsadm: disk_link: invalid disk device number (2051)
devfsadm: disk_link: invalid disk device number (2051)
devfsadm: disk_link: invalid disk device number (2051)
devfsadm: disk_link: invalid disk device number (2051)
devfsadm: disk_link: invalid disk device number (2051)
devfsadm: disk_link: invalid disk device number (2051)
devfsadm: disk_link: invalid disk device number (2051)
devfsadm: disk_link: invalid disk device number (2051)
devfsadm: disk_link: invalid disk device number (2051)
devfsadm: disk_link: invalid disk device number (2051)
devfsadm: disk_link: invalid disk device number (2051)
devfsadm: disk_link: invalid disk device number (2051)
devfsadm: disk_link: invalid disk device number (2051)
devfsadm: disk_link: invalid disk device number (2051)
Time: 0.400378s
ERROR: Failed to evaluate 'flar create -n ec2.archive -S -R / -x /export/home/gf21 -x /export/home/mysql -x /rpool/boot -x /rpool/etc -x /export/home -x /bin -x /boot -x /dev -x /devices -x /etc -x /export -x /home -x /kernel -x /lib -x /lost+found -x /media -x /mnt -x /net -x /opt -x /platform -x /proc -x /.profile -x /root -x /rpool -x /sbin -x /sysbench -x /system -x /tmp -x /usr -x /var -x /mnt/cert-SGB3LC7W3STUADHK6YLJGLH45V6NGQQU.pem -x /mnt/ec2-bundle-workspace -x /mnt/pk-SGB3LC7W3STUADHK6YLJGLH45V6NGQQU.pem -x /mnt/cert-SGB3LC7W3STUADHK6YLJGLH45V6NGQQU.pem -x /mnt/ec2-bundle-workspace -x /mnt/pk-SGB3LC7W3STUADHK6YLJGLH45V6NGQQU.pem -x /mnt/ptmpimage -x /mnt/ec2-bundle-workspace /mnt/ec2-bundle-workspace/archive 2> /dev/null'. Reason: .




It turns out that Solaris AMIs have a different bundling procedure, so the instructions provided by Amazon in their guide don't apply (I think they're for Fedora (or other RedHat derrivatives) images).

For instructions specific to Solaris see
this.

1 comment:

Anonymous said...

Thank you, YMMD!