8

I wanted to change my Minecraft server's port number from the default, so I updated the server-port property to the port I wanted in the server.properties file.

Once I restarted the server, I could see that the port had changed.

Now I want the client to use the new port number, but there is no field to specify a non-default port number. So for the server address I am entering xxx.xxx.xxx.xxx:yyyy, where yyyy is the new port number, but the client does not connect.

How can I tell the Minecraft client to use the port number I want?

5
  • Erm.. Which server are you trying to specify the port of? The LAN server, a regular server or a Bukkit/Spigot/whatever one? | Altogether, it may seem like your server may have not yet been refreshed to the new port (restart the server), or that you haven't port-forwarded the new port yet... Or something may be running on that port. | Do you think you can refine your question to be a little more specific? – aytimothy Jan 11 '15 at 5:59
  • That's the only way to use that port. IP connections are setup in a way that when connecting, you use the following syntax. [IP]:[Port] Why can't you use 25565 anyway? – user92092 Jan 11 '15 at 6:20
  • 1
    i want to change the port number because of security. This server is just for a small group of users and i don't other's to find it and attempt to log in. – ChiliYago Jan 11 '15 at 12:24
  • You could perhaps use a whitelist. Also check if anything else is running on that port, that it's forwarded. Or, if you're hosted that your host allows port changes. – Thomas Carroll Jan 11 '15 at 17:11
  • i activated white list but some player still can log in somehow – ChiliYago Jan 11 '15 at 18:54
4

This is assuming that you are attempting to access the server from outside your LAN (e.g. the IP isn't 192.168.x.x).

1) Port Forwarding - If you haven't port forwarded, do so. Without port forwarding, you'll only be able to access it from within your LAN. To do so, go into your router's admin interface and forward the port that you're going to use to the same port - and specify it to be forwarded to the server's internal IP, assuming it's on the same network. If this doesn't work, but you can ping the machine from an external network (e.g. ping xxx.xxx.xxx.xxx from the cmd on a windows machine), there may be a problem with the server's firewall.

2) Using ports that are reserved by other services - Usually on *NIX systems (and many more!) if you try and run the server under a certain port, it may not let you unless you have the relevant access rights. The first 1024 ports, in particular, are reserved for system stuff. If you're using any port under that, there's your problem. Change it, and it may work.

3) Firewall Problems - Make sure you've port forwarded first. Then, depending on what OS the server is running on, you'll need to allow the communication from someone not on your network for the specific port that you're going to be using for the server. By default, not all ports are open on certain machines and are blocked by a firewall for security reasons. There are plenty of guides for whatever OS you're using, just find one of those. If you're running in some Linux environment, it's probably "iptables" that's blocking those ports.

0

You should be able to access the port of your minecraft server the same place you port forwarded. Just change 25565 - 25565 to be what you would like it to be.

0

Sounds like you need to port forward on your router. Go into your router's admin, port forwarding, and forward port 25566 (let's say it's 25566) to 25566 on the LAN computer on which your server is running. So you would specify something like 192.168.1.2 for that computer in the port forward config. You're basically telling the router which computer on your LAN to send these packets to for incoming traffic specifying that port.

If you have two routers in succession, you must port forward on both. From the first router to the second, then from the second router to the computer in question.

0

you tell your friends to enteer your servers address as aaa.bbb.ccc.ddd:xxxxx where abcd is your ip, and xxxxx is your new port# they have to enter a colon after the ip but before the port

New contributor
Phil Fischer is a new contributor to this site. Take care in asking for clarification, commenting, and answering. Check out our Code of Conduct.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.