Naming Screen Session Log Same As Screen Session Name
Clash Royale CLAN TAG#URR8PPP
up vote
0
down vote
favorite
I'm currently writing an update / launch script for multiple game servers, and am wanting to add auto-update functionality to the game servers.
startL4D2.sh
screen -mdS left4dead2_server /home/dustin/Steam/SteamFolder/L4D2/srcds_run -game left4dead2 ...
- Is it possible to have the screen output log file (screen -L) be named the same
as the screen session name (left4dead2_server)? All game servers will have a unique screen name. - I'd want the file to be overwritten every time the server launches (so the screen log is only from the last active session). For example, for this particular server, the screen log is saved as 'left4dead2_server.output'. For a CS:GO server, it might be CSGO.output. There can be anywhere from 1 to 10+ servers on the same machine, all with unique screen names.
So basically I'd be doing something like this:
- (Before game server launches) Does a screen output log exist with the same name as the screen name that's about to be launched?
- If yes, grep for word "MasterRequestRestart" from that log file. If found - there'll be an update before the server launches.
logs gnu-screen
New contributor
add a comment |Â
up vote
0
down vote
favorite
I'm currently writing an update / launch script for multiple game servers, and am wanting to add auto-update functionality to the game servers.
startL4D2.sh
screen -mdS left4dead2_server /home/dustin/Steam/SteamFolder/L4D2/srcds_run -game left4dead2 ...
- Is it possible to have the screen output log file (screen -L) be named the same
as the screen session name (left4dead2_server)? All game servers will have a unique screen name. - I'd want the file to be overwritten every time the server launches (so the screen log is only from the last active session). For example, for this particular server, the screen log is saved as 'left4dead2_server.output'. For a CS:GO server, it might be CSGO.output. There can be anywhere from 1 to 10+ servers on the same machine, all with unique screen names.
So basically I'd be doing something like this:
- (Before game server launches) Does a screen output log exist with the same name as the screen name that's about to be launched?
- If yes, grep for word "MasterRequestRestart" from that log file. If found - there'll be an update before the server launches.
logs gnu-screen
New contributor
add a comment |Â
up vote
0
down vote
favorite
up vote
0
down vote
favorite
I'm currently writing an update / launch script for multiple game servers, and am wanting to add auto-update functionality to the game servers.
startL4D2.sh
screen -mdS left4dead2_server /home/dustin/Steam/SteamFolder/L4D2/srcds_run -game left4dead2 ...
- Is it possible to have the screen output log file (screen -L) be named the same
as the screen session name (left4dead2_server)? All game servers will have a unique screen name. - I'd want the file to be overwritten every time the server launches (so the screen log is only from the last active session). For example, for this particular server, the screen log is saved as 'left4dead2_server.output'. For a CS:GO server, it might be CSGO.output. There can be anywhere from 1 to 10+ servers on the same machine, all with unique screen names.
So basically I'd be doing something like this:
- (Before game server launches) Does a screen output log exist with the same name as the screen name that's about to be launched?
- If yes, grep for word "MasterRequestRestart" from that log file. If found - there'll be an update before the server launches.
logs gnu-screen
New contributor
I'm currently writing an update / launch script for multiple game servers, and am wanting to add auto-update functionality to the game servers.
startL4D2.sh
screen -mdS left4dead2_server /home/dustin/Steam/SteamFolder/L4D2/srcds_run -game left4dead2 ...
- Is it possible to have the screen output log file (screen -L) be named the same
as the screen session name (left4dead2_server)? All game servers will have a unique screen name. - I'd want the file to be overwritten every time the server launches (so the screen log is only from the last active session). For example, for this particular server, the screen log is saved as 'left4dead2_server.output'. For a CS:GO server, it might be CSGO.output. There can be anywhere from 1 to 10+ servers on the same machine, all with unique screen names.
So basically I'd be doing something like this:
- (Before game server launches) Does a screen output log exist with the same name as the screen name that's about to be launched?
- If yes, grep for word "MasterRequestRestart" from that log file. If found - there'll be an update before the server launches.
logs gnu-screen
logs gnu-screen
New contributor
New contributor
New contributor
asked 6 mins ago
johndoe
61
61
New contributor
New contributor
add a comment |Â
add a comment |Â
active
oldest
votes
active
oldest
votes
active
oldest
votes
active
oldest
votes
active
oldest
votes
johndoe is a new contributor. Be nice, and check out our Code of Conduct.
johndoe is a new contributor. Be nice, and check out our Code of Conduct.
johndoe is a new contributor. Be nice, and check out our Code of Conduct.
johndoe is a new contributor. Be nice, and check out our Code of Conduct.
Sign up or log in
StackExchange.ready(function ()
StackExchange.helpers.onClickDraftSave('#login-link');
);
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
StackExchange.ready(
function ()
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2funix.stackexchange.com%2fquestions%2f475340%2fnaming-screen-session-log-same-as-screen-session-name%23new-answer', 'question_page');
);
Post as a guest
Sign up or log in
StackExchange.ready(function ()
StackExchange.helpers.onClickDraftSave('#login-link');
);
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Sign up or log in
StackExchange.ready(function ()
StackExchange.helpers.onClickDraftSave('#login-link');
);
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Sign up or log in
StackExchange.ready(function ()
StackExchange.helpers.onClickDraftSave('#login-link');
);
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Sign up using Google
Sign up using Facebook
Sign up using Email and Password