2010-09-09 54 views
3

有几个应用程序,其中EC2小型实例太大了。所以微型实例的发布正是医生所订购的。EC2小型到微型实例降级问题

我想采取一个小实例的EBS卷,分离它,并与微型实例配对。在某种程度上,以另一种方式并将微型实例升级为小型或超越型可能会很好。

对于这个实验失败我想:

  1. 创建一个新的小实例与Alestic的Ubuntu 10.04 32位AMI(AMI-1234de7b)。靴子就像一个魅力。
  2. 关闭我新鲜铸造的微型实例,分离上一步为我创建的卷。
  3. 将小实例的卷附加到微实例。
  4. 加电。
  5. Nada。

有什么奇怪的是,没有控制台日志输出直到我关机。然后我看到了这一切。

[ 0.000000] Reserving virtual address space above 0xf5800000 
[ 0.000000] Initializing cgroup subsys cpuset 
[ 0.000000] Initializing cgroup subsys cpu 
... 
[ 1.221261] VFS: Mounted root (ext3 filesystem) readonly on device 8:1. 
[ 1.221261] VFS: Mounted root (ext3 filesystem) readonly on device 8:1. 
[ 1.222164] devtmpfs: mounted 
[ 1.222202] Freeing unused kernel memory: 216k freed 
[ 1.223409] Write protecting the kernel text: 4328k 
[ 1.223760] Write protecting the kernel read-only data: 1336k 
init: console-setup main process (63) terminated with status 1 
%Ginit: plymouth main process (45) killed by SEGV signal 
init: plymouth-splash main process (196) terminated with status 2 
cloud-init running: Thu, 09 Sep 2010 17:37:54 +0000. up 2.61 seconds 
mountall: Disconnected from Plymouth 
init: hwclock-save main process (291) terminated with status 1 
Checking for running unattended-upgrades: * Asking all remaining processes to terminate...  
[80G 
[74G[ OK ] 
* All processes ended within 1 seconds....  
[80G 
[74G[ OK ] 
* Deconfiguring network interfaces...  
[80G 
[74G[ OK ] 
* Deactivating swap...  
[80G 
[74G[ OK ] 
* Unmounting local filesystems...  
[80G 
[74G[ OK ] 
* Will now halt 
[ 185.599636] System halted. 

交换的这种方法在过去同尺寸的实例化之间运作良好,这是我在不同尺寸之间做这第一次尝试。这仅仅是不可能的,还是我错过了我的EC2知识中的一些基础知识?

回答

-1

我没有在您身边看到问题。这可能是亚马逊基础架构中的一个问题。

5

即使这可能会迁移到服务器故障,我今天早些时候遇到了与此实例完全相同的问题。

看起来这个图像assumes that there will be ephemeral storage present,当微实例没有。要解决这个问题,注释掉在/ etc/fstab中的以下行:

/dev/sda2 /mnt auto defaults,comment=cloudconfig 0 0 

这可以防止例如,从挂在启动时,或者至少是与AMI-1234de7b为我做的。

1

我使用alestic ami(ami-2c354b7e)创建了一个新的微型实例。我能够第一次正常登录系统。但一旦我重新启动系统,我无法再次登录。

评论上面指出的行为我工作。 “/ dev/sda2/mnt auto defaults,comment = cloudconfig 0 0”

1

将线条注释掉并没有完全解决。如果重新启动,它会写在同一行早在您需要:

$ l="deb http://archive.ubuntu.com/ubuntu lucid-proposed main" 
$ echo "$l" | sudo tee -a /etc/apt/sources.list 
$ sudo apt-get update && sudo apt-get install cloud-init 
$ dpkg-query --show cloud-init 

我假定这将很快固定在Ubuntu官方发布,你会不会有做到这一点,但对于现在...

来源:https://bugs.launchpad.net/ubuntu/+source/cloud-init/+bug/634102

同时,我们有过基于Ubuntu官方AMI的微的这项工作一对夫妇图片:http://blog.simpledeployr.com/2010/09/new-ruby-amis-with-latest-ubuntu-lucid.html