[lxc-users] oracle linux 7 in LXC: ulimit problem for root

Tamas Papp tompos at martos.bme.hu
Wed Nov 25 11:33:58 UTC 2015



On 11/25/2015 11:38 AM, Harald Dunkel wrote:
> Hi folks,
>
> hopefully this is not too much ot for this list:
>
> I am running Oracle Linux 7 in LXC. Problem: If I try to login
> as root via ssh, then I am kicked out after authentication,
> apparently due to an ulimit problem:
>
> Nov 25 11:08:58 lxc1.example.com sshd[186]: pam_limits(sshd:session): Could not set limit for 'nofile': Operation not permitted
> Nov 25 11:08:58 lxc1.example.com sshd[186]: pam_unix(sshd:session): session opened for user root by (uid=0)
> Nov 25 11:08:58 lxc1.example.com sshd[186]: error: PAM: pam_open_session(): Permission denied
>
> /etc/security/limits.conf says:
>
> * hard nofile 65536
> #root hard nofile 65536
>
> Please note that the "root" line is commented out. According to
> the documentation there is no reason for pam to touch root's
> ulimit, but I have to comment out the other line as well to enable
> ssh support for root.
>
>
> How comes?
>
> Every helpful comment is highly appreciated
>

Check out /etc/security/limits.d/ too.

tamas


More information about the lxc-users mailing list