Saturday, August 13, 2022
Advertisement
Firnco
  • Home
  • Cloud Computing
  • Cybersecurity News
  • Tutorials & Certification
No Result
View All Result
  • Home
  • Cloud Computing
  • Cybersecurity News
  • Tutorials & Certification
No Result
View All Result
Firnco
No Result
View All Result
Home Cloud Computing

How one can migrate a gaggle of person circumstances to a stateful MIG the usage of Python script

August 7, 2022
in Cloud Computing
Reading Time: 7 mins read
0
How one can migrate a gaggle of person circumstances to a stateful MIG the usage of Python script
74
SHARES
1.2k
VIEWS
Share on Twitter



A GCP Compute Engine controlled example staff (MIG) helps any VM configuration that you want, and it is helping organize the VMs for you. As an example, when a VM in a MIG abruptly stops working, the MIG recreates that VM in keeping with the configuration that you just set. You’ll additionally arrange an application-based well being test to ensure that your utility responds as anticipated on every VM.

Along with that, MIGs additionally lets you deploy complicated stateful packages, similar to databases (Cassandra, ElasticSearch) or information processing packages (Kafka, Flink), the place preservation of person VM state (for instance, a database shard, or app configuration) is necessary. 

In case you are simply beginning to paintings with GCP and need to deploy a stateful utility, then it’s extremely beneficial to make use of a stateful MIG configuration. A stateful MIG lets you keep the original state of every example (together with example title, connected continual disks, IP addresses – to be had in Preview, and metadata) on VM restart, sport, auto-healing, or replace. You’ll be told extra about Stateful MIGs via studying the medical doctors.

The purpose of this weblog submit is to assist those that have already got an present stateful utility working on standalone (unmanaged) Compute Engine circumstances and who need to mechanically migrate them to a stateful MIG the usage of a Python script. The script code and detailed directions for its use and set up may also be discovered right here. In case you need to do that complete procedure manually, you’ll pass in the course of the Migrate an present workload to a stateful controlled example staff educational.

Let’s dive into the good judgment of the script and notice how it may be performed. 

Script necessities

Earlier than working the script, make sure that your present circumstances meet the next standards:

  • All supply circumstances will have to have the similar example configuration (for instance, gadget sort). Keep in mind that all circumstances in a MIG are created in keeping with the similar example template. The script creates a template for you in keeping with considered one of your present circumstances.

  • Your boot disks must be stateless. Should you will have to keep state in your boot disks, then you’ll nonetheless create a stateful MIG, however you can’t replace running programs or tool via rolling out boot symbol updates.

  • The script will forestall your supply VM circumstances. The script leaves all supply VMs stopped with their disks intact, for simple reverting if the MIG does not paintings as anticipated. This leads to further prices, for the next causes:

  1. The script does not detach or delete the unique disks.

  2. The script creates photographs from present disks.

Script steps

  1. Forestall all circumstances

  2. If wanted, create a boot disk symbol

  3. Create an example template in keeping with the houses of a selected example, whilst ignoring connected information disks.

  4. Create an empty MIG.

  5. For every example within the unique staff, carry out the next steps:

    1. Clone all example disks excluding the boot disk.

    2. Create an example within the MIG in keeping with the example template, and come with the cloned disks from the supply example.

  6. Print instructions for cleansing up the supply circumstances upon getting verified that the stateful MIG serves your wishes.

In case you are in a position to make use of the script, apply the hyperlink for set up and execution.

Utilization instance

Let’s now believe some example configuration and display how the script proceeds. Assume now we have 3 standalone circumstances with names “alpha”, “beta”, and “gamma” within the us-central1-a zone and we need to migrate them to a MIG with the title “greek”.

Example “alpha” has two further disks: “alpha-disk-1” and “alpha-disk-2”, example “beta” has one further disk “beta-disk-1”, and “gamma” has 0 further disks. On the similar time we wish to create a disk symbol for the boot symbol.

Run the next command:

$ python3 migrate_script.py -s alpha beta gamma -z us-central1-a -m greek --image_for_boot_disk

Let’s have a look at the output step-by-step:

  1. The entire circumstances are stopped on the very starting.



Supply hyperlink

Tweet19

Recommended For You

CCSK Good fortune Tales: From the VP of Inner Safety

August 13, 2022
CCSK Good fortune: From a CISO and Leader Privateness Officer

This is a part of a weblog collection interviewing cybersecurity execs who've earned their Certificates of Cloud Safety Wisdom (CCSK). In those blogs we invite people to proportion...

Read more

Who Plays a SOC 2 Audit? The Position of SOC 2 Auditors

August 13, 2022
Who Plays a SOC 2 Audit? The Position of SOC 2 Auditors

Firstly revealed via A-LIGN right here. Written via Stephanie Oyler, Vice President of Attestation Products and services, A-LIGN. Information breaches and ransomware assaults proceed to dominate the inside...

Read more

The usage of Id Governance and Azure Purposes To Construct a Self-Provider Utility Get right of entry to Control Answer – Phase 2

August 13, 2022
The usage of Id Governance and Azure Purposes To Construct a Self-Provider Utility Get right of entry to Control Answer – Phase 2

On this sequence:Growing an authenticated internet software and the use of Azure Purposes to ask visitor customers to the groupGrowing an get right of entry to package deal...

Read more

5 Tactics the Cloud Can Free up New Alternatives for Your Accounting Observe

August 13, 2022

The accountancy career is awash with communicate of cloud adoption. Certainly, many companies have already recognised one of the tangible advantages that the cloud can carry. On the...

Read more

SOC as a Provider: The entirety You Want to Know

August 13, 2022
SOC as a Provider: The entirety You Want to Know

SOC as a Provider: The entirety You Want to Know Via WatServ August 12, 2022 A big pillar of any group’s clean operations is a forged cybersecurity plan....

Read more
Next Post
Azure IoT Edge 1.3.0 unencumber

Azure IoT Edge 1.3.0 unencumber

Leave a Reply Cancel reply

Your email address will not be published. Required fields are marked *

Related News

Amazon RDS for MariaDB helps new minor variations 10.6.8, 10.5.16, 10.4.25, 10.3.35, 10.2.44

AWS AppSync launches new API command to check GraphQL resolvers

July 28, 2022
Jonnychipz – In Dialog with Jeff Wouters – Cloud Computing with a facet of Chipz

Jonnychipz – In Dialog with Jeff Wouters – Cloud Computing with a facet of Chipz

August 2, 2022
Stegomalware Surge – Attackers The use of Document, Video, Symbol To Disguise Malware

Stegomalware Surge – Attackers The use of Document, Video, Symbol To Disguise Malware

August 8, 2022

Browse by Category

  • Black Hat
  • Breach
  • Cloud Computing
  • Cloud Security
  • Cybersecurity News
  • Hacks
  • InfoSec Insider
  • IoT
  • Malware
  • Malware Alerts
  • News
  • Podcasts
  • Privacy
  • Sponsored
  • Tutorials & Certification
  • Vulnerabilities
  • Web Security
Firnco

© 2022 | Firnco.com

66 W Flagler Street, suite 900 Miami, FL 33130

  • About Us
  • Home
  • Privacy Policy

305-647-2610 [email protected]

No Result
View All Result
  • Home
  • Cloud Computing
  • Cybersecurity News
  • Tutorials & Certification

© 2022 | Firnco.com

Are you sure want to unlock this post?
Unlock left : 0
Are you sure want to cancel subscription?