Minecraft, Yourcraft, Ourcraft—building is more fun with your buddies.

Minecraft is a sandbox-type game where you gather materials and use them to create things, which is about as understated a description as "the sun is a big bright light in the sky." The poster child for indie gaming success, Minecraft began as a basement coding project by hat-wearing Swede Markus Persson in 2010; it has since become a bona fide phenomenon.

In Minecraft, you play a mute protagonist in an unending retro-blocky landscape populated by lots and lots of NPCs, with no traditional adventure game-type goal other than survival. This seems easy at first. When the game begins, you invariably find yourself on a sandy beach somewhere, and a bit of experimentation quickly yields the knowledge that you can affect your environment by punching things. You can punch trees to break them apart and collect wood, for instance, which you can use to make tools, which you can use to gather more materials, which you can use to make more things. You'll just be getting the hang of the basic mechanics when night falls—and the zombies and skeletons and spiders and creepers come out to collect your soul.

As the game grew more popular, Persson (known to fans by his in-game handle "Notch") hired staff and eventually turned over daily programming duties to other folks. These days, Notch spends his days developing other games and being interviewed by famous Internet journalists, while Minecraft thrives on multiple platforms including PC, Mac, Linux, and XBox 360.

The game has an engrossing single-player component, with a core gameplay mechanism that feels like a LEGO block set—go build stuff!—but it's much more fun to make things with your friends than to labor alone. Public Minecraft servers are widely available (here's a good list), but they have an unfortunate dark side: as with any public online game, keeping out folks bent on making mischief is ultimately impossible. If you want to play Minecraft with just your friends, the easiest way to do so is to run your own server.

Your first choice, should you go this route, is whether you want to use a managed hosting provider, use a regular non-Minecraft host, or just run the server yourself. Each option has tradeoffs. Choosing to use a fully managed Minecraft host like Servercraft or BeastNode means that you'll be up and hosting within minutes of forking over your credit card number, but you may have less control.

A non-Minecraft Web host, like a virtual private server from A Small Orange, might cost more, but it gives you additional flexibility in configuration (what if you want to add mods or tweak things later, or install additional server software?).

Finally, hosting the code yourself on a dedicated server in your closet is the most complex option, but can also be the cheapest and most flexible, assuming you have spare hardware lying around. For smaller Minecraft instances where you expect to only have a couple of players—for example, if you just want to play Minecraft with your kids—you can even run the server on your main computer without needing a separate piece of hardware.

In this guide, bits of which have appeared on my personal blog over the last few months, we will walk through some fairly generic instructions which should apply to both a VPS and self-hosting. After that, we'll move on to more advanced options that you can implement to spice up your Minecraft hosting experience. We're going to burn more words talking about how to make this all work with Linux than with other operating systems, since Linux is the most common option for hosting; if you're using a VPS, you'll almost certainly be using Linux, and if you're hosting out of your home, that's probably what you should use as well. However, don't feel left out if you want to get a Minecraft server running on Windows or OS X—we'll include you, too!

One quick note: this guide assumes that you're interested in running a Minecraft server because you're already a Minecraft player. We're not going to spend any time explaining how to actually download and set up the Minecraft client, nor will we talk about Minecraft basics like gameplay or strategy. This guide is long enough as it is!

Quick start

