Register for the iXsystems Community to get an ad-free experience and exclusive discounts in our eBay Store.

How to install Minecraft server in a jail!

Joined
Apr 3, 2013
Messages
11
Thanks
0
#21
That's a well known problem with 9.2.1. There's a bug ticket in for it. My advice is to wait for a fix to come or go back to 9.2.0. 9.2.1 is a total mess, which is why I never ever upgrade to the "latest" version until a month or so has passed. Let the other suckers deal with the problems. Sorry, but today you are the sucker. ;)
Lol damn. I've been on 8.3.1 for the last year and I thought today would be the day to finally upgrade. Ill go back to 9.2.0 and see what happens. Thanks!
 
Joined
Mar 25, 2012
Messages
19,154
Thanks
1,850
#24
I'm running one on my home server.
 
Joined
Feb 10, 2014
Messages
7
Thanks
4
#26
I had this problem. I found the following method fixed it....

(As root)

# cd /usr/local/etc/pkg/repos/
# touch FreeBSD.conf
# <editor> FreeBSD.conf

For now make it look like this...

FreeBSD: {
url: "http://pkg.FreeBSD.org/${ABI}/latest",
mirror_type: "srv",
enabled: yes
}

<save file>
# pkg update

It SHOULD update pkg first before it does anything. Afterweards edit the FreeBSD.conf file again and change:
url: "http://pkg.FreeBSD.org/${ABI}/latest",
to
url: "pkg+http://pkg.FreeBSD.org/${ABI}/latest",

That method worked for me. The reason for the change is because the jail comes with an older version of pkg. After it updates it will still work with http://... but will spit out errors about changing it to pkg+http. The older version doesn't know how to handle the pkg+http address.

Hope that helps, that's what I did to fix it. Good luck.
 
Joined
Mar 25, 2012
Messages
19,154
Thanks
1,850
#27
PM sent. I have to whitelist you though.. ;)
 
Joined
Oct 8, 2013
Messages
51
Thanks
6
#28
If I can directly ping the server at the correct IP address, is there any reason to believe my setup is wrong? I still cannot connect via minecraft, but I can ping it using the windows ping command with no problem. I'm pretty sure I'm having a permissions problem, but being a noob, I'm not sure how to verify that. I've been step-by-step through cyberjock's setup with no apparent issues...any ideas would be great.
Thanks,
Fish
 
Joined
Mar 25, 2012
Messages
19,154
Thanks
1,850
#29
If you can ping it that just means your networking is correct. That doesn't provide any insight on if Minecraft is properly setup. Unfortunately, you are kind of on your own as there's no way to easily identify the problem.
 
Joined
Feb 10, 2014
Messages
7
Thanks
4
#30
I ran into connection issues due to server client mismatches. The server was v1.6 and the client was v1.7. You sure this isn't the issue? Craftbukkit recommended is v1.6, beta is 1.7. Not sure if you're using that.
 
Joined
Mar 25, 2012
Messages
19,154
Thanks
1,850
#31
Thanks for the info Mace. But I think I should reiterate that this forum is for FreeNAS support and not Minecraft. You should stick to running the vanilla version of Minecraft first. Then, if or when you feel comfortable using a custom build suck as Bukkit then consider "Upgrading" accordingly. Of course, if you have problems with it, that is outside of the realm of this forum's topical subjects.
 
Joined
Oct 8, 2013
Messages
51
Thanks
6
#32
I am able to get it to work, but only if I "manually" start the server by, as root in the jail and in the directory /srv/minecraft, typing in the "java -jar minecraft_server.jar" command. The server starts normally and I can log on and all seems well (without extensive testing).
That begs my question, however, is why it works that way but doesn't seem to start automatically as I infer it should after following cyberjock's tutorial. The only changes I had to make from cyberjocks tutorial were to initially change permissions in the jail (using the recursive check block in the gui) to allow me to copy over the 4 files to the various locations in the jail using CIFS shares. This was done before changing the permissions as stated in the tutorial.
Again, it seems to work but I was wondering if anyone had any clues, based on how I had to get it working, why it won't work as per the tutorial. I guess I shouldn't look a gift horse in the mouth, but there is obviously something I don't understand and I'm hoping to gain some insight.
Again, thanks to cyberjock for the tutorial. Without it, I would still be sitting in corner somewhere, rocking, trying to get this thing to work.
Thanks,
Fish
 
Joined
Mar 25, 2012
Messages
19,154
Thanks
1,850
#33
Sounds like the files you copies don't have execute permissions. The mcwatchdog and minecraft files in /usr/local/etc/rc.d should have execute permissions.
 
Joined
Jan 30, 2014
Messages
40
Thanks
0
#34
If I want to create portjail I get an error
  • ERROR: A template with this nickname already exists!
 
Joined
Mar 25, 2012
Messages
19,154
Thanks
1,850
#35
If I want to create portjail I get an error
  • ERROR: A template with this nickname already exists!
I don't even understand that error. Were you trying to create a new template instead of trying to create a new jail?
 
Joined
Mar 4, 2014
Messages
1
Thanks
0
#37
I am able to get it to work, but only if I "manually" start the server by, as root in the jail and in the directory /srv/minecraft, typing in the "java -jar minecraft_server.jar" command. The server starts normally and I can log on and all seems well (without extensive testing)..... The only changes I had to make from cyberjocks tutorial were to initially change permissions in the jail (using the recursive check block in the gui)

As cyberjock suggested.. the problem is the file permissions. I had the exact same problem as you and it stemmed from me recursively setting permissions on that jail so I could copy the files via CIF share i set up. To fix it, I deleted the jail and started again. When it came time to copy the files over, i used FTP instead and logged in with root. That allowed me to copy the files without having to reset any permissions. After I completed all the steps, minecraft was ready to go.

FYI....I did have an issue getting FTP to start up (likely a memory issue as I am running this on a 4G PC). I found another thread that said if I go to Settings-Advanced and uncheck Use system dataset for syslog: FTP would likely start until I restart Freenas. I did that.. and FTP started right up.. I copied my files... turned off FTP.. and went on with the steps. After finishing the whole setup, I don't need FTP as my CIF share allows me to edit the files I need to. All is good.
 

hervon

FreeNAS Experienced
Joined
Apr 23, 2012
Messages
208
Thanks
41
#38
Thanks cyberjock for this great tutorial. Got the server running in a few minutes. Thanks also to Mace post #26 that helped me install pkg using 9.2.1.2.
 
Joined
Mar 25, 2012
Messages
19,154
Thanks
1,850
#40
Your SSH isn't properly configured or your user isn't properly setup.
 
Top