> For the complete documentation index, see [llms.txt](https://spacecore.gitbook.io/wiki/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://spacecore.gitbook.io/wiki/ua/network-and-security-configuration/resolv.conf-fix.md).

# \[DNS] Temporary failure resolving...

Якщо у вас виникають проблеми з DNS-серверами.

Помилка виглядає так:

<figure><img src="/files/qZ36ezyZcW47tAEwBKBN" alt=""><figcaption></figcaption></figure>

Ми покажемо два способи вирішення проблеми: через SSH-доступ і через sFTP-доступ.

## **Використання SSH**

Використайте утиліту Nano для перегляду та редагування файлу resolv.conf, де налаштовуються DNS-сервери вашого сервера. Введіть команду:

```
nano /etc/resolv.conf
```

Перед нами відкрився редактор файлів resolv.conf.

<figure><img src="/files/C5RLFS1JWBgBMDCkdvLa" alt=""><figcaption></figcaption></figure>

{% hint style="info" %}
Файл буде порожнім або міститиме текст як опис, залежно від обраного дистрибутиву Linux.
{% endhint %}

У цьому файлі потрібно вказати nameserver для вашої ОС.

{% hint style="info" %}
Який nameserver вибрати? Ви можете дізнатися більше про це в кінці статті. У цьому випадку ми будемо використовувати DNS 8.8.8.8 як основний.
{% endhint %}

Введіть цей текст у файл:

```
nameserver 8.8.8.8
nameserver 1.1.1.1
```

<figure><img src="/files/LFi2VDI1VMufSXE4AfTk" alt=""><figcaption></figcaption></figure>

Натисніть Ctrl + X, щоб вийти з файлу. Потім натисніть Y для збереження змін.

<figure><img src="/files/6iphzv4nmPJYeVP3WPEH" alt=""><figcaption></figcaption></figure>

Потім натисніть Enter, щоб залишити ім'я файлу без змін.

<figure><img src="/files/D90YAjXrxdFrfAk773aA" alt=""><figcaption></figcaption></figure>

## **Використання sFTP**

Підключіться до нашого сервера через sFTP. Далі нам потрібно перейти до каталогу /etc і знайти там файл resolv.conf.

<figure><img src="/files/NB5oa2M2gU6LIhDDfA8G" alt=""><figcaption></figcaption></figure>

Відкрийте його за допомогою будь-якого текстового редактора.

<figure><img src="/files/27NLcH04xBPMzAIqXs6m" alt=""><figcaption></figcaption></figure>

{% hint style="info" %}
Файл буде порожнім або міститиме текст як опис, залежно від обраного вами дистрибутиву Linux.
{% endhint %}

Нам потрібно додати тут оптимальний nameserver, вказати кілька з них на випадок проблем з одним із них.

```
nameserver 8.8.8.8
nameserver 1.1.1.1
```

<figure><img src="/files/NweLM3wYmSKTBT3LSx4f" alt=""><figcaption></figcaption></figure>

Чудово, збережіть файл і завантажте його на сервер.


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## 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, and the optional `goal` query parameter:

```
GET https://spacecore.gitbook.io/wiki/ua/network-and-security-configuration/resolv.conf-fix.md?ask=<question>&goal=<endgoal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is optional and describes the broader end goal you are ultimately trying to accomplish on behalf of the user. GitBook uses it to tailor the answer towards what is most useful for that goal.

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.
