Stack Exchange Network

Stack Exchange network consists of 175 Q&A communities including Stack Overflow, the largest, most trusted online community for developers to learn, share their knowledge, and build their careers.

Visit Stack Exchange

Questions tagged [gnu-screen]

GNU Screen is a software application that can be used to multiplex several virtual consoles.

5
votes
2answers
3k views

Putty + Bash + Screen, up arrow for history not working (Ubuntu 11.10)

I have a fresh install of Ubuntu Server 11.10 that I am logging into SSH via PuTTy. When I am inside screen, I cannot use the up arrow to recall bash history (though this works outside of screen). I ...
2
votes
2answers
417 views

Restart screen in screen session

Similarly to this question about restarting ssh when ssh is the only mode of connection to a server, what happens if I aptitude upgrade screen inside a screen session?
1
vote
1answer
147 views

Reconnect to screen and preserve splits

Is it possible to reconnect to a disconnected screen session and preserve the screen splits?
0
votes
2answers
271 views

Running php inside screen with parameters?

i am running a php file that takes up to 2-4 hours to run, and because my internet is so bad i will need to run it inside a linux server (screen). My question is: How can i run php file inside screen ...
3
votes
1answer
130 views

customizing terminal ssh shell [closed]

The other day I saw someone connected to an ssh shell with status bars on the bottom (Mac OS X Terminal) of the terminal. It has things such as upload rate, memory usage, time, current username, and ...
2
votes
1answer
910 views

ulimit permissions are hard set directly from a screen instance. How can this be fixed?

At best I can describe this issue with a shell session: This shows that ulimit works fine. This is the start of a normal ssh session: $>ulimit -c 0 (ushanka:973:0) ~ $>ulimit -c unlimited (...
2
votes
3answers
868 views

How can I run a batch of commands inside one “screen” window?

I'm using screen (LINUX) to run servers or task, but I want to put more than one task in one screen, is it impossible? Like: screen -A -m -d -S test_screen userdel -r user_test && useradd -m -...
0
votes
4answers
897 views

Continually check to make sure php script is running

Is it possible to configure my CentOS VPS to continually check to make sure that a php script is running? Currently I'm using the screen php method which works fine, but if it gets terminated somehow, ...
0
votes
2answers
1k views

256 Color Issue when using GNU Screen inside GNU Screen

When I have a SSH session in GNU Screen to another machine on which I'm also using GNU Screen, 256 colors don't seem to work. The $TERM is still set correctly. However, if I run Vim, the theme does ...
4
votes
2answers
2k views

Why can't I attach a screen session

I've got a screen session running which I would like to :quit, but I can't because when I try to re-attach, I get an error saying it can't open my terminal. I'm sure I could kill the daemon or ...
1
vote
1answer
2k views

run several bash scripts with expect code and leave them running

I have a bunch of several bash scripts that will perform some actions that require user input, therefore I'm using expect with it. However, I need one to keep running. But if I use expect, the expect ...
3
votes
2answers
875 views

How to prevent GNU screen from expanding tabs into spaces?

Using a normal bash prompt echo -e 'hello\tworld' produces a real tab. However the same command run within GNU screen puts spaces between the two words. I have tested this on Ubuntu 10.04 with Screen ...
0
votes
1answer
3k views

Can't type in commands after reattching to a screen session

Using CentOS 5, I have a screen session running and I often reattach to it after a day or two with the usual: screen -r <sockname> The session reattaches fine, and runs fine (I can see output ...
3
votes
2answers
1k views

screen not dropping down a line?

Minor annoyance with the Screen linux utility; when connected to a Linux (Fedora) box from my Mac (using Terminal), when I'm writing out a long command, usually when the text reaches the edge of the ...
6
votes
2answers
7k views

GNU screen clearing on vim,less,etc. exit

I'm very new to screen but have configured my ~/.screenrc file according to various recommendations I've found on the internet. I have one issue with it though which I'm sure could be resolved very ...
0
votes
1answer
307 views

Ubuntu using screen to control a Java server

I have a shell script that makes a backup of my server files before starting it. However I wish it to instead of just running it open a new screen session and then start it from there. Once its ...
2
votes
1answer
600 views

I cannot use screen stuff command from cron, but I can from a shell script (same user)

I have a shell script on FreeBSD that sends a few screen stuff commands to a running screen session (which runs a Minecraft server). The commands work when I execute it manually. But if I put the ...
2
votes
3answers
476 views

How can I return to nohup after logout?

I'm working on an AIX and cannot install screen but want to use its capabilities. Basically I want to be able to run a session (maybe logout), then the same user but logged in again to be able to get ...
1
vote
2answers
1k views

Send input to all screen windows

Is there a command in screen to replicate a command to every window? I'd like to send something such as 'reboot' to every window at once. Is this possible? I've seen talk about the 'at' command via ...
8
votes
4answers
3k views

GNU Screen and Tmux: tips and tricks

So I am a big fan of the multiplexers like GNU Screen and Tmux, but even using Screen for years now I still recognize that there are many things there I don't know (and I only use Tmux for a couple of ...
5
votes
1answer
277 views

How to “Open a new window in GNU/Screen” by running a command?

I want to know how to accomplish this: Open a new window in GNU/screen, by running a command. Here's what I want to do: I uses GNU/screen daily. My laptop runs in UTF-8 locale, and I need to ssh to ...
69
votes
7answers
24k views

How to check if I'm in screen session?

is it somehow possible to check if I'm right now in screen session? I need it to determine if hitting ctrl+d would disconnect me from server or just close current screen. Thanks.
36
votes
2answers
15k views

Why does redirecting 'script' to /dev/null/ allow 'screen' to work while su'ed as another user?

I was su'ed into a user to run a particular long running script. I wanted to use screen but I got the error message "Cannot open your terminal '/dev/pts/4' - please check." So I Googled around and ...
1
vote
2answers
777 views

Disable clear at start of screen via .screenrc?

Is there any way to disable the behavior of gnu-screen, of issuing a clear at startup? I'm using screen merely as a backstop, so that if disconnected, the session isn't HUP'ed. And I've got my shell (...
1
vote
1answer
809 views

embedded linux serial terminal

I have built a custom embedded system using debian 6.0. using /etc/inittab i have made several (8) processes running on different /dev/ttyX terminals, which i can switch between using Alt+FX key ...
2
votes
4answers
2k views

Should I update the kernel on a Linux machine?

As I understand it, updating to a new kernel (with the normal linux-image... package, not by rolling my own) requires a server restart. However, one of our servers (Ubuntu 10.04) is running several ...
7
votes
3answers
14k views

Specifying a log name for screen output without relying on .screenrc

In a bash script, I use "screen -L" to log executed commands in color. For example : screen -L tree Then we read logfile with less -R. When this script is executed, other screens are potentially ...
0
votes
3answers
569 views

Can't SSH through screen

I have set up hosts.allow on the remote Arch Linux server as follows: sshd: ALL: ALLOW while hosts.deny is set to: ALL: ALL I have no problems using SSH through Cygwin (with a Corkscrew tunnel ...
96
votes
2answers
44k views

How to re-order windows, change the scroll shortcut, and modify the status bar contents in GNU Screen?

I learned to use gnu-screen and have been using it for the past several weeks. I got a grip of the basics now, and would be very helpful if I get these queries clarified: How do I rename / reorder / ...
1
vote
2answers
3k views

confusion in attaching detaching screen on Ubuntu

screen -list shows There are screens on: 9531.pts-0.ubuntu (03/02/2011 12:43:34 PM) (Detached) 2101.pts-0.ubuntu (03/02/2011 12:39:17 PM) (Attached) 2219.pts-0.ubuntu (03/02/...
6
votes
2answers
9k views

How to prevent screen from terminating when command in window terminates

When running 'screen ls' the screen stops with the text [screen is terminating]. I would like screen to keep the session alive and reattach to it to see the output of ls. Of course the real thing is ...
4
votes
1answer
2k views

Screen -X exec commands not working until manually attached

I have a batch script that starts a java server application inside of a screen. The command looks like this: cd /dir/ && screen -A -m -d -S javascreen java -Xms640M -Xmx1024M -jar ...
10
votes
4answers
29k views

How do I use crontab to start a screen session?

I want to create a crontab entry so that it starts screen, starts a gameserver and detaches. This is for in case the server is rebooted and I want it to automatically start this for me. 0 0 0 0 0 (...
4
votes
7answers
4k views

I have a perl script that is supposed to run indefinitely. It's being killed… how do I determine who or what kills it?

I run the perl script in screen (I can log in and check debug output). Nothing in the logic of the script should be capable of killing it quite this dead. I'm one of only two people with access to ...
1
vote
1answer
223 views

Some keys not working under screen in vim

When using vim under screen, some keys are not working. Namely, Pressing Alt-Left produces '3D' and Alt-Right produces '3C' Also, pressing Up/Down when scrolling list of files in Command-T plugin ...
0
votes
2answers
444 views

Is gnu screen or tmux more stable for keeping running on the server?

I want to keep a screen or tmux session running forever on a Ubuntu server, possibly for running a Clojure web server application so I can tap into the process via REPL at any time. Gnu screen or tmux ...
0
votes
1answer
2k views

Howto get exit code of a script started in screen session

I am currently creating a backup script which uses screen to start a backup job with rsync inside a screen session. The backup jobs are started as follows. screen -dmS backup /usr/bin/rsync ... As ...
5
votes
3answers
11k views

VMware ESXi display guest screen instead of console

I'm using ESXi 4.1 for my virtualitzation platform, and I would like to display one of the guests screen to the host VGA output. Is this possible? I want to do this because my host machine is plugged ...
17
votes
2answers
10k views

How to tell GNU screen to run .bash_profile in each new window?

When I open a new window in GNU screen, it runs .bashrc but not .bash_profile. In my setup, this results in some environment variables not being set up correctly in that window. How can I tell GNU ...
0
votes
3answers
198 views

Screen windows dies

I am using screen with irssi, ssh to some servers. At the moment I have 4 windows "open" in my screen. Two of those windows is "dead". I can't write something in those, for example. How do I "exit" ...
9
votes
12answers
100k views

Remote Desktop Connection Screen is totally black but server is working perfectly

Server is working perfectly but when I do RDC screen is only black. This happened before and I fixed it by powering off the server via KVM/IP, but I don't want do that again. How can I fix this issue. ...
3
votes
2answers
1k views

Configure GNU screen so that it stores command histories in files

I would like to configure GNU screen such that it stores the command histories of all the different windows in different files. I know by default GNU screen does not store the command histories (of ...
1
vote
2answers
251 views

GNU Screen: opening each screen buffer in a separate terminal tab

I'm looking for a Linux terminal that is fully integrated with GNU Screen, i.e. mapping each screen buffer to a separate tab and with full scrollback support - all that inside a SSH session. Is this ...
3
votes
2answers
2k views

in linux screen how do you turn off the status tab?

Is there a way in screen to turn off the status bar? Ideally, only display it when I have 2+ tabs open? What .screenrc entries would accomplish this?
5
votes
1answer
768 views

send interrupt to window in screen

How can I send a interrupt to a window within screen. I have screen running with several windows. Each of the windows have processes running within them. I wish to be able to send and interrupt to ...
8
votes
2answers
1k views

Does tmux have all the features that screen has? And those screen is missing?

I'm considering switching from screen to tmux, but I've invested lots of time developing an extensive .screenrc, and I don't want to find after many hours of porting it to tmux that tmux can't do ...
5
votes
2answers
999 views

When using vim with screen the keys ctrl + right and ctrl + left don't work

In the last days i became very addicted of using the combination terminator (in full screen) + screen + vim. But i'm having problems with the ctrl + right and ctrl + left key mappings, they are ...
0
votes
2answers
981 views

How can I go back in the (GNU) screen command history? (NOT shell command history!)

Currently, when I enter ^a : (control-A followed by ':') to send a command to GNU screen, I can go back one step in the history, and see exactly ONE previous command. This is really annoying, as I'm ...
13
votes
6answers
40k views

How to scroll back in screen within a ssh session from OS X? [closed]

I do the following: Open Terminal.app Open a ssh session to a remote Linux server Open a screen session on the server Start a program who breaks with many lines of error reporting… How can I scroll ...
1
vote
5answers
2k views

Using screen to monitor non-interactive scripts (or some other solution)

I have some autonomous scripts that run commands on remote machines over ssh. These scripts rely on getting stdout, stderr, and the return code of each command run. I want to be able to monitor the ...