Elizabeth
Elizabeth

Reputation: 297

Update Google Compute Engine Instance type in real time

I would like to know if you can change the type of one instance to another, e.g:

n1-standard-1 to n1-standard-2

I don't see nothing to that in the documentation, but may be I miss something.

In case that is not posible, how i deal with this, there is another way to do this change?

Upvotes: 9

Views: 3330

Answers (2)

user33629
user33629

Reputation: 171

You can stop the machine, edit it then launch it again. I just did it now and it worked fine.

switched from micro to small without changing my data.

Regards.

Upvotes: 16

Carlos Rojas
Carlos Rojas

Reputation: 5897

You need create a new instance with the new type.

  1. Disconnect your persistent disk from n1-standard-1.

  2. Create new instance in the same zone with the type n1-standard-2 and choose boot from disk. (choose the persistent disk)

  3. Run the new instance.

Note: I recommend have a snapshot from the disk before to try this procedure.

for realtime you can choose in "boot from disk" choose the snapshot instead of the persistent disk. and when you test that this instance its working, associate the ip address from VM1 to VM2.

Upvotes: 9

Related Questions