A
A
Alexander Fedorov2016-03-05 14:38:21
LXC
Alexander Fedorov, 2016-03-05 14:38:21

How to recover password for lxc container?

I forgot the password from the lxc container raised in proxmox... And I would not want to lose the data that is inside the container :)
Is it possible to reset the password in the container (I suspect that this should not be possible ...) or at least extract data from it (again, I suspect that there should not be such a possibility either).

Answer the question

In order to leave comments, you need to log in

2 answer(s)
A
Alexander Fedorov, 2016-03-05
@Pagliaccio

It turns out that both (reset the password in the container) and the other (get access to the files in the container) are possible ...
The first can be done with a bang with the lxc-attach command:

  1. go to the hypervisor console
  2. using the command lxc-attach -n 200, we connect to the desired container (in my case, the container with the name 200) - we are inside the container
  3. next passwdand enter a new password for the root user of the container

P
Puma Thailand, 2016-03-05
@opium

From host PCT enter ID

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question