How to run a dedicated server using "screen"

Post Reply
mtmtyu
Posts: 2
Joined: 20 Jan 2021 10:08

How to run a dedicated server using "screen"

#1 Post by mtmtyu » 25 Mar 2023 09:29

I want the server to work even if I disconnect the SSH connection using 'screen'.
However, it didn't work and I couldn't find it on Google, so I'm posting it here.
(I'm Japanese and use Google Translate.)
User avatar
donfede
Posts: 126
Joined: 03 Feb 2017 03:55
Contact:

Re: How to run a dedicated server using "screen"

#2 Post by donfede » 25 Mar 2023 11:33

Hello @mtmtyu

Can you share the steps/commands you tried, and the error message or symptom please?

Not having more info, wondering if the screen detatch command sequence was used. The default screen detach command is

Code: Select all

CTRL-A CTRL-D
One can later reconnect to the screen session with

Code: Select all

screen -R -D
Happy convoy :)
Last running ETS2 and ATS on Debian GNU/Linux old-stable "stretch" 9 64bit
mtmtyu
Posts: 2
Joined: 20 Jan 2021 10:08

Re: How to run a dedicated server using "screen"

#3 Post by mtmtyu » 25 Mar 2023 12:18

@donfede I am using "Canonical-Ubuntu-22.04-2023.02.15-0" and using "CTRL-A CTRL-D" does not work. The software uses teraterm
Last edited by mtmtyu on 25 Mar 2023 12:20, edited 2 times in total.
jester197110
Posts: 2
Joined: 09 Nov 2021 12:07

Re: How to run a dedicated server using "screen"

#4 Post by jester197110 » 06 Oct 2023 22:14

Try running the server form the terminal with "nohup <process> <process_options". The "no hangup" should prevent the process form closing when the teminal closes. This does not need the screen comand.

More info here: https://www.google.com/search?q=linux+m ... e&ie=UTF-8

Posts merged

Another way to go, if this server platform is on the same computer you are gaming from, is to got to a TTY terminal (e.g. Crtl+Alt+F3), login and run the server with nohup or screen, and then switch back to the GUI (Ctrl+Alt+F7). This may not work with all distro's but I am confident it will for most.

Also, instead of using a GUI terminal window, use the TTY to ssh wherever else the server needs to be started. If you use the screen option, Ctrl+A Ctrl+D should work fine from the TTY environment.
Post Reply

Return to “Technical Problems”

Who is online

Users browsing this forum: No registered users and 14 guests