Take the 2-minute tour ×
Arqade is a question and answer site for passionate videogamers on all platforms. It's 100% free, no registration required.

I have been trying to set up a bukkit server to run on localhost, so that I'd be the only one playing it.

I had someone on another forum help me get started by saying, basically, "Download the latest bukkit.jar from here, make folder and put that in it with a start.sh file that launches it (like this) and it will self populate the folder you put it in." The only difference in the start.sh I made was I listed the full path to the directory, and shrank the ram size to 1G. That didn't work, it wasn't populating the directory at all. So I tried loading the vanilla minecraft_server.jar, didn't work either.

I was told it could be a permission problem but it all looks fine to me. Below you can see the path to the craftbukkit.jar, aswell as the permissions from there. I'd appreciate any help, as I am very very new to any type of server setup.

ra@ra-desktop:~$ ls -al ~/.minecraft | grep Bukkit && ls -al ~/.minecraft/Bukkit 
drwxr-xr-x  2 ra ra    4096 2013-07-31 22:00 Bukkit
total 20896
drwxr-xr-x  2 ra ra     4096 2013-07-31 22:00 .
drwxr-xr-x 23 ra ra     4096 2013-07-31 00:54 ..
-rwxr-xr-x  1 ra ra 15249389 2013-07-30 08:54 craftbukkit-1.6.2.jar
-rwxr--r--  1 ra ra  6134331 2013-07-31 22:00 minecraft_server.1.6.2.jar
-rwxr-xr-x  1 ra ra       91 2013-07-31 22:00 start.sh

My start.sh looks like this now:

#!/bin/sh
 BINDIR=$(dirname "$(readlink -fn "$0")")
 cd "$BINDIR"
 java -Xmx1024M -jar craftbukkit-1.6.2.jar -o true

Here's the output though, being run from /home/ra/.minecraft/Bukkit:

ra@ra-desktop:~/.minecraft/Bukkit$ bash start.sh
start.sh: line 2: /home/ra/.minecraft/Bukkit: is a directory
03:43:47 [INFO] Starting minecraft server version 1.6.2
03:43:47 [INFO] Loading properties
03:43:47 [INFO] Default game type: SURVIVAL
03:43:47 [INFO] Generating keypair
03:43:47 [INFO] Starting Minecraft server on *:25565
03:43:47 [INFO] This server is running CraftBukkit version git-Bukkit-1.5.2-R1.0-35-g4176258-b2823jnks (MC: 1.6.2) (Implementing API version 1.6.2-R0.1-SNAPSHOT)
03:43:47 [INFO] Preparing level "FunInTheHELL"
03:43:48 [INFO] Preparing start region for level 0 (Seed: 8440585574752452648)
03:43:49 [INFO] Preparing spawn area: 9%
03:43:50 [INFO] Preparing spawn area: 22%
03:43:50 [INFO] ----- Bukkit Auto Updater -----
03:43:50 [INFO] It appears that you're running a Development Build, when you've specified in bukkit.yml that you prefer to run Recommended Builds.
03:43:50 [INFO] If you would like to be kept informed about new Development Build releases, it is recommended that you change 'preferred-channel' in your bukkit.yml to 'dev'.
03:43:50 [INFO] With that set, you will be told whenever a new version is available for download, so that you can always keep up to date and secure with the latest fixes.
03:43:50 [INFO] If you would like to disable this warning, simply set 'suggest-channels' to false in bukkit.yml.
03:43:50 [INFO] ----- ------------------- -----
03:43:51 [INFO] Preparing spawn area: 37%
03:43:52 [INFO] Preparing spawn area: 47%
03:43:53 [INFO] Preparing spawn area: 59%
03:43:54 [INFO] Preparing spawn area: 74%
03:43:55 [INFO] Preparing spawn area: 93%
03:43:56 [INFO] Preparing start region for level 1 (Seed: 8440585574752452648)
03:43:57 [INFO] Preparing spawn area: 16%
03:43:58 [INFO] Preparing spawn area: 28%
03:43:59 [INFO] Preparing spawn area: 48%
03:44:00 [INFO] Preparing spawn area: 69%
03:44:01 [INFO] Preparing spawn area: 90%
03:44:01 [INFO] Preparing start region for level 2 (Seed: 8440585574752452648)
03:44:02 [INFO] Preparing spawn area: 50%
03:44:03 [INFO] Server permissions file permissions.yml is empty, ignoring it
03:44:03 [INFO] Done (15.852s)! For help, type "help" or "?"
>stop
03:44:39 [INFO] CONSOLE: Stopping the server..
03:44:39 [INFO] Stopping server
03:44:39 [INFO] Saving players
03:44:39 [WARNING] DSCT: Socket closed
03:44:39 [INFO] Saving worlds
03:44:39 [INFO] Closing listening thread
03:44:39 [INFO] Saving chunks for level 'FunInTheHELL'/Overworld
03:44:40 [INFO] Saving chunks for level 'FunInTheHELL_nether'/Nether
03:44:40 [INFO] Saving chunks for level 'FunInTheHELL_the_end'/The End

… and here's the output run from any other directory:

