Install Steam
login
|
language
简体中文 (Simplified Chinese)
繁體中文 (Traditional Chinese)
日本語 (Japanese)
한국어 (Korean)
ไทย (Thai)
Български (Bulgarian)
Čeština (Czech)
Dansk (Danish)
Deutsch (German)
Español - España (Spanish - Spain)
Español - Latinoamérica (Spanish - Latin America)
Ελληνικά (Greek)
Français (French)
Italiano (Italian)
Bahasa Indonesia (Indonesian)
Magyar (Hungarian)
Nederlands (Dutch)
Norsk (Norwegian)
Polski (Polish)
Português (Portuguese - Portugal)
Português - Brasil (Portuguese - Brazil)
Română (Romanian)
Русский (Russian)
Suomi (Finnish)
Svenska (Swedish)
Türkçe (Turkish)
Tiếng Việt (Vietnamese)
Українська (Ukrainian)
Report a translation problem
For your Linux VM
6 cores ( you can try 7 and 8 cores but they typically don't get touched.)
16gb ram (32 gb + for full 32 players , rule of thumb 1gb per user.)
8-16gb swap
60 gb drive space
/etc/sysctl.conf
bottom of file
vm.swappiness=10
vm.vfs_cache_pressure=50
Also note invasions have a huge memory leak.
bEnableInvaderEnemy=false turns off raids , if you want raids, set up a cron job to reboot the server every 6 - 24 hours .
The server easely uses about 8GB of RAM or more when peoplare are actively playing on it (tested with 4 players). Memory leak issue is compounding this and makes it use more and more RAM over time.
If the server hits its RAM limit, it will just stop without any warning.
Thank you.
Can you elaborate what those 2 config changes do? (i am not an strong linux user :/)
ALso sadly seams that the first part is going to be impossible for me then as my poor servers CPU only has 4 cores.
VM cache pressure is a measure of how much pressure the kernel is under to free up memory used for caching directory and inode objects
swappiness value to 10, which means that the swap file will only be used when the RAM usage is around 80-90%
You can use 4 cores minimum but I wouldn't go beyond 10 players maximum. I would reboot the server every 4-6 hours to make your life not a living hell
Now, the game does appear to have a memory leak on the server side. Sometimes it will be fine, but other times you need to reboot it every 8-10 hrs as the memory will continue to increase.
Now I did try hosting this off a 4 vcore VPS and for whatever reason the memory leak on Linux is WAYYYY worse than windows.
Thank you for going into details on those configs.
I have made it a point to restart the server atleast once a day. It has been rubber banding and lagging from the get go and restarts doesn't seam to help all that much. It thing i've noticed is that giving more RAM just delayed the inevitable crash from the leak catching up to the memory cap. (I really need to setup an automated restart task at some point)
Yeah... we could last for maybe 6 hours with 12GB of RAM. so i just said ef it and gave it 22. Now it will last a day before it NEEDs are restart.
Setting up a cronjob to reboot the server, you can do this with
sudo crontab -e
Paste this at the bottom
0 */6 * * * /sbin/shutdown -r now (this would be every 6 hours dont put the stuff in brackets in the cron job )
I am using LGSM for hosting the server (easier to setup for a linux noob like me) and it makes it easier to setup cron jobs for restarts. More or less just have to tell it to write 1 command (./pwserver restart) and done. I've just been putting it off because for now, manual restarting works fine (ish) and i have not read up on how to setup the cronjob correctly yet.
sudo nano /etc/systemd/system/palworld.service
[Unit]
Description=Palworld Server
Wants=network-online.target
After=network-online.target
[Service]
RuntimeMaxSEc=86400
Type=simple
Restart=always
RestartSec=30s
MemoryMax=12G
User=userid
WorkingDirectory=/homeuserid/
ExecStartPre=/usr/games/steamcmd +force_install_dir '/home/userid/Steam/steamapps/common/PalServer' +login anonymous +app_update 2394010 +quit
ExecStart=/home/userid/Steam/steamapps/common/PalServer/PalServer.sh -useperfthreads -NoAsyncLoadingThread -UseMultithreadForDS > /dev/null
Restart=always
[Install]
WantedBy=multi-user.target
User id = the user id you will run palworld as a service under.
after you save it you will want to run
sudo systemctl enable palworld
sudo systemctl start palworld
sudo systemctl status palworld <<< shows you the status of the running service if its running or if it crashed with error
restart=no | always | on-success | on-failure | on-abnormal | on-abort | on-watchdog
MemoryMax= as low as .5mb - 32G (note: lower then .5mb is going to cause issues)
understand well continue reading if you have any questions ask.. << likes linux obviously lol.
correct the memory leak is worse, hence why you should reboot more, however the server overhead in linux is way less then windows. You can actually negate the leak mostly with turning off the raid mechanic atm.
My container does not have those variables in the config file.
I see a bunch of variables for networking, but not the aforementioned ones
this is the end of the .conf file:
https://prnt.sc/skaiB9kNjZM3
You need to manually enter them in under the line
#kernel.sysreq=438