Re: [lxc-users] authentication in containers jacked-up!

2018-04-09 Thread Fajar A. Nugraha
On Thu, Mar 29, 2018 at 8:22 PM, Ray Jender  wrote:
> ray@ container 2:/etc$  sudo visudo
>
> sudo: no tty present and no askpass program specified
>

Try 'sudo -S visudo'

-- 
Fajar
___
lxc-users mailing list
lxc-users@lists.linuxcontainers.org
http://lists.linuxcontainers.org/listinfo/lxc-users

Re: [lxc-users] authentication in containers jacked-up!

2018-04-09 Thread David Favor

Ray Jender wrote:
So in Ubuntu 16.04.4 I created  4 LXD containers using LXC. From the 
host I created the first container then did $ lxc copy containter1 
container2 , 1 to 3 and 1 to 4.


It was a challenge for me to make them accessible from the outside world 
but I conquered that.


 


Now however I cannot su or sudo inside the containers?  For instance:


Provide details of host environment (cat /etc/os-release | /etc/redhat-release),
along with commands you used to create your containers will be helpful.
___
lxc-users mailing list
lxc-users@lists.linuxcontainers.org
http://lists.linuxcontainers.org/listinfo/lxc-users

Re: [lxc-users] authentication in containers jacked-up!

2018-04-09 Thread Christian Brauner
On Thu, Mar 29, 2018 at 09:22:07AM -0400, Ray Jender wrote:
> So in Ubuntu 16.04.4 I created  4 LXD containers using LXC. From the host I
> created the first container then did $ lxc copy containter1 container2 , 1
> to 3 and 1 to 4.
> 
> It was a challenge for me to make them accessible from the outside world but
> I conquered that.
> 
>  
> 
> Now however I cannot su or sudo inside the containers?  For instance:
> 
>  
> 
> sudo find / -name testfile -print
> 
> sudo: no tty present and no askpass program specified
> 
>  
> 
> also.
> 
>  
> 
> When I do   $  lxc exec container1  /bin/bash  from the host:
> 
>  
> 
> I am put in:  ray@container1:/root$  // The "/root"  does not seem correct?
> 
>  
> 
> Also.
> 
>  
> 
> ray@container2:/etc$  visudo
> 
> visudo: /etc/sudoers: Permission denied
> 
>  
> 
> ray@ container2:/etc$  su visudo
> 
> su: must be run from a terminal
> 
>  
> 
> ray@ container 2:/etc$  sudo visudo
> 
> sudo: no tty present and no askpass program specified
> 
>  
> 
> Also when I try to putty into the container, I get the "login as:"  prompt,
> but when I enter the user name, I get:
> 
>  
> 
> puTTY Fatal Error
> 
> Disconnected: No supported authentication methods available (server sent:
> publickey)
> 
> (same error from WinSCP)
> 
>  
> 
> Any idea what I am missing?
> 
>  
> 
> Thanks, appreciate your help on this.

What containers (distro) are you creating?
What LXD version and what LXC version?

Christian
___
lxc-users mailing list
lxc-users@lists.linuxcontainers.org
http://lists.linuxcontainers.org/listinfo/lxc-users

[lxc-users] authentication in containers jacked-up!

2018-04-07 Thread Ray Jender
So in Ubuntu 16.04.4 I created  4 LXD containers using LXC. From the host I
created the first container then did $ lxc copy containter1 container2 , 1
to 3 and 1 to 4.

It was a challenge for me to make them accessible from the outside world but
I conquered that.

 

Now however I cannot su or sudo inside the containers?  For instance:

 

sudo find / -name testfile -print

sudo: no tty present and no askpass program specified

 

also.

 

When I do   $  lxc exec container1  /bin/bash  from the host:

 

I am put in:  ray@container1:/root$  // The "/root"  does not seem correct?

 

Also.

 

ray@container2:/etc$  visudo

visudo: /etc/sudoers: Permission denied

 

ray@ container2:/etc$  su visudo

su: must be run from a terminal

 

ray@ container 2:/etc$  sudo visudo

sudo: no tty present and no askpass program specified

 

Also when I try to putty into the container, I get the "login as:"  prompt,
but when I enter the user name, I get:

 

puTTY Fatal Error

Disconnected: No supported authentication methods available (server sent:
publickey)

(same error from WinSCP)

 

Any idea what I am missing?

 

Thanks, appreciate your help on this.


Ray

 

 

 

 

___
lxc-users mailing list
lxc-users@lists.linuxcontainers.org
http://lists.linuxcontainers.org/listinfo/lxc-users