Chapter 9. Configuring a RHEL instance on Google Cloud with AMD SEV SNP
To create a trusted boot environment, you can configure AMD Secure Encrypted Virtualization with Secure Nested Paging (SEV-SNP) on Red Hat Enterprise Linux (RHEL) instances on Google Cloud. SEV-SNP aims at protecting your data from access by the hypervisor and cloud service provider.
Prerequisites
-
You have installed the
opensshandopenssh-clientspackages. -
You have installed the
google-cloud-cliutility. For details, see installing gcloud CLI on RHEL. - You have created a Google Cloud instance using an AMD EPYC processor-based machine type from the supported list. For details, see the specified Google Cloud instance types.
Procedure
Log in to Google Cloud by using the
google-cloud-cliutility:gcloud auth login
$ gcloud auth loginCopy to Clipboard Copied! Toggle word wrap Toggle overflow Create a new Google Cloud project:
gcloud projects create <example_sev_snp_project> --name="RHEL SEV SNP Project"
$ gcloud projects create <example_sev_snp_project> --name="RHEL SEV SNP Project"Copy to Clipboard Copied! Toggle word wrap Toggle overflow Configure the Google Cloud project:
gcloud config set project <example_sev_snp_project>
$ gcloud config set project <example_sev_snp_project>Copy to Clipboard Copied! Toggle word wrap Toggle overflow Create a RHEL compute instance:
Copy to Clipboard Copied! Toggle word wrap Toggle overflow Connect to the RHEL instance by using public and private RSA key pair:
Connect to the RHEL instance by using a new public and private RSA key pair:
gcloud compute ssh <cloud_user>@<example-rhel-10-sev-snp-instance>
$ gcloud compute ssh <cloud_user>@<example-rhel-10-sev-snp-instance>Copy to Clipboard Copied! Toggle word wrap Toggle overflow Connect to the RHEL instance by using an existing key pair:
ssh -i <example_private_key> <cloud_user>@<instance_ip>
$ ssh -i <example_private_key> <cloud_user>@<instance_ip>Copy to Clipboard Copied! Toggle word wrap Toggle overflow
Verification
Check metadata of VM configuration on RHEL instance:
gcloud compute instances describe <example-rhel-10-sev-snp-instance> --format="get(metadata)"
$ gcloud compute instances describe <example-rhel-10-sev-snp-instance> --format="get(metadata)"Copy to Clipboard Copied! Toggle word wrap Toggle overflow Check kernel logs to verify status of SEV-SNP:
sudo dmesg | grep -i sev
$ sudo dmesg | grep -i sevCopy to Clipboard Copied! Toggle word wrap Toggle overflow Copy to Clipboard Copied! Toggle word wrap Toggle overflow