Minecraft Wiki
Advertisement
Information icon
This feature is exclusive to Java Edition. 

Template:NotClassicServer

This user page is about the server requirements of the current Minecraft PC version, . For the game requirements, see Hardware requirements. For performance comparisons, see Hardware performance.

What is Minecraft Server

Add introduction and description here.

Server requirements

  • Requirements may change depending on specific system configurations, mods, plugins, etc. These requirements are more of 'minimum guidelines' than strict requirements.
CPU RAM HDD Uplink Downlink
Dual Core Processor with a Single Thread Passmark Score of 1500 or higher. 1GB / Player 3GB / Player 5 mbit / Player 3 mbit / Player

† Minecrafter Server does not benefit from more than 2 cores, so a higher single thread score is better. A processor with more than 2 cores can still be useful however, because other tasks unrelated to running minecraft can run on the other cores.

Minecraft Server will run on just about any hardware that will run Java (specifically Java JRE/JDK 8). It is recommended to install Minecraft Server on a headless operating system (such as Ubuntu Server) to reduce unnecessary overhead. However, this is not a requirement by any means and if your server will only be used by a handful of users (such as a small LAN party), Minecraft Server should be able to run on just about any hardware and any OS that can run JRE/JDK 8.

Overview

Note 
Running server software on your computer without a clear understanding of what you are doing may make your system vulnerable for attacks from outside.

This tutorial will takes you through the steps of setting up your own Minecraft Server. Before you being, there are a few things you should keep in mind:

  • Setting up a Minecraft Server is not particular complicated, but does require some basic technical knowledge.
  • A Minecraft Server does not need to be a high-end machine, but the better your hardware the more players you can have online at the same time and the better your overall experience.
  • Hosting and playing on the same machine is also possible, if your computer is powerful enough.
  • Having many players in a wireless network is not recommended. Use a wired network whenever possible.
  • If you want to run a server but would rather just pay someone, take a look at Minecraft server hosting area.


If you plan on opening your server up to the internet, you are strongly encouraged to have a good understanding of network security, including but not limited to DNS, DHCP, IP Addresses, Port Forwarding, and Firewalls. If this terminology is confusing to you, you should not set up a Minecraft Server that is accessable outside your local network.

If you only want to set up a Minecraft Server that will be accessable inside your network (i.e. only people connected to your home network can access the server), then you can disregard most of the network security warnings.

Installation

Linux (Recommended)

Note 
These instructions are out of date


Windows

Note 
These instructions may be out of date
  1. Install (or update to) the most recent Java Runtime Environment (JRE)
  2. Download Minecraft Server and place it inside an empty folder on your desktop
  3. Right click the .jar file and 'Run as Administrator'. It will generate some files and folders, then exit
  4. 'Accept' the EULA by opening the eula.txt file inside the application folder and change eula=false to eula=true
  5. Test the installation by running java -jar file.jar from a command prompt. You will need to replace file.jar with the correct version, for example minecraft_server.1.9.4.jar

(Optional) Creating a .bat file

See configuration section below for more information.

To start the configured Minecraft server, without having to enter all commands every time, you can create a .bat file in the server folder. You can include the pause command to tell the window to stay open after the /stop command is issued. Useful if you want to read what happened as it shut down.

Here is an example of a bat file:

   java -Xms1024M -Xmx2048M -jar file.jar nogui
   pause

Double click the file to start your server. You may get a "Class_Not_Found" and ServerGuiConcole error, just ignore these errors and you should see your "Server Thread/INFO" dialog start the server.


Mac

Note 
These instructions may be out of date


A three step in-depth video tutorial of the process can be seen here. Keep in mind that the server won't run correctly on OS X 10.4 and may crash your machine.

  1. Java Runtime Environment should already be pre-installed on OS X, but make sure you have installed all necessary updates before continuing
  2. Download Minecraft Server and place it inside an empty folder on your desktop and rename it to server.jar
  3. Open TextEdit, set the format to plain text (Format > Make Plain Text), copy and paste in the following:
   #!/bin/bash
   cd "$(dirname "$0")"
   exec java -Xms1G -Xmx1G -jar server.jar nogui
  1. Save the text file as start.command and put it in the same folder as server.jar
  2. Grant execute permissions to start.command by typing chmod a+x , with a space after it then drag and drop the start.command file into the terminal window and then press enter.
  3. Double-click the start.command file to start the server. You will see several errors the first time you run the command, this is normal.