ra@ra-desktop:~/[literally-anywhere]$ bash ~/.minecraft/Bukkit/start.sh
/home/ra/.minecraft/Bukkit/start.sh: line 2: /home/ra/.minecraft/Bukkit: is a directory
03:51:44 [INFO] Starting minecraft server version 1.6.2
03:51:44 [INFO] Loading properties
03:51:44 [WARNING] server.properties does not exist
03:51:44 [INFO] Generating new properties file
03:51:44 [INFO] Default game type: SURVIVAL
03:51:44 [INFO] Generating keypair
03:51:44 [INFO] Starting Minecraft server on *:25565
03:51:45 [INFO] This server is running CraftBukkit version git-Bukkit-1.5.2-R1.0-35-g4176258-b2823jnks (MC: 1.6.2) (Implementing API version 1.6.2-R0.1-SNAPSHOT)
03:51:45 [WARNING] Failed to load operators list: java.io.FileNotFoundException: ./ops.txt (No such file or directory)
03:51:45 [WARNING] Failed to load white-list: java.io.FileNotFoundException: ./white-list.txt (No such file or directory)
03:51:45 [INFO] Preparing level "world"
03:51:45 [INFO] Preparing start region for level 0 (Seed: 103591942867456033)
03:51:45 [INFO] ----- Bukkit Auto Updater -----
03:51:45 [INFO] It appears that you're running a Development Build, when you've specified in bukkit.yml that you prefer to run Recommended Builds.
03:51:45 [INFO] If you would like to be kept informed about new Development Build releases, it is recommended that you change 'preferred-channel' in your bukkit.yml to 'dev'.
03:51:45 [INFO] With that set, you will be told whenever a new version is available for download, so that you can always keep up to date and secure with the latest fixes.
03:51:45 [INFO] If you would like to disable this warning, simply set 'suggest-channels' to false in bukkit.yml.
03:51:45 [INFO] ----- ------------------- -----
03:51:46 [INFO] Preparing spawn area: 8%
03:51:47 [INFO] Preparing spawn area: 22%
03:51:48 [INFO] Preparing spawn area: 34%
03:51:49 [INFO] Preparing spawn area: 45%
03:51:50 [INFO] Preparing spawn area: 56%
03:51:51 [INFO] Preparing spawn area: 65%
03:51:52 [INFO] Preparing spawn area: 74%
03:51:53 [INFO] Preparing spawn area: 84%
03:51:54 [INFO] Preparing spawn area: 93%
03:51:55 [INFO] Preparing start region for level 1 (Seed: 103591942867456033)
03:51:56 [INFO] Preparing spawn area: 22%
03:51:57 [INFO] Preparing spawn area: 40%
03:51:58 [INFO] Preparing spawn area: 58%
03:51:59 [INFO] Preparing spawn area: 76%
03:52:00 [INFO] Preparing spawn area: 93%
03:52:01 [INFO] Preparing start region for level 2 (Seed: 103591942867456033)
03:52:02 [INFO] Preparing spawn area: 53%
03:52:03 [INFO] Done (17.802s)! For help, type "help" or "?"

Shouldn't this keep any population in the Bukkit dir?

share|improve this question
    
Can you post the output from the command you use to start the servers? That would give us a better indication of what's going on. –  MBraedley Aug 2 '13 at 20:39
    
The command seems to complete properly, but I'm not sure what's happening, because like I said the Bukkit directory is SUPPOSED to be populating, but it's populating my home directory with the bukkit files/subdirectories. Here's the output though, being run from /home/ra/.minecraft/Bukkit and here's the output run from any other directory Also, my start.sh looks like this now. Shouldn't this keep any population in the Bukkit dir? –  darbargar Aug 3 '13 at 7:57
    
The first line in the output seems suspicous. Try with a fixed path to cd into. –  Maerlyn Aug 4 '13 at 8:12
1  
Oddly the name of the jar file you are executing doesn't exist (according to the output of your ls above). I assume this is a typo, and that you aren't somehow executing another jar in a different directory? –  Bryan Aug 7 '13 at 17:46
    
Are you double-clicking this I a graphical interface to run this? That will mess with your working directory.this should be run in the terminal within the Bukkit directory. –  SevenSidedDie Aug 14 '13 at 18:24
show 3 more comments

2 Answers 2

According to the log output it at least tries to generate the files just fine. Could it be that it is creating the files in a different location? Try this to find out:

    cd /
    find . -name "*FunInTheHELL*" -print

Depending on the size of your HDD, it might take a while for the command to finish.

share|improve this answer
    
Wouldn't find ~/ -name "*FunInTheHELL*" -print make more sense? It's not going to have permission to write anywhere else. –  SevenSidedDie Aug 14 '13 at 18:36
    
It isn't generating them anywhere, it's just generating the default (world 1, etc) in my home directory. –  darbargar Aug 14 '13 at 19:52
add comment

There is an error in your BINDIR expression: you're using readlink incorrectly. From the man page for readlink:

If the given argument is not a symbolic link, readlink will print nothing and exit with an error.

So what you're feeding to dirname is an empty string, resulting in BINDIR being set to the empty string, which makes cd change to your home directory. You can confirm this by commenting out the java line and adding a line reading pwd just before it.

Change it to:

#!/bin/sh
 BINDIR=$(dirname "$0")
 cd "$BINDIR"
 pwd
 java -Xmx1024M -jar craftbukkit-1.6.2.jar -o true

… and it should work. Lesson: don't uncomment the "execution" line of a script until you've confirmed your cds are working correctly!

share|improve this answer
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.