Accessing an LXC container
There are several ways in which we can access a LXC container:
The noVNC console
SSH
Direct shells through the CLI
We can access and view the container directly from the GUI using the noVNC
console. It is almost a visual remote access to the instance. The console is identical to a KVM virtual machine. After a long inactivity when we try to access the container using the console, it may appear, as shown in the following screenshot, with just a cursor and no login option:
By simply pressing the Enter key, we can make the login prompt appear, as shown in the following screenshot:
One of the best features of an LXC container is the ability to directly access the container shell through the CLI of the host node. The Proxmox command to access the LXC container shell is as follows:
# pct enter <ct_id>
This gives us the direct shell prompt of the container, as shown in the following screenshot:
In the previous example, we are accessing the LXC container name, Ubuntu-LXC...