> For the complete documentation index, see [llms.txt](https://docs.synteq.com/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.synteq.com/system-administration/common-issues/lost-ssh-key/lost-ssh-key-on-a-dedicated-server.md).

# Lost SSH key on a dedicated server

### 1. Go to your server

Start by going into [Metal](https://metal.crunchbits.com/), and logging in. Then select your server, by clicking on it's name.

<figure><img src="/files/39ffdEr0OJJmgPePFaso" alt=""><figcaption></figcaption></figure>

Then go to the `Rescue` tab.

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

### 2. Reset the root password

First, select the `Reset Admin Password` \[1] option, then select the `Reset Admin Password` \[2] option once again.&#x20;

<figure><img src="/files/9BUmvtpt4xnLd94KDvnk" alt=""><figcaption></figcaption></figure>

Then scroll down to the bottom, and input your new password into the `Set root password` \[1] field, and click `START RESCUE` \[2]. In here, you can also optionally add an SSH key.&#x20;

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

Then read the warning, and if you agree with these terms click on `START PASSWORD RESET`.

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

Afterward, wait for it to finish the password reset process.

{% hint style="warning" %}
If it's stuck on `Preparing boot environment` for 10+ minutes, then first please try to restart the server. If that doesn't fix it, please reach out to us via the buttons on the right top.
{% endhint %}

### 3. Add in your new SSH key/enable password root SSH logins

From here, you can console into the server as outlined in [Entering console](/dedicated-servers/server-management/entering-console.md), and either directly add in your new SSH key there, or modify your `/etc/ssh/sshd_config` to allow password authentication. \[The variable for this is `PasswordAuthentication`, and it should be set to `Yes`]


---

# 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://docs.synteq.com/system-administration/common-issues/lost-ssh-key/lost-ssh-key-on-a-dedicated-server.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.
