Select a documentation version: <button class="button button-with-icon cloud-select-dropdown__button button-primary" aria-haspopup="true">16.3.0</button>

- [16.3.0](https://docs.cloud.google.com/alloydb/omni/kubernetes/16.3.0/docs/quickstart.md.txt)
- [15.7.1](https://docs.cloud.google.com/alloydb/omni/kubernetes/15.7.1/docs/quickstart.md.txt)
- [15.7.0](https://docs.cloud.google.com/alloydb/omni/kubernetes/15.7.0/docs/quickstart.md.txt)
- [15.5.5](https://docs.cloud.google.com/alloydb/omni/kubernetes/15.5.5/docs/quickstart.md.txt)
- [15.5.4](https://docs.cloud.google.com/alloydb/omni/kubernetes/15.5.4/docs/quickstart.md.txt)
- [15.5.2](https://docs.cloud.google.com/alloydb/omni/kubernetes/15.5.2/docs/quickstart.md.txt)

<br />

This quickstart shows you how to install AlloyDB Omni that can run in any UNIX-based environment which supports container runtimes.

<br />

For an overview of AlloyDB Omni, see [AlloyDB Omni overview](https://docs.cloud.google.com/alloydb/omni/kubernetes/16.3.0/docs).

## Before you begin

Before you install AlloyDB Omni, make sure that you meet the
following requirements.

> [!NOTE]
> **Note:** You can run AlloyDB Omni on macOS. However, AlloyDB Omni in a Docker container on macOS uses Docker's compatibility layer, which can result in reduced performance compared to running it directly on Linux.

### Choose a download or installation option

<br />

| **Media** | **Download locations and installation guides** | **Deployment to** |
|---|---|---|
| **Debian image** | [DockerHub](https://hub.docker.com/r/google/alloydbomni/tags) (tags) | - [Docker](https://www.docker.com/), [Podman](https://podman.io/). You can run these containerization tools as a container in any virtual machine (VM). <!-- --> - [Google Cloud Marketplace](https://console.cloud.google.com/marketplace/product/click-to-deploy-images/alloydb-omni) <!-- --> - [AWS Marketplace](https://aws.amazon.com/marketplace/pp/prodview-sne7ttiby7nxi) <!-- --> - [Azure Marketplace](https://azuremarketplace.microsoft.com/en-us/marketplace/apps/google-cloud-alloydb-omni.alloydbomni?tab=overview) |
| **UBI Image (Red Hat)** | [Red Hat Ecosystem Catalog](https://catalog.redhat.com/software/container-stacks/detail/67d88bd7ce4ca47642c2a072) | - Red Hat environment. Run this as a container. <!-- --> - [Red Hat Marketplace](https://catalog.redhat.com/software/containers/google/alloydbomni/681daa13362cef4fe8a0115f) (UBI) |

<br />

### Fulfill hardware and software requirements

Make sure that you meet the following minimum hardware and software requirements:

<br />

| OS/Platform | Minimum hardware | Minimum software |
|---|---|---|
| Linux | - x86-64 or Arm (\*) CPU with AVX2 support - 2 GB of RAM - 10 GB of disk space | - Debian based OS (Ubuntu, etc.), RHEL 8 or 9 - Linux kernel version 5.3 or higher - [Cgroupsv2 enabled](https://docs.cloud.google.com/alloydb/omni/kubernetes/16.3.0/docs/quickstart.md.txt#verify-cgroupsv2) - Docker Engine 20.10+ or Podman 4.2.0+ |
| macOS | - Intel CPU with AVX2 support or M-chip - 2GB of RAM - 10 GB of disk space | - Docker Desktop 4.20 or higher |

<br />

> [!NOTE]
> **Note:** AlloyDB Omni supports Arm ([Preview](https://cloud.google.com/products#product-launch-stages)).

#### Verify that cgroupsv2 is enabled

To determine whether cgroupsv2 is enabled on your machine, run the following command:

```bash
grep cgroup /proc/filesystems
```

If your machine supports cgroupsv2, you see the following output:

    nodev cgroup
    nodev cgroupsv2

If your machine doesn't support cgroupsv2, you see the following output:

    nodev cgroup

### Install a container runtime

Install a container runtime like [Docker](https://docs.docker.com/engine/install/)
or [Podman](https://podman.io/docs/installation). AlloyDB Omni
runs in a container.

## Install AlloyDB Omni using Docker

[Root access](https://docs.docker.com/engine/install/linux-postinstall/#manage-docker-as-a-non-root-user) isn't required for installing AlloyDB Omni.

> [!NOTE]
> **Note:** If you want to deploy AlloyDB Omni in your production environment, see [Run AlloyDB Omni in production](https://docs.cloud.google.com/alloydb/omni/current/docs/run-alloydb-omni-production).

### Docker

1. Use the `docker run` command to create a new container with AlloyDB Omni named `my-omni`:

   ```bash
     docker run --name my-omni \
       -e POSTGRES_PASSWORD=NEW_PASSWORD \
       -d google/alloydbomni:IMAGE_TAG
   ```

   Replace the following variables:
   - `NEW_PASSWORD`: the password to assign the new container's `postgres` user after its creation.
   - `IMAGE_TAG`: use `16.3.0` for the latest Debian
     image or `16.3.0-ubi` for the latest UBI image.

     > [!NOTE]
     > **Note:** By default, AlloyDB Omni stores your data on the container itself, and not on your host file system. The data directory is deleted once you delete your AlloyDB Omni container. To mount a data directory stored on your host file system, see instructions in [Customize your AlloyDB Omni installation](https://docs.cloud.google.com/alloydb/omni/kubernetes/16.3.0/docs/install.md.txt).

2. Connect to containerized AlloyDB Omni using `psql`:

   ```bash
     docker exec -it my-omni psql -h localhost -U postgres
   ```

   The terminal window displays `psql` login text that ends with a
   `postgres=#` prompt.

### Podman

1. Use the `podman run` command to create a new container with AlloyDB Omni named `my-omni`:

   ```bash
     podman run --name my-omni \
       -e POSTGRES_PASSWORD=NEW_PASSWORD \
       -d google/alloydbomni:IMAGE_TAG
   ```

   Replace the following variables:
   - `NEW_PASSWORD`: the password to assign the new container's `postgres` user after its creation.
   - `IMAGE_TAG`: use `16.3.0` for the latest Debian
     image or `16.3.0-ubi` for the latest UBI image.

     > [!NOTE]
     > **Note:** By default, AlloyDB Omni stores your data on the container itself, and not on your host file system. The data directory is deleted once you delete your AlloyDB Omni container. To mount a data directory stored on your host file system, see instructions in [Customize your AlloyDB Omni installation](https://docs.cloud.google.com/alloydb/omni/kubernetes/16.3.0/docs/install.md.txt).

2. Connect to containerized AlloyDB Omni using `psql`:

   ```bash
   podman exec -it my-omni psql -h localhost -U postgres
   ```

   The terminal window displays `psql` login text that ends with a
   `postgres=#` prompt.

## Clean up

To clean up the AlloyDB Omni container you created during this quickstart, use these steps:

### Docker

1. Stop your AlloyDB Omni container named `my-omni`:

   ```bash
     docker container stop my-omni
   ```
2. Delete your AlloyDB Omni container named `my-omni`:

   ```bash
     docker container rm my-omni
   ```

### Podman

1. Stop your AlloyDB Omni container named `my-omni`:

   ```bash
     podman container stop my-omni
   ```
2. Delete your AlloyDB Omni container named `my-omni`:

   ```bash
     podman container rm my-omni
   ```

For instructions how to install AlloyDB Omni in a new container for production usage, go to the [Customize your AlloyDB Omni installation](https://docs.cloud.google.com/alloydb/omni/kubernetes/16.3.0/docs/install.md.txt) page.

## What's next

- [Run and connect to AlloyDB Omni](https://docs.cloud.google.com/alloydb/omni/kubernetes/16.3.0/docs/run-connect.md.txt)

- [Customize your AlloyDB Omni installation](https://docs.cloud.google.com/alloydb/omni/kubernetes/16.3.0/docs/install.md.txt)

- [Set up your AlloyDB Omni for production](https://docs.cloud.google.com/alloydb/omni/kubernetes/16.3.0/docs/configure-omni.md.txt)