Skip to content

[GCP] Support G4 preview instance type #3155

@peterschmidt85

Description

@peterschmidt85

This instance type is preview-only right now and will be generally available soon. Users want to already test it via dstack.

The instance type is not listed publiclly but can now be provisioned via gcloud CLI.

I tested the folowing command and it just worked with our latest GCP VM image:

gcloud compute instances create g4-test --machine-type "g4-standard-48" --zone "us-central1-b" --maintenance-policy TERMINATE --restart-on-failure --boot-disk-size 200 --image "projects/dstack/global/images/dstack-cuda-0-11rc2" --project dstack
Created [https://www.googleapis.com/compute/v1/projects/dstack/zones/us-central1-b/instances/g4-test].
WARNING: Some requests generated warnings:
 - Disk size: '200 GB' is larger than image size: '20 GB'. You might need to resize the root repartition manually if the operating system does not support automatic resizing. See https://cloud.google.com/compute/docs/disks/add-persistent-disk#resize_pd for details.

NAME     ZONE           MACHINE_TYPE    PREEMPTIBLE  INTERNAL_IP  EXTERNAL_IP   STATUS
g4-test  us-central1-b  g4-standard-48               10.128.0.7   34.56.24.128  RUNNING
❯ gcloud compute ssh g4-test --project=dstack
No zone specified. Using zone [us-central1-b] for instance: [g4-test].
Warning: Permanently added 'compute.7739872803818157005' (ED25519) to the list of known hosts.
Welcome to Ubuntu 24.04.3 LTS (GNU/Linux 6.14.0-1015-gcp x86_64)

 * Documentation:  https://help.ubuntu.com
 * Management:     https://landscape.canonical.com
 * Support:        https://ubuntu.com/pro

 System information as of Mon Oct  6 18:42:08 UTC 2025

  System load:  0.08               Temperature:           29.9 C
  Usage of /:   2.4% of 192.69GB   Processes:             530
  Memory usage: 0%                 Users logged in:       0
  Swap usage:   0%                 IPv4 address for ens3: 10.128.0.7


Expanded Security Maintenance for Applications is not enabled.

0 updates can be applied immediately.

Enable ESM Apps to receive additional future security updates.
See https://ubuntu.com/esm or run: sudo pro status


The list of available updates is more than a week old.
To check for new updates run: sudo apt update


The programs included with the Ubuntu system are free software;
the exact distribution terms for each program are described in the
individual files in /usr/share/doc/*/copyright.

Ubuntu comes with ABSOLUTELY NO WARRANTY, to the extent permitted by
applicable law.

cheptsov@g4-test:~$ sudo su
root@g4-test:/home/cheptsov# nvidia-smi
Mon Oct  6 18:42:16 2025
+-----------------------------------------------------------------------------------------+
| NVIDIA-SMI 570.172.08             Driver Version: 570.172.08     CUDA Version: 12.8     |
|-----------------------------------------+------------------------+----------------------+
| GPU  Name                 Persistence-M | Bus-Id          Disp.A | Volatile Uncorr. ECC |
| Fan  Temp   Perf          Pwr:Usage/Cap |           Memory-Usage | GPU-Util  Compute M. |
|                                         |                        |               MIG M. |
|=========================================+========================+======================|
|   0  NVIDIA RTX PRO 6000 Blac...    Off |   00000000:05:00.0 Off |                    0 |
| N/A   29C    P0             70W /  600W |       0MiB /  97887MiB |      0%      Default |
|                                         |                        |             Disabled |
+-----------------------------------------+------------------------+----------------------+

+-----------------------------------------------------------------------------------------+
| Processes:                                                                              |
|  GPU   GI   CI              PID   Type   Process name                        GPU Memory |
|        ID   ID                                                               Usage      |
|=========================================================================================|
|  No running processes found                                                             |
+-----------------------------------------------------------------------------------------+

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions