clearml-docs/docs/deploying_clearml/upgrade_server_linux_mac.md

61 lines
2.4 KiB
Markdown
Raw Normal View History

2021-05-13 23:48:51 +00:00
---
title: Linux or macOS
---
2023-02-22 10:29:36 +00:00
<Collapsible title="Important: Upgrading from v0.14 or older" type="info">
2021-05-13 23:48:51 +00:00
2023-02-22 10:29:36 +00:00
For Linux only, if upgrading from <strong>Trains Server</strong> v0.14 or older, configure the <strong>ClearML Agent Services</strong>.
2021-05-13 23:48:51 +00:00
2022-05-19 06:59:10 +00:00
* If ``CLEARML_HOST_IP`` is not provided, then **ClearML Agent Services** uses the external public address of the ClearML Server.
2024-07-21 12:19:32 +00:00
* If ``CLEARML_AGENT_GIT_USER`` / ``CLEARML_AGENT_GIT_PASS`` are not provided, then **ClearML Agent Services** can't access any private repositories for running service tasks:
2021-05-13 23:48:51 +00:00
2024-06-30 06:16:11 +00:00
```
export CLEARML_HOST_IP=server_host_ip_here
export CLEARML_AGENT_GIT_USER=git_username_here
export CLEARML_AGENT_GIT_PASS=git_password_here
```
2021-05-13 23:48:51 +00:00
:::note
For backwards compatibility, the environment variables ``TRAINS_HOST_IP``, ``TRAINS_AGENT_GIT_USER``, and ``TRAINS_AGENT_GIT_PASS`` are supported.
:::
2023-02-22 10:29:36 +00:00
</Collapsible>
2021-05-13 23:48:51 +00:00
<br/>
**To upgrade ClearML Server Docker deployment:**
2024-07-21 12:19:32 +00:00
1. Shutdown ClearML Server. Execute the following command (which assumes the configuration file is in the environment path):
2024-06-30 06:16:11 +00:00
```
docker-compose -f docker-compose.yml down
```
2021-05-13 23:48:51 +00:00
2022-02-13 16:54:59 +00:00
1. If upgrading from **Trains Server** version 0.15 or older, a data migration is required before continuing this upgrade. See instructions [here](clearml_server_es7_migration.md).
2021-05-13 23:48:51 +00:00
2022-02-13 17:40:04 +00:00
1. If upgrading from ClearML Server version older than 1.2, you need to migrate your data before upgrading your server. See instructions [here](clearml_server_mongo44_migration.md).
2022-05-19 06:59:10 +00:00
1. [Backing up data](clearml_server_linux_mac.md#backing-up-and-restoring-data-and-configuration) is recommended and, if the configuration folder is
2021-05-13 23:48:51 +00:00
not empty, backing up the configuration.
2024-07-21 12:19:32 +00:00
1. If upgrading from **Trains Server** to **ClearML Server**, rename `/opt/trains` and its subdirectories to `/opt/clearml`:
2021-05-13 23:48:51 +00:00
2024-06-30 06:16:11 +00:00
```
sudo mv /opt/trains /opt/clearml
```
2024-07-21 12:19:32 +00:00
1. Download the latest `docker-compose.yml` file:
2021-05-13 23:48:51 +00:00
2024-06-30 06:16:11 +00:00
```
curl https://raw.githubusercontent.com/allegroai/clearml-server/master/docker/docker-compose.yml -o /opt/clearml/docker-compose.yml
```
2024-07-21 12:19:32 +00:00
1. Startup ClearML Server. This automatically pulls the latest ClearML Server build:
2021-05-13 23:48:51 +00:00
2024-06-30 06:16:11 +00:00
```
docker-compose -f /opt/clearml/docker-compose.yml pull
docker-compose -f /opt/clearml/docker-compose.yml up -d
```
2021-05-13 23:48:51 +00:00
2024-07-21 12:19:32 +00:00
If issues arise during your upgrade, see the FAQ page, [How do I fix Docker upgrade errors?](../faq.md#common-docker-upgrade-errors)