Re: putty or ssh, screen $cmd

2011-05-29 Thread Martin Pelikan
On Fri, May 27, 2011 at 11:15:14PM -0400, Hugo Villeneuve wrote:
 Just saying that at least, screen has been working for decades
 properly. Even if it was archaic. But it's not like tty are anything
 new themselves (the 8bit version ones).

Have you ever tried to use screen inside a screen? ssh'd to other
machines?  Not to mention ^A is beginning-of-line in most terminals.
And the screen's window management!  What a pleasure!
And the way screen reports its messages!  Still a mystery to me.
tmux ftw :-)

--
Martin Pelikan



Re: putty or ssh, screen $cmd

2011-05-29 Thread Abel Abraham Camarillo Ojeda
On Sun, May 29, 2011 at 6:46 PM, Martin Pelikan
martin.peli...@gmail.com wrote:
 Have you ever tried to use screen inside a screen? ssh'd to other
 machines? B Not to mention ^A is beginning-of-line in most terminals.

I generally map ^a to be the prefix key on tmux...



Re: putty or ssh, screen $cmd

2011-05-29 Thread Nick Holland
On 05/27/11 23:14, Hugo Villeneuve wrote:
...
 Has tmux been fixed to work on  150 MHz computers since it has
 moved to libevent?

Have you stopped beating your wife and kids? [ ] yes[ ] no

Anyway... tmux seems to work just fine on a well-under 150MHz system here.

OpenBSD 4.9-current (GENERIC) #3: Mon May 23 21:40:58 MDT 2011
dera...@i386.openbsd.org:/usr/src/sys/arch/i386/compile/GENERIC
cpu0: Intel 486DX2 (GenuineIntel 486-class)
cpu0: FPU,V86
real mem  = 66646016 (63MB)
avail mem = 54743040 (52MB)
mainbus0 at root
bios0 at mainbus0: AT/286+ BIOS, date 09/15/94
...

(that's probably a 66MHz proc)

So, IF there was a problem...I don't see it as-reported on -current.

Nick.



Re: putty or ssh, screen $cmd

2011-05-29 Thread Amit Kulkarni
 OpenBSD 4.9-current (GENERIC) #3: Mon May 23 21:40:58 MDT 2011
dera...@i386.openbsd.org:/usr/src/sys/arch/i386/compile/GENERIC
 cpu0: Intel 486DX2 (GenuineIntel 486-class)
 cpu0: FPU,V86
 real mem  = 66646016 (63MB)
 avail mem = 54743040 (52MB)
 mainbus0 at root
 bios0 at mainbus0: AT/286+ BIOS, date 09/15/94
 ...

 (that's probably a 66MHz proc)

True up and down scalability :-) 66Mhz vs 6.6Ghz (on a future IBM
Power 8/Power 9/Power 10 machine)

I am joking of course



Re: putty or ssh, screen $cmd

2011-05-28 Thread gilbert . fernandes
On Fri, May 27, 2011 at 10:27:59PM -0400, Nick Holland wrote:

 dunno what works fine means, but today, we use a program called
 tmux, which is part of base OpenBSD.

And tmux seems better written. On the Yeeloong, using
screen will send you in a kernel failure with a Trap 4
error, while using tmux you can do anything you want,
it's rock stable. screen has some shitty code inside
that overflows my fb and miod even tried to fix it
but it keeps crashing. moved to tmux, all problems gone.

Using tmux as suggested is a very good idea. First,
it's in the base system install, and second, there is
some shitty code in screen that does really bad things
to some consoles that just go nuts.

If you like to use Control-A in tmux like in screen,
create a .tmux.conf file in your home folder and
put the following inside of it :

set-option -g prefix C-a
bind-key C-a last-window
unbind C-b
set -g base-index 1
setw -g aggressive-resize on
bind-key -n F10 prev
bind-key -n F11 next
set-window-option -g mode-keys vi
set-window-option -g utf8 on

To copy/paste : Control-A to enter copy mode
(upper right a thing between [] appears) and
go to beginning of text to copy. Press space
bar once. Move to end of stuff to copy, press
Enter and it's done (sometimes you don't get a
visual feedback because of the console, don't
care). Use Control-a ] to paste as usual.

This config file uses Control-a instead of
Control-b, you can press Control-a twice to get
between the two last consoles (as screen does).
I use F10 and F11 keys to move to previous/
next console, you can remove those lines or change
them if you want to use other keys

Ditch screen. Use tmux.

-- 
Gilbert Fernandes



Re: putty or ssh, screen $cmd

2011-05-28 Thread gilbert . fernandes
On Fri, May 27, 2011 at 11:15:14PM -0400, Hugo Villeneuve wrote:

 Just saying that at least, screen has been working for decades
 properly. Even if it was archaic. But it's not like tty are anything
 new themselves (the 8bit version ones).

If you try screen on some machines, you will crash so badly
that even DDB inside the kernel is frozen after displaying
one or two lines of panic. At first, you wonder. Then you try
tmux, and it no longer crashes. And last, you go see the
screen sources, and it's like being Nicky Larson getting
a 10-ton hammer hit on the head...

-- 
Gilbert Fernandes



Re: putty or ssh, screen $cmd

2011-05-28 Thread David Vasek

On Sat, 28 May 2011, gilbert.fernan...@orange.fr wrote:


If you try screen on some machines, you will crash so badly
that even DDB inside the kernel is frozen after displaying
one or two lines of panic. At first, you wonder. Then you try
tmux, and it no longer crashes.


Never blame an application for OS crashes, btw.

Regards,
David



Re: putty or ssh, screen $cmd

2011-05-28 Thread Miod Vallat
 Has tmux been fixed to work on  150 MHz computers since it has
 moved to libevent?

