Advertisement
Guest User

Untitled

a guest
Apr 26th, 2024
1,653
1
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 2.14 KB | None | 1 0
  1. Termux from GitHub or F-Droid
  2. AnLinux -> Dashboard -> Ubuntu
  3.  
  4. Paste the AnLinux command into Termux
  5. Once done, run ./start-ubuntu.sh
  6.  
  7. Run these commands one after another
  8.  
  9. apt update
  10. apt-get clean
  11. apt-get install -y build-essential
  12. apt-get install software-properties-common
  13. add-apt-repository ppa:openjdk-r/ppa
  14. apt-get update
  15. apt-get install openjdk-8-jre
  16. apt-get install openjdk-21-jdk
  17.  
  18. wget -O minecraft_server.jar (link to the file)
  19. ** do note that you can use a link to Paper, or Spigot, or whatever else, just replace the name and the link, for example, "wget -O paper-1.20.4-496.jar (link to paper 1.20.4)"
  20.  
  21.  
  22. chmod +x minecraft_server.jar
  23. ** if you used paper or whatever else, change "minecraft_server.jar" to whatever else you used, for example, "chmod +x paper-1.20.4-496.jar"
  24.  
  25. java -Xmx(RAM AMOUNT) -Xms (RAM AMOUNT) -jar minecraft_server.jar nogui
  26. ** if you used paper or whatever else, change "minecraft_server.jar" to whatever else you used, for example, "java -Xmx(RAM AMOUNT) -Xms (RAM AMOUNT) -jar paper-1.20.4-496.jar nogui"
  27.  
  28. Let it run and show the EULA warning
  29.  
  30. apt install nano
  31. nano eula.txt
  32.  
  33. Then run java -Xmx(RAM AMOUNT) -Xms (RAM AMOUNT) -jar minecraft_server.jar nogui again
  34.  
  35. It should be working now, do note that **this tutorial does not show port forwarding and how to show with friends, this is a completely local server**
  36.  
  37. If you want to host this server publicly, I used ngrok for it. Use the ARM64 Linux build
  38. https://ngrok.com/download
  39.  
  40. Swipe right from the left side of the device on Termux (like -> this way from the left edge of your device) to bring up the sessions menu, start a **new** session while your server is running
  41.  
  42. wget -O ngrok.tgz (link)
  43. tar zxvf ngrok.tgz
  44.  
  45. Then register for an account on ngrok, copy your authentication token, and run the command
  46.  
  47. ./ngrok authtoken (auth token from ngrok site)
  48.  
  49. Then once it's configured
  50.  
  51. ./ngrok tcp 25565
  52.  
  53. Your Minecraft Server IP will be under "forwarding". You may need to rotate your device to see the full link. for example, mine could be 8.tcp.us-cal-1.ngrok.io:12345, that's the public server IP. It will change if you close ngrok!
  54.  
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement