Sponsored Content
Top Forums UNIX for Advanced & Expert Users Help with GNU screen: Backtick and Caption. Post 302350001 by akbar on Wednesday 2nd of September 2009 01:20:11 PM
Old 09-02-2009
Help with GNU screen: Backtick and Caption.

I'm trying to get GNU screen to show the output of "uptime" for the host being accessed in the current window, but unfortunately, no matter what window I go in, it shows the uptime for the host I originally launched screen in ("adminhost").

Does anyone know how to get this to update from the current host I'm on?

Here's my screenrc:

escape ^Ww
sessionname akbar
shell /bin/ksh
backtick 1 5 5 uptime
backtick 2 10 10 hostname
caption always "%2` %1`"

screen -t adminhost
screen -t host1 ssh host1
screen -t host2 ssh host2
screen -t host3 ssh host3



Thanks in advance my friends.
 

10 More Discussions You Might Find Interesting

1. UNIX for Advanced & Expert Users

GNU Screen: Send to Multiple Screens at Once?

There is a feature that I used in KDE's Konsole that I really miss when I'm on a non-GUI server. The ability to "broadcast" what I type to all open windows. That led me to wonder if this could be done with GNU screen (since it can do a whole lot of other cool stuff)? Basically, it would be... (3 Replies)
Discussion started by: deckard
3 Replies

2. HP-UX

Compiling GNU 'screen' on HP-UX 11i

I finally gave up and installed the prepackaged version of 'screen', but I really want to get a better understanding of why my compilation of 'screen' failed on HP-UX 11i using GNU gcc (also from a prepackaged version). Whenever I would try to run './configure' to prep for building screen, it... (4 Replies)
Discussion started by: deckard
4 Replies

3. UNIX for Advanced & Expert Users

GNU screen

Hello, One of the things I like about screen is that it has a scrollback buffer, which if you go into the copy mode, will let you go back for a specified number of line. Is there a way to extend the number of scrollback lines in screen? I've looked thoroughly online and I could not find a... (2 Replies)
Discussion started by: neked
2 Replies

4. UNIX for Dummies Questions & Answers

Redirection to GNU screen attached serial port

I'm using GNU screen as a terminal to connect with a usb serial port. eg. screen /dev/tty.usbserial . This works well enough for manual processes. Is there a way to redirect the output of a script running in another session to the stdin of this virtual terminal? ie. I want to repeatedly send some... (1 Reply)
Discussion started by: geoffjMontreal
1 Replies

5. Shell Programming and Scripting

By using awk, how to '(backtick)?

Can I know how to express the '(backtick) in awk?! By typing \' ??? (8 Replies)
Discussion started by: patrick87
8 Replies

6. UNIX for Dummies Questions & Answers

GNU Screen - viewing hardcopy (binary)

I generate a hardcopy (C-a h) of an ncurses screen which has some formatting on it (boxes, highlights). If I "cat" the file, i get only text. If I do a cat hardcopy.n | less , then i see a lot of control characters where the boxes are. most hardcopy.n shows me a hexdump of the file. less... (0 Replies)
Discussion started by: sentinel
0 Replies

7. HP-UX

GNU screen on HP-UX 11.23

I compiled GNU screen on HP-UX 11.23 and following the compile, I get the following error when I try to run screen Cannot find terminfo entry for 'vt100' By default the TERMINFO is not set, I found a reference that setting it might help. I tried the following but I still receive the same... (2 Replies)
Discussion started by: scotbuff
2 Replies

8. UNIX for Advanced & Expert Users

GNU screen: shortcut to go to tab 10,11 etc

Using GNU-Screen for a long time. C-a 1 2 n p to navigate to other tabs. This works till 9. I often have 10, 11 etc. Is there any way to go to them quickly ? Currently, i have to do C-a 9, C-a n which is quite a pain. Thanks. (0 Replies)
Discussion started by: sentinel
0 Replies

9. Shell Programming and Scripting

GNU-Screen Stuff problems

OPTIONS="java -Xms1024M -Xmx1024M -jar craftbukkit.jar" PROCESS=server01 screen -dmS $PROCESS $OPTIONS nogui # Starting the application screen -x $PROCESS -X stuff `printf "stop\r"` # Closing the application screen -x $PROCESS # Attaching to the... (3 Replies)
Discussion started by: Zanax
3 Replies

10. Linux

GNU Screen key bindings....

After I do CTRL-" to show all of my screen sessions, I typically use the up and down arrows to navigate up and down. Suddenly this has changed, and instead only "j" and "k" seem to work for up and down. This has changed in the middle of my screen session. First one changed, and then the... (1 Reply)
Discussion started by: akbar
1 Replies
uptime(1)							   User Commands							 uptime(1)

NAME
uptime - show how long the system has been up SYNOPSIS
uptime DESCRIPTION
The uptime command prints the current time, the length of time the system has been up, and the average number of jobs in the run queue over the last 1, 5 and 15 minutes. It is, essentially, the first line of a w(1) command. EXAMPLES
Below is an example of the output uptime provides: example% uptime 10:47am up 27 day(s), 50 mins, 1 user, load average: 0.18, 0.26, 0.20 ATTRIBUTES
See attributes(5) for descriptions of the following attributes: +-----------------------------------------------------------+ |ATTRIBUTE TYPE ATTRIBUTE VALUE | |Availability SUNWcsu | +-----------------------------------------------------------+ SEE ALSO
w(1), who(1), whodo(1M), attributes(5) NOTES
who -b gives the time the system was last booted. SunOS 5.11 18 Mar 1994 uptime(1)
All times are GMT -4. The time now is 01:21 PM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy