Invision Community 4: SEO, prepare for v5 and dormant account notifications By Matt Monday at 02:04 PM
MSUKForum Posted November 20, 2019 Posted November 20, 2019 I've looked into Elasticsearch but it puzzles me somewhat, has anyone done this with their forum and can give me a rundown of how you set it up and what provider you used? Thanks in advance.
b416 Posted November 21, 2019 Posted November 21, 2019 I have implemented elasticsearch localy, i.e. on the same server than everything else; I can give you some pointers if you are interested.
Maxxius Posted November 21, 2019 Posted November 21, 2019 me to locally, search gets amazing results. my advice increase heap size (in my case from 1GB which is default to 3GB) when it worked with stability. no idea about any other settings.
b416 Posted November 21, 2019 Posted November 21, 2019 I have increased the heap size to 8G (I have 32 in the server, 6 reserved is for MySQL). The last elasticsearch 6.8.5 did some improvements, I have a test machine with only 8G and on this one I reserved only 2 for elastic. Up to this last version it was really really slow, and now it's much better.
MSUKForum Posted November 22, 2019 Author Posted November 22, 2019 17 hours ago, b416 said: I have implemented elasticsearch localy, i.e. on the same server than everything else; I can give you some pointers if you are interested. Yeah please, I'd really appreciate it. I don't particularly know where to download it from and what it costs? We are on a VPS with quite good techies who'd help us install it server side.
b416 Posted November 22, 2019 Posted November 22, 2019 I use the open source version, so it's free. You can download it from elactic.co directly, the way I use it on Ubuntu is to set up a repository and use apt as for everything else. Be aware that only 6.x works with IPS, don't take the 7.x version (yet). I installed it with the default configuration (it runs on localhost only, port 9200 - that's the default settings in IPS also). The only thing I changed is the heap size, the defaults are too small for my indexes. Here is the guide for this. When you switch to elastic, IPS will rebuild the indexes, it takes some time (you will see the background tasks in the ACP), for me it took about 10 hours. The site continues to work OK during this time, there is just a warning when you access the search page or dynamic pages that relay on indexes such as unread, activity... And that's it. Almost forgot, elastic runs fine on a single node, but is configured by default to expect at least 2 nodes and run in a cluster, so when you check the status with a command line or supervision tool, it will appear as "yellow". You can ignore it, or if you are a control freak like me, you can tweak it so it will be all green, even on a single node. To see the status on command line : curl -XGET localhost:9200/_cluster/health/content?pretty to see the index list (ignore the .tasks, it's for elastic internal use) : curl -XGET localhost:9200/_cat/indices?v to put replicas to 0 on all active indexes (replace index with the name of the index from the command above (content by default with IPS): curl -XPUT 'localhost:9200/_settings' -H "Content-Type: application/json" -d '{ "index" : { "number_of_replicas" : 0 } }' to put all future replicas to 0 : curl -XPUT localhost:9200/_template/zeroreplicas -H "Content-Type: application/json" -d '{"template":"*", "order":1, "settings":{"number_of_replicas":0}}' to check the status of your new template : curl -XGET localhost:9200/_template/zeroreplicas?pretty Now your status will always be green. Run the first command again to check.
Recommended Posts
Archived
This topic is now archived and is closed to further replies.