Digital Ocean unable to access console
Asked Answered
C

6

10

I am unable to access my droplet console in digital ocean, it is giving a notification "enable the new Droplet Console for native-like terminal access to your Droplet from your browser". To enable the Droplet Console, log in to your Droplet as root or as a user with sudo access. Once connected, download and execute the agent installation script with the following command to enable the console immediately:

wget -qO- https://repos-droplet.digitalocean.com/install.sh | sudo bash

but I am have no access to its console so I have no idea where I can give this command, putty is also not giving any response. screenshot of the notification

Clank answered 26/8, 2021 at 8:30 Comment(0)
J
13

You are unable to connect to the console because by mistake you started the ufw without allowing ssh

To get console back: Step 1: Go to Launch Recovery Console

enter image description here

Step 2: after logging in run: ufw allow ssh

Step 3: you will see something like:

enter image description here

Step 4: Try to login with SSH, it will be successful!

Jitters answered 27/5, 2023 at 1:53 Comment(2)
thanks for your answer, although the issue I found was that the server went to panic mode so I recovered my files by getting into recovery modeClank
This works, thanks @Parth Developer!Deutero
M
8

TLDR; run it in the Recovery Console.

I know this is an old question but posting in case any one else lands here in a search.

Click the "Launch Recovery Console" button in the "Recovery Console" section of Droplet's Access page.

Sign in as root. If you don't know the password, use the "Reset root Password" button in the "Reset root password" section below.

paste the wget command you have there from the "Droplet Console" section and run it. It may take a bit.

When that completes, the first section "Droplet Console" should now update and have a button to "Launch Droplet Console"

You may need to log out of and back into Digital Ocean before the Droplet Console will launch successfully.

Mistral answered 17/3, 2023 at 16:54 Comment(1)
Thanks for this answer sure it will help someone if he is looking out for this.Clank
D
4

It fixed itself for me in a day. Possibly, you need to logout/login. And also I've added 2FA to my account. After that actions I finally can use that feature.

Davy answered 26/10, 2021 at 21:56 Comment(0)
E
2

Digital Ocean provides extensive documentation:

https://docs.digitalocean.com/products/droplets/how-to/connect-with-ssh/putty/

Once you're ssh'd into the Droplet, you need to run that command.

Then:

https://docs.digitalocean.com/products/droplets/how-to/connect-with-console/

Extramarital answered 26/8, 2021 at 15:51 Comment(3)
This doesn't answer the question, but it's helpful for anyone that's using the droplet console. The droplet console is difficult to use in production. It can't scroll through its output, its window size is small, and doesn't expand when maximized, and it incorrectly formats pasted text.Jefferey
Instead, use Visual Studio Code. You can create, open, edit, and transfer files on the virtual machine from within the code editor like you would on your regular computer. You can run commands on multiple terminal applications in parallel. It also doesn't have any of the limitations that the web-based terminal application had.Jefferey
Link to tutorial: medium.com/p/44afcc954d38Jefferey
E
1

In my case, I disallowed root access permission and, in the config file.

#Solution

if you have backup enable just rollback to previous backup before the incident.

This solved my problem

Ephram answered 12/1 at 14:4 Comment(0)
G
1

Fixed

  1. Connect to your Recovery Console by clicking on Launch Recovery Console
login: root
password: *****
  1. You need to make sure that the firewall allows SSH connections so that we can log back in next time:
sudo ufw status
sudo ufw allow OpenSSH
suduo ufw status
Gingivitis answered 1/5 at 2:12 Comment(0)

© 2022 - 2024 — McMap. All rights reserved.