Questions tagged [gnu-screen]

screen (GNU Screen) is a full-screen window manager that multiplexes a physical terminal between several processes, typically interactive shells. Before using this tag, read the "Which site is more appropriate?" section of the tag wiki.

screen (GNU Screen) is used to create virtual terminals, which run by their own when not under direct user control. This is especially useful while working with a remote system, when a disconnect can occur at any moment. In this case, the screen session will continue to execute and you may reattach a running screen later.

Screen also allows you to execute multiple commands in a single terminal without losing control over them.

One additional trick is that a single virtual screen can be used by several users simultaneously, allowing them to guide and observe actions of each other.

Which site is more appropriate?

If you intend to tag your question with this tag, consider if the question is more suitable for other Stack Exchange sites:

1022 questions
0
votes
1 answer

Starting Screen with a Command

I need to be able to start up a screen without connecting to it, but it also needs to run my start.sh script which contains the java line to start Minecraft. screen -d -m new3 -c start.sh Is what I've been trying to use, but it never runs…
Jeremy Sayers
  • 637
  • 4
  • 10
  • 23
-1
votes
2 answers

What is causing my figures to be invisible when I switch to a detached screen

Can't see pyplot figures when on a detached screen Pyplot figures were visible when on attached screen and I expected its behavior to not change. It did. Code I'm using for the plots: def plot(self, _): def total_seconds(fecha): …
Vandraren
  • 1
  • 4
-1
votes
2 answers

The display is wrong when using iTerm2 + screen + emacs on macOS monterey

When I use iTerm2 + screen + emacs, the display is something wrong. For example, underline is set automatically at whitespace even if I don't customize setting. And character's color is different from what I don't use screen. The color is pink on…
htano
  • 55
  • 4
-1
votes
2 answers

Using bash with screen in an alias

I have a screen session that is always running in a separate user (for a minecraft server). Each time I want to attach to this screen, I use su -c 'screen -r mc-1.18.2' minecraft to attach back to this screen. I wanted to make an alias for this…
That_Dude
  • 11
  • 3
-1
votes
1 answer

Systemctl(?) killing detached screens

I have a program written in Go that programmatically creates and manages screens. Here's an example: _, err := exec.Command("screen", "-S", "screen-"+strings.ToLower(name), "-X", "stuff", command+"\n").Output() This works fine. When I Control+C the…
-1
votes
1 answer

Syntax error when using screen with ssh and remote gawk

I need to run the following command in a bash script. The command needs to be run inside a GNU screen so I can see the progress. So the command needs to be in quotes, but because of that I am having problems with the syntax and the code isn't…
anarchy
  • 3,709
  • 2
  • 16
  • 48
-1
votes
1 answer

Bash - Is there a way to execute a command on a running screen?

I am running some minecraft servers on a debian 9 based machine. These different servers are running on some screens. I have made a backup script that I planned with cron tab but my problem is I wish to inject a command on the minecraft server's…
Antoine Bonal
  • 39
  • 2
  • 7
-1
votes
1 answer

Get name of current screen session

How to get current screen session name (bash)? I need implement it in Python, so would be much more better just command without Ctrl combinations. I know way with screen -ls | grep 'Attached' but it's not elegant and sometimes not correct
-1
votes
1 answer

GNU Screen: connection already closed

I am running some tasks that might take 3-4months to complete (datasets transfer) on remote server via ssh, so I used screen to run a python scripts doing the job. Unfortunately, connection breaks after running for like 6-8 days (this happen twice),…
arilwan
  • 3,374
  • 5
  • 26
  • 62
-1
votes
1 answer

How to use bash to open multiple screen and let them run independently

Screen only supports ctrl+a+d for temporary departure, I try to use expect's send "/ 01d" but there is no response, there is no response to executing the expect script alone in screen, is there a better way to complete execution in screen and create…
GiGOB
  • 1
  • 1
-1
votes
1 answer

Show user in vim status line

I already have set in vim a permanent status line which is quite nice, with the following config in my .vimrc " Status line config set statusline= set statusline+=%<\ " cut at start set statusline+=%2*[%n%H%M%R%W]%*\ "…
Joel.O
  • 1,980
  • 3
  • 16
  • 26
-1
votes
1 answer

screen logging not working over ssh terminal

I want to run "screen" on a debian linode server, starting up over a ssh terminal window. I'd like a shell script to start and detach a screen, so that a process can continue when I log off. I'd also like the logging file screenlog.0 to be…
rshaw
  • 111
  • 1
  • 3
-1
votes
1 answer

How do I use popen to open "screen" in C++?

I have a c++ program: #include #include #include #include #include #include #include using namespace std; int main (int argc, const char * argv[]) { // system("script…
StarckOverflar
  • 1,577
  • 2
  • 10
  • 13
-1
votes
1 answer

Screen: continuously record the buffer values and save onto a file

I am asking using the screen command in Ubuntu. I know there is a command that use hardcopy which basically save the buffer onto the file. But how do I continously ask screen to write the output onto a file for me? If I do the following: python…
Nygen Patricia
  • 229
  • 2
  • 8
-1
votes
2 answers

Shell command in screenrc

I'm trying to improve my screen software, so I'll have a lot of questions because there are many answers that I have difficulty to find on internet... Anyway, this one is about a shell command that I would like screen to execute when opening, and it…
hugogogo
  • 501
  • 4
  • 24