Define `fixed'. What do you consider broken?

I use tmux daily on 2-digit MHz machines, but then I don't use the
status bar because I have no use for it.

Miod



Re: putty or ssh, screen $cmd

2011-05-28 Thread Miod Vallat
 And tmux seems better written. On the Yeeloong, using
 screen will send you in a kernel failure with a Trap 4
 error, while using tmux you can do anything you want,
 it's rock stable. screen has some shitty code inside
 that overflows my fb and miod even tried to fix it
 but it keeps crashing. moved to tmux, all problems gone.

Oh give me a break. This was a driver bug, it has been fixed, and it did
not show up under tmux because tmux does not send the same terminal
escape sequences as screen. This alone does not make screen a piece of
shit.

Miod



Re: putty or ssh, screen $cmd

2011-05-28 Thread Ted Unangst
No program, no matter how poorly written, can crash a correctly written
kernel.

On May 28, 2011, at 4:54 AM, gilbert.fernan...@orange.fr wrote:

 On Fri, May 27, 2011 at 11:15:14PM -0400, Hugo Villeneuve wrote:

 Just saying that at least, screen has been working for decades
 properly. Even if it was archaic. But it's not like tty are anything
 new themselves (the 8bit version ones).

 If you try screen on some machines, you will crash so badly
 that even DDB inside the kernel is frozen after displaying
 one or two lines of panic. At first, you wonder. Then you try
 tmux, and it no longer crashes. And last, you go see the
 screen sources, and it's like being Nicky Larson getting
 a 10-ton hammer hit on the head...

 --
 Gilbert Fernandes



Re: putty or ssh, screen $cmd

2011-05-28 Thread Helmut Schneider
Nick Holland wrote:

 On 05/27/11 14:53, Helmut Schneider wrote:
  [Problem with screen]
[...]
 http://www.openbsd.org/faq/faq7.html#tmux
 man tmux
[...]

Thanks for all replies (also by pm), tmux indeed looks promissing.

Helmut



Re: putty or ssh, screen $cmd

2011-05-27 Thread Nick Holland
On 05/27/11 14:53, Helmut Schneider wrote:
 Hi,
 
 I'd like to supply a command to screen. Unfortunatly when using putty
 or ssh nothing seems to happen:

screen?  screen?  I dimly recall a program called screen.  Archaic piece
of sh**, as I recall.

 [helmut@OBSDHelmut ~]$ screen ls -la
 [screen is terminating]
 [helmut@OBSDHelmut ~]$
 
 [helmut@BSDHelmut ~]$ ssh -t obsdhelmut screen ls -la
 Enter passphrase for key '/home/helmut/.ssh/id_dsa':
 [screen is terminating]
 Connection to obsdhelmut closed.
 [helmut@BSDHelmut ~]$
 
 When doing this on a console it works fine. 

dunno what works fine means, but today, we use a program called
tmux, which is part of base OpenBSD.

n...@fluffy.in.nickh.org
/home/nick $ ssh backup tmux -c 'ls -la /'
nick@backup's password:
total 65500
drwxr-xr-x  17 root  wheel  512 May 23 20:14 .
drwxr-xr-x  17 root  wheel  512 May 23 20:14 ..
-rw-r--r--   1 root  wheel  578 Feb 28  2009 .cshrc
-rw-r--r--   1 root  wheel  468 May 23 20:14 .profile
drwxr-xr-x   2 root  wheel  512 Mar  2 08:51 altroot
drwxr-xr-x   2 root  wheel 1024 Mar  2 08:53 bin
...

Seems to do something more than you show.  Not sure what you are trying
to accomplish, and since you didn't explain, I'm not going to worry
about it. :)  Whatever you wish to do with screen, you can probably
accomplish with tmux...most likely better, and if you can't figure out
how to make it dance as you want, as it is part of OpenBSD, ask right here.

http://www.openbsd.org/faq/faq7.html#tmux
man tmux

Introduce your Linux and other BSD users to tmux, they'll love it, other
than the ones that love screen only because it hasn't changed in
years...  (several of my coworkers are absolutely going ga-ga over tmux
and now pushing it more obnoxiously than me).

Nick.



Re: putty or ssh, screen $cmd

2011-05-27 Thread Hugo Villeneuve
On Fri, May 27, 2011 at 10:27:59PM -0400, Nick Holland wrote:
 On 05/27/11 14:53, Helmut Schneider wrote:
  Hi,
  
  I'd like to supply a command to screen. Unfortunatly when using putty
  or ssh nothing seems to happen:
 
 screen?  screen?  I dimly recall a program called screen.  Archaic piece
 of sh**, as I recall.
 
 
 http://www.openbsd.org/faq/faq7.html#tmux
 man tmux
 

Has tmux been fixed to work on  150 MHz computers since it has
moved to libevent?

It was so bad I would compile a pre-libevent version on those
computers.

(Will need to check. It was probably more a libevent issue than tmux.)

Just saying that at least, screen has been working for decades
properly. Even if it was archaic. But it's not like tty are anything
new themselves (the 8bit version ones).



Re: putty or ssh, screen $cmd

2011-05-27 Thread Theo de Raadt
 Just saying that at least, screen has been working for decades
 properly. Even if it was archaic. But it's not like tty are anything
 new themselves (the 8bit version ones).

Go read the source code some time.

bye bye.



Re: putty or ssh, screen $cmd

2011-05-27 Thread Ted Unangst
On Fri, May 27, 2011 at 11:15 PM, Hugo Villeneuve
harpa...@jwales.eintr.net wrote:
 Has tmux been fixed to work on  150 MHz computers since it has
 moved to libevent?

Has anyone reported what doesn't work?