[GH-ISSUE #1677] Ubuntu 14.04 Won't Log, Empty Log files in /log/console/ #1304

Closed
opened 2026-02-27 02:56:24 +03:00 by kerem · 5 comments
Owner

Originally created by @medic917 on GitHub (Oct 30, 2017).
Original GitHub issue: https://github.com/GameServerManagers/LinuxGSM/issues/1677

I migrated my server to Ubuntu 14.04 from Debian 7, and I run into this problem where my log files are empty and I think it is due to permissions. If you see my screenshot below, the permissions are 0664.
https://i.imgur.com/6huTGrg.png

I'm using an old version of this script that uses this snippet of code to write the log file. I have to use the old version since it is synced with my system for auto updates.

logdays="7"
gamelogdir="${systemdir}/logs"
scriptlogdir="${rootdir}/log/script"
consolelogdir="${rootdir}/log/console"

scriptlog="${scriptlogdir}/${servicename}-script.log"
consolelog="${consolelogdir}/${servicename}-console.log"
emaillog="${scriptlogdir}/${servicename}-email.log"

scriptlogdate="${scriptlogdir}/${servicename}-script-$(date '+%d-%m-%Y-%H-%M-%S').log"
consolelogdate="${consolelogdir}/${servicename}-console-$(date '+%d-%m-%Y-%H-%M-%S').log"

fn_scriptlog(){
echo -e "$(date '+%b %d %H:%M:%S') ${servicename}: ${1}" >> ${scriptlog}
}

Do you think it is due to permissions issue? Notice how in the screenshot there is no default tf2-server-console.log file, just a bunch of empty ones being created. Usually the most recent log will have no dates on it, but on my new ubuntu server, it doesnt even exist.

The server script runs fine, it's just the logging that is having issues.

Originally created by @medic917 on GitHub (Oct 30, 2017). Original GitHub issue: https://github.com/GameServerManagers/LinuxGSM/issues/1677 I migrated my server to Ubuntu 14.04 from Debian 7, and I run into this problem where my log files are empty and I think it is due to permissions. If you see my screenshot below, the permissions are 0664. https://i.imgur.com/6huTGrg.png I'm using an old version of this script that uses this snippet of code to write the log file. I have to use the old version since it is synced with my system for auto updates. logdays="7" gamelogdir="${systemdir}/logs" scriptlogdir="${rootdir}/log/script" consolelogdir="${rootdir}/log/console" scriptlog="${scriptlogdir}/${servicename}-script.log" consolelog="${consolelogdir}/${servicename}-console.log" emaillog="${scriptlogdir}/${servicename}-email.log" scriptlogdate="${scriptlogdir}/${servicename}-script-$(date '+%d-%m-%Y-%H-%M-%S').log" consolelogdate="${consolelogdir}/${servicename}-console-$(date '+%d-%m-%Y-%H-%M-%S').log" fn_scriptlog(){ echo -e "$(date '+%b %d %H:%M:%S') ${servicename}: ${1}" >> ${scriptlog} } Do you think it is due to permissions issue? Notice how in the screenshot there is no default tf2-server-console.log file, just a bunch of empty ones being created. Usually the most recent log will have no dates on it, but on my new ubuntu server, it doesnt even exist. The server script runs fine, it's just the logging that is having issues.
kerem closed this issue 2026-02-27 02:56:24 +03:00
Author
Owner

@MarkTwoFive commented on GitHub (Oct 30, 2017):

If this is a permissions issue you need to check the permissions of the log directory so you know if lgsm is even allowed to create files and directories.

<!-- gh-comment-id:340525715 --> @MarkTwoFive commented on GitHub (Oct 30, 2017): If this is a permissions issue you need to check the permissions of the log directory so you know if lgsm is even allowed to create files and directories.
Author
Owner

@medic917 commented on GitHub (Oct 31, 2017):

Forgot to mention that I tried changing the permissions to directory, but the files keep writing as 0664 no matter what I try. I'm on ubuntu 14.04 so perhaps I'm missing something? Is there a root command that I should be using? I usually just use my WinSCP gui to change permissions of directories.

<!-- gh-comment-id:340626210 --> @medic917 commented on GitHub (Oct 31, 2017): Forgot to mention that I tried changing the permissions to directory, but the files keep writing as 0664 no matter what I try. I'm on ubuntu 14.04 so perhaps I'm missing something? Is there a root command that I should be using? I usually just use my WinSCP gui to change permissions of directories.
Author
Owner

@MarkTwoFive commented on GitHub (Oct 31, 2017):

0664 is perfectly fine for log files. The default file permissions are defined by the umask (just in case you wanna google that).

Verify that the log folder also has at least 66x set as its permissions.

<!-- gh-comment-id:340741432 --> @MarkTwoFive commented on GitHub (Oct 31, 2017): 0664 is perfectly fine for log files. The default file permissions are defined by the ``umask`` (just in case you wanna google that). Verify that the log folder also has at least 66x set as its permissions.
Author
Owner

@UltimateByte commented on GitHub (Nov 8, 2017):

If you watch the FAQ, you learn that tmux lower than 1.6 or equal to 1.8 has no logging.
https://github.com/GameServerManagers/LinuxGSM/wiki/Tmux

No relevant info, no support.
https://github.com/GameServerManagers/LinuxGSM/wiki/Support
Also user support isn't done on github anyways.

<!-- gh-comment-id:342664716 --> @UltimateByte commented on GitHub (Nov 8, 2017): If you watch the FAQ, you learn that tmux lower than 1.6 or equal to 1.8 has no logging. https://github.com/GameServerManagers/LinuxGSM/wiki/Tmux No relevant info, no support. https://github.com/GameServerManagers/LinuxGSM/wiki/Support Also user support isn't done on github anyways.
Author
Owner

@lock[bot] commented on GitHub (Nov 8, 2018):

This thread has been automatically locked since there has not been any recent activity after it was closed. Please open a new issue for related bugs.

<!-- gh-comment-id:436834385 --> @lock[bot] commented on GitHub (Nov 8, 2018): This thread has been automatically locked since there has not been any recent activity after it was closed. Please open a new issue for related bugs.
Sign in to join this conversation.
No labels
Atomic
Epic
cannot reproduce
command: backup
command: console
command: debug
command: details
command: fast-dl
command: install
command: mods
command: monitor
command: post-details
command: restart
command: send
command: start
command: stop
command: update
command: update-lgsm
command: validate
command: wipe
distro: AlmaLinux
distro: Arch Linux
distro: CentOS
distro: Debian
distro: Fedora
distro: RedHat
distro: Rocky Linux
distro: Ubuntu
distro: openSUSE
engine: goldsrc
engine: source
game: 7 Days to Die
game: ARMA 3
game: Ark: Survival Evolved
game: Assetto Corsa
game: Avorion
game: BATTALION: Legacy
game: Barotrauma
game: Battalion 1944
game: Battlefield 1942
game: Black Mesa: Deathmatch
game: Blade Symphony
game: Call of Duty 2
game: Call of Duty 4
game: Call of Duty: United Offensive
game: Counter-Strike 1.6
game: Counter-Strike 2
game: Counter-Strike: Global Offensive
game: Counter-Strike: Source
game: Day of Infamy
game: Dayz
game: Death Match Classic
game: Don't Starve Together
game: ET: Legacy
game: Eco
game: Factorio
game: Factorio
game: Garry's Mod
game: Half-Life
game: Hurtword
game: Insurgecy
game: Insurgecy
game: Insurgency: Sandstorm
game: Just Cause 3
game: Killing Floor
game: Killing Floor 2
game: Left 4 Dead 2
game: Minecraft
game: Minecraft Bedrock
game: Mordhau
game: Multi Theft Auto
game: Mumble
game: Natural Selection 2
game: No More Room in Hell
game: Pavlov VR
game: Post Scriptum
game: Project Zomboid
game: Quake 3
game: QuakeWorld
game: Red Orchestra: Ostfront 41-45
game: Return to Castle Wolfenstein
game: Rising World
game: Rust
game: San Andreas Multiplayer
game: Satisfactory
game: Soldat
game: Soldier of Fortune 2
game: Squad
game: Squad 44
game: Starbound
game: Stationeers
game: Sven Co-op
game: Team Fortress 2
game: Teamspeak 3
game: Teeworlds
game: Terraria
game: The Front
game: Unreal Tournament 2004
game: Unreal Tournament 3
game: Unreal Tournament 99
game: Unturned
game: Valheim
game: Wurm Unlimited
game: Zombie Master Reborn
game: label missing
good first issue
help wanted
info: alerts
info: dependency
info: docker
info: docs
info: email
info: query
info: steamcmd
info: systemd
info: tmux
info: website
info: website
needs more info
outcome: duplicate
outcome: issue resolved
outcome: issue resolved
outcome: issue unresolved
outcome: pr accepted
outcome: pr rejected
outcome: unconfirmed
outcome: wontfix
outcome: wrong forum
potential-duplicate
priority
pull-request
type: bug
type: feature
type: feature
type: feature request
type: game server request
type: refactor
waiting response
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
starred/LinuxGSM#1304
No description provided.