Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update docker quick start section in docs #11485

Open
wants to merge 12 commits into
base: main
Choose a base branch
from

Conversation

ggerlakh
Copy link

@ggerlakh ggerlakh commented Nov 11, 2024

Changelog category

  • Documentation (changelog entry is not required)

Additional information

Update docker quick start section in documentation for Macs with ARM

Copy link

Hi! Thank you for contributing!
The tests on this PR will run after a maintainer adds an ok-to-test label to this PR manually. Thank you for your patience!

@asmyasnikov asmyasnikov added the ok-to-test Special label used to approve a PR for testing on our infrastructure label Nov 11, 2024
@github-actions github-actions bot removed the ok-to-test Special label used to approve a PR for testing on our infrastructure label Nov 11, 2024
Copy link

❌ Documentation build

Revision build failed

Build logs

Errors (6)

❌ /en/quickstart.md: 102: MD009/no-trailing-spaces Trailing spaces [Expected: 0 or 2; Actual: 6]

❌ /en/quickstart.md: 106: MD009/no-trailing-spaces Trailing spaces [Expected: 0 or 2; Actual: 6]

❌ /en/quickstart.md: 108: MD009/no-trailing-spaces Trailing spaces [Expected: 0 or 2; Actual: 8]

❌ /ru/quickstart.md: 101: MD009/no-trailing-spaces Trailing spaces [Expected: 0 or 2; Actual: 6]

❌ /ru/quickstart.md: 105: MD009/no-trailing-spaces Trailing spaces [Expected: 0 or 2; Actual: 6]

❌ /ru/quickstart.md: 107: MD009/no-trailing-spaces Trailing spaces [Expected: 0 or 2; Actual: 8]

Copy link

github-actions bot commented Nov 11, 2024

2024-11-11 15:58:14 UTC Pre-commit check linux-x86_64-release-asan for ddca997 has started.
2024-11-11 15:58:26 UTC Artifacts will be uploaded here
2024-11-11 16:01:05 UTC ya make is running...
🔴 2024-11-11 16:01:36 UTC Build failed, see the logs. Also see fail summary

Copy link

github-actions bot commented Nov 11, 2024

2024-11-11 15:58:16 UTC Pre-commit check linux-x86_64-relwithdebinfo for ddca997 has started.
2024-11-11 15:58:27 UTC Artifacts will be uploaded here
2024-11-11 16:00:58 UTC ya make is running...
🔴 2024-11-11 16:01:30 UTC Build failed, see the logs. Also see fail summary

Copy link

✅ Documentation build

Revision built successfully
Revision preview link

@github-actions github-actions bot added documentation Improvements or additions to documentation and removed new-feature documentation Improvements or additions to documentation labels Nov 11, 2024
@asmyasnikov asmyasnikov added the ok-to-test Special label used to approve a PR for testing on our infrastructure label Nov 14, 2024
@github-actions github-actions bot removed the ok-to-test Special label used to approve a PR for testing on our infrastructure label Nov 14, 2024
Copy link

github-actions bot commented Nov 14, 2024

2024-11-14 12:44:38 UTC Pre-commit check linux-x86_64-release-asan for 6128d90 has started.
2024-11-14 12:44:49 UTC Artifacts will be uploaded here
2024-11-14 12:47:13 UTC ya make is running...
🟢 2024-11-14 12:48:31 UTC Tests successful.

Test history | Ya make output | Test bloat

TESTS PASSED ERRORS FAILED SKIPPED MUTED?
0 0 0 0 0 0

🟢 2024-11-14 12:48:36 UTC Build successful.

Copy link

github-actions bot commented Nov 14, 2024

2024-11-14 12:45:27 UTC Pre-commit check linux-x86_64-relwithdebinfo for 6128d90 has started.
2024-11-14 12:45:39 UTC Artifacts will be uploaded here
2024-11-14 12:48:10 UTC ya make is running...
🟢 2024-11-14 12:49:11 UTC Tests successful.

Test history | Ya make output | Test bloat

TESTS PASSED ERRORS FAILED SKIPPED MUTED?
0 0 0 0 0 0

🟢 2024-11-14 12:49:17 UTC Build successful.

Copy link

✅ Documentation build

Revision built successfully
Revision preview link

Copy link

✅ Documentation build

Revision built successfully
Revision preview link

asmyasnikov
asmyasnikov previously approved these changes Nov 20, 2024
@@ -97,6 +97,11 @@ Normally, {{ ydb-short-name }} stores data on multiple SSD/NVMe or HDD raw disk
The `YDB_USE_IN_MEMORY_PDISKS` setting makes all data volatile, stored only in RAM. Currently, data persistence by turning it off is supported only on x86_64 processors.
To disable the `YDB_USE_IN_MEMORY_PDISKS` option when running a Docker container on a Mac with an Apple Silicon processor, it must emulate the x86_64 instruction set:
- With [colima](https://github.com/abiosoft/colima), use the `colima start --arch aarch64 --vm-type=vz --vz-rosetta` options.
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Working Colima template

# Architecture of the virtual machine (x86_64, aarch64, host).
#
# NOTE: value cannot be changed after virtual machine is created.
# Default: host
arch: host

# Virtual Machine type (qemu, vz)
# NOTE: this is macOS 13 only. For Linux and macOS <13.0, qemu is always used.
#
# vz is macOS virtualization framework and requires macOS 13
#
# NOTE: value cannot be changed after virtual machine is created.
# Default: qemu
vmType: vz

# Utilise rosetta for amd64 emulation (requires m1 mac and vmType `vz`)
# Default: false
rosetta: true

# Volume mount driver for the virtual machine (virtiofs, 9p, sshfs).
#
# virtiofs is limited to macOS and vmType `vz`. It is the fastest of the options.
#
# 9p is the recommended and the most stable option for vmType `qemu`.
#
# sshfs is faster than 9p but the least reliable of the options (when there are lots
# of concurrent reads or writes).
#
# NOTE: value cannot be changed after virtual machine is created.
# Default: virtiofs (for vz), sshfs (for qemu)
mountType: virtiofs

# Propagate inotify file events to the VM.
# NOTE: this is experimental.
mountInotify: false

@@ -97,6 +97,11 @@ Normally, {{ ydb-short-name }} stores data on multiple SSD/NVMe or HDD raw disk
The `YDB_USE_IN_MEMORY_PDISKS` setting makes all data volatile, stored only in RAM. Currently, data persistence by turning it off is supported only on x86_64 processors.
To disable the `YDB_USE_IN_MEMORY_PDISKS` option when running a Docker container on a Mac with an Apple Silicon processor, it must emulate the x86_64 instruction set:
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

А мне нравится это предложение.
YDB_USE_IN_MEMORY_PDISKS по умолчанию НЕ включена. Поэтому вообще весь этот абзац существует

Copy link

❌ Documentation build

Revision build failed

Build logs

Errors (5)

❌ /en/quickstart.md: 100: MD009/no-trailing-spaces Trailing spaces [Expected: 0 or 2; Actual: 1]

❌ /en/quickstart.md: 101: MD009/no-trailing-spaces Trailing spaces [Expected: 0 or 2; Actual: 1]

❌ /en/quickstart.md: 102: MD009/no-trailing-spaces Trailing spaces [Expected: 0 or 2; Actual: 1]

❌ /en/quickstart.md: 106: MD009/no-trailing-spaces Trailing spaces [Expected: 0 or 2; Actual: 5]

❌ /en/quickstart.md: 99: MD009/no-trailing-spaces Trailing spaces [Expected: 0 or 2; Actual: 1]

ydb/docs/ru/core/quickstart.md Outdated Show resolved Hide resolved
ydb/docs/ru/core/quickstart.md Outdated Show resolved Hide resolved
Copy link

❌ Documentation build

Revision build failed

Build logs

Errors (7)

❌ /en/quickstart.md: 100: MD009/no-trailing-spaces Trailing spaces [Expected: 0 or 2; Actual: 1]

❌ /en/quickstart.md: 101: MD009/no-trailing-spaces Trailing spaces [Expected: 0 or 2; Actual: 1]

❌ /en/quickstart.md: 102: MD009/no-trailing-spaces Trailing spaces [Expected: 0 or 2; Actual: 1]

❌ /en/quickstart.md: 106: MD009/no-trailing-spaces Trailing spaces [Expected: 0 or 2; Actual: 5]

❌ /en/quickstart.md: 99: MD009/no-trailing-spaces Trailing spaces [Expected: 0 or 2; Actual: 1]

❌ /ru/quickstart.md: 98: MD009/no-trailing-spaces Trailing spaces [Expected: 0 or 2; Actual: 1]

❌ Note must be closed in /ru/quickstart.md

Copy link

❌ Documentation build

Revision build failed

Build logs

Errors (5)

❌ /en/quickstart.md: 100: MD009/no-trailing-spaces Trailing spaces [Expected: 0 or 2; Actual: 1]

❌ /en/quickstart.md: 101: MD009/no-trailing-spaces Trailing spaces [Expected: 0 or 2; Actual: 1]

❌ /en/quickstart.md: 102: MD009/no-trailing-spaces Trailing spaces [Expected: 0 or 2; Actual: 1]

❌ /en/quickstart.md: 106: MD009/no-trailing-spaces Trailing spaces [Expected: 0 or 2; Actual: 5]

❌ /en/quickstart.md: 99: MD009/no-trailing-spaces Trailing spaces [Expected: 0 or 2; Actual: 1]

Copy link

✅ Documentation build

Revision built successfully
Revision preview link


```bash
docker run -d --rm --name ydb-local -h localhost \
--platform linux/amd64 \
-p 2135:2135 -p 2136:2136 -p 8765:8765 \
-v $(pwd)/ydb_certs:/ydb_certs -v $(pwd)/ydb_data:/ydb_data \
-e GRPC_TLS_PORT=2135 -e GRPC_PORT=2136 -e MON_PORT=8765 \
-e YDB_USE_IN_MEMORY_PDISKS=true \
{{ ydb_local_docker_image}}:{{ ydb_local_docker_image_tag }}
```

Если контейнер успешно запустился, вы увидите его идентификатор. Контейнеру может потребоваться несколько минут для инициализации. База данных будет недоступна до окончания инициализации.
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
Если контейнер успешно запустился, вы увидите его идентификатор. Контейнеру может потребоваться несколько минут для инициализации. База данных будет недоступна до окончания инициализации.
Если контейнер успешно запустился, вы увидите его идентификатор. Контейнеру может потребоваться несколько секунд для инициализации. База данных будет недоступна до окончания инициализации.

Настройка `YDB_USE_IN_MEMORY_PDISKS` делает все данные волатильными, хранящимися только в оперативной памяти. В настоящее время сохранение данных путем её отключения поддерживается только на x86_64 процессорах.
{% note warning %}

В настоящее время сохранение данных на диск поддерживается только на x86_64 процессорах. Чтобы отключить сохранение данных на диск и сделать все данные волатильными, хранящимися только в оперативной памяти, добавьте в команду запуска Docker-контейнера параметр `YDB_USE_IN_MEMORY_PDISKS=true`.
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
В настоящее время сохранение данных на диск поддерживается только на x86_64 процессорах. Чтобы отключить сохранение данных на диск и сделать все данные волатильными, хранящимися только в оперативной памяти, добавьте в команду запуска Docker-контейнера параметр `YDB_USE_IN_MEMORY_PDISKS=true`.
В настоящее время сохранение данных на диск поддерживается только на x86_64 процессорах. Чтобы отключить сохранение данных на диск и сделать все данные волатильными, хранящимися только в оперативной памяти, добавьте в команду запуска Docker-контейнера параметр `-e YDB_USE_IN_MEMORY_PDISKS=true`.


В настоящее время сохранение данных на диск поддерживается только на x86_64 процессорах. Чтобы отключить сохранение данных на диск и сделать все данные волатильными, хранящимися только в оперативной памяти, добавьте в команду запуска Docker-контейнера параметр `YDB_USE_IN_MEMORY_PDISKS=true`.

Если вы не хотите отключать сохранение данных на диск при запуске контейнера Docker на Mac с процессором Apple Silicon, необходимо эмулировать набор инструкций x86_64 с помощью одной из следующих программ:
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
Если вы не хотите отключать сохранение данных на диск при запуске контейнера Docker на Mac с процессором Apple Silicon, необходимо эмулировать набор инструкций x86_64 с помощью одной из следующих программ:
Если вы не хотите отключать сохранение данных на диск при запуске контейнера Docker на Mac с процессором Apple Silicon, необходимо эмулировать набор инструкций x86_64, используя технологию виртуализации rozetta:

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Можно ссылкой сделать розетту

Copy link

✅ Documentation build

Revision built successfully
Revision preview link

Copy link

✅ Documentation build

Revision built successfully
Revision preview link

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
documentation Improvements or additions to documentation external
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants