# Database initialization

> Configure Airflow Database start-up.

By default, Airflow will run database initialization routines (checking and/or creating the metadata schema and creating an admin user) on start-up. These are idempotent and can be run every time as the overhead is minimal. However, if these steps should be skipped, a running Airflow cluster can be patched with a resource like this to deactivate the initialization:

```yaml
---
apiVersion: airflow.stackable.tech/v1alpha1
kind: AirflowCluster
metadata:
  name: airflow
spec:
  clusterConfig:
    databaseInitialization:
      enabled: false  (1)
```

(1) Turn off the initialization routine by setting `databaseInitialization.enabled` to `false`

> **Note:** The field `databaseInitialization.enabled` is `true` by default to be backwards-compatible. A fresh Airflow cluster cannot be created with this field set to `false` as this results in missing metadata in the Airflow database.

> **Warning:** Setting `databaseInitialization.enabled` to `false` is an unsupported operation as subsequent updates to a running Airflow cluster can result in broken behaviour due to inconsistent metadata. Only set `databaseInitialization.enabled` to `false` if you know what you are doing!
