can't ssh into centos lxc container

zustudios

Renowned Member
Dec 13, 2015
86
0
71
How do I ssh into a centos lxc container? I'm able to ssh into ubuntu and debian but I get connection refused for centos. How to I set it up?
 
you can log in to the container from cli
Code:
pct enter VMID

then as you may already know check sshd_config and logs.

or login from pve https console.
 
How do I "check sshd_config and logs" I don't know the centos 6.7 commands. Yes I can login from pve https console. but I need ssh to install cpanel and also ftp and sftp. All I had to do to fix the ssh problem on debian and ubuntu was add the gateway. I can't access the outside world on the centos container but it's showing up on my router. I'm on an outside computer.I'm not on my host.
 
I can ssh through "pct enter VMID" .I think the problem is the container can't access the outside world.
 
the pct enter command does not use ssh.

use pct or console to connect again. then from within the lxc test ping:
Code:
ping -c 3  google.com

does ping work?
 
Yes it did ,it's installing cpanel now but I still can't ssh into it directly. Any idea why?
lxc centos 6
 

About

The Proxmox community has been around for many years and offers help and support for Proxmox VE, Proxmox Backup Server, and Proxmox Mail Gateway.
We think our community is one of the best thanks to people like you!

Get your subscription!

The Proxmox team works very hard to make sure you are running the best software and getting stable updates and security enhancements, as well as quick enterprise support. Tens of thousands of happy customers have a Proxmox subscription. Get yours easily in our online shop.

Buy now!