30$ REQ: Help to setup a ramdisk init script on Debian Linux

Discussion in 'Bukkit Help' started by SupaYoshi, Feb 19, 2012.

Thread Status:
Not open for further replies.
  1. Offline

    SupaYoshi

    Hello everyone, I am having some major problems getting my server to work on a ramdisk, I just keep doing things wrong and it is starting to confuse and misunderstand it more and more.

    Where I'm usually quite good with startup scripts, this ramdisk thing has been a real issue for me since 2 days. I'm trying all sort of different scripts for init.d, they all seem to work, however none can load craftbukkit.jar, I get 100 different type of advices, Google isn't helping me so I am seriously asking to help me on this Init script for Linux, since I am just to new to it to do it myself.


    What I did so far:
    I have managed to set-up an Ramdisk, with a specific folder, using the following guide:
    http://www.minecraftwiki.net/wiki/Tutorials/Ramdisk_enabled_server
    Doing this

    Code:
    Firstly, start by creating a directory for the ramdisk in your home directory, i.e. "/home/username/minecraft_ramdisk".
    To mount it as a ramdisk, simply edit your /etc/fstab/ file:
    sudo nano /etc/fstab
    Then add this line, making sure that the path is correct (username, dir name etc.)
    tmpfs  /home/username/minecraft_ramdisk tmpfs  defaults,size=512m      0      0
    The size of the ramdisk MUST be larger than the minecraft directory world. Make sure that you give yourself some overhead.
    Restart your computer. The ramdisk will now be loaded every time you restart. If you wish to load immediately, type
    mount -t tmpfs none /home/username/minecraft_ramdisk -o size=512m
    It's now a matter of simply running a modified script that loads the files on the drive onto the server, copies them back on a timely basis to prevent data loss, and does backups. Again, this is a modified version of the script found at Aimless Bits.
    Modified ofcourse to my amoun of RAMDISK size, and that is working very well.

    However here comes my tricky part / the part I am having a hard time on.
    The part where I need to set-up the script to run and do specific tasks, as start, stop, backup, status, restart, disksaverun etc.

    That works all fine when I use the script from http://www.minecraftwiki.net/wiki/Tutorials/Ramdisk_enabled_server

    However I do not have access to a "screen" from linux with that script, as far as I was not able to do it atleast using that script.
    And it loads the whole directory, including worldmap, craftbukkit.jar itself, etc. into the RAMDISK, where I just want to get the following files and directories in the RAMDISK:

    - plugins directory
    - worlds directories
    - orebfusctater cache directory
    - server.log file
    - lib directory

    I do not need the craftbukkit.jar in the RAMDISK, i heard this isn't need to be loaded on the RAMDISK, because it's only needed once. (Tell me if they are wrong, or I am wrong)

    I have been using the following scripts so far to achieve the loading / starting of craftbukkit into the ramdisk so far:

    1. http://www.minecraftwiki.net/wiki/Tutorials/Ramdisk_enabled_server
    2. http://forums.bukkit.org/threads/admin-linux-init-script-for-bukkit.53235/
    The problem I have here is that the server starts but all sort of things are going wrong. I think it has to do with the way I had setup the symbolic links they describe in their tutorial.
    https://github.com/Codeprogrammers/codecraft-init-script/wiki/Setup
    Also I am not very satisfied with the way this script works, its using all sort of different folders and not loading the plugins on the ramdisk, which I actually want aswell, and the orebfuscater_cache

    3. https://github.com/Ahtenus/minecraft-init
    Same as 2, but could not get this to work at all. (craftbukkit.jar would not load?)

    Please help me out I will reward you with something nice if you are interested, + alot of thanks, :)

    Normally I can quite get things to work myself, but not at this thing I'm afraid.

    Any adittional info is welcome to ask, I will provide anything you want :) I'm currently testing this at an testserver so there is nothing that can be screwed up really. :)
     
  2. Offline

    mbaxter ʇıʞʞnq ɐ sɐɥ ı

    The first one you linked, from the minecraft wiki, does work, I've used it myself in testing. That init script creates a screen on whatever account is listed as USERNAME in the config area. That's the user from which you can run the command screen -r minecraft to access the server console. Your list of things you don't want loaded is pretty much everything except craftbukkit.jar, so you don't need to worry about it, just let it load everything.

    How I'd set it up:

    Create a username minecraft and set up the server there.
    Create the ramdisk within a space the user can access.
    Configure the init script to use the username minecraft and point to those directories.
    Go!
     
Thread Status:
Not open for further replies.

Share This Page