Jump to content

I’m trying to do research on how to make a minecraft server with some old parts that i have but it seems like every youtube video i watch tells me different but similar things, can anyone give me a video you recommend or any tips?

Link to comment
https://linustechtips.com/topic/1577037-minecraft-server/
Share on other sites

Link to post
Share on other sites

It is easy. If you want to host it yourself, then on the server PC, download this file from - https://www.minecraft.net/en-us/download/server. You must have Java installed. Install the latest JDK version Java website (JDK 22 right now). After that as said on the Minecraft website, run the jar file with the given commands. But, I would highly recommend increasing the -Xmx and -Xms numbers. There are the arguments given to the Minecraft server in how much memory it is allocated, and they haven't bothered to update the requirements with the newer versions, but I think the default 1 GB that they have given works, but for good experience, at least 2 - 4GB is recommended. Just change the 1024M to like 4096M (4GB) or I think even just 4G works. And I also recommend to remove the "nogui" part. The GUI is helpful in seeing the server performance like the memory usage and the tick speed.

 

Once you have the server running, to connect to that server, it depends on how your computers are connected. If you were running the Minecraft server on the same PC where you have your client open (which you are not), you would just type localhost in the IP address box in multiplayer.

 

If you have direct connection between the server and the client through Ethernet, then you configure both the Ethernet ports to run under the same local network. This is a bit involved, bit if you are on Windows, then go to Control panel -> Network and Sharing Center -> Change adapter options (top left) -> your Ethernet -> Properties -> TCP/IPv4-> Properties -> check the box enable setting a custom IP address, and then an add an IP address like 192.168.0.1, a Subnet mask of 255.255.255.0, and a default gateway like 192.168.0.2. On the second PC, do the same but set the IP address to 192.168.0.2, same Subnet mask, and the default gateway of 192.168.0.1. Notice the criss-cross of the IP address and the default gateway. Now on your client, just connect to the local IP address of your server. Note that if you want to get correct internet access on your ethernet ports, then you need to remove the changes (click to get automatic IP address) to fall back to DHCP.

 

If your server and the client are both connected to the same router, then I believe that you can just connect by entering the IP address of the client. You can check your IP address in the Ethernet section of the performance tab in task manager.

 

And if you want to host you server over the internet, then I have no idea about it, but I know that it is possible easily. If you really just don't want the hassle, you can use something like Aternos for free, but they only limit their render distance to 6 and with quite a bit latency.

Microsoft owns my soul.

 

Also, Dell is evil, but HP kinda nice.

Link to comment
https://linustechtips.com/topic/1577037-minecraft-server/#findComment-16470177
Share on other sites

Link to post
Share on other sites

If you want a Windows Server aim for Intel 8th Gen or AMD Ryzen 2000 Series or newer.

If you go Linux Aim for Intel 4th Gen or anything from the AMD Ryzen line or newer.

Reasoning is OS Support will fall somewhere around here and id consider it to be the lowest you would want go anyways with the Intel 4th gen really pushing it.

 

Assuming you are talking about Java Minecraft this is my recommendation.

 

For Memory I would aim for around 8G to 10G. This seems to be about the average necessary in my experience, to little or to much and you run into issues. This can however be set for the Java Runtime Environment so feel free to have more.

 

The most important thing however is single thread performance, You want this to be as high as possible. The more you have going on in your world and the more chunks you have to generate the more it will matter, as a result the number of players can also have a big impact especially if you are going in opposite directions. Chunk Generation is probably the hardest, you can get around a lot of it by pre-generation chunks with something like chunky, you just run it ahead of time before you start playing.

 

If you are looking for atleast what I would consider a simple way to run a Minecraft Server I would check out Docker Minecraft, which does require Docker/Podman.

Link to comment
https://linustechtips.com/topic/1577037-minecraft-server/#findComment-16470180
Share on other sites

Link to post
Share on other sites

time for the full ramble i suppose...

(presumption, java edition server.. i have no idea about the performance of bedrock)

 

first things first, dont ever home-host for anyone else than your direct friends. there's a whole long-arse rant i could do about this, but essentially just either keep it to friends, or stick it in a datacenter where it belongs.

 

on the presumption that we're talking about a "group of friends" situation... there's a few key aspects to a minecraft server:

- minecraft server is essentially single thread. there's some things that are offloaded to other threads, but the tick thread is always your bottleneck. there's projects to multi-thread the tick thread, but that's specialized stuff you dont mess with until you've got people on payroll.

- RAM is important, but there's some people around with wild theories that make no sense what so ever.. in short, with 16GB you've probably got plenty of memory to always be at a point where the tick thread is a problem before the RAM is a problem.

 