Once setup is complete, see below to configure your server.

Using Time Capsule

Some homes use AirPort Time Capsule as a wireless router instead of other brands. This section will teach you how to set one up without messing up your file server.

NOTE: Make sure you have your admin username and password.

  1. Open System Preferences > Network.
  2. Click the Advanced button and go under TCP/IP.
  3. Where it says Configure IPv4, change that option to Using DHCP with manual address.
  4. Change the IP address to 10.0.1.x, where x is a number between the last number of the two numbers under DHCP range (i.e. 10.0.1.2 to 10.0.1.254 would be anywhere between 2 and 254).
  5. Now go to the Sharing section and make sure that Internet Sharing is on.
  6. Now, open up AirPort Utility and edit your Time Capsule settings.
  7. Go under Network and make sure the option Router Mode is set to DHCP and NAT. Now, click the + button under the Port Settings.
  8. Type in the following:
    • Description: Minecraft Server (or whatever you want to call it)
    • Private IP Address: The address you chose for the 4th step.
  9. Change everything with the word port in it to 25565.
  10. Now hit Save and update the Time Capsule.

That's it! You're now ready to configure your server.



Configuration

If you prefer not to use the server's Graphical User Interface (GUI) to enter administration commands, simply add the option nogui to the end of the command:

java -jar minecraft_server.jar nogui

Some people have reported that this requires (significantly) less memory and CPU resources.

You can also replace the java command with javaw. Javaw.exe is identical to Java.exe but there is no associated console window. This may be preferable when using a .bat file. (See the next section.) Note however that Javaw also doesn't show any error messages in the command window if anything is wrong.

Using the Xms and Xmx parameters, the initial and maximum memory size for Java can be specified. By default, your server runs with about 100 MB of RAM, which is very little. Most people will change their server to run with more, for example:

  • java -Xms512M -Xmx1G ...
  • java -Xms1024M -Xmx1024M ...
  • java -Xms1G -Xmx2G ...

Add in -d64 if your server is on a 64-bit Solaris system using 64-bit Java.

Add -o true to tell the server to run in online mode so only authenticated users can join.


Access server from outside network

Running the Server

.


.


.


.


.




Linux instructions

This tutorial for how to set up a Minecraft server on Linux was designed for people who don't have a lot of experience with Linux. There is a outdated but more advanced tutorial in the forums.

This tutorial was tested on Ubuntu 9.10 32-bit but should work with the 32-bit and 64-bit descendants of Debian. (Note that a 64-bit version of Linux will probably perform better on a 64-bit CPU, and that a 32-bit version will only use the first 4 GiB of RAM if more than that is installed.)

Downloading

Download the latest server application software from the download page.

Installing Java

If you get java: command not found (which may be followed by more text) or if you do have another Java version than 1.6 then you need to install or update java. The official Oracle Java is recommended. A few individuals have experienced issues with OpenJDK. Others report that running on OpenJDK is completely fine.

Debian

Ensure that the non-free repository is being scanned by apt. You do this by adding non-free to your /etc/apt/sources.list file. e.g.:

deb http://ftp.uk.debian.org/debian/ squeeze main contrib non-free

Update your sources list (as root):

apt-get update

Then to install Java, simply type this in terminal and press enter (as root):

apt-get install sun-java6-jre

Ubuntu

Unfortunately, some licensing issues have prevented Canonical from allowing repositories to have Sun Java, so you must either download it directly from Oracle, package it, and install it or you could use the PPA provided by webupd8 by following the instructions below.

This guide has been tested on Ubuntu Server 12.10.

Note: You might need to install the package "software-properties-common" by running sudo apt-get install software-properties-common and/or "python-software-properties" by running sudo apt-get install python-software-properties to use the apt-add-repository command.

Run the following commands in this order to add the PPA, update the source list and then install java:
sudo apt-add-repository ppa:webupd8team/java
sudo apt-get update
sudo apt-get install oracle-java7-installer