The Minecraft server binaries can be downloaded from the same page as the full game. The server package is free and available as either a Windows executable or a Java .jar file for Linux and OS X (and for Windows, too, if you don't want the executable version). Grab whichever one you need.

Windows users have it easiest: simply download the executable and run it. If you don't have a Java runtime environment installed, the executable will direct you to a download page where you can get it; once installed, re-run the Minecraft server binary. This gets you a Minecraft server up and available on TCP port 25565. Connect to it with your Minecraft client and explore your shiny new world.

To run Minecraft on OS X and Linux, you'll also need a Java runtime environment installed. For OS X, you can quickly install the latest Apple-approved version of Java by opening a Terminal window (click the Spotlight icon, type "terminal") and executing the command "java". If you don't already have Java installed, OS X will automatically grab it for you.

On a Debian-derived flavor of Linux like Ubuntu or Mint, the OpenJDK Java project is available from the default repositories and can be installed with a quick sudo aptitude install openjdk-7-jre (yes, we're using aptitude instead of apt-get, and so should you! Aptitude is available by default in Ubuntu server, but you might have to install it via apt-get for the desktop version). If you feel like you need the actual, genuine, Oracle-produced Java runtime environment instead of OpenJDK, you need to follow a few more steps.

That's it—just like your PC brethren, you're up and running with a Minecraft world available on port 25565.

The first time you start your Minecraft server, it checks for any existing Minecraft world and configuration files. If it doesn't find any, it creates everything it needs. In a fresh install, you'll end up with a world directory containing the newly generated Minecraft map, some configuration files, and a log file. If you plan on running Minecraft under a dedicated Minecraft user account, like on a real server, you might want to pre-create that account before firing up the server, though it's not strictly necessary to do so. (We'll cover how to move the Minecraft directory shortly.)

Lee Hutchinson
Lee is the Senior Technology Editor at Ars and oversees gadget, automotive, IT, and culture content. He also knows stuff about enterprise storage, security, and manned space flight. Lee is based in Houston, TX. Emaillee.hutchinson@arstechnica.com//Twitter@Lee_Ars

Let me get this straight. Those images of mincraft were all built from the basic tools that comes with the game? Is that right?

All the images in the article are from the server I run, which is a survival-only map. No creative mode. A couple of industrious players took advantage of an item duplication bug for a couple of days (someone whom I won't name has a house made out of diamond and gold blocks!), but there's no flying, no map editing, and no summoning of items except for the bit of fun bug-exploiting duping. Personally, I consider bug exploitation to be all part of the fun, as long as it doesn't ruin the game for everyone.

The last thing we're going to talk about is how to apply mods to Minecraft. The short answer is that you sort of can't, but the short answer is misleading. The more verbose answer is that you cannot mod Minecraft directly, at least not to any great effect,

I have to strongly disagree with that. The short answer is : there is no offical way of doing it (yet).The long answer is : there are many mods out there working in multiplayer with really deep effect on gameplay (I can mention RedPower, Buildcraft, IndustrialCraft and Smart Move among others). There are modding APIs working in multiplayer (ie: Forge). Those may take a bit of tweaking to get working but you have more choice than what has been ported to Bukkit.

You should correct this part of the artical, has it seems that you can't mod minecraft without installing Bukkit which is has far from the truth as day and night.

As a general rule of thumb, start with 1GB and consider allocating another half a gigabyte per regular player. If you expect to have four folks regularly playing on your server, 2-3 gigabytes should be plenty.

I used to work as an administrator at Hostgator. At least once a week, somebody had to deal with some poor sap who couldn't understand why Minecraft wasn't working on our lowest-level VPSes with approximately 256-768 MiB RAM and would not upgrade to one with more memory.

Long story short: Don't be that guy. Do your research and know what you're doing: it will make everyone's day go more smoothly.

Running minecraft on OSX is hard because you have to setup all these accounts and stuff, but Linux users can just run screen? That's dumb. Why is it okay to run the server under screen on Linux but not OSX? IMO, it's a pretty poor idea for either OS.

Sometimes, I miss the Ars MC server... Could have used this when I started out my own server a few months ago... Better late then never! Looks like I'll be checking out that second mapping software you suggested, as I have yet to implement a mapping tool...

Let me get this straight. Those images of mincraft were all built from the basic tools that comes with the game? Is that right?

The mountain-top castle is partly a collaborative effort. Qchronod prepared a lot of the terrain and infrastructure like bridges, then invited other players to construct their own towers / buildings in the area.

Zaktar's pyramid is even more impressive from the inside. It is hollow and contains an entire forest. In the near future he wants to take advantage of the upcoming "adventure" features to make the pyramid into a combat pit.

The rollercoaster is an incredible bit of work too. You really have to take a ride to appreciate the amount of work that went into it.

There's some pretty cool things on the Big Dino server. It's inspired several builds on my server. Any body interested in MC should look at the thread in GESC since there's some really cool pics there.

F_WRLCK wrote:

Wait, what?

Running minecraft on OSX is hard because you have to setup all these accounts and stuff, but Linux users can just run screen? That's dumb. Why is it okay to run the server under screen on Linux but not OSX? IMO, it's a pretty poor idea for either OS.

The server I admin is run on a dedicated linux box but I've run a local test server under my standard OS X account many, many times without issue.

I would dearly love to know how to send commands to a server on OS X. Using the excellent wiki article I'm now running a standard server & a tekkit server as daemons under a dedicated account, but it is painful to have to start minecraft and connect just to issue server commands.

Incidentally, as a result of running the servers I am now the most popular Dad in the neighbourhood and my son takes more phone calls per day than my wife and myself combined. His "MineCo" business is booming!

The rollercoaster is an incredible bit of work too. You really have to take a ride to appreciate the amount of work that went into it.

SO MUCH DEATH I can't count how many times I died putting that thing together - I still have plans on extending it further out through the jungle as well, but had to take a sanity break/get back to school. I'm also working on a glass maze in the... hollowed out mountain next to it - me and Planar_Demon already have a few challenges setup, but the maze has yet to be completed (you may suffer some spoilers if you check it out though).

Must stress how important it is to get enough resources for the server. Java is a pig, and minecraft even more so - especially if you get into things keeping the world saved in a ramdisk, or decide to run a number of mods.

Speaking from experience, minecraft is a brutal thing to pit most servers against.

My boys play Minecraft all the time, and I'd love to run a server for them; it's pretty annoying what a resource hog it is. The only "spare" machine I have that could run the server is the one they're actually using to play, and that wouldn't be a popular solution. Thanks for the guide though, maybe I'll recycle some hardware in the future.

My boys play Minecraft all the time, and I'd love to run a server for them; it's pretty annoying what a resource hog it is. The only "spare" machine I have that could run the server is the one they're actually using to play, and that wouldn't be a popular solution. Thanks for the guide though, maybe I'll recycle some hardware in the future.

I've had several instances of minecraft running on my system at the same time, usually just my client and a local server, but on occasion I've had 2 or 3 servers running at once. Provided that your system has atleast 2GB of memory and a 2GHz Core2Duo or better, I don't see any reason why you wouldn't be able to do the same. It sounds like they'd be playing one at a time, so it shouldn't put any strain on your computer.

You seem to be not using the same username consistently. you use 'user' twice as the home dir and 'mcuser' a few other times....

Great write-up. You should probably also mention that for the "play with other people in your house" you can now just open your world to lan on single player and other people can join. It would be by far the simplest solution for those people.

Great article. I hosted a Minecraft server for nearly a year for friends and family and as fun and addicting as it is standalone, going spelunking with friends is even better. Also watching them fall off of things is hilarious. Lots of chat-swearing. Oh, and my server was an old crappy Pentium 4 with barely a gig of RAM. Had a little lag, but quite playable for the most part. I had to stop when our family decided that we would try every mod ever made and an update made our entire world one block lower than before (weird ocean effects) and I decided that armageddon had come. Still planning a comeback though when I get the energy to futz with the router.

My boys play Minecraft all the time, and I'd love to run a server for them; it's pretty annoying what a resource hog it is. The only "spare" machine I have that could run the server is the one they're actually using to play, and that wouldn't be a popular solution. Thanks for the guide though, maybe I'll recycle some hardware in the future.

I've had several instances of minecraft running on my system at the same time, usually just my client and a local server, but on occasion I've had 2 or 3 servers running at once. Provided that your system has atleast 2GB of memory and a 2GHz Core2Duo or better, I don't see any reason why you wouldn't be able to do the same. It sounds like they'd be playing one at a time, so it shouldn't put any strain on your computer.

+1. I run two servers and the client on a mac mini - Core 2 Duo, 2.0GHz, 8Gb of ram. About three or four external parties in addition to the client is about the limit before it starts getting too laggy. I set it to wake at 6am and sleep automatically at 9pm and it automatically switches the monitor off after about 5 minutes to save power.

This will come in handy.I have a spare box (i5, 32 Gigs, HD, boot SSD), and a friendly neighbor with a Comcast Business line.

What general security tips do you recommend for the box? It's been mumble mumble years since I used UNIX (SUNOS). And have forgotten more than I remember. Plus since we were on a secure network we didn't realy need to worry about that sort of thing (aside from physical penetration).

What I'd like to see is better (as in any) support for proxy servers. We're trying to set up a Minecraft server at work but our (slightly daft) infrastructure is giving us headaches - not to mention the policies that prevent us from tunnelling or any other convenient workaround. It's irritating and could easily be fixed. The same is true for Steam come to that, it seems developers don't really consider users outside of a home environment.

You know, I have been running Minecraft on Azure for the past two months or so, it works like a dream, and potentially, the "pay per hour" model has HUGE potential. I'll just get me and my buddies to pitch in, and give everyone control over the azure instance.

Just turn the instance on when you want to play, and turn it off when you are done

I never did "get" Minecraft. Spent some time in the beta digging, punching trees, combining the wood for some basic tools... and that's about it. The interface didn't really help me figure out how to build anything in the world, and the few guides I found online assumed you already knew that.

Even then, I really didn't have anything I wanted to build. Was planning a simple fort, just to see how the night bit worked, but didn't even make it that far.

You know, I have been running Minecraft on Azure for the past two months or so, it works like a dream, and potentially, the "pay per hour" model has HUGE potential. I'll just get me and my buddies to pitch in, and give everyone control over the azure instance.

Just turn the instance on when you want to play, and turn it off when you are done

Hey, that's cool! I will try that on my Azure account this very evening.

I never did "get" Minecraft. Spent some time in the beta digging, punching trees, combining the wood for some basic tools... and that's about it. The interface didn't really help me figure out how to build anything in the world, and the few guides I found online assumed you already knew that.

Even then, I really didn't have anything I wanted to build. Was planning a simple fort, just to see how the night bit worked, but didn't even make it that far.

My boys play Minecraft all the time, and I'd love to run a server for them; it's pretty annoying what a resource hog it is. The only "spare" machine I have that could run the server is the one they're actually using to play, and that wouldn't be a popular solution. Thanks for the guide though, maybe I'll recycle some hardware in the future.

I have spent sooo many hours playing Minecraft with my kids (9 and 11). We have set up tons of servers, with all kinds of zany mods. Such a great way to spend time together.

I usually host on my laptop, actually. For the three of us, it runs just fine. It's a pretty heavy laptop, though.

I've owned and operated my own Minecraft server for about two years now and I've seen the game grow so much in that time. Wonderful things have been made especially from the creative modding community. There was always one thing that I found lacking though which was server administration for people who aren't the owner.

For example my three servers have combined about 20 members of staff and if I want them to run the server in my absense and be useful then they need tools that work outside of the game. Our servers are all linked to our IRC chat so they can view what is going on in-game without being logged in. Great for diffusing arguments and if someone needs a staff member they need only call for one.

So to help my staff outside of the game I wrote an Admin Control Panel or ACP as we call it for short. This is what it looks like: http://i.imgur.com/JeFLM.png

It allows me to add an unlimited amount of servers to it and they are all controlled from that one page. If a user is ranked up on one server they are ranked up on all three, if they are banned from that page they are banned across all three etc

It has made administration for us so much easier and I've integrated it with our forum so it's secure and to access the Admin Control Panel the staff merely go to the main forum index and click on it. I'm currently writing a UCP or User Control Panel for our players which looks similar but has different functions. Enabling them to control their skins, upload skins to mojang, store them on their UCP page, view all their skins as 3D models in their browser (using HTML5 Canvas WebGL etc), download & upload schematics of things they have built (or got elsewhere) it also enables them to send and receive in-game mails so they can organise amongst themselves without using the forums PM function since not all players check the forum regularly but they do always get their in-game mails. And finally it allows them to check their achievements, stats, view the games maps and our servers idea bank where they can upvote things they want to see happen.

After two years of running a Minecraft server I can tell you the most difficult thing to maintain is players. People get burned out on Minecraft very fast. If you think back to when you were a child playing with Lego you would have tons of fun but then you'd be done building what you set out to do and you wouldn't want to start building something new. You hit a creative roadblock that made you put the blocks back in their container and go play with something else.

A similar thing happens with Minecraft, people get bored after a while they leave then they come back a few weeks/months later after they get that itch to be creative again. The churn rate on Minecraft is massive and it's these tools like the ACP and UCP which are helping me and my servers to entice players to stay after they get burned out. A lot of players tell me they aren't bored of our community, they think we are a great bunch of people but it's the game itself that they tire of, so they stay around our forums and IRC but don't log in to play anymore. We've had over 14,000 unique players through our servers in the past 6 months but usually just 20-30 people online at any one moment.

If you're a new Minecraft server operator and you want to make your server public, beyond just your personal circle of friends then don't get discouraged by the high churn rate. People will come and go in vast numbers. You will have large flurries of activity especially over the summer holidays and when kids go back to school your servers will seem like a cemetery but it all evens out in the end.

If anyone would like to PM me for advice or anything feel free I've been doing this now for a long time and although I'm not the authority on Minecraft administration I've picked up a lot of experience, heck I've been doing this longer than Bukkit even existed. Hey0 forever!

I never did "get" Minecraft. Spent some time in the beta digging, punching trees, combining the wood for some basic tools... and that's about it. The interface didn't really help me figure out how to build anything in the world, and the few guides I found online assumed you already knew that.

Even then, I really didn't have anything I wanted to build. Was planning a simple fort, just to see how the night bit worked, but didn't even make it that far.

Wow, daytime lasts about 10 minutes, impatient much?

Not when I was playing. Maybe the setting in that beta was off, but I spent at least half an hour to 45 mins scrambling around before shutting it down.

I get about 20-30 emails a week from players who have server that has crashed. 90% of the time it's because of a lack of RAM, and after about 2-3 emails back and forth the issue is cleared up. Long story short, overbuy your servers.

It may not make sense right now, especially if you don't think that anyone will be on the server or it's 'just for friends', but you could wake up one morning to have your server offline due to a spike in traffic or in one person's case get your server taken offline and erased for some type of fraudulent use BS.

On the topic of modding: there are tons of mods out there, which I'm struggling to keep up with and write about on a regular basis. The really cool thing about Minecraft is that Notch is pretty open to modding and really wants to make a tool to allow other people to create amazing things, which is why I think that people keep coming back to the game, even after taking some time off because they aren't feeling creative.