AWS Migration Hub provides a set of tools for planning your migration to cloud. An agent needs to be installed either inside the OS or on the hypervisor. Captured usage will be used to make recommendation on migration approach and even sizing. In this example, I will put agents to 2 Linux VMs and then review the recommendations.
Create IAM user
Before starting, create an IAM user with the AWSApplicationDiscoveryAgentAccess policy. Select programmatic access when creating the user, and note the access id and secret key.
Install discovery agent
On my 2 Linux VMs, install the discovery agent.
curl -o ./aws-discovery-agent.tar.gz https://s3-us-west-2.amazonaws.com/aws-discovery-agent.us-west-2/linux/latest/aws-discovery-agent.tar.gz tar -xzf aws-discovery-agent.tar.gz sudo bash install -r ap-northeast-1 -k AAA -s SSS
After a minute or 2, the servers will show up under Discover > Servers
Start data collection
Now go to Discover > Data Collectors > Agents. Select the machines and click Start data collection.
After data collection has been ran for some amount of time, preferably capturing usage of peak and normal hours, go to Access > EC2 Instance Recommendations. Choose the appropriate sizing options and deployment spec. Then click Export recommendations.
A CSV file will be available for download. Inside, one shall see the recommended instance size. In my case, even though rock8 is allocated with more CPU and RAM on the current platform, AWS recommends a smaller instance size compared to the agw VM. That makes sense, as rock8 is just a vanilla rocky linux with no application running. While agw is my VPN appliance with some light traffic.
Now we have a glimpse of what Migration Hub can do. If you are planning a more serious migration, check out the data collector tool, which can analyze usage through vCenter. With data collector, you will be able to use the Strategy tool and see if your workload is best migrated using one of the six migration strategy.