Then run this to check what version you have installed:
java -version

The output should be similar to:
java version "1.7.0_10"
Java(TM) SE Runtime Environment (build 1.7.0_10-b18)
Java HotSpot(TM) 64-Bit Server VM (build 23.6-b04, mixed mode)

For more information or troubleshooting see this link at webupd8s site

openSUSE

On older versions, you can simply type zypper in java-1_6_0-sun into a terminal.

On newer versions, there is a tutorial here describing how to install Java.

Arch Linux

Open a terminal and run pacman -S jre7-openjdk as root.

Arch Linux ARMv7

On ARMv7 it could better to use java from oracle http://www.oracle.com/technetwork/java/javase/downloads/jdk7-arm-downloads-2187468.html Accept license agreement and download jdk-7u60-linux-arm-vfp-hflt.tar.gz Extract file in /usr/lib/jvm/

and change java default with

archlinux-java set jdk1.7.0_60

Then

java -version

should give something like that:

java version "1.7.0_60" Java(TM) SE Runtime Environment (build 1.7.0_60-b19) Java HotSpot(TM) Client VM (build 24.60-b09, mixed mode)

(tested on Raspberry Pi 2)

Gentoo

Use: emerge virtual/jre

Other distros

Alternatively, you can visit Java's website directly to download the Java package for Linux. Most distros work with this (either 32 or 64-bit). Instructions for the installation of those different packages are given on the site.

If during installation, it asks for a password, enter your password. If you get asked "Is this OK [Y/N]" Enter Y and press enter if required. Java should now be installed.

Start the Minecraft server

Open the terminal again Applications > Accessories > Terminal Enter the following commands, substituting 'minecraft_server' with the name of the folder you extracted the server to:

cd minecraft_server
java -Xms1G -Xmx1G -jar minecraft_server.jar nogui

Less than 1GB free RAM

If you have less than 1024MB RAM, the above line may cause problems with swapping and out of memory conditions, which makes the game hard to play.

cd minecraft_server
java -Xms1G -Xmx1G -jar minecraft_server.jar nogui
free -m
It may look like this:

File:Ram left.PNG

You are interested in the last number in the third line, 2163 in this case. Subtract some RAM as safety. On this computer, the server may use up to 1536 MB RAM. Now, replace the 1024 in the above example with the calculated number:

java -Xms1536M -Xmx1536M -jar minecraft_server.jar nogui

Voila, it should run smoothly now

Tip: If you want to spare more memory, you may set the -Xms parameter even lower, say:

java -Xms32M -Xmx512M -jar minecraft_server.jar nogui

The parameter controls how much memory is reserved on startup Your server will start with 32MB RAM and whenever it needs more memory it will allocate some until it reaches the maximum of 512 MB. However, this will result in a little slowdown whenever the allocation is done.

Startup and maintenance script

Alternatively you can manage/automate the startup and shutdown of the Minecraft server using a script such as the ones listed below:

A simple installer script (also installs Java)

https://github.com/silvertriclops/MCSLI

Note: this is a very early project, designed with offline installation in mind, and will be updated periodically to make it more user friendly.

FreeBSD instructions

This part was tested with FreeBSD 10.0 amd64 and 'jre-7u65-linux-i586.tar.gz'

Installing Java

Due to performance and crash issue with OpenJDK and Minecraft server, we will install Sun/Oracle JRE made for linux.
Before installing this JRE, you have to install the linux binary compatibility on FreeBSD, you can follow this documentation.
Jave requires some information about the proc. You have to mount linprocfs, type:

 kldload linprocfs
 mount -t linprocfs linprocfs /compat/linux/proc

and add this line to /etc/fstab:

 linprocfs   /compat/linux/proc   linprocfs   rw   0  0


The Sun/Oracle JRE has a dependency marked as forbidden and the installation will fail. Go to /usr/ports/textproc/linux-f10-expat2.0.1/ and in the Makefile remove the line which starts with FORBIDDEN=.
Next you have to manually get the linux tarball due to licence issue (like `jre-7u65-linux-i586.tar.gz') from java official web site and copy the file to /usr/ports/distfiles. Then to install the JRE, go to /usr/ports/java/linux-sun-jre17/ and run:

 make install distclean

Note: The previous version of this part, tested on FreeBSD 9.2 amd64, was explained like this: You may have to set JRE_UPDATE_VERSION variable in your Makefile to the actual number (e.g. 45 like in this example) and run 'make install NO_CHECKSUM=1'.

Try running java -version. You may end up with a message that it can not find libjli.so. One way to fix it is to add your java paths to the search explicitly. Make a symlink:

 ln -s /usr/local/linux-sun-jre1.7.0/lib/i386 /compat/linux/usr/lib/java

And in /compat/linux/etc/ld.so.conf.d/java.conf add:

 /usr/lib/java
 /usr/lib/java/jli

Run /compat/linux/sbin/ldconfig.
Now java -version should work.

Launching Minecraft Server

Create a folder and copy the minecraft server jar in it.
In the actual version you will get this exception syscall epoll_create not implemented if you run the server in the usual way, so we add this line to the command to fix that -Djava.nio.channels.spi.SelectorProvider=sun.nio.ch.PollSelectorProvider.
The command to launch is like
java -Xmx1024M -Xms1024M -Djava.nio.channels.spi.SelectorProvider=sun.nio.ch.PollSelectorProvider -jar minecraft_server.1.7.10.jar nogui

Plan 9

Use: alien-convert <path-to-your-jre->.deb chmod ~/~ rwx for <current user> Then snarf java -jar <path to your .jar> xvmf in acme

Port forwarding

See also: Port forwarding

Port forwarding is used when you have a router and you wish to let users connect to your server through it. If you wish to host your server for local reasons, it is not required that you do so. Keep in mind that port forwarding might cause security risks.

When port forwarding, it varies on how your router will ask you for the information. If you don't understand on how your router wants you to input the information, try visiting PortForward.com for a tutorial. If you still need help, please visit the Minecraft Forums and create a thread asking for help (You need to register).


Once you have managed to locate your router's admin page, and find the Port Forwarding page; hit add new service (may not work) (if you use Belkin, this can be very difficult to perform) or custom service. When you get a page asking to setup the new rule, it should prompt you on what you want to call it. You may name it as you wish but for simplicity, name it "minecraft". Then you want to look for "type". Select TCP. For the ports (internal and external), enter 25565. If it asks for anything else other than output IP (or internal IP, server IP), leave it alone and continue.

To find your computer's IP address, use the following steps:

WindowsWindows 10 Windows

Press ⊞ Win + R; this should being up the "Run" dialog box. Type cmd and hit ↵ Enter. This should open a command window with a black background. From there, type ipconfig and press ↵ Enter. You should be given a list of text. Scroll up to "Wireless LAN" (if using wireless) or "Ethernet" (if using a wired connection), and look at "IPv4 address". To the right of this should be a string of numbers (of the form xxx.xxx.xxx.xxx). Copy this down by right clicking the window and selecting "Mark", then highlight the area and hit Enter. Don't copy any parenthesis or letters.

macOS Mac

Ip-address-mac-610x206

The IP location on OS X

Locate your way to your desktop. Pull up the apple menu under the logo and scroll down to System Preferences; then select "Network" your IP should be on the lower right as "IP address (xxx.xxx.xxx.xxx)". Once you have your IP, copy it down.

Linux Linux

Either you use the network diagnose center (depending on distribution), or the terminal with ifconfig. The output should return all your interfaces. Search for inet addr:xxx.xxx.xxx.xxx, copy the xxx.xxx.xxx.xxx numbers down.

Once you have this IP, enter it in the "Output IP / Server IP" or whatever way it asks for where the service points to.

Once you have completed it, find where it says to save/continue/apply. And you have successfully port forwarded. When you run your Minecraft server, you have to leave the Server IP field empty in the server properties.

For people to connect to your server, they must use your external IP, which you can find at websites such as IP Chicken. If you don't want to use such IPs, use DynDNS services such as ...

Configure and connect

Now it is time to configure and connect.

Setting up a VPN

Paper
The contents of this section are not supported by Mojang Studios or the Minecraft Wiki.

An alternate way to set up a server between you and your friends is to set up a VPN (virtual private network). This method may be deemed unrecommended, and an inconvenience for many users due to the fact that all users whom wish to connect to the server must download external software in order to join or create server. An alternative to this method is to port forward. A free software utility that can be used to set up a VPN ais Hamachi by LogMeIn. OpenVPN is another (free, open source) alternative that supports most OSes, but is a bit more difficult to configure. The free version of Hamachi allows up to 5 connections (i.e. players).

Setting up Hamachi

  1. Install Hamachi on each computer that wishes to participate in the server, including the host.
    Windows / Mac
    Linux (32-bit and 64-bit .deb and .rpm packages are available, you can install it on Gentoo by emerging "net-misc/logmein-hamachi")
  2. The host server signs up for admin via the Logmein website.
  3. On the host machine, a new Hamachi network is created.
  4. The host installs and configures the Minecraft server software:
    The server IP field in server.properties is left blank (as default).
  5. The host passes the newly created Hamachi network credentials to each of the players.
  6. The players connect to the host's Hamachi network.
  7. Now that all the machines are connected within the same Hamachi network, the host gives their machine's Hamachi IPv4 address to the players.
  8. Each player connects using this IP as per the usual Minecraft multiplayer screen.

Configuring the Minecraft server

  1. Configure the server by editing the server.properties file, the format for which is explained here. Be certain to edit the file with a text editor that does not add formatting (e.g., for italics), such as Windows Notepad. Additional configuration may not be necessary as many servers run fine from the default values.
  2. To become or add an operator (op), type /op <targets> into the server console or gui. This adds the specified user's username and UUID to the ops.json file. Operator status will not be changed if you change your username due to the use of UUID.
    • Administrators and operators may execute commands. In other words, operator (op) privileges allow you to control certain aspects of the game (e.g., teleporting players).
    • ops.json contents:
[{"uuid": "user-UUID-value","name": "your-name","level": 4}, ...]
  1. If your server.properties is configured to enable whitelist, you can add a user to the whitelist.json by typing /whitelist add <player> into the server console or gui. Due to the transition to the UUID system, it is not recommended to directly edit whitelist.json.

Connect to the Minecraft server

  • If you are playing on the same machine on which the server is running, select the "Multiplayer" option in the game client, click direct connect, and then type in "localhost" instead of an IP address.
    • Both hosting and playing on the same machine is not a recommended practice unless you have a powerful computer (e.g. more than 6 gigabytes of ram (5 for the server, 1 for the client, and remainder for system).
  • Users within your local network (i.e. that are accessing the same router) can connect using your internal IP address - port forwarding is not required for such local connections. The internal IP address of a specific network adapter can be found by typing "ipconfig" into command prompt and looking for the ipv4 address.
  • People connecting from the Internet (i.e., outside of your local network) must connect using your external IP address. You must port forward for someone outside your network to connect to the server.

IP address notes

  • Unless you set a static IP for the computer that is hosting the game, the internal IP address can change. This affects port forwarding rules, and can make them invalid. Each modem or router has a different way of setting a static IP address. You should refer to the manual for your device(s) or online documentation for further instruction.
  • If you are having players connect to your external IP, your external IP can change if you do not have a static IP from your internet service provider. Use a tool such as MyWANIP to periodically check on the external IP address. You may also search "my ip address" on Google and it will show your IP address. Alternatively, you can look into a DNS service that will allow you to have a name, rather than an IP address, that will remain the same. The name will point to your external IP address, regardless of whether or not it changes (the DNS is updated when changes occur).
  • For troubleshooting purposes you can try running Minecraft on the server machine and connect locally. You can connect through either localhost, your home network IP (192.168.x.x) or your public (Internet) IP.
  • If for some reason you have trouble with connecting publicly over your IPv4, try connecting over IPv6. This should only be done for testing whether your server is online, external players should still use IPv4.

Firewalling, NATs and external IP addresses

  • You must open a TCP port (default is 25565) on the firewall.
    • If the server in question is not reachable via a globally routable IP address, you will need to add appropriate address and/or port number translation rules to the gateway — usually your router has the global IP address.
  • For help with address translation, opening the firewall and routing (these three make up what people call port mapping/forwarding), portforward.com is a good source. Select your router from that list, skip the ad that comes after selecting the device, and you will see instructions for setting up port forwarding. Alternatively, you can read the documentation supplied with your router, modem, or other ISP related hardware.
  • Verify the port is open, and note your external IP by using a port checker tool, such as You Get Signal. The default port you should test is 25565, unless you specified something else. Have the Minecraft server running when you test the port.
  • You can obtain your external IP address from YouGetSignal.

Local network dedicated servers

This only applies to Classic (v0.30) servers.

A common problem for server administrators is the inability to connect to your own server via another machine on your local network. A typical scenario for this is that you have a Classic server running on a dedicated machine, and you have your own machine which you play on. They're both connected to the same router/switch, and have internal IP's with the octets '192.168.x.x'. Normally, connecting via the URL generated for your server will result in an error message claiming that the server is offline.

To correct this, you must add a function to the end of your URL, bookmarks, or whatever else you connect by. The function is: ?override=true
Example: http://www.minecraft.net/classic/play/4c3bebb1a01816acbe31c5ece1570da5?override=true

Previously, (before the 1.8 beta and website update) this was &override=true. This caused much confusion since the change was not announced by Mojang, and wasn't announced on the website applet pages either. Before the update, connecting to your own URL via the website resulted in red text under the applet window saying "If you can't connect, try this link instead." The link returned the same thing, with the &override=true affixed to the end.

Note: This situation does not effect Beta servers, and you should be able to connect via an internal or external IP.

FAQ (frequently asked questions)

Q: I have a problem which is not answered in here! What should I do to?

A: Go to the Minecraft Forums and post your problem there. To help you, they need the following information:

  • Operating system
  • Version of Java
  • One machine or multiple computers
  • Exact description of the problem
  • Steps you have taken to solve the problem
  • Any errors you encountered
  • Screenshots of the problem (if possible)
  • Anything else that might help us to solve your problem - there almost never is too much information (passwords would be too much information!)

And please, if we were able to help you, post where the problem was exactly and what the fix was for that. Other people will appreciate that (and we will be able to get a grip on the common problems)!


Q: On a Windows computer, when I double click the batch file it opens a command prompt window, but quickly disappears and the server does not start.

A: Right-click your .bat program and hit edit; add a new line and type pause save and run the file. If it says invalid path, it is probably due to an incorrect path for javaw.exe or your server software. You may just need to change /jre7/ to /jre6/ . Or search your system for javaw.exe and adjust the path accordingly. (It's probably under c:\program files or c:\program files (x86).) Also, you must have the offline version of Java installed—not just the Java plug-in for your browser.

You can also try replacing the contents of the .bat file with: START "minecraft" "C:\Program Files (x86)\Java\jre7\bin\javaw.exe" -Xms1024m -Xmx1024m -jar "Minecraft_Server.jar" amending name values/locations as required


Q: Whenever I try to get the server up, it says "Failed to bind to port!".

A: The most common reason this happens is because you put an IP address in the server-ip field in your server.properties file. If the IP you specify isn't the same as any of your network interfaces, (your wireless or wired IPv4 from ipconfig/ifconfig/ip a) Minecraft will throw the port binding failure message. By leaving it blank, you let it bind to all interfaces. You will then be able to connect using localhost and people on your wired/wireless network (in the same subnet) can connect using the computers/server's (private) IP address.

Alternatively, the error can mean that you have tried to use a port that is already in use or that you do not have permission to use (ports < 1024 are privileged and require root/Administrator access to bind to). You can try a different port by changing it in your server.properties file in this line: server-port=25565.

Note: You should avoid using the following ports for your server as some ISPs may block these ports for security reasons and you shouldn't be running the Minecraft server as root (in the case of a Linux type OS and ports < 1024):

  • 21 (Used by most FTP Servers)
  • 22 (Used by Secure Shell daemon)
  • 25 (Used by Mail Servers for SMTP)
  • 53 (Used by DNS Servers)
  • 80 (Used by most Web Servers)
  • 110 (Used by most Mail Servers for POP3)
  • 115 (Used by Simple File Transfer Protocol)
  • 143 (Used by Mail Servers for IMAP)
  • 443 (SSL port for Web Servers)
  • 3306 (Used by most MySQL Servers)

Generally avoid any port below number 1024, since those ports are generally referred as well-known ports and are registered with the IANA for important services.


Q: I tried to run the server with Solaris/OpenSolaris and got the following error:

java.io.InterruptedIOException: Operation interrupted 
at java.net.SocketInputStream.socketRead0(Native Method) 
at java.net.SocketInputStream.read(SocketInputStream.java:129) 
at java.net.SocketInputStream.read(SocketInputStream.java:182) 
at java.io.FilterInputStream.read(FilterInputStream.java:66) 
at gq.a(SourceFile:131) 
at ji.g(SourceFile:197) 
at ji.c(SourceFile:17) 
at oq.run(SourceFile:84) 
2011-05-31 16:57:26 [INFO] /:44673 lost connection

A: For whatever reason, out of all of the operating systems, only Solaris throws that exception when a thread interrupts a connection. A workaround is to change the default behavior on the command line:

java -Xmx1G -Xms32M -XX:-UseVMInterruptibleIO -XX:+UseConcMarkSweepGC \
 -XX:+CMSIncrementalPacing -XX:ParallelGCThreads=$CPU_COUNT -XX:+AggressiveOpts\
 -jar minecraft.jar nogui

This instructs Java to use an interruptible IO stack instead of the default IO that is sensitive to interrupted threads.


Q: When I try to connect to my server this is what it says:

               Connection lost 
 
The server responded with an invalid server key

A: This error is usually caused when the server sends an unrecognized function to the client, which may be caused by using unrecognized server software, unbalanced client / server versions or modifications to the client.


Q: I cannot break/place any blocks!?

A: This is most usually caused by interacting with blocks in a protected area. If you are trying to interact near spawn, most likely it has been protected, by the minecraft server software; either build away from it or get operator status.


Q: My server runs fine but I cannot connect to it!

A: This could be caused by a series of issues. Please post a thread using the template provided above.


Q: How do you give a .jar server more ram?

A: Change the numbers in the server launch command "-Xmx1G -Xms1G". The -Xms part specifies how much memory the server starts with, and the -Xmx part is the maximum amount of memory the server can use. -Xmx1G -Xms2G = 1GB -Xmx2G -Xms1G = 2GB And so on.


Q: Why is the server CPU constantly at full load?

A: Some users are experiences full CPU load on the server. This may be caused by the GUI (graphic user interface) window. Run the server with the nogui option to disable this window.


Q: Help! How do you find out your server's IP address?

A: Read #Connect to the Minecraft server


Q: I port forwarded and allowed java.exe in my firewall and it's still not working!

A: Your modem might be acting as a router as well. If you switch ISP's or upgrade your connection to the Internet, you may get issued a modem/router combination (which might explain why it worked in the past). You can verify this by looking for the WAN IP of your router. If it's a private IP, you'll need to log into the modem/router your ISP issued to you, and configure port forwarding to the WAN IP of your router.

Video/Alternative Tutorials

Here are some other tutorials on how to set up a Minecraft server:

















This user page is about the multiplayer software in Java Edition. For the multiplayer experience, see Multiplayer. For the official Mojang paid-for servers, see Realms. For the official featured servers in Bedrock Edition, see featured servers. For unofficial Java Edition server software, see custom servers.
Information icon
This feature is exclusive to Java Edition. 

Minecraft servers allow players to play online or via a local area network with other people. Official server software is only available on Java Edition. For Bedrock Edition, only unofficial server software is available.

Types of servers

Multiple archetypes of Minecraft servers exist, distinguished by the unique gameplay features, rules, and societal structures which they implement. No two servers are the same, and frequently the line between archetypes is blurred or indistinguishable. Many special types of servers rely on the use of map editors or the creative game mode to build custom maps and the CraftBukkit server software to provide additional features. Some of these servers are more PVP orientated, some involve aspects of Survival, Creative and Adventure mode, some have a built in economy, and some of them contain built in mini games.

Hosting a server

There are many tools provided for players to be able to manage and host a server. Note that servers have requirements in order to run efficiently and smoothly.

  • The default multiplayer software is free of charge and is available by Mojang for Windows, Mac OS X and Unix-like systems (Linux, BSD...). See the Minecraft multiplayer server tutorial and Mojang's Minecraft multiplayer server download page for help.
  • Opening a world to LAN provides a server that is only accessible to other people in your local network unless you setup port forwarding on your router. See the setting up a LAN world tutorial for more information.
  • External server clients such as Bukkit, Spigot, and Sponge provide players a way to add plugins to a server. These are generally used for larger servers that run plugins to ensure griefer protection, non-vanilla commands (e.g. /sethome), custom minigames, etc.
  • Rented servers are servers which are hosted externally by another company. These hosted servers are not provided free of charge - the player must rent them on a regular basis.
  • Realms are Mojang's official hosting service which allows a limited amount of players onto a server. Note that the Java Realms are still separate from Realms for other versions of Minecraft.

See Tutorials#Servers for tutorials on how to use these programs.

Managing and maintaining a server

Servers are generally managed by administrators and operators. The administrator generally takes responsibility of the server. It may be that the server is running from their machine, or that they simply have jurisdiction over a server. Operators generally assist the administrators to moderate a server, and to prevent unruly players and griefers. Both operators and administrators have access to various commands in order to ensure the smooth running of the server. On a default server, players are assigned as operator or administrator by using the /op <playername> command, or by editing the ops json file (ops.json) in the server directory, then restarting the server.

Local servers do not strictly require access to minecraft.net, and so can be played on an isolated local network with no internet connection. They use minecraft.net as a repository of player skins and also a database containing a list of accounts, preventing hackers and griefers from using false names while on such a server. This and other settings are modified by editing the server.properties text file.

The server saves the level in the "world" folder every 30 seconds if chunks have been modified, by default.

Kick messages

Kick messages are messages that are displayed when an operator kicks the player, or the player has issues connecting to the server.

  • End Of Stream (Client message) – The server has stopped sending data to the client
  • Internal Server Error:java.net.Minecraft – The server is sending unknown information to the client, usually from a server mod
  • Internal exception: java.io.IOException: Received string length longer than maximum allowed ([Number]>256) – A chat message that the client sent to the server exceeded the maximum character limit.
  • Internal Server Error – The server generated an exception when handling the client's request.
  • Disconnected - The player disconnected by using the Disconnect button in the Main Menu
  • Illegal characters in chat – The client was denied sending certain characters, such as the § symbol
  • disconnect.spam - The client is sending chat messages too quickly
  • Read timed out – The server can't find the player's connection
  • Bad login – The client is running in offline mode and can't connect to an authenticated server
  • Outdated client (Please use {version}) – The server is running a more recent version of Minecraft then the client is
  • Outdated server (I'm still on {version}) – The client is running a more recent version of Minecraft than the server is
  • You are banned from this server (May be followed by Reason: {reason} and/or Your ban will be removed on {date}) – Self-explanatory, the client is banned and will remain banned until pardoned by an admin
  • You have been IP banned. - The client's IP has been banned.
  • Kicked by an operator. - The client has been disconnected using the /kick command.[note 1]
  • Flying is not enabled on this server - The client tried to fly for longer than 5 seconds in Survival or Adventure mode
  • Attempting to attack an invalid entity - ??, Happens when a client tries to hit themselves (using mods)
  • Illegal stance - ??, Happens when a client is extremely high or low
  • Illegal position - The client is beyond X/Z: ±30,000,000 (±32,000,000 in 1.6.4 and lower.)
  • You have died. Game over, man, it's game over! - The client is dead but tried to join in Hardcore mode.
  • You have been idle for too long! - The client was idle for a longer time than allowed.
  • Out of memory! - This only happens when your memory is 100%, or if one traveled past X/Z: ±34,359,738,368 in Beta 1.7.3 or lower (see Far Lands). (It shows up on the F3 Debug screen)
  1. Please note that the /kick command can disconnect clients with custom message.

See also

External links




References


Advertisement