Help: Setting up, running, and maintaining a server
Re: Help: Setting up, running, and maintaining a server
If it works inside a LAN then your server is ok. Now if you want it to work over the internet you have to forward the port that your minetest server listens to (by default is 30000), to your server (your computer). Look up the name of your router + port forwarding on the internet.
Then you have to give your friends your internet IP address, which you can see on your router or on an IP address detection website.
Then you have to give your friends your internet IP address, which you can see on your router or on an IP address detection website.
- r1bnc
- Member
- Posts: 38
- Joined: Mon Dec 23, 2019 07:57
- GitHub: r1bnc
- IRC: r1bnc
- In-game: r1bnc
- Location: Philippines
- Contact:
Re: Help: Setting up, running, and maintaining a server
This may be not related but i still don't know where to ask. In the server list it shows player names, is there an official way to scrape those details? im trying to make a histograph of players that play at specific time of day on a particuler server.
cdb_4afce6e9210a
twitch.tv/r1bnc
twitch.tv/r1bnc
- Festus1965
- Member
- Posts: 4181
- Joined: Sun Jan 03, 2016 11:58
- GitHub: Festus1965
- In-game: Festus1965 Thomas Thailand Explorer
- Location: Thailand ChiangMai
- Contact:
Re: Help: Setting up, running, and maintaining a server
You mean a gamer named "Thomas" follow over different servers, playing during a day ?
If that, so imagine as me cant play with Thomas every-way ... special Thomas has 5 people at MT and so I use 3 different names already.
But anyway, interesting - good luck.
Human has no future (climate change)
If urgend, you find me in Roblox (as CNXThomas)
If urgend, you find me in Roblox (as CNXThomas)
Re: Help: Setting up, running, and maintaining a server
There is a way to access the information on servers.minetest.net in a json format so you can parse what you need, however I don't know how that goes, maybe someone else here knows how to do that. Also remember that the server list doesn't get updated information about a server quickly if said server has a slow connection, so you might lose some data, if you have access to the server you want to get data from it's better to use the logs.
- FrostRanger
- Member
- Posts: 80
- Joined: Thu Oct 11, 2018 05:40
- GitHub: WulftheNordicRanger
- IRC: FrostRanger FrostRanger[m]
- In-game: FrostRanger FrostStar
- Location: In the untamed wilderness of wherever I happen to be dimension hopping this time...
- Contact:
Re: Help: Setting up, running, and maintaining a server
T6C wrote: ↑Sat Nov 28, 2020 17:06I'm already running into an issue. For starters, if anyone's trying to install the most up-to-date, stable minetest-server onto an Ubuntu 20.04 machine, you must do these steps first (make sure you're fully updated before you begin).This is the point where I'm running into problems. I tried to install minetest-server, and I got this error.
- In a terminal add the buster-backports repository to the sources list. You can create a new file under /etc/apt/sources.list.d or add it to /etc/apt/sources.list. The new entry in the file should look like this.
Code: Select all
deb http://deb.debian.org/debian buster-backports main
- Add the public keys for buster-backports to the apt catalogue.
Code: Select all
user@host:~$sudo apt-key adv --keyserver keyserver.ubuntu.com --recv-keys 04EE7237B7D453EC user@host:~$sudo apt-key adv --keyserver keyserver.ubuntu.com --recv-keys 648ACFD622F3D138
- Run sudo apt update, and perform an upgrade, if required (it will tell you if upgrades are available).
- Add the buster-backports version of minetest to your apt preferences. Go to /etc/apt/preferences.d, and create a new file. I used the filename 99debian-backports. Enter these as the entries in the file.
Code: Select all
Package: minetest Pin: release a=buster-backports Pin-Priority: 900 Package: minetest-data Pin: release a=buster-backports Pin-Priority: 900 Package: minetest-server Pin: release a=buster-backports Pin-Priority: 900
That dependency is not in the buster-backports repository, or any Ubuntu repository that is installed with 20.04, and it's not one of the dependencies that were required when I installed the Minetest client on my laptop several months ago. How do I get this dependency? Do I need to add the buster repository, too, or is there an Ubuntu repository I should use, instead? I found a package called libspatialindex-dev, but I don't think apt will accept that as a substitute for libspatialindex5.Code: Select all
The following packages have unmet dependencies: minetest-server : Depends: libspatialindex5 (>= 1.8.5) but it is not installable
Do I need to install the minetest and minetest-data packages with minetest-server? I won't be actually playing the game on the server; users will log in from their own remote clients. How do I create and set up a world on the server if it has no GUI and no minetest client; is that done through minetest.conf, too (e.g., mg type, seed, etc.)?
Ik this post is old, but I just wanted to clear this up for anyone who is trying to install the latest version of Minetest on Ubuntu, Do not use the buster backports, use the minetest ppa's instead
https://launchpad.net/~minetestdevs/+ar ... ntu/stable
https://launchpad.net/~minetestdevs/+ar ... ily-builds
Those are the links to the stable and unstable ppa's respectively. There are instructions on how to add them to your system on the site. I have no idea if using the buster backports will break anything, but it's probably easier to just use the official ppa in any case
I would also like to point out that installing the minetest server package is mostly redundant anyways as you can start the regular client in server mode my doing
systemctl start minetest.service
The advantage of just using the regular client in server mode is that you can run a server using the latest version of minetest where if you use the minetest server package you will be stuck at 5.0. This site does a pretty good job of explaining how to properly set up a server on ubuntu for anyone interested https://www.vultr.com/docs/how-to-setup ... untu-17-04 Again, this post is more directed at random forum goers rather than T6C as I am aware that this post is several months old.
Sole ranger and ruler of the frozen realms of Cabin Fever and seeker of the ever elusive Dungeon Master...
Re: Help: Setting up, running, and maintaining a server
Thanks for posting this. The reason I went with the buster backports repository was because I couldn't find minetest-server in the ubuntu PPAs, and I couldn't find the dependencies, either. Now I know better.FrostRanger wrote: ↑Sat Feb 20, 2021 03:53Ik this post is old, but I just wanted to clear this up for anyone who is trying to install the latest version of Minetest on Ubuntu, Do not use the buster backports, use the minetest ppa's instead
https://launchpad.net/~minetestdevs/+ar ... ntu/stable
https://launchpad.net/~minetestdevs/+ar ... ily-builds
I have questions about this. I was under the impression that it's better to run minetest-server, rather than minetest client, when the machine was a dedicated Minetest server. I'm running my Minetest server on AWS, so I don't have access to a GUI, only the terminal. You mention a terminal command for running the client in server mode, but does this use more system resources than running minetest-server? How would I log in as the server admin to do things like grant privileges, give items, etc., if the server is running in the client, and I don't have access to the server's GUI (it might not even have a GUI)?FrostRanger wrote: ↑Sat Feb 20, 2021 03:53I would also like to point out that installing the minetest server package is mostly redundant anyways as you can start the regular client in server mode my doing
systemctl start minetest.service
The advantage of just using the regular client in server mode is that you can run a server using the latest version of minetest where if you use the minetest server package you will be stuck at 5.0.
My post several months ago was from the standpoint of a complete beginner to servers (I'm still a complete beginner, imho), and I was trying to help other newbies avoid the issues I was having. If I have an Ubuntu server in AWS Lightsail, and I want to use it to host a Minetest game, what's the best way to go about that? Using the client in server mode, or using minetest-server? The server instructions I followed only mentioned the client in passing, which is why I went with minetest-server.
Re: Help: Setting up, running, and maintaining a server
The difference between the minetest-server package and the minetest package is that minetest-server is compiled with only the server component so you cannot use it as a client and it automatically registers a systemd service along with a configuration file for the server to start running it quickly and easily.
On the other hand, the minetest package is compiled with both the client and server and thus should have a bigger size, but the difference is not that much I believe. This package doesn't include a systemd service neither a server configuration file so you have to make those yourself or run the server manually from a commant. For example, to run it as a server you would issue this command: minetest --server --world /path/to/world --config /path/to/config/file --logfile /path/to/logfile
This is more troublesome because you have to take the configuration file from somewhere else or make it from scratch. The minetest-server package was made to allow a server to be setup more easily.
You can take a look at the options the minetest program has in its manpage. In a computer with minetest client installed you can issue: man minetest
EDIT: corrected grammar and added logfile parameter
On the other hand, the minetest package is compiled with both the client and server and thus should have a bigger size, but the difference is not that much I believe. This package doesn't include a systemd service neither a server configuration file so you have to make those yourself or run the server manually from a commant. For example, to run it as a server you would issue this command: minetest --server --world /path/to/world --config /path/to/config/file --logfile /path/to/logfile
This is more troublesome because you have to take the configuration file from somewhere else or make it from scratch. The minetest-server package was made to allow a server to be setup more easily.
You can take a look at the options the minetest program has in its manpage. In a computer with minetest client installed you can issue: man minetest
EDIT: corrected grammar and added logfile parameter
- FrostRanger
- Member
- Posts: 80
- Joined: Thu Oct 11, 2018 05:40
- GitHub: WulftheNordicRanger
- IRC: FrostRanger FrostRanger[m]
- In-game: FrostRanger FrostStar
- Location: In the untamed wilderness of wherever I happen to be dimension hopping this time...
- Contact:
Re: Help: Setting up, running, and maintaining a server
The method you use to access the server doesn't change at all regardless of which method you use. You still have to set up an admin account on the server either way and you would log in as usual to do routine tasks. As far as back end stuff goes, you shouldn't need a gui at all. You'd just ssh into the machine and do what you need to do which does not change at all regardless of the method you choseT6C wrote: ↑Thu Mar 04, 2021 23:53I have questions about this. I was under the impression that it's better to run minetest-server, rather than minetest client, when the machine was a dedicated Minetest server. I'm running my Minetest server on AWS, so I don't have access to a GUI, only the terminal. You mention a terminal command for running the client in server mode, but does this use more system resources than running minetest-server? How would I log in as the server admin to do things like grant privileges, give items, etc., if the server is running in the client, and I don't have access to the server's GUI (it might not even have a GUI)?
Either one is fine, but using the client means that you will have access to newer versions. Yes, you do have to create a minetest.conf file and set a systemd process but those things are trivial to do. It honestly shouldn't matter too much as long as your vps isn't a complete potato.T6C wrote: ↑Thu Mar 04, 2021 23:53My post several months ago was from the standpoint of a complete beginner to servers (I'm still a complete beginner, imho), and I was trying to help other newbies avoid the issues I was having. If I have an Ubuntu server in AWS Lightsail, and I want to use it to host a Minetest game, what's the best way to go about that? Using the client in server mode, or using minetest-server? The server instructions I followed only mentioned the client in passing, which is why I went with minetest-server.
Sole ranger and ruler of the frozen realms of Cabin Fever and seeker of the ever elusive Dungeon Master...
Re: Help: Setting up, running, and maintaining a server
I totally agree, pls, help us and update tutorial how to setup linux server from snap package. Please, somebody.Rayjack wrote: ↑Fri Jul 10, 2020 23:08I don't think the Linux section in the "Setting up a server, Minetest Wiki" is up to date. I think I go to Home/snap/minetest/ .... what do I do from there to set up a dedicated server. I have folders 1619, common, and current. FYI I spun up a droplet on digital ocean running Ubuntu 20.04, installed the Ubuntu desktop, then installed minetest 5.3 (a snap package) from the ubuntu software center ... so I have everything ready to go ... I just need current documentation on where to go to set up a dedicated minetest server from here. Thank you.
Thank you
Re: Help: Setting up, running, and maintaining a server
Hi, I made a tutorial on youtube before I backed off of using youtube ... if this helps, this is how I currently set up a server https://youtu.be/c7D3aK-8rew
Re: Help: Setting up, running, and maintaining a server
In my case it looks like this:
/snap/minetest/current
and here are subdirectories:bin, etc, lib, meta, share, snap, usr
and file: launcher
then there is other snap directory in my home folder:
/home/test/snap/minetest/current
in which are: mods, worlds, debug.txt and minetest.conf
How to setup server, pls?
Now I can run server from minetest only (with gui...)
My linux distro is Manjaro.
Thank you for help.
/snap/minetest/current
and here are subdirectories:bin, etc, lib, meta, share, snap, usr
and file: launcher
then there is other snap directory in my home folder:
/home/test/snap/minetest/current
in which are: mods, worlds, debug.txt and minetest.conf
How to setup server, pls?
Now I can run server from minetest only (with gui...)
My linux distro is Manjaro.
Thank you for help.
Re: Help: Setting up, running, and maintaining a server
Oh, I missed this post. I'll take a look on it. Thanks
Re: Help: Setting up, running, and maintaining a server
I've had my AWS server running for about three weeks now. Every week it crashes, though, and I can't figure out why. I'm running a server using the new 5.4.0 client on Ubuntu 20.04 LTS. It seems to be running just fine, and then suddenly after about a week, it pegs the CPU at 100% and locks the system up. I can't even log into a terminal to kill the process, so I have to force a reboot of the server through the AWS console. Normally, the CPU hovers around 10% while I'm logged in.
The crashes seem to happen when someone is logged on, then a second person logs on, and then both people are logged in for more than about 15 minutes. I looked through the logs, and it's not giving me any indication why it does this. The last time this happened was this afternoon, and these were the final log entries before it pegged the CPU (I was AFK while a blinky plant emptied a chest into a tube from pipeworks)...
I did notice these in the log when the Minetest service restarted after reboot...
Is this normal for the Farming Redo mod? The mod seems to be working OK, so I assume this isn't what caused the crashes. Similarly, I found these for the Technic Plus mod. Again, they seem to be working OK, despite the warnings.
Finally, I found lots of warnings like these (and I do mean lots).
When I set up the server, several mods were causing the Minetest service to fail, so I disabled and removed those mods. I'm going to post in the mods' threads about those, because I really liked those, so I'm hoping for updates. But, any idea what's causing these crashes?
On a side note, I have the minetest.conf file set up to announce itself to the server list in the client, but it's not showing up in the list. I have to manually type in my server's IP address to log in. Why isn't it showing up?
The crashes seem to happen when someone is logged on, then a second person logs on, and then both people are logged in for more than about 15 minutes. I looked through the logs, and it's not giving me any indication why it does this. The last time this happened was this afternoon, and these were the final log entries before it pegged the CPU (I was AFK while a blinky plant emptied a chest into a tube from pipeworks)...
Code: Select all
ACTION[Server]: [User] takes default:cobble from chest at (-160,-11,203)
ACTION[Server]: [User] takes default:cobble from chest at (-160,-11,203)
ACTION[Server]: [User] takes default:cobble from chest at (-160,-11,203)
ACTION[Server]: [User] takes default:cobble from chest at (-160,-11,203)
ACTION[Server]: [User] takes default:cobble from chest at (-160,-11,203)
Code: Select all
WARNING[Main]: Mod name conflict detected: "farming"
WARNING[Main]: Will not load: /usr/share/minetest/games/minetest_game/mods/farming
WARNING[Main]: Overridden by: /home/minetest/.minetest/mods/farming
WARNING[Main]: Field "use_texture_alpha": Boolean values are deprecated; use the new choices
ACTION[Main]: [MOD] Mobs Redo loaded
Code: Select all
WARNING[Main]: Not registering alias, item with same name is already defined: technic:panel_concrete_bottom -> technic:panel_concrete
WARNING[Main]: Not registering alias, item with same name is already defined: technic:micro_concrete_bottom -> technic:micro_concrete
WARNING[Emerge-0]: Call to deprecated function 'get3d', please use 'get_3d' at .../.minetest/mods/technic_plus/technic_worldgen/oregen.lua:170
Code: Select all
WARNING[Main]: No craft recipe matches input
WARNING[Server]: active block modifiers took 201ms (processed 371 of 485 active blocks)
WARNING[Server]: ServerEnvironment::deactivateFarObjects(): id=3460 m_static_exists=true but static data doesn't actually exist in (-10,-64,12)
WARNING[Server]: StaticObjectList::remove(): id=3460 not found
On a side note, I have the minetest.conf file set up to announce itself to the server list in the client, but it's not showing up in the list. I have to manually type in my server's IP address to log in. Why isn't it showing up?
Re: Help: Setting up, running, and maintaining a server
Farming redo always makes the server show that warning because that mod is designed to completely override "redo" the farming mod from minetest_game, so do not worry for that.
The warnings from technic are probably a bug with item definitions that has not been fixed yet, but likely is not the cause of your problem.
Now the important part, this means that the server had 485 loaded mapblocks at that specific moment, for a server with just 2 or 3 simultaneous players that is a lot, it is not normal for a server to not let you ssh in even with 100% CPU load from userspace, because Linux handles loads very well, I suspect what happened is that you were running out of memory and your system was swapping hard (and I hope you are not running the minetest server as root, that gives it more priority than needed and is a security issue), if you have a swap file/partition and you were running out of RAM that 100% CPU load was mostly from I/O to swap, and that usually makes a Linux computer completely unusable. You might want to keep an eye at memory usage and CPU usage with top, it displays usage from userspace programs, I/O and more, that may help you determine the cause of the slowness. Also, you might find it useful to install sar, it is a program available in repositories which monitors memory/disk/CPU usage and keeps a record which you can check later, you can use it to see what resources were being exhausted at the time of the slowness.
If the problem is that you are running out of RAM you can:
a)More RAM!!
b)Set unused_data_timeout to a lower value, try with 300 for example, this requires a lot of experimentation to suit your needs, you find this setting in minetest.conf
Again, this is normal and means that [User] is taking items from a chest, in your case with an automated method (injector from technic)I did notice these in the log when the Minetest service restarted after reboot..
The warnings from technic are probably a bug with item definitions that has not been fixed yet, but likely is not the cause of your problem.
These mean that an object in block (-10,-64,12) was removed because its data does not exist, to get the real coordinates multiply those numbers by 16 (mapblock size), this may be a bug in the minetest engine or some mod, it happens quite often depending on your mods selection.WARNING[Server]: ServerEnvironment::deactivateFarObjects(): id=3460 m_static_exists=true but static data doesn't actually exist in (-10,-64,12)
WARNING[Server]: StaticObjectList::remove(): id=3460 not found
Code: Select all
WARNING[Server]: active block modifiers took 201ms (processed 371 of 485 active blocks)
If the problem is that you are running out of RAM you can:
a)More RAM!!
b)Set unused_data_timeout to a lower value, try with 300 for example, this requires a lot of experimentation to suit your needs, you find this setting in minetest.conf
In minetest.conf make sure that the server address is the same as your IP address (if your IP is static), if your IP is dynamic you have to use a DDNS service or ask your provider for an internet hostname, and make sure to set server_announce = true, if those two settings are correct it should show up in the server list.On a side note, I have the minetest.conf file set up to announce itself to the server list in the client, but it's not showing up in the list. I have to manually type in my server's IP address to log in. Why isn't it showing up?
- Festus1965
- Member
- Posts: 4181
- Joined: Sun Jan 03, 2016 11:58
- GitHub: Festus1965
- In-game: Festus1965 Thomas Thailand Explorer
- Location: Thailand ChiangMai
- Contact:
Re: Help: Setting up, running, and maintaining a server
Code: Select all
WARNING[Server]: active block modifiers took 201ms (processed 371 of 485 active blocks)
but even
* with 32 GB Ram, 25 for mt available that can happen, so most
* at start first time abm runs = don't mind
* also a 4 Core CPU with 8 Threas at 3.4-3.9 GHz it can happen ...
but
* during game: take some mods and adjust them to have less often abm with lower chance then 100%, mean when there is an mod what had interval = 1, but change only 5, (mean every second = every time abm runs, but only 20% that it will do something) ==> to interval 5 but chance 1, so it runs only every 5 second, but will do for sure (like grow of a plant)
That will reduce your abm problems a lot.
plantlife, pipeworks, moretrees, etc ... those mods which work often, with low chance ...
Another option is, when your compiling your mtserver yourself, change the time abm has from 250 ms to 333 or 500 ms, as the next round will be after 1 sec, so the abm is just using 25% of a second that cpu might have time to work it. (Somewhere in my server thread I have posted the file and the change to do)
Human has no future (climate change)
If urgend, you find me in Roblox (as CNXThomas)
If urgend, you find me in Roblox (as CNXThomas)
Re: Help: Setting up, running, and maintaining a server
I just happened to be logged into a console when the server crashed again, and I can confirm that this is exactly what is happening.
More RAM is an option, but I'll need to upgrade to a higher AWS Lightsail tier. Currently, I'm on a tier that provides 1 GB RAM. Moving to a higher tier that doubles the RAM also doubles the cost. Festus mentioned above that this problem can also occur when you have 32 GB RAM in your system, though, so I'm not sure how much it would help to increase my tier.
I tried setting the unused_data_timeout setting to 180, but it crashed even more quickly. I had that setting commented out before, so it was whatever the default setting is.
Until I get this issue fixed, my Minetest server is essentially unplayable, since it just eats more and more memory the longer it's running, until it causes the system to lock up in a fit of swapping. I never had this issue with the v5.0 minetest-server package. Any idea why? Is v5.4 really that much more resource-intensive?
On a possibly related note, I have never had a problem logging in quickly; it takes about five seconds for me. However, my friend says it's taking her five minutes to log into the server. Her computer is far more powerful than mine, so I wonder if it's because of the texture pack she's using. I'm not using any texture pack.
- Attachments
-
- Screenshot 2021-03-27 11.43.47.png (159.34 KiB) Viewed 3642 times
Re: Help: Setting up, running, and maintaining a server
Sorry, the default value for server_unused_data_timeout is 29, try with a value of 5 because you have very little RAM.
Interesting, also I had the impression that 5.4.0 uses more memory, so it may turn out to be true.
Interesting, also I had the impression that 5.4.0 uses more memory, so it may turn out to be true.
This is really difficult to answer without more information, it may be because her computer has a slow disk to load the mods, or her internet connection is slow, or maybe your server is slow.On a possibly related note, I have never had a problem logging in quickly; it takes about five seconds for me. However, my friend says it's taking her five minutes to log into the server. Her computer is far more powerful than mine, so I wonder if it's because of the texture pack she's using. I'm not using any texture pack.
Re: Help: Setting up, running, and maintaining a server
Still experiencing issues with server timeouts about twice per week. This time, I happened to catch it right as the server pegged the CPU at 100%. The Minetest log showed a lot of entries like this over the previous 20 minutes...
No one had been logged on for over 24 hours. That's why only 4 blocks were loaded. So, what's going on that it's taking nearly 2 minutes to process the ABMs? Minetest was eating only about 3% of the CPU when it suddenly decided to use 100% of the CPU cycles. Also, this usually happens at 3 AM when no one is ever logged in. It just happened to occur at 5 PM this time.
I looked at the Ubuntu system logs in /var/log, and the only indication of something going wrong are these same log entries from minetest.service. Nothing in crontabs indicates a problem when this normally occurs at 3 AM.
Edit: Here's a screenshot of what the episodes look like in the CPU utilisation. It's running fine until suddenly...
Code: Select all
2021-05-07 22:25:24: WARNING[Server]: active block modifiers took 101627ms (processed 1 of 4 active blocks)
I looked at the Ubuntu system logs in /var/log, and the only indication of something going wrong are these same log entries from minetest.service. Nothing in crontabs indicates a problem when this normally occurs at 3 AM.
Edit: Here's a screenshot of what the episodes look like in the CPU utilisation. It's running fine until suddenly...
- Attachments
-
- Screenshot 2021-05-07 19.47.27.png (56.31 KiB) Viewed 3642 times
Re: Help: Setting up, running, and maintaining a server
I suggest installing the sar package (system activity reporter), then wait until the issue happens again, and check the reports from sar to see what was the CPU/RAM/Disk I/O usage at the time of the incident. I still believe you are running out of RAM, but with sar you can know which resource was being exhausted.
Re: Help: Setting up, running, and maintaining a server
I'll install that tool and see what it says. I have the server_unused_data_timeout set to 3 in the minetest.conf file, so it's already about as low as it can go. Not sure how else to save RAM usage without slashing mods. Unfortunately, I'm using them all to some degree, so removing one would almost certainly break the world. :(Minix wrote: ↑Sun May 09, 2021 05:44I suggest installing the sar package (system activity reporter), then wait until the issue happens again, and check the reports from sar to see what was the CPU/RAM/Disk I/O usage at the time of the incident. I still believe you are running out of RAM, but with sar you can know which resource was being exhausted.
I find it interesting that AWS claims you can comfortably run a Minecraft server on this same Lightsail instance while hosting up to 5 simultaneous players. That's difficult to believe, since It's having trouble running Minetest with one player logged in, and Minetest—even with all these mods installed—uses significantly less RAM than Minecraft.
Re: Help: Setting up, running, and maintaining a server
Done and done. :) I set up sysstat, and captured the system metrics when another incident occurred (screenshots below). If I understand these correctly, you're right; it looks like I'm running out of RAM, and the system just starts swapping itself into oblivion. But the swap stats are all zero. Am I reading these right? Something else to note is that at 07:55 when the system goes back to its normal mostly-idle state, it's completely unresponsive. I can't even SSH into a terminal window. The only recourse I have at this point is to force a system reboot.
Would increasing the RAM from 1 to 2 GB help here, or would Minetest simply use all 2 GB, too, and leave me with the same issue? I don't know how Minetest is designed to manage its memory usage.
- Attachments
-
- Screenshot 2021-05-30 13.33.30.png (87.37 KiB) Viewed 3642 times
-
- Screenshot 2021-05-30 13.32.33.png (179.32 KiB) Viewed 3642 times
-
- Screenshot 2021-05-30 13.31.32.png (329.24 KiB) Viewed 3642 times
Re: Help: Setting up, running, and maintaining a server
Good, you identified your issue. The swap metrics are all zero because you have no swap enabled, you could either increase RAM or add swap. You could try first enabling a little swapfile, maybe 2 GB, and see how it performs, if your storage is fast it could be good enough.
Most likely what happened there was that the Out of Memory Killer tried to solve the RAM issue but the system ended up crashed.
If you set the server_unused_data_timeout value very high Minetest will use as much memory as you give it to cache data.
- Festus1965
- Member
- Posts: 4181
- Joined: Sun Jan 03, 2016 11:58
- GitHub: Festus1965
- In-game: Festus1965 Thomas Thailand Explorer
- Location: Thailand ChiangMai
- Contact:
Re: Help: Setting up, running, and maintaining a server
that can be now, but sure will happen some days later, when more gamer in and world file is bigger.
You might have 6 months to reach this border again ... or other, depending on your settings, world usage ...
Human has no future (climate change)
If urgend, you find me in Roblox (as CNXThomas)
If urgend, you find me in Roblox (as CNXThomas)
Re: Help: Setting up, running, and maintaining a server
I just added a 2 GB swap file to the root directory. I'll monitor for several days to see how it performs. Speed-wise, it should be fine, since the storage is on an SSD. It's strange that swap wasn't pre-configured on this Lightsail instance, since it has very little physical RAM. It's technically against best practices to configure a swap file on the same file system and drive as your OS, and it's generally a bad idea to enable swap on a SSD, but since it's not my hardware, I won't worry too much about that. ;)
I'd like to avoid upgrading to the 2 GB physical RAM instance, because that doubles my cost from $5/month to $10/month. Yeah, not much in the grand scheme of things, but every penny saved is a penny earned.
I have server_unused_data_timeout set to 3 in minetest.conf, which is far below the default value of 21, so hopefully, I won't need to worry about Minetest eating all my memory for a while, now that I've enabled a 2 GB swap file.Festus1965 wrote: ↑Mon May 31, 2021 08:09that can be now, but sure will happen some days later, when more gamer in and world file is bigger.
You might have 6 months to reach this border again ... or other, depending on your settings, world usage ...
- Festus1965
- Member
- Posts: 4181
- Joined: Sun Jan 03, 2016 11:58
- GitHub: Festus1965
- In-game: Festus1965 Thomas Thailand Explorer
- Location: Thailand ChiangMai
- Contact:
Re: Help: Setting up, running, and maintaining a server
in this case:
* check all your system and shut down programs and services that are not needed !
* check the mts if there are mods with massive memory load ... and decide
* go and learn about swappiness = x in the sysctl.cong (?) file to set it es less using as possible.
* go to learn and maybe set 'noatime,nodiratime' in fstab
* also the cache settings from system and storage to avoid 'false' data using them (= against mts)
to save real ram,
yes, to set memory (data time out) low is logic - but find a way to balance that, data in memory is faster then have to been read again from SSD (as there is no diff if read new raw data or known from swapfile)
* check all your system and shut down programs and services that are not needed !
* check the mts if there are mods with massive memory load ... and decide
* go and learn about swappiness = x in the sysctl.cong (?) file to set it es less using as possible.
* go to learn and maybe set 'noatime,nodiratime' in fstab
* also the cache settings from system and storage to avoid 'false' data using them (= against mts)
to save real ram,
yes, to set memory (data time out) low is logic - but find a way to balance that, data in memory is faster then have to been read again from SSD (as there is no diff if read new raw data or known from swapfile)
Human has no future (climate change)
If urgend, you find me in Roblox (as CNXThomas)
If urgend, you find me in Roblox (as CNXThomas)
Who is online
Users browsing this forum: No registered users and 3 guests