I've been running a small Minecraft server for a couple weeks with just a couple of friends. I wanted to share my knowledge about running a server on Amazon EC2. It's really a great tool for hosting Minecraft. Take my tutorial for what it is, a general guideline. I'm by no mean a linux master.
Several advantages:
- no long term server commitment - pay as you go
- easily scalable - shut a server down and reboot it with more processing power and ram within minutes
- save money - You can host a server just in the evenings or weekends with your friends and not have to pay to run it 24/7 unless you chose to.
- plenty of bandwidth - if you're like me you're limited to less than half a megabit upstream at home which makes hosting a server pretty much out of the question.
- easy backups - save your world easily anytime you choose into bootable server images.
- quick provisioning - get a server running within seconds or minutes.
I. Register for Amazon EC2
1. Go to aws.amazon.com and make an account.
2. Read over all appropriate charges that you will incur. You'll be charged for bandwidth, disk io, the server itself, ebs volumes, etc. There is a free tier for new customers but you will probably incur some extra charges outside of that tier.
3. Understand pricing structure of EC2 servers. There are 3 pricing tiers. Servers are charged per hour of usage.
On Demand: Most expensive but pay as you go and guaranteed server time. Set up within seconds usually.
Reserved: Same as on demand but you pay for access to lower prices for 1 or 3 years with a one time fee.
Spot: (what i generally use) based on bid for unused servers. Cheapest prices of all. Set a maximum price you're wiling to pay for server time and a server is obtained through a bidding process. Usually costs 1/3 of price of on demand instances. If current bid prices rises above your maximum bid your server will be shut down and your data will be lost. I usually bid 5x more than the current bid rate just to be safe. Your bid price doesn't effect the market price you will pay. So if you bid $1.00 an hour and the market price was .30 you would still pay .30. If the price per hour spiked to .50 briefly you're server would still be running since your maximum bid is high enough.
Spot instances can take a few minutes to set up whereas on demand and reserved generally take just a few seconds.
Typical server prices per hour for linux. As of March 2011.
Players per server instance type is an estimate and not a tested value.
Micro - don't use. Too slow in my experience even for 2 people.
32 bit instances
Small - up to 10 players
On demand: .085
Reserved: .03
Spot: .029-.031
Medium - up to 25 players
On demand: .17
Reserved: .06
Spot: .057-.063
64 bit instances
Large - unsure 75-100 players?
On demand: .34
Reserved: .12
Spot: .114-.125
Extra Large - 200 players?
On demand: .68
Reserved: .24
Spot: .231-1.00
II. Creating and setting up server
1. Create security group.
A. Navigate to security groups under ec2 in the aws console.
B. Create new group with name like minecraft so you know what it applies to.
C. Allow TCP Ports 22 and 25565 with source 0.0.0.0/0 on both.
2. Get elastic IP - Navigate to elastic IPs under ec2 and allocate new address.
3. Create a key pair - ec2 servers don't accept passwords to login via ssh. You will need to create a key pair for use when logging in. Name the key pair and download the file to somewhere you know where it is like your desktop.
4. Create instance.
A. Determine how many players you will want on your server. If more than 25 players will generally be playing you will probably want a 64 bit server. If its a small group of people go with 32 bit.
B. Go to the ec2 dashboard and click "create instance" I generally use the basic amazon 32 bit AMI for my server so that's what I would recommend. Again, use 64 bit if you're planning on running a larger server. By using 64 bit, though, you won't have access to the cheaper small and medium tiers should you chose to downsize your server at a later date. You want to chose an AMI with EBS since EBS is persistent, meaning if your server reboots for any reason your data will still be there.
C. Chose your instance type and payment method. I would suggest requesting a spot instance since it's MUCH cheaper. Just set a bid at 3-5x the current price and you should be pretty well protected if the current price fluctuates any.
D. Use default kernel and disk id
E. On the next step next to name just put in a name that will easily identify your server. This is just incase you have multiple servers running you can identify which is which.
F. Select your existing minecraft key pair you set up earlier as well as your minecraft security group.
G. Launch instance
H. After your instance is running go to elastic IP page and associate elastic IP with the instance
5. Log into instance
Windows
A. Download Putty
B. Enter your elastic IP
C. use keygen which is included in the putty install to change .pem into the putty format .ppk.
D. Associate the key with putty under shh and security options.
E. Connect
Mac
A. Open terminal
B. Navigate to the directory with the key pair file you downloaded earlier. To do this type in cd and then the directory. (ex. "cd desktop" for desktop)
C. Type "ls" to list files on your desktop or other folder
D. Type "chmod 400 yourkeyname.pem"
E. Go to AWS management and view your running instance. Right click on it and click connect. Under the prompt that comes up copy and paste the text displayed under "enter the following command line". It should look something like this "ssh -i macminecraft.pem [email protected]". Change the root right before the @ symbol to ec2-user. Copy and paste this into the terminal.
F. You should be connected through ssh in your terminal at this point.
6. Setting up Minecraft on the server
I'm using the 32bit Amazon AMI. I'm not sure how this differs on different AMIs.
A. In terminal/putty type "wget http://www.minecraft.net/download/minecraft_server.jar"
B. To run server enter "java -Xmx1024M -Xms1024M -jar minecraft_server.jar nogui"
C. You should now be able to connect to your server using your elastic IP
7. Saving server/backing up server
Saving a server in its current state is really easy in ec2 and is one of the reasons i love ec2 so much. If you don't want to pay to run a server when you and your friends aren't on then don't. It gives you complete control.
Simply right click on a running instance and click "create image (EBS AMI)". When your server is saved into an AMI it can be started easily at the that point. Once you're AMI is created it's safe to terminate your instance. Your data is safe.
To launch a previously saved AMI navigate to AMIs and right click "launch instance" and your server will pick up where it left off.
Tips:
- you can not boot from a snapshot. Always save as an AMI.
- always release your elastic IP address after you shut down your server or you'll be charged .01 per hour for an unassociated IP. You could decide to keep the IP of course if you didn't want to distribute a new one everytime you started a server.
Credit: This man is awesome
Now you know how to do it. I don't want to see anyone else using Hamachi!!!
Looks helpful! I've not tried to set up a server on the Amazon cloud, but I've been thinking about it.
Just to confirm, If I run a server with at max 5 players on at a time, and then only for a few hours a day, how much would it cost at the cheapest?
And is it possible to run a virtual machine with a linux distro (MineOS, to be exact) on it? If so, does this cost any extra?
Thanks!
Rollback Post to RevisionRollBack
Quote from A wise man once »
Religion is like a penis. It's ok to have one, and it's ok to be proud of it. But don't go waving it around in public, and don't try to shove it down kids' throats.
Quote from He also »
Ambition is a poor excuse for not having enough sense to be lazy.
For running a 5 man server i would say a small instance would probably do it just fine.
If you had the server up for like 6 hours with 5 players the total cost would probably be something like 25-50 cents. This is a really rough estimate but it gives you a general idea.
Server = .03x6 = .18
Provisioned storage = .01
Bandwidth = .15-.30 for 1-2GB
Disk I/O = .02-.03
As far a running mine OS, I'm sure you can and there shouldn't be any additional cost. You have full access to the server so if it can run on linux you shouldn't have any problems. I'm not sure about the process as far as installing Mine OS onto the machine though since I've never done it and I'm not very familiar with the software.
Personally, I'm completely happy with administrating the server through ssh. I really don't see any advantages to running Mine OS unless you're just really adverse to typing server commands and prefer a graphical interface. Even then from just looking at it quickly it looks more limiting than useful. I would just stick to administration through the typical minecraft server.
If you're a new customer they also have a free tier so most of the provisioned storage, bandwidth, and disk I/O would probably be mostly free for you. Take a look at their free tier.
I really don't see any advantages to running Mine OS unless you're just really adverse to typing server commands and prefer a graphical interface.
I don't currently use MineOS because I need a more robust server for other things when I am not playing Minecraft, but having tested it I can say it has more advantages than you might think. It has an incredibly small memory foot print and takes up an extremely small amount of drive space. In a cloud environment, I would assume that both of these would be a good thing since the more resources you use the more you pay.
Rollback Post to RevisionRollBack
zombiecraft.serverbeer.com - Permissions enabled home server, focusing on big builds
Finally some solid info on this for someone like me. I've been curious about it for some time, but I'm just so afraid of how they split up their charges. I've always been afraid that I would screw up and end up racking up a huge bill. From your estimates it does look to be fairly competitive in pricing for such use. Have you been able to run any tests on their bandwidth to see just how high the upload can go to?
I haven't done any tests on bandwidth but from what I understand their allocated internal network speed per instance is as follows.
small - 250Mbps
large - 500Mbps
xlarge - 1000Mbps
Of course since that is your speed within the datacenter the connection speed to the outside world would probably be a little slower. I don't see the connection speed being a problem. I've never run into any bandwidth issues. But then again I've only hosted smaller servers and not the 200 slot beasts that some people host. Bandwidth looks like it would scale well with the size of the instance. I don't see it being a problem for even large servers requiring like 100-1000Mbits.
I've been playing around with EC2 for work and I decided to test it out with Minecraft.
Just for total ease of use, I launched a small Windows spot instance ($0.05/hour!). I used RDC to connect to the server. On it, I installed Java and Dropbox (for super simple file transfer). I launched my MC server with no problems.
Afterward I saved everything out as a private AMI and terminated the instance. I then released my Elastic IP. My only question is this... the instance I launched uses EBS for storage, so in AWS it indicates that I have a 30G EBS volume "in-use" even though my server is shut down. I can't seem to do anything with it (such as "detach"), so I wonder if having that there will generate any charges.
Yeah windows instances are more expensive which is one of the main reasons I use primarily linux. When you save as an AMI it creates a snapshot image of your EBS drive. I'm guessing this is what you're referring to. You shouldn't still have a ebs running under volumes after your instance is terminated. This is a quote from amazon regarding the pricing of snapshots.
Snapshot storage is based on the amount of space your data consumes in Amazon S3. Because data is compressed before being saved to Amazon S3, and Amazon EBS does not save empty blocks, it is likely that the size of a snapshot will be considerably less than the size of your volume. For the first snapshot of a volume, Amazon EBS will save a full copy of your data to Amazon S3. However for each incremental snapshot, only the part of your Amazon EBS volume that has been changed will be saved to Amazon S3.
So yes the snapshots will cost money but a very negligible amount in the grand scheme of things.
Your guide has been helpful. I currently have a server up and running and it works fine! The only trick with Windows Server 2008 is that I had to open port 25565 in the Windows firewall.
Yeah, Windows servers are more expensive, but if you fear the Linux command line... it's nice to know it works.
However! I still think Amazon EC2 is too expensive to run a full time server. A small instance running at $.05/hour still amounts to $37/mo. I'm looking at VolumeDrive.com for VPS hosting of a much beefier server for $15/month. Linux though, so I gotta get used to that.
I was connected to it via SSH in Terminal on my Macbook. I closed the computer (it went to sleep), and apparently that caused the server to shut down. How do I prevent this so I can quit terminal while the server is still going?
Rollback Post to RevisionRollBack
Quote from A wise man once »
Religion is like a penis. It's ok to have one, and it's ok to be proud of it. But don't go waving it around in public, and don't try to shove it down kids' throats.
Quote from He also »
Ambition is a poor excuse for not having enough sense to be lazy.
To keep the server running when the ssh client is closed you need to run the server in screen. Instead of the normal "java -Xmx1024M -Xms1024M -jar minecraft_server.jar nogui" use "screen -S minecraft java -Xms1024M -Xmx1024M -jar minecraft_server.jar nogui" to start it in an active screen session. If you then close the client minecraft will still run on the server and if you ssh back into it you can resume viewing the minecraft session by entering "screen -r minecraft"
Your server may not have screen installed by default. I'm not sure off the top of my head what the command is to get screen if you don't have it. It's probably "sudo apt-get install screen".
You're recommendation of volumedrive.com intrigued me. I actually went ahead and ordered their smallest vps which has specs that should run minecraft with more than enough power. I had my doubts based on their pricing since the only way to achieve those prices would be though massive overselling. After getting the server set up I have to say that I was correct in my assumption. Its physically impossible to run a server on their service. I had problems even SSHing into the server their service was so laggy and oversold. I'd definitely recommend staying away from their service for minecraft hosting.
I'm working right now to move the files over to a new xen based server at thrustvps.com. I believe the xen platform should work much better for a minecraft server since it's pretty much impossible to be oversold.
I should add though that Amazon ec2 is still a great service for the money. I'm only getting 512Mb ram and thrust vps for $8/m whereas i was getting 1700 with a small instance with ec2 for around $20-30/m if I run it constantly through the month. A similar vps at a budget provider, thrustvps.com, with 1.5GB ram runs for $23/m. You get what you pay for with hosting. Amazon still has a premium quality service at a very good price comparable to budget providers. Amazon's pricing is very good in terms of xen based providers.
For the record:
openvz = cheap, sucky, oversold, laggy
xen = fast, worth the money, not oversold
I've worked with EC2 a bit and am currently running a small test server on it. I went about things a bit differently, namely using an EBS volume to store everything minecraft related. I did this because I am a sucker for the cheap spot instances and it prevents me from having to worry about having an updated backup if the server happens to get shut down due to price.
It's fairly trivial to get an EBS volume formated and attached - I could write something up if anyone was interested. Having everything stored on the EBS volume allows me to use an instance store AMI and prevents me from getting charged for a large EBS volume that will hardly get used.
I tried using S3 (which would be cheaper) through S3FS but couldn't get it mount correctly - I was also worried about write failures and latency with S3. I also tested using Dropbox; it worked but was much more of a hassle to set up.
If you are having trouble using screen I would suggest running byobu. It adds a little top display at the bottom of the screen and allows you to use F2, F3, & F4 to create new screens and move around them.
You're recommendation of volumedrive.com intrigued me. I actually went ahead and ordered their smallest vps which has specs that should run minecraft with more than enough power. I had my doubts based on their pricing since the only way to achieve those prices would be though massive overselling. After getting the server set up I have to say that I was correct in my assumption. Its physically impossible to run a server on their service. I had problems even SSHing into the server their service was so laggy and oversold. I'd definitely recommend staying away from their service for minecraft hosting.
I agree 100%! I signed up for VolumeDrive and found it to be completely unusable. I'm canceling right away.
I have been running a large Linux/MySQL instance on Amazon EC2 for a couple of weeks now and it has been going fairly well. I love the ease of use and theoretical scalability, but the price is still up there... even while using a Spot Instance which is the cheapest option.
After about 3 weeks I've burned through $60-$70 worth of service. And I'm also skeptical about performance. I'm not sure why, but lately with about 14 people on the server I'm getting nothing but "can't keep up" messages. This server has 7Gigs of RAM! I have a feeling that the High-CPU instance might be a better choice, but it's more expensive.
I have been running a large Linux/MySQL instance on Amazon EC2 for a couple of weeks now and it has been going fairly well. I love the ease of use and theoretical scalability, but the price is still up there... even while using a Spot Instance which is the cheapest option.
After about 3 weeks I've burned through $60-$70 worth of service. And I'm also skeptical about performance. I'm not sure why, but lately with about 14 people on the server I'm getting nothing but "can't keep up" messages. This server has 7Gigs of RAM! I have a feeling that the High-CPU instance might be a better choice, but it's more expensive.
Anyone else have any EC2 thoughts?
Be sure to checkout the CloudWatch section and see if your CPU is actually being maxed out. You could temporarily enable the premium CloudWatch monitoring if you need more resolution in the data. It could be an I/O thing or a latency issue communicating with your MySQL database. Try disabling your MySQL if possible just to see if that solves the problem. I saw a similar issue in the forums related to EC2 a week or so ago and that ended up being the issue.
I agree 100%! I signed up for VolumeDrive and found it to be completely unusable. I'm canceling right away.
I've been really happy with my experience with thrustvps. I have the $8/month XenPV 512mb plan right now in the New Jersey datacenter and I've had no issues at all with lag. I've had a max of 6 players on it and lots of plugins like dynmap. Would definitely recommend for smaller servers. I would still consider EC2 a viable solution though in terms of cost. Just for a small server for me and a couple of friends ~$22+ per month for a small instance is a little high for that particular application.
I've been looking into selling some server space myself. I've actually enjoyed learning about linux system administration more than actually playing Minecraft if I dare say so. I'm working on the business plan now. I should be able to offer a price on par with what thrustvps offers but at a better Ghz to ram ratio. It should be at or above 1.2Ghz per 1GB of ram. I should be able to offer at least twice the disk space too. This is still at least a couple months out so we shall see.
Is there any way of doing this with a custom world file? Would we just do wget (URL of world file)? And would that also work for making it a bukkit server?
It's a lot more important to me to have the custom world file, but bukkit would be nice also.
Several advantages:
- no long term server commitment - pay as you go
- easily scalable - shut a server down and reboot it with more processing power and ram within minutes
- save money - You can host a server just in the evenings or weekends with your friends and not have to pay to run it 24/7 unless you chose to.
- plenty of bandwidth - if you're like me you're limited to less than half a megabit upstream at home which makes hosting a server pretty much out of the question.
- easy backups - save your world easily anytime you choose into bootable server images.
- quick provisioning - get a server running within seconds or minutes.
I. Register for Amazon EC2
1. Go to aws.amazon.com and make an account.
2. Read over all appropriate charges that you will incur. You'll be charged for bandwidth, disk io, the server itself, ebs volumes, etc. There is a free tier for new customers but you will probably incur some extra charges outside of that tier.
3. Understand pricing structure of EC2 servers. There are 3 pricing tiers. Servers are charged per hour of usage.
On Demand: Most expensive but pay as you go and guaranteed server time. Set up within seconds usually.
Reserved: Same as on demand but you pay for access to lower prices for 1 or 3 years with a one time fee.
Spot: (what i generally use) based on bid for unused servers. Cheapest prices of all. Set a maximum price you're wiling to pay for server time and a server is obtained through a bidding process. Usually costs 1/3 of price of on demand instances. If current bid prices rises above your maximum bid your server will be shut down and your data will be lost. I usually bid 5x more than the current bid rate just to be safe. Your bid price doesn't effect the market price you will pay. So if you bid $1.00 an hour and the market price was .30 you would still pay .30. If the price per hour spiked to .50 briefly you're server would still be running since your maximum bid is high enough.
Spot instances can take a few minutes to set up whereas on demand and reserved generally take just a few seconds.
Typical server prices per hour for linux. As of March 2011.
Players per server instance type is an estimate and not a tested value.
Micro - don't use. Too slow in my experience even for 2 people.
32 bit instances
Small - up to 10 players
On demand: .085
Reserved: .03
Spot: .029-.031
Medium - up to 25 players
On demand: .17
Reserved: .06
Spot: .057-.063
64 bit instances
Large - unsure 75-100 players?
On demand: .34
Reserved: .12
Spot: .114-.125
Extra Large - 200 players?
On demand: .68
Reserved: .24
Spot: .231-1.00
II. Creating and setting up server
1. Create security group.
A. Navigate to security groups under ec2 in the aws console.
B. Create new group with name like minecraft so you know what it applies to.
C. Allow TCP Ports 22 and 25565 with source 0.0.0.0/0 on both.
2. Get elastic IP - Navigate to elastic IPs under ec2 and allocate new address.
3. Create a key pair - ec2 servers don't accept passwords to login via ssh. You will need to create a key pair for use when logging in. Name the key pair and download the file to somewhere you know where it is like your desktop.
4. Create instance.
A. Determine how many players you will want on your server. If more than 25 players will generally be playing you will probably want a 64 bit server. If its a small group of people go with 32 bit.
B. Go to the ec2 dashboard and click "create instance" I generally use the basic amazon 32 bit AMI for my server so that's what I would recommend. Again, use 64 bit if you're planning on running a larger server. By using 64 bit, though, you won't have access to the cheaper small and medium tiers should you chose to downsize your server at a later date. You want to chose an AMI with EBS since EBS is persistent, meaning if your server reboots for any reason your data will still be there.
C. Chose your instance type and payment method. I would suggest requesting a spot instance since it's MUCH cheaper. Just set a bid at 3-5x the current price and you should be pretty well protected if the current price fluctuates any.
D. Use default kernel and disk id
E. On the next step next to name just put in a name that will easily identify your server. This is just incase you have multiple servers running you can identify which is which.
F. Select your existing minecraft key pair you set up earlier as well as your minecraft security group.
G. Launch instance
H. After your instance is running go to elastic IP page and associate elastic IP with the instance
5. Log into instance
Windows
A. Download Putty
B. Enter your elastic IP
C. use keygen which is included in the putty install to change .pem into the putty format .ppk.
D. Associate the key with putty under shh and security options.
E. Connect
Mac
A. Open terminal
B. Navigate to the directory with the key pair file you downloaded earlier. To do this type in cd and then the directory. (ex. "cd desktop" for desktop)
C. Type "ls" to list files on your desktop or other folder
D. Type "chmod 400 yourkeyname.pem"
E. Go to AWS management and view your running instance. Right click on it and click connect. Under the prompt that comes up copy and paste the text displayed under "enter the following command line". It should look something like this "ssh -i macminecraft.pem [email protected]". Change the root right before the @ symbol to ec2-user. Copy and paste this into the terminal.
F. You should be connected through ssh in your terminal at this point.
6. Setting up Minecraft on the server
I'm using the 32bit Amazon AMI. I'm not sure how this differs on different AMIs.
A. In terminal/putty type "wget http://www.minecraft.net/download/minecraft_server.jar"
B. To run server enter "java -Xmx1024M -Xms1024M -jar minecraft_server.jar nogui"
C. You should now be able to connect to your server using your elastic IP
7. Saving server/backing up server
Saving a server in its current state is really easy in ec2 and is one of the reasons i love ec2 so much. If you don't want to pay to run a server when you and your friends aren't on then don't. It gives you complete control.
Simply right click on a running instance and click "create image (EBS AMI)". When your server is saved into an AMI it can be started easily at the that point. Once you're AMI is created it's safe to terminate your instance. Your data is safe.
To launch a previously saved AMI navigate to AMIs and right click "launch instance" and your server will pick up where it left off.
Tips:
- you can not boot from a snapshot. Always save as an AMI.
- always release your elastic IP address after you shut down your server or you'll be charged .01 per hour for an unassociated IP. You could decide to keep the IP of course if you didn't want to distribute a new one everytime you started a server.
Credit: This man is awesome
Now you know how to do it. I don't want to see anyone else using Hamachi!!!
Just to confirm, If I run a server with at max 5 players on at a time, and then only for a few hours a day, how much would it cost at the cheapest?
And is it possible to run a virtual machine with a linux distro (MineOS, to be exact) on it? If so, does this cost any extra?
Thanks!
If you had the server up for like 6 hours with 5 players the total cost would probably be something like 25-50 cents. This is a really rough estimate but it gives you a general idea.
Server = .03x6 = .18
Provisioned storage = .01
Bandwidth = .15-.30 for 1-2GB
Disk I/O = .02-.03
As far a running mine OS, I'm sure you can and there shouldn't be any additional cost. You have full access to the server so if it can run on linux you shouldn't have any problems. I'm not sure about the process as far as installing Mine OS onto the machine though since I've never done it and I'm not very familiar with the software.
Personally, I'm completely happy with administrating the server through ssh. I really don't see any advantages to running Mine OS unless you're just really adverse to typing server commands and prefer a graphical interface. Even then from just looking at it quickly it looks more limiting than useful. I would just stick to administration through the typical minecraft server.
http://aws.amazon.com/free/
I don't currently use MineOS because I need a more robust server for other things when I am not playing Minecraft, but having tested it I can say it has more advantages than you might think. It has an incredibly small memory foot print and takes up an extremely small amount of drive space. In a cloud environment, I would assume that both of these would be a good thing since the more resources you use the more you pay.
See what we are building here: http://zombiecraft.servebeer.com
small - 250Mbps
large - 500Mbps
xlarge - 1000Mbps
Of course since that is your speed within the datacenter the connection speed to the outside world would probably be a little slower. I don't see the connection speed being a problem. I've never run into any bandwidth issues. But then again I've only hosted smaller servers and not the 200 slot beasts that some people host. Bandwidth looks like it would scale well with the size of the instance. I don't see it being a problem for even large servers requiring like 100-1000Mbits.
Just for total ease of use, I launched a small Windows spot instance ($0.05/hour!). I used RDC to connect to the server. On it, I installed Java and Dropbox (for super simple file transfer). I launched my MC server with no problems.
Afterward I saved everything out as a private AMI and terminated the instance. I then released my Elastic IP. My only question is this... the instance I launched uses EBS for storage, so in AWS it indicates that I have a 30G EBS volume "in-use" even though my server is shut down. I can't seem to do anything with it (such as "detach"), so I wonder if having that there will generate any charges.
http://aws.amazon.com/ebs/
So yes the snapshots will cost money but a very negligible amount in the grand scheme of things.
Your guide has been helpful. I currently have a server up and running and it works fine! The only trick with Windows Server 2008 is that I had to open port 25565 in the Windows firewall.
Yeah, Windows servers are more expensive, but if you fear the Linux command line... it's nice to know it works.
However! I still think Amazon EC2 is too expensive to run a full time server. A small instance running at $.05/hour still amounts to $37/mo. I'm looking at VolumeDrive.com for VPS hosting of a much beefier server for $15/month. Linux though, so I gotta get used to that.
I was connected to it via SSH in Terminal on my Macbook. I closed the computer (it went to sleep), and apparently that caused the server to shut down. How do I prevent this so I can quit terminal while the server is still going?
Your server may not have screen installed by default. I'm not sure off the top of my head what the command is to get screen if you don't have it. It's probably "sudo apt-get install screen".
You're recommendation of volumedrive.com intrigued me. I actually went ahead and ordered their smallest vps which has specs that should run minecraft with more than enough power. I had my doubts based on their pricing since the only way to achieve those prices would be though massive overselling. After getting the server set up I have to say that I was correct in my assumption. Its physically impossible to run a server on their service. I had problems even SSHing into the server their service was so laggy and oversold. I'd definitely recommend staying away from their service for minecraft hosting.
I'm working right now to move the files over to a new xen based server at thrustvps.com. I believe the xen platform should work much better for a minecraft server since it's pretty much impossible to be oversold.
I should add though that Amazon ec2 is still a great service for the money. I'm only getting 512Mb ram and thrust vps for $8/m whereas i was getting 1700 with a small instance with ec2 for around $20-30/m if I run it constantly through the month. A similar vps at a budget provider, thrustvps.com, with 1.5GB ram runs for $23/m. You get what you pay for with hosting. Amazon still has a premium quality service at a very good price comparable to budget providers. Amazon's pricing is very good in terms of xen based providers.
For the record:
openvz = cheap, sucky, oversold, laggy
xen = fast, worth the money, not oversold
Do the following to install the package:
sudo yum -y install screen
Screen still doesn't work for me.
I just get:
[Screen is Terminating]
I've worked with EC2 a bit and am currently running a small test server on it. I went about things a bit differently, namely using an EBS volume to store everything minecraft related. I did this because I am a sucker for the cheap spot instances and it prevents me from having to worry about having an updated backup if the server happens to get shut down due to price.
It's fairly trivial to get an EBS volume formated and attached - I could write something up if anyone was interested. Having everything stored on the EBS volume allows me to use an instance store AMI and prevents me from getting charged for a large EBS volume that will hardly get used.
I tried using S3 (which would be cheaper) through S3FS but couldn't get it mount correctly - I was also worried about write failures and latency with S3. I also tested using Dropbox; it worked but was much more of a hassle to set up.
If you are having trouble using screen I would suggest running byobu. It adds a little top display at the bottom of the screen and allows you to use F2, F3, & F4 to create new screens and move around them.
And finally, if you are using EC2 currently or just playing around with it you should definitely check out this: http://aws.amazon.com/about-aws/build-a-cluster-in-under-10/hpc-credit-request-form/?00N500000026nJd=SM_awsblog_hpctrial It is for a $20 EC2 credit. It's supposed to be for a high performance cluster tutorial but as far as I know it can be applied to any EC2 charges.
I agree 100%! I signed up for VolumeDrive and found it to be completely unusable. I'm canceling right away.
I have been running a large Linux/MySQL instance on Amazon EC2 for a couple of weeks now and it has been going fairly well. I love the ease of use and theoretical scalability, but the price is still up there... even while using a Spot Instance which is the cheapest option.
After about 3 weeks I've burned through $60-$70 worth of service. And I'm also skeptical about performance. I'm not sure why, but lately with about 14 people on the server I'm getting nothing but "can't keep up" messages. This server has 7Gigs of RAM! I have a feeling that the High-CPU instance might be a better choice, but it's more expensive.
Anyone else have any EC2 thoughts?
Be sure to checkout the CloudWatch section and see if your CPU is actually being maxed out. You could temporarily enable the premium CloudWatch monitoring if you need more resolution in the data. It could be an I/O thing or a latency issue communicating with your MySQL database. Try disabling your MySQL if possible just to see if that solves the problem. I saw a similar issue in the forums related to EC2 a week or so ago and that ended up being the issue.
I've been really happy with my experience with thrustvps. I have the $8/month XenPV 512mb plan right now in the New Jersey datacenter and I've had no issues at all with lag. I've had a max of 6 players on it and lots of plugins like dynmap. Would definitely recommend for smaller servers. I would still consider EC2 a viable solution though in terms of cost. Just for a small server for me and a couple of friends ~$22+ per month for a small instance is a little high for that particular application.
I've been looking into selling some server space myself. I've actually enjoyed learning about linux system administration more than actually playing Minecraft if I dare say so. I'm working on the business plan now. I should be able to offer a price on par with what thrustvps offers but at a better Ghz to ram ratio. It should be at or above 1.2Ghz per 1GB of ram. I should be able to offer at least twice the disk space too. This is still at least a couple months out so we shall see.
It's a lot more important to me to have the custom world file, but bukkit would be nice also.