as for what this translates to in hardware:

- if you're buying second hand hardware, as long as it'll do 16GB RAM, look for whatever has the highest single core performance.

- i probably dont need to repeat it again.. but IMO 16GB is probably your sweet spot for RAM. if you're doing very big modpacks you might want to push to 32, if you're doing straight up vanilla with a small handful of friends, you're probably fine with 8, or even 4.

- get an SSD for your server storage, nothing special, just anything better than spinning rust.

 

if you need some input on the software side of things:

- use something linux as your OS, if you're not comfortable delving into propper server stuff, just run xubuntu or any other ubuntu derivative.

- i've tried out just about every "minecraft hosting panel" that is available for free, and IMO they all suck. cant say it any better than that, it's just a horrible experience all around. i use a very hacky way to run my minecraft servers (or well.. anything really) as a linux service with some trickery with the screen package.  but nothing's stopping you from just running it on the desktop and accessing it from there.

Link to comment
https://linustechtips.com/topic/1577037-minecraft-server/#findComment-16470190
Share on other sites

Link to post
Share on other sites

1 hour ago, Gat Pelsinger said:

It is easy. If you want to host it yourself, then on the server PC, download this file from - https://www.minecraft.net/en-us/download/server. You must have Java installed. Install the latest JDK version Java website (JDK 22 right now). After that as said on the Minecraft website, run the jar file with the given commands. But, I would highly recommend increasing the -Xmx and -Xms numbers. There are the arguments given to the Minecraft server in how much memory it is allocated, and they haven't bothered to update the requirements with the newer versions, but I think the default 1 GB that they have given works, but for good experience, at least 2 - 4GB is recommended. Just change the 1024M to like 4096M (4GB) or I think even just 4G works. And I also recommend to remove the "nogui" part. The GUI is helpful in seeing the server performance like the memory usage and the tick speed.

 

Once you have the server running, to connect to that server, it depends on how your computers are connected. If you were running the Minecraft server on the same PC where you have your client open (which you are not), you would just type localhost in the IP address box in multiplayer.

 

If you have direct connection between the server and the client through Ethernet, then you configure both the Ethernet ports to run under the same local network. This is a bit involved, bit if you are on Windows, then go to Control panel -> Network and Sharing Center -> Change adapter options (top left) -> your Ethernet -> Properties -> TCP/IPv4-> Properties -> check the box enable setting a custom IP address, and then an add an IP address like 192.168.0.1, a Subnet mask of 255.255.255.0, and a default gateway like 192.168.0.2. On the second PC, do the same but set the IP address to 192.168.0.2, same Subnet mask, and the default gateway of 192.168.0.1. Notice the criss-cross of the IP address and the default gateway. Now on your client, just connect to the local IP address of your server. Note that if you want to get correct internet access on your ethernet ports, then you need to remove the changes (click to get automatic IP address) to fall back to DHCP.

 

If your server and the client are both connected to the same router, then I believe that you can just connect by entering the IP address of the client. You can check your IP address in the Ethernet section of the performance tab in task manager.

 

And if you want to host you server over the internet, then I have no idea about it, but I know that it is possible easily. If you really just don't want the hassle, you can use something like Aternos for free, but they only limit their render distance to 6 and with quite a bit latency.

that’s what i mostly heard downloading the server jar thing, but the one i hear a lot of different options is the hosting outside of local, also i just multiply the amount of ram i want by 1024 then put that number?

Link to comment
https://linustechtips.com/topic/1577037-minecraft-server/#findComment-16470257
Share on other sites

Link to post
Share on other sites

1 hour ago, manikyath said:

i use a very hacky way to run my minecraft servers (or well.. anything really) as a linux service with some trickery with the screen package.  but nothing's stopping you from just running it on the desktop and accessing it from there.

I will dump this here as it's how we ran Minecraft Servers before moving to docker-minecraft in k8s. It does however rely on the now unmaintained mcrcon.

 

Spoiler

[Unit]
Description=Minecraft Server
After=network.target

[Service]
User=minecraft
Nice=1
KillMode=none
SuccessExitStatus=0 1
ProtectHome=true
ProtectSystem=full
PrivateDevices=true
NoNewPrivileges=true
WorkingDirectory=/opt/minecraft
Restart=on-failure
RestartSec=5s
ExecStart=/usr/bin/java @user_jvm_args.txt @libraries/net/minecraftforge/forge/1.19.2-43.2.6/unix_args.txt
ExecStop=/opt/minecraft/tools/mcrcon -H 10.0.20.85 -P 25575 -p your_rcon_password stop

