# Upgrade and Maintenance

<code class="expression">space.vars.ionos\_cloud</code> updates and patches your In-Memory DB instance to achieve high standards of functionality and security. This includes minor patches for In-Memory DB and patches for the underlying operating system. Generally, these updates are unnoticeable and do not interrupt your operation. However, occasionally, <code class="expression">space.vars.ionos\_cloud</code> restarts your In-Memory DB instance to allow the changes to take effect.

## Prerequisites

* Prepare for a downtime during the version upgrade.
* Ensure the instance has enough available storage. While the upgrade is space-efficient (because it does not copy the data directory), some temporary data is written to the disk.

{% hint style="info" %}
**Note:**

* Updates to a new minor version are always backward compatible. Such updates are done during the maintenance window with no additional actions from your end.
* Failure to configure persistence for a single instance might result in data loss.
  {% endhint %}

Currently, <code class="expression">space.vars.ionos\_cloud</code> DBaaS supports only minor version upgrades for In-Memory DB instances. Any changes that could cause service interruptions, such as version upgrades, are performed during a one-hour weekly maintenance window, which may result in brief connection interruptions. We recommend reconnecting to resume and complete any transactions that may have been affected during the maintenance window.

{% hint style="info" %}
**Note:** Maintenance operations are initiated during the scheduled one-hour weekly maintenance window, but the duration may extend depending on the task. For example, tasks such as data replication may require additional time.
{% endhint %}

You can configure a maintenance window during the In-Memory DB instance creation using the same API request. For more information, see [<mark style="color:blue;">Create an In-Memory DB Instance</mark>](/cloud/databases/in-memory-db/api-howtos/create-in-memory-db-instance.md). You can also configure one when you modify the existing In-Memory DB instance. For more information, see [<mark style="color:blue;">Modify an In-Memory DB Instance</mark>](/cloud/databases/in-memory-db/api-howtos/modify-in-memory-db-instance.md).

The following code schedules automatic maintenance every `Monday` at `16:30:59`:

```bash
"maintenanceWindow":{
         "time":"16:30:59",
         "dayOfTheWeek":"Monday"
      },
```


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://docs.ionos.com/cloud/databases/in-memory-db/overview/upgrade-maintenance.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
