User Tools

Site Tools


morelore:server-pack

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revisionPrevious revision
Next revision
Previous revision
morelore:server-pack [2023/05/28 15:21] – Update server pack problems AnarchyOf5morelore:server-pack [2025/11/09 15:52] (current) AnarchyOf5
Line 1: Line 1:
 ====== How to install MoreLore on your own Server ====== ====== How to install MoreLore on your own Server ======
  
-**Update: 28 May 2023 - I am working through Curseforge's "process." The server pack is ready but they keep rejecting it for having non-Curseforge mods. SMH - it is identical with the main pack :| ... More to follow.**+** THIS TUTORIAL IS FOR LINUX ONLY **
  
-Eventually I plan to release a proper server pack, but until then use these steps to get up and running.+===== Downloading and Installing NeoForge =====
  
-===== Fabric Server Installer =====+Download the correct version of Neoforge for the version of the pack you want to run. Neoforge version is listed in the [[morelore:changelog|changelog]]. The Neoforge installer can be downloaded from [[https://neoforged.net/|here]]. Make sure you select the correct version of Minecraft and Neoforge in the drop down menu at the top of the page. You will download a JAR file that is named something like: 
  
-  Create an empty folder to hold your pack (you can name it whatever you like) +<code>neoforge-21.1.209-installer.jar</code>
-  Download the latest Fabric server installer following the instructions [[https://fabricmc.net/use/server/|here]]. You will receive a .jar file after you are finished. This file is the one you need to start your modded MoreLore server instance. Place this file in your newly created folder. +
-  - Fortunately, MoreLore mods all work (or disable themselves as they should) in a server pack. So all you need to do is create a local client instance using your favorite launcher i.e. Curseforge, ATLauncher etc. +
-  - Copy over the following folders from the client instance, into your newly created server folder: +
-    * mods +
-    * config +
-    * kubejs+
  
-===== Start and Stop Script =====+You will need to SCP/SFTP/FTP this up to your server (outside the scope of this article). One you have it on your server run: 
  
-To automate the process of starting and stopping your server, you can use the following bash code as a referenceIf you are hosting this on a dedicated Linux server, I recommend using either ''screen'' or ''tmux'' to run the game in the backgroundThis will allow you to ssh in and attach/detach from the current game session without the server shutting down.+<code>java -jar neoforge-21.1.209-installer.jar</code>
  
-  #!/bin/sh +This will create the server.jar and the run.sh files you will need to start your server.
-  # More Lore Enhanced Vanilla Server Startup Script +
-   +
-  # Edit the below values to change JVM Arguments or Allocated RAM for the server+
-  ALLOCATED_RAM="8G" +
-  JVM_ARGUMENTS="-XX:+UseG1GC -XX:+UnlockExperimentalVMOptions -XX:MaxGCPauseMillis=100 -XX:+DisableExplicitGC -XX:TargetSurvivorRatio=90 -XX:G1NewSizePercent=50 -XX:G1MaxNewSizePercent=80 -XX:G1MixedGCLiveThresholdPercent=50 -XX:+AlwaysPreTouch" +
-  FILE="./fabric-server-mc.1.19.2-loader.0.14.17-launcher.0.11.2.jar" +
-   +
-  # Start server. +
-  echo "Starting MoreLore Server." +
-  java -jar -Xms${ALLOCATED_RAM} -Xmx${ALLOCATED_RAM} ${JVM_ARGUMENTS} ${FILE} nogui +
-  echo "Server shutting down on $(date)."+
  
-You can save this code into a file named whatever you want with a ''.sh'' extension. Make sure to make it executable using the following command (on Linux)+===== Uploading Pack =====
  
-  chmod +x YourFile.sh +The client pack can be safely uploaded, using the same method you used to get the installer jar on your server. Make sure to remove the following mods:
-   +
-After that you are good to go! Keep in mind that if you run this is an active shell, the server will stop when you close that shell/terminalAs mentioned above, you can use the GNU Screen utility to create a specific "virtual terminal session" using something like this:+
  
-  screen -S Minecraft+  * Entity Texture Features 
 +  * Freecam
  
-This will create a new session called minecraft and pop you in itThen run shell script to start the server:+These mods are client side only and will cause an error if you try to run the serverOnce removed, you can run the server by entering the following command./run.sh
  
-  ./YourFile.sh+This will create your world and start your server.
  
-As it boots up, you can "detach" from the running session using ''Control + A + D''+===== Persisting Server in Background =====
  
-To return to you session in the future you can use:+This will require you to be logged in to stay running. Obviously, we don't want that. So, we can use either TMUX or Screen to create a special terminal session that will persists, even after you logout of your ssh session. For example, you can create a TMUX session using the following:
  
-  screen -R Minecraft+<code>tmux new-session -t morelore</code> 
 + 
 +This will pop you into a TMUX session named morelore. From here, start your server using the command above and the hit CTRL + ALT then B to detach from the session. You can now safely log out and your server will stay running. We recommend restarting your server at least once a day. You can automate this using a cronjob, which you can set as you need. here's a basic restart script to get you started. It runs a 5 minute countdown timer and messages players in-game giving them a head's up a restart is about to happen. 
 + 
 +<code> 
 +#!/usr/bin/bash 
 +# 5 Minute count down and restart 
 +tmux send-keys -t morelore:0.0 'tellraw @a {"text": "Restarting in 5 minutes", "color":"red"}' ENTER 
 +sleep 1m 
 +tmux send-keys -t morelore:0.0 'tellraw @a {"text": "Restarting in 4 minutes", "color":"red"}' ENTER 
 +sleep 1m 
 +tmux send-keys -t morelore:0.0 'tellraw @a {"text": "Restarting in 3 minutes", "color":"red"}' ENTER 
 +sleep 1m 
 +tmux send-keys -t morelore:0.0 'tellraw @a {"text": "Restarting in 2 minutes", "color":"red"}' ENTER 
 +sleep 1m 
 +tmux send-keys -t morelore:0.0 'title @a subtitle {"text":"Get ready!","color":"red","italic":true}' ENTER 
 +tmux send-keys -t morelore:0.0 'title @a title {"text":"Server Restart","bold":true}' ENTER 
 +tmux send-keys -t morelore:0.0 'tellraw @a {"text": "Restarting in 1 minute!", "color":"red"}' ENTER 
 +sleep 1m 
 +tmux send-keys -t morelore:0.0 'stop' ENTER 
 +</code> 
 + 
 +Keep in mind, the cronjob should be set for the non-admin user that is running your server! TMUX sessions are unique to the user that starts them.
  
 If everything goes smooth, you should now have a working MoreLore server to play on with your friends! Congratulations. If everything goes smooth, you should now have a working MoreLore server to play on with your friends! Congratulations.
morelore/server-pack.1685287281.txt.gz · Last modified: by AnarchyOf5