# Optimization

**GitProtect** provides several features to help you optimize your backup tasks and configure them quickly and easily, depending on your needs. When creating a backup plan, you can customize the backup window, task balancing, storage location, bandwidth limits, and more.

***

## Scheduler & Retention <a href="#scheduler" id="scheduler"></a>

This feature allows you to automate your backup schedule, set a backup window, and define the time zone for your backup plans.

{% hint style="info" %}
Learn more about scheduling in[ **Scheduler & Retention** article](https://helpcenter.gitprotect.io/management/scheduler-and-retention).
{% endhint %}

<figure><img src="https://696332517-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FtsE6XtJyUIEKVdSxPlS3%2Fuploads%2FBt8FiNOkhvyOavUEzy1R%2Fimage.png?alt=media&#x26;token=dc917933-940a-46a6-b802-dc3925086f0f" alt=""><figcaption></figcaption></figure>

### <mark style="background-color:blue;">Backup window</mark> <a href="#backup_window" id="backup_window"></a>

The **backup window** allows you to specify the hours during which backups are permitted to run. Any backup tasks scheduled outside of this window will not start, and tasks that exceed the allowed time frame will be stopped and marked as failed. This ensures that backups do not interfere with business hours or critical system operations, giving you full control over when your backup processes run.

{% hint style="danger" %}
There is no way to run a backup task that was stopped for exceeding the backup window.
{% endhint %}

{% hint style="danger" %}
It is not possible to run a backup task during a blocked time frame.
{% endhint %}

<figure><img src="https://696332517-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FtsE6XtJyUIEKVdSxPlS3%2Fuploads%2Fsy5UlEUX2xbhGqZRW2IB%2Fimage.png?alt=media&#x26;token=fe8a77f3-10b9-4376-a039-1cccea532581" alt=""><figcaption></figcaption></figure>

***

## Task balancing

Balance backup speed and CPU load — **task balancing** feature allows you to set a limit on the number of concurrent tasks or configure a delay between the start of successive tasks.

Task balancing can be configured in the **Advanced settings** of a backup plan.

<figure><img src="https://696332517-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FtsE6XtJyUIEKVdSxPlS3%2Fuploads%2FdQT80xyvltkRWnBldj0y%2Fimage.png?alt=media&#x26;token=83c7e492-ce26-4e1e-aa49-3a639b642df1" alt="" width="301"><figcaption></figcaption></figure>

***

## Backup storage <a href="#backup_storage" id="backup_storage"></a>

In the **Backup storage** tab, you can view information about the assigned storages—**GitProtect** is a **multi-storage system**, allowing you to distribute backup data across multiple locations.

To optimize resource usage on the devices where data is stored, you can assign each backup plan to a different storage.

***

## Backup scripts

**Backup scripts** are divided into three categories depending on the moment at which we want to execute them:

1. **Pre-backup** — executed <mark style="color:red;">**before**</mark> the backup starts. You can configure the backup to wait until this script finishes, which is mandatory for scenarios like **SQL** database backups.
2. **Post-snapshot** — executed <mark style="color:red;">**after**</mark> the backup snapshots have been created.
3. **Post-backup** — executed <mark style="color:red;">**after**</mark> the backup completes. For example, this script can be used to shut down the backed-up machine.

<figure><img src="https://696332517-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FtsE6XtJyUIEKVdSxPlS3%2Fuploads%2FAaGaySAvOKIAkq3jlZA0%2Fimage.png?alt=media&#x26;token=a5b13381-ffa6-4a36-92af-822543009e8d" alt="" width="296"><figcaption></figcaption></figure>

### <mark style="background-color:blue;">Shutdown</mark>

To shut down the computer after finishing the task, select the **Post-task script**, then choose the operating system and select **Shutdown** from the drop-down list. This script helps optimize backups by reducing energy consumption and freeing up system resources once the backup is complete, especially for machines that do not need to remain running outside working hours.

<figure><img src="https://696332517-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FtsE6XtJyUIEKVdSxPlS3%2Fuploads%2FSa10IeSBecvOcznGVk7n%2Fimage.png?alt=media&#x26;token=8bfaeb1e-7d62-4a3c-9a64-03949064e565" alt="" width="294"><figcaption></figcaption></figure>

### <mark style="background-color:blue;">Enter path</mark>

Allows you to run a custom script; simply type the path to your script to execute it using **GitProtect** (**Windows**, **Linux**, and **macOS**).

***

## Bandwidth limit

With the **bandwidth limit** feature, you can control network usage by setting an internet speed limit— simply enter a value and select the unit (**kB/s**, **MB/s**, or **GB/s**).

<figure><img src="https://696332517-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FtsE6XtJyUIEKVdSxPlS3%2Fuploads%2F4OkVbVj4p0KxQ59f8UyY%2Fimage.png?alt=media&#x26;token=ce4145af-d0b8-4e25-b5cd-b71c5fde365e" alt="" width="301"><figcaption></figcaption></figure>