[Install]
WantedBy=multi-user.target

 

Link to comment
https://linustechtips.com/topic/1577037-minecraft-server/#findComment-16470276
Share on other sites

Link to post
Share on other sites

22 minutes ago, Pirito said:

that’s what i mostly heard downloading the server jar thing, but the one i hear a lot of different options is the hosting outside of local, also i just multiply the amount of ram i want by 1024 then put that number?

Yes it might be more feasible if you do not have a public IP address and/or domain name at home. There are plenty of VPS providers selling cloud machines dedicated for Minecraft, equipped with fast consumer-grade processors and a lot of RAM. For self-hosting, it's recommended to follow their choices like Ryzen 5000 series or later.

 

Secondly, you need to simply apply the option -Xmx8G to the Java arguments for Minecraft, where 8G correspond to the maximum amount of RAM the game is allowed to use. Typically 8 GB would suffice in most scenarios, vanilla or with minimal mods.

 

Additionally, you may grab Java from open-source communities rather than Oracle. A good candidate is Amazon Corretto, which I have utilized for years and never crashed.

Link to comment
https://linustechtips.com/topic/1577037-minecraft-server/#findComment-16470298
Share on other sites

Link to post
Share on other sites

3 hours ago, manikyath said:

time for the full ramble i suppose...

(presumption, java edition server.. i have no idea about the performance of bedrock)

 

first things first, dont ever home-host for anyone else than your direct friends. there's a whole long-arse rant i could do about this, but essentially just either keep it to friends, or stick it in a datacenter where it belongs.

 

on the presumption that we're talking about a "group of friends" situation... there's a few key aspects to a minecraft server:

- minecraft server is essentially single thread. there's some things that are offloaded to other threads, but the tick thread is always your bottleneck. there's projects to multi-thread the tick thread, but that's specialized stuff you dont mess with until you've got people on payroll.

- RAM is important, but there's some people around with wild theories that make no sense what so ever.. in short, with 16GB you've probably got plenty of memory to always be at a point where the tick thread is a problem before the RAM is a problem.

 

as for what this translates to in hardware:

- if you're buying second hand hardware, as long as it'll do 16GB RAM, look for whatever has the highest single core performance.

- i probably dont need to repeat it again.. but IMO 16GB is probably your sweet spot for RAM. if you're doing very big modpacks you might want to push to 32, if you're doing straight up vanilla with a small handful of friends, you're probably fine with 8, or even 4.

- get an SSD for your server storage, nothing special, just anything better than spinning rust.

 

if you need some input on the software side of things:

- use something linux as your OS, if you're not comfortable delving into propper server stuff, just run xubuntu or any other ubuntu derivative.

- i've tried out just about every "minecraft hosting panel" that is available for free, and IMO they all suck. cant say it any better than that, it's just a horrible experience all around. i use a very hacky way to run my minecraft servers (or well.. anything really) as a linux service with some trickery with the screen package.  but nothing's stopping you from just running it on the desktop and accessing it from there.

what are your thoughts on this build to run my server? https://pcpartpicker.com/list/ZMg7QP the missing parts is because i already have them, gpu is 1660, psu is 600w and storage is 1tb crucial p3

Link to comment
https://linustechtips.com/topic/1577037-minecraft-server/#findComment-16470417
Share on other sites

Link to post
Share on other sites

9 minutes ago, Pirito said:

what are your thoughts on this build to run my server? https://pcpartpicker.com/list/ZMg7QP the missing parts is because i already have them, gpu is 1660, psu is 600w and storage is 1tb crucial p3

i'd go for a cpu with integrated graphics, to forego the GPU entirely, and not spend 20 bucks on more fans than the case you picked out can hold.

Link to comment
https://linustechtips.com/topic/1577037-minecraft-server/#findComment-16470424
Share on other sites

Link to post
Share on other sites

19 minutes ago, manikyath said:

i'd go for a cpu with integrated graphics, to forego the GPU entirely, and not spend 20 bucks on more fans than the case you picked out can hold.

i already have a gpu, would it benefit me if i go with integrated graphics instead?

Link to comment
https://linustechtips.com/topic/1577037-minecraft-server/#findComment-16470444
Share on other sites

Link to post
Share on other sites

On 7/19/2024 at 2:14 PM, manikyath said:

it would likely decrease power usage, if that's something you're worried about.

hey ik its been a couple of days but i wanted to ask you what parts i should buy new and what is okay to buy used?

Link to comment
https://linustechtips.com/topic/1577037-minecraft-server/#findComment-16472268
Share on other sites

Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

×