itzg / itzg/docker-minecraft-bedrock-server
Bedrock version is constantly disconnected
- Dominant language
- Shell
- Stars
- 1.9k
- Forks
- 302
- Avg merge
- 2h 26m
- Merged PRs (30d)
- 2
Description
I have the same setup for my Java version excep that I changed everything to UDP. I get these logs
```
Downloading Bedrock server version 1.14.60.5 ...
2020/05/14 16:27:38 Setting difficulty to normal in server.properties
2020/05/14 16:27:38 Setting max-players to 16 in server.properties
2020/05/14 16:27:38 Setting default-player-permission-level to operator in server.properties
Starting Bedrock server...
NO LOG FILE! - setting up server logging...
[2020-05-14 16:27:38 INFO] Starting Server
[2020-05-14 16:27:38 INFO] Version 1.14.60.5
[2020-05-14 16:27:38 INFO] Session ID 66254136-498c-407e-979a-f5f55155efe3
[2020-05-14 16:27:38 INFO] Level Name: Bedrock level
[2020-05-14 16:27:38 INFO] Game mode: 0 Survival
[2020-05-14 16:27:38 INFO] Difficulty: 2 NORMAL
[2020-05-14 16:27:38 INFO] opening worlds/Bedrock level/db
[2020-05-14 16:27:53 INFO] IPv4 supported, port: 19132
[2020-05-14 16:27:53 INFO] IPv6 not supported
[2020-05-14 16:27:53 INFO] IPv4 supported, port: 44642
[2020-05-14 16:27:53 INFO] IPv6 not supported
[2020-05-14 16:27:54 INFO] Server started.
[2020-05-14 16:29:52 INFO] Player connected: mjwrazor, xuid: 2535409695687979
[2020-05-14 16:30:03 INFO] Player disconnected: mjwrazor, xuid: 2535409695687979
[2020-05-14 16:30:12 INFO] Player connected: mjwrazor, xuid: 2535409695687979
[2020-05-14 16:30:23 INFO] Player disconnected: mjwrazor, xuid: 2535409695687979
[2020-05-14 16:32:48 INFO] Player connected: mjwrazor, xuid: 2535409695687979
[2020-05-14 16:32:59 INFO] Player disconnected: mjwrazor, xuid: 2535409695687979
[2020-05-14 16:33:06 INFO] Player connected: mjwrazor, xuid: 2535409695687979
[2020-05-14 16:33:17 INFO] Player disconnected: mjwrazor, xuid: 2535409695687979
```
Where my character is instantly kicked out.
my kubernetes file is
```yaml
apiVersion: apps/v1
kind: StatefulSet
metadata:
labels:
instance: game-1
name: game-statefulset-1
spec:
serviceName: game-svc-1
selector:
matchLabels:
instance: game-1 # has to match .spec.template.metadata.labels
template:
metadata:
labels:
instance: game-1 # has to match .spec.selector.matchLabels
spec:
terminationGracePeriodSeconds: 30
containers:
- image: itzg/minecraft-bedrock-server:latest
name: game-server-1
imagePullPolicy: IfNotPresent
ports:
- containerPort: 19132
resources:
limits:
memory: 2Gi
cpu: 1800m
requests:
memory: 2Gi
cpu: 1600m
env:
- name: EULA
value: 'TRUE'
- name: VERSION
value: '1.14'
- name: DIFFICULTY
value: normal
- name: MAX_PLAYERS
value: '16'
- name: DEFAULT_PLAYER_PERMISSION_LEVEL
value: 'operator'
# SERVER CONFIG
- name: MEMORY
value: 2G
readinessProbe:
exec:
command:
- /usr/local/bin/mc-monitor
- status-bedrock
- --host
- 127.0.0.1
- --port
- "19132"
initialDelaySeconds: 120
periodSeconds: 60
failureThreshold: 10
livenessProbe:
exec:
command:
- /usr/local/bin/mc-monitor
- status-bedrock
- --host
- 127.0.0.1
- --port
- "19132"
initialDelaySeconds: 120
periodSeconds: 60
failureThreshold: 10
volumeMounts:
- name: game-server-storage-1
mountPath: /data
# Make sure and set Volumes in patch, dif requirements per provider
volumes:
- name: game-server-storage-1
persistentVolumeClaim:
claimName: game-server-pvc-1
```
The server has 2cpu and 4gb of ram. only 2.2gb are able to allocate on that node
Contributor guide
Research direction
Begin with the posted Kubernetes StatefulSet, especially the UDP port 19132 and the mc-monitor readiness and liveness commands, then compare those settings with the connection and disconnection logs. Reproduce the behavior and inspect container and probe output; done means a confirmed cause and a tested configuration or documented limitation.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- docker, kubernetes, shell
- Domain
- devops, infrastructure
- Issue type
- Bug
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Needs clarification
- Newbie friendliness
- 25/100