Hi
I'm confused how group permissions work. Where are you able to configure them? If I go to the admin area, it tells me to go here but there are little to no permissions here to configure. Is this meant to be?
And also, the talkyard_search_1 container always crashes with the following error:
[1]: max virtual memory areas vm.max_map_count [65530] is too low, increase to at least [262144]
Where could I fix this?
- KajMagnus @KajMagnus2024-02-22 04:05:44.593Z
1/2. You can configure per category permissions, by going to the category (e.g. to
https://forum.talkyard.io/latest/support
if you were admin here) clicking Edit category, and then click the Security tab. There, you can configure which user groups may see pages in that category and sub categories, and post new topics or replies. (Good question, seems it'd be good if this was more discoverable via the UI.)2/2. About the search container: You need to tweak an operating system setting. Have a look at this section in the installation instructions, https://github.com/debiki/talkyard-prod-one:
Prepare the OS: install tools, enable automatic security updates, simplify troubleshooting, and make ElasticSearch work: (Consider reading the script first...)
.
/scripts/prepare-os.sh 2>&1 | tee -a talkyard-maint.log
(...If you don't want to run the whole script, you at least need to copy the sysctl net.core.somaxconn and vm.max_map_count settings in the script to your /etc/sysctl.conf config file — otherwise, the full-text-search-engine (ElasticSearch) won't work. Afterwards, run sysctl --system to reload the system configuration.)
This is the most relevant line, in the
prepare-os.sh
script: (it addsvm.max_map_count=262144
to the system config)Here you can read more: https://www.elastic.co/guide/en/elasticsearch/reference/current/vm-max-map-count.html
Don't forget to add the
net.core.somaxconn
setting too (mentioned above, & you'll find it a few lines higher up in theprepare-os.sh
script).- @sybe
Hi, thanks for your reply. I have run the script yesterday and just did it again (I've also rebooted to be sure and tried without rebooting), and it's still giving me the same error.
2024-02-21T23:19:06,091][INFO ][o.e.t.TransportService ] [Rp4qTpz] publish_address {172.26.0.61:9300}, bound_addresses {0.0.0.0:9300} [2024-02-21T23:19:06,097][INFO ][o.e.b.BootstrapChecks ] [Rp4qTpz] bound or publishing to a non-loopback address, enforcing bootstrap checks ERROR: [1] bootstrap checks failed [1]: max virtual memory areas vm.max_map_count [65530] is too low, increase to at least [262144] [2024-02-21T23:19:06,103][INFO ][o.e.n.Node ] [Rp4qTpz] stopping ... [2024-02-21T23:19:06,110][INFO ][o.e.n.Node ] [Rp4qTpz] stopped [2024-02-21T23:19:06,110][INFO ][o.e.n.Node ] [Rp4qTpz] closing ... [2024-02-21T23:19:06,115][INFO ][o.e.n.Node ] [Rp4qTpz] closed [2024-02-21T23:20:08,157][WARN ][o.e.c.l.LogConfigurator ] [unknown] Some logging configurations have %marker but don't have %node_name. We will automatically add %node_name to the pattern to ease the migration for users who customize log4j2.properties but will stop this behavior in 7.0. You should manually replace `%node_name` with `[%node_name]%marker ` in these locations: /usr/share/elasticsearch/config/log4j2.properties
When I go to the system file, it did get added:
Any ideas?- KajMagnus @KajMagnus2024-02-26 16:41:43.429Z
How odd, it still says
max virtual memory areas vm.max_map_count [65530] is too low
. What OS and version do you use b.t.w.? Is it a VPS in Google Cloud or Digital Ocean or something? Or is it a local physical server with some KVM or other virtualization in addition to Docker?What happens if you run this?:
sudo sysctl vm.max_map_count
(I get this:
vm.max_map_count = 262144
)(I wonder if there's some other OS startup script that also sets this parameter, and somehow overwrites the value in
/etc/sysctl.conf
. Or what's going on)- @sybe
Hi, thanks for your reply. Unfortunately, I switched to regular Discourse because I needed a functional forum as soon as possible.
Do you still want me to investigate?- KajMagnus @KajMagnus2024-02-26 17:16:28.970Z
Yes thanks if you have time to run that command? :- ) (And could be good to know if you use Debian or ... Ubuntu? or sth else?)
How much RAM? If you type:
free -m
what's the output?- @sybe
root@box:~# sudo sysctl vm.max_map_count vm.max_map_count = 65530 root@box:~#
I run Ubuntu 22.04 on OpenVZ. It is rented from a server provider, specifically MC-Node (Dutch Company).
- @sybe
I've also tried using a service file and make it run at startup and set it that way, but that also has no change. I don't know why it doesn't wanna change to what's provided
- KajMagnus @KajMagnus2024-02-26 17:21:07.704Z
Maybe one needs to do the change in both OpenVZ and Ubuntu or sth like that. I haven't used OpenVZ. Thanks for the info anyway :- )