fab-user
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Fab-user] service and pty=False


From: Abhi
Subject: Re: [Fab-user] service and pty=False
Date: Wed, 5 Dec 2012 14:37:30 +0530

Thanks for that Jeff. I did not know that pty is a configurable property in sudoers file.

On Mon, Nov 26, 2012 at 7:05 AM, Jeff Forcier <address@hidden> wrote:
Hi Abhi,

On Sun, Nov 18, 2012 at 9:24 PM, Abhi <address@hidden> wrote:
> I am using fabric to restart tomcat(using service or init.d) and even though
> it says tomcat restarted successfully it does not. So, as per the FAQ, I set
> pty=False and tried again. But, now, I get this error:
>
> sudo: /etc/init.d/tomcat restart
>
> out: sudo: sorry, you must have a tty to run sudo

That's tough -- having pty off is the only quick solution we've found
to the problem where init scripts misbehave, and if you cannot change
your sudo configuration to allow tty-less runs (the easiest solution
by far), that's lose-lose.

Depending on what access you have, you may want to see if a
non-init-script method of running Tomcat will work better under a pty.
'service' still runs init scripts under the hood which is why it isn't
helping -- I'd look into supervisord, upstart or runit/daemontools.
These tools run your program under their own process and may behave
better with ptys.

Best of luck,
Jeff

--
Jeff Forcier
Unix sysadmin; Python/Ruby engineer
http://bitprophet.org



--
Cheers,
Abhi

reply via email to

[Prev in Thread] Current Thread [Next in Thread]