Yesterday, I cobbled together a Docker image. Which looks like this (or the dockerfile of the image):
FROM openjdk: 8u212-jre-alpine
RUN mkdir data
WORKDIR / data
VOLUME / data
EXPOSE 27777
CMD java -Xmx2048M -jar server.jar
As far as I know, I've got a volume, put in Server.jar, Eula.txt and server.properites, and now I want to start the Docker container:
Docker run -v / var / lib / docker / volumes / test / _data: / data -p 25565: 27777 --name NAME imagename
Then the container also starts, and outputs the normal startup process of an MC server: And then the error comes:
Loading libraries, please wait…
[10:05:44 INFO]: Starting minecraft server version 1.8
[10:05:44 INFO]: Loading properties
[10:05:44 INFO]: Default game type: SURVIVAL
[10:05:44 INFO]: Generating keypair
[10:05:44 INFO]: Starting Minecraft server on: 27777 [10:05:45 WARN]: FAILED TO BIND TO PORT! [10:05:45 WARN]: The exception was: java.lang.ArithmeticException: / by zero [10:05:45 WARN]: Perhaps a server is already running on that port? [10:05:45 INFO]: Stopping server
I realize that the error is usually issued when the port is occupied ect -> Jeoch I have already spit out sämmtlioche things: - I have changed several times Intenren docker port / host port, - in the server.properties the Changed port, - changed ip in server.properties (127.0.0.1/172.17.0.2/185.239.xxx.xx)
- when starting the contasiner:
docker run --net host -v […]
tries
But why is it? On gitub you can find similar docker-files that basically make the same thing as my image, and they do not work either. Is it due to a misconfiguration of my vServer? Network configuration?
Do I need a proxy or rirgedwas s.der firewall?
LG Thanks in advance.
ps: even the firewall (s) activation did not help…
Try to start the server, if your firewall is off.
Nope - executed iptables -L, and then the same error still occurs.
@ jerry230602 A firewall other than IPtables is Debian but not right?
Phew, I do not know that.
Okay thanks anyway - I guess it is then s.VServer or Ip configuratio 'n of zap or what I
Try it now on a local vm
There are quite a few firewalls on Debian to choose from. With a Debian out of the box but none of them should be installed.
I have now updated the vServer with ubuntu - and there ufw and iptables deachtiviert, and still comes the error hm
Did you enter the IP address at the server.properties?
Delete the ip in the server.properties out and leave the entry empty
Which of the addresses must be there? That from the host, or the 172.17.0.2 which will be output when i run ikm container 'ifconfig'?
Did I already do this? /
Or localhost?
* ne is nonsense
The 172.17.0.2 it should be.
Okay thanks i'll try it again