-
Notifications
You must be signed in to change notification settings - Fork 10
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
segmentation fault in Kubernetes #27
Comments
Heyho, the values are replaced via: sed -Ei "/${source}.*/d" "${CFG_PATH}" Currently the value is not escaped so I would expect your value isn't sed safe? E.g. contains /, \, [, ], &, *. |
Hi, I did that replacement to Its weird that there are no logs after the replacement, though. |
You can find out what happens by setting env var DEBUGGING to true which will add xtrace, so every cmd will be printed before execution. |
I guess I will just burn the password now. This is the container log with debugging enabled:
It immediately stops after that last command. The |
It seems to work if I remove |
updated the dev build first, e7aecfe Edit: "...-develop" should work as tag |
docker hub needs probably around a few minutes to build it. |
I just had a quick look at the
|
Oh, and the console log shows a segmentation fault 🙃 https://gist.github.com/alexstaeding/d5952cb1cf6bf0a827f2b827eed7b86c |
Console log is a good idea because after |
I just wiped everything (sts, pvc) and get the same segfault. This is a clean installation without mods.
What else can I look at? |
From a fresh start I have the same msg but server is working. Maybe important side note, gmod is very old e.g. it doesn't like if configured port and port from outside is not matching. So maybe there are issue with virtual networking but as I experienced it it didn't crashed it just wasnt reachable. Maybe lets test this config: volumes:
TTTDebug:
services:
debug:
build: .
ports:
- 27016:27016/tcp
- 27016:27016/udp
environment:
INSTALL_CSS: "true"
SERVER_PORT: 27016
SERVER_NAME: "Example Name"
SERVER_PASSWORD: securePassword
SERVER_VOICE_ENABLE: 0
SERVER_MAX_PLAYERS: 20
SERVER_RCON_PASSWORD: securePassword
volumes:
- TTTDebug:/home/steam/serverfiles
Log: /home/steam/log/console/gmodserver-console.log
|
In my configuration I have all ports set to the same number: 27015. I also tried 27016 as in your example but that still doesn't explain the segfault. Also, your container log keeps going further than mine. Mine stops here:
|
Sry I missed the note that I merged docker logs with console log: If the log until server start is identical, you have no addition warning or error, probably the issue is somewhere deeper.
|
The md5sum of the file matches...
I have tried now with a very simple docker compose configuration to debug this. version: '3.8'
services:
server:
image: jusito/docker-ttt:gmod_ttt_debian
container_name: ttt-server
ports:
- "27015:27015/tcp"
- "27015:27015/udp"
environment:
- SERVER_PORT=27015
- INSTALL_CSS=true
- WORKSHOP_COLLECTION_ID=2176094350
- SERVER_NAME=My Server
- SERVER_PASSWORD=server-password
- SERVER_DEFAULT_MAP=ttt_waterworld
I think that is a different error on my macbook, so I will open another issue. |
I discovered (at least part of) the problem. This diff fixes it: diff --git a/kubernetes/ttt/deploy.yaml b/kubernetes/ttt/deploy.yaml
index 898d92b..5a4ec75 100644
--- a/kubernetes/ttt/deploy.yaml
+++ b/kubernetes/ttt/deploy.yaml
@@ -54,7 +54,8 @@ spec:
value: "ttt_waterworld"
volumeMounts:
- name: data-volume
- mountPath: /home/steam/serverfiles
+ mountPath: /home/steam/serverfiles/steam_cache
+ subPath: steam_cache
volumeClaimTemplates:
- metadata:
name: data-volume It seems there are some files in the |
But even mounting the
sigh |
One more thing
Is it possible to pipe the console log directly to the container log? It's kind of counter-intuitive to have to enter the container to check the logs - this is normally available directly from the container logs (e.g. |
It is and actually in my last project: https://github.com/jusito/LinuxGSM-Docker |
Still trying to figure out what the cause could be, but I am making no progress. I will keep this issue open and added a label for the workaround; if others have the same issue, the workaround could also work for them. |
This is the manifest I am using: https://github.com/alexstaeding/homelab/blob/d0412c55d9212f60ce7aac4e7a6c15030110561e/kubernetes/ttt/deploy.yaml
The container seems to work according to logs but terminates before starting the server. These are the last log messages before the container restarts:
The text was updated successfully, but these errors were encountered: