[one-users] sudo: sorry, you must have a tty to run sudo

Florian Heigl fheigl at wartungsfenster.de
Wed Nov 9 14:18:46 PST 2011


Hi,

You need to put
!Requiretty for the user oneadmin

Florian

On 11/09/2011 09:08 PM, Rubens Pinheiro wrote:
> Hello,
> I'm trying to configure a xen host, but when I create the host, oned
> rise an error:
>
> Wed Nov    9 16:55:33 2011 [InM][I]: STDERR follows.
>
> Wed Nov    9 16:55:33 2011 [InM][I]: sudo: sorry, you must have a tty to run sudo
>
> Wed Nov    9 16:55:33 2011 [InM][I]: Error executing xen.rb
>
> Wed Nov    9 16:55:33 2011 [InM][I]: ExitCode: 255
>
> Wed Nov    9 16:55:33 2011 [InM][E]: Error monitoring host 14 : MONITOR FAILURE 14 Could not monitor host 192.168.0.31
>
> I've already configured sudoers file to permit scripts run sudo command.
> Here is my xen host sudoers file:
>
> #
> # This file MUST be edited with the 'visudo' command as root.
> #
> # Please consider adding local content in /etc/sudoers.d/ instead of
> # directly modifying this file.
> #
> # See the man page for details on how to write a sudoers file.
> #
> Defaults env_reset
> Defaults requiretty
>
> # Host alias specification
>
> # User alias specification
>
> # Cmnd alias specification
>
> # User privilege specification
> root ALL=(ALL:ALL) ALL
> %xen ALL=(ALL) NOPASSWD: /usr/sbin/xm *
> %xen ALL=(ALL) NOPASSWD: /usr/sbin/xentop *
>
> # Members of the admin group may gain root privileges
> %admin ALL=(ALL) ALL
>
> # Allow members of group sudo to execute any command
> %sudo ALL=(ALL:ALL) ALL
>
> #includedir /etc/sudoers.d
>
> I've set the "Defaults requiretty" in sudoers and oneadmin is already in
> xen group, but onehost give me the same error.
> "sudo: sorry, you must have a tty to run sudo"
>
> regards,
>
> --
>
>
> _______________________________________________
> Users mailing list
> Users at lists.opennebula.org
> http://lists.opennebula.org/listinfo.cgi/users-opennebula.org




More information about the Users mailing list