public inbox for cygwin@cygwin.com
 help / color / mirror / Atom feed
* tail/head not working with a pseudoterminal
@ 2011-11-25 14:22 Costin Caraivan
  2011-11-25 14:32 ` Corinna Vinschen
  0 siblings, 1 reply; 4+ messages in thread
From: Costin Caraivan @ 2011-11-25 14:22 UTC (permalink / raw)
  To: cygwin

Hello,

I'm trying to tail a file through SSH. I'm launching ssh through
Python, like this:
ssh -t user@vm-admin.corp.com "tail
/cygdrive/c/ctier/ctl/var/logs/ctlcenter/STAGING/Administration/\[Staging\]\
Sleep/7.txt"

And I get this:
Pseudo-terminal will not be allocated because stdin is not a terminal.
TAIL: lseeki64() failed 22

This works from the command line :(

Also head fails with:
Pseudo-terminal will not be allocated because stdin is not a terminal.
bash: /cygdrive/c/apps/activeperl/bin/head: /usr/bin/perl: bad
interpreter: Permission denied

This also works from the command line :(

The Cygwin version is: CYGWIN_NT-6.0-WOW64 1.7.9(0.237/5/3) 2011-03-29 10:10

Any ideas?

Thanks,
_____________
Costin Caraivan

--
Problem reports:       http://cygwin.com/problems.html
FAQ:                   http://cygwin.com/faq/
Documentation:         http://cygwin.com/docs.html
Unsubscribe info:      http://cygwin.com/ml/#unsubscribe-simple

^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: tail/head not working with a pseudoterminal
  2011-11-25 14:22 tail/head not working with a pseudoterminal Costin Caraivan
@ 2011-11-25 14:32 ` Corinna Vinschen
  2011-11-25 14:48   ` Csaba Raduly
  0 siblings, 1 reply; 4+ messages in thread
From: Corinna Vinschen @ 2011-11-25 14:32 UTC (permalink / raw)
  To: cygwin

On Nov 25 16:03, Costin Caraivan wrote:
> Hello,
> 
> I'm trying to tail a file through SSH. I'm launching ssh through
> Python, like this:
> ssh -t user@vm-admin.corp.com "tail
> /cygdrive/c/ctier/ctl/var/logs/ctlcenter/STAGING/Administration/\[Staging\]\
> Sleep/7.txt"
> 
> And I get this:
> Pseudo-terminal will not be allocated because stdin is not a terminal.
> TAIL: lseeki64() failed 22

This is not Cygwin's tail.  The error message looks pretty weird.

Try ssh -tt.

> This works from the command line :(
> 
> Also head fails with:
> Pseudo-terminal will not be allocated because stdin is not a terminal.
> bash: /cygdrive/c/apps/activeperl/bin/head: /usr/bin/perl: bad
> interpreter: Permission denied

You're running the wrong head command.  This is some activestate perl
script, not the Cygwin head tool from coreutils.  Change your $PATH
to find the Cygwin apps first.


Corinna

-- 
Corinna Vinschen                  Please, send mails regarding Cygwin to
Cygwin Project Co-Leader          cygwin AT cygwin DOT com
Red Hat

--
Problem reports:       http://cygwin.com/problems.html
FAQ:                   http://cygwin.com/faq/
Documentation:         http://cygwin.com/docs.html
Unsubscribe info:      http://cygwin.com/ml/#unsubscribe-simple

^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: tail/head not working with a pseudoterminal
  2011-11-25 14:32 ` Corinna Vinschen
@ 2011-11-25 14:48   ` Csaba Raduly
  2011-11-25 15:48     ` Costin Caraivan
  0 siblings, 1 reply; 4+ messages in thread
From: Csaba Raduly @ 2011-11-25 14:48 UTC (permalink / raw)
  To: cygwin

On Fri, Nov 25, 2011 at 3:21 PM, Corinna Vinschen  wrote:
> On Nov 25 16:03, Costin Caraivan wrote:
...
>> Also head fails with:
>> Pseudo-terminal will not be allocated because stdin is not a terminal.
>> bash: /cygdrive/c/apps/activeperl/bin/head: /usr/bin/perl: bad
>> interpreter: Permission denied
>
> You're running the wrong head command.  This is some activestate perl
> script, not the Cygwin head tool from coreutils.  Change your $PATH
> to find the Cygwin apps first.

It's HEAD from lwp-request:
http://search.cpan.org/~gaas/libwww-perl-6.03/bin/lwp-request

Found unfortunately due to case-insensitive NTFS.

Costin, try /usr/bin/head explicitly.

Csaba
-- 
GCS a+ e++ d- C++ ULS$ L+$ !E- W++ P+++$ w++$ tv+ b++ DI D++ 5++
The Tao of math: The numbers you can count are not the real numbers.
Life is complex, with real and imaginary parts.
"Ok, it boots. Which means it must be bug-free and perfect. " -- Linus Torvalds
"People disagree with me. I just ignore them." -- Linus Torvalds

--
Problem reports:       http://cygwin.com/problems.html
FAQ:                   http://cygwin.com/faq/
Documentation:         http://cygwin.com/docs.html
Unsubscribe info:      http://cygwin.com/ml/#unsubscribe-simple

^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: tail/head not working with a pseudoterminal
  2011-11-25 14:48   ` Csaba Raduly
@ 2011-11-25 15:48     ` Costin Caraivan
  0 siblings, 0 replies; 4+ messages in thread
From: Costin Caraivan @ 2011-11-25 15:48 UTC (permalink / raw)
  To: cygwin

> It's HEAD from lwp-request:
> http://search.cpan.org/~gaas/libwww-perl-6.03/bin/lwp-request
>
> Found unfortunately due to case-insensitive NTFS.
>
> Costin, try /usr/bin/head explicitly.
>
> Csaba

Thanks, that should do it.

I see one path when connecting manually with SSH, and another one when
launching SSH from Python :-(
_____________
Costin Caraivan

--
Problem reports:       http://cygwin.com/problems.html
FAQ:                   http://cygwin.com/faq/
Documentation:         http://cygwin.com/docs.html
Unsubscribe info:      http://cygwin.com/ml/#unsubscribe-simple

^ permalink raw reply	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2011-11-25 14:48 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2011-11-25 14:22 tail/head not working with a pseudoterminal Costin Caraivan
2011-11-25 14:32 ` Corinna Vinschen
2011-11-25 14:48   ` Csaba Raduly
2011-11-25 15:48     ` Costin Caraivan

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).