1. This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn More.

my Elasticsearch server configured properly?

Discussion in 'Enhanced Search Support' started by Codeless, Oct 11, 2016.

  1. Codeless

    Codeless Active Member

    hy some can tell me if my server is configured properly and working fine
    here is screen print
    [​IMG]

    Sorry to say i am newbie
     
  2. Codeless

    Codeless Active Member

    i am asking bcoz when i search anything
    i got message
    Search Results for Query: PayPal
    1. No results found.
     
  3. Mike

    Mike XenForo Developer Staff Member

    Have you built the search index after switching on ES? It doesn't look like it by those stats.
     
  4. Codeless

    Codeless Active Member

    yes Mike its working fine now. that was my first attempt
     
  5. XxUnkn0wnxX

    XxUnkn0wnxX Active Member

    Hey @Mike can you check my config as well?

    Search Settings:
    [​IMG]


    The Index name is same as Cluster Right? in cluster.name: (elasticsearch.yml)

    Also what does this do "Enable recency weighted relevance searching with specified half-life (days)" i don't understand

    this description here:

    The half-life allows you to control how heavily weighted more recent documents are. For every X days old the document is, the document's relevancy score will be halved. Smaller values will weight more recent documents more heavily.

    is to vague for me.

    as for elasticsearch

    are these values correct?

    /etc/elasticsearch/elasticsearch.yml
    Code:
    # ======================== Elasticsearch Configuration =========================
    #
    # NOTE: Elasticsearch comes with reasonable defaults for most settings.
    #       Before you set out to tweak and tune the configuration, make sure you
    #       understand what are you trying to accomplish and the consequences.
    #
    # The primary way of configuring a node is via this file. This template lists
    # the most important settings you may want to configure for a production cluster.
    #
    # Please see the documentation for further information on configuration options:
    # <http://www.elastic.co/guide/en/elasticsearch/reference/current/setup-configuration.html>
    #
    # ---------------------------------- Cluster -----------------------------------
    #
    # Use a descriptive name for your cluster:
    #
     cluster.name: Xenportal
    #
    # ------------------------------------ Node ------------------------------------
    #
    # Use a descriptive name for the node:
    #
    # node.name: node-1
    #
    # Add custom attributes to the node:
    #
    # node.rack: r1
    #
    # ----------------------------------- Paths ------------------------------------
    #
    # Path to directory where to store the data (separate multiple locations by comma):
    #
     path.data: /var/elasticsearch
    #
    # Path to log files:
    #
     path.logs: /var/log/elasticsearch
    #
    # ----------------------------------- Memory -----------------------------------
    #
    # Lock the memory on startup:
    #
    # bootstrap.memory_lock: true
    #
    # Make sure that the `ES_HEAP_SIZE` environment variable is set to about half the memory
    # available on the system and that the owner of the process is allowed to use this limit.
    #
    # Elasticsearch performs poorly when the system is swapping the memory.
    #
    # ---------------------------------- Network -----------------------------------
    #
    # Set the bind address to a specific IP (IPv4 or IPv6):
    #
     network.host: 127.0.0.1
    #
    # Set a custom port for HTTP:
    #
     http.port: 9200
    #
    # For more information, see the documentation at:
    # <http://www.elastic.co/guide/en/elasticsearch/reference/current/modules-network.html>
    #
    # --------------------------------- Discovery ----------------------------------
    #
    # Pass an initial list of hosts to perform discovery when new node is started:
    # The default list of hosts is ["127.0.0.1", "[::1]"]
    #
    # discovery.zen.ping.unicast.hosts: ["host1", "host2"]
    #
    # Prevent the "split brain" by configuring the majority of nodes (total number of nodes / 2 + 1):
    #
    # discovery.zen.minimum_master_nodes: 3
    #
    # For more information, see the documentation at:
    # <http://www.elastic.co/guide/en/elasticsearch/reference/current/modules-discovery.html>
    #
    # ---------------------------------- Gateway -----------------------------------
    #
    # Block initial recovery after a full cluster restart until N nodes are started:
    #
    # gateway.recover_after_nodes: 3
    #
    # For more information, see the documentation at:
    # <http://www.elastic.co/guide/en/elasticsearch/reference/current/modules-gateway.html>
    #
    # ---------------------------------- Various -----------------------------------
    #
    # Disable starting multiple nodes on a single system:
    #
    # node.max_local_storage_nodes: 1
    #
    # Require explicit names when deleting indices:
    #
    # action.destructive_requires_name: true
    
    and /etc/sysconfig/elasticsearch

    Code:
    ################################
    # Elasticsearch
    ################################
    
    # Elasticsearch home directory
    #ES_HOME=/usr/share/elasticsearch
    
    # Elasticsearch configuration directory
    #CONF_DIR=/etc/elasticsearch
    
    # Elasticsearch data directory
    #DATA_DIR=/var/lib/elasticsearch
    
    # Elasticsearch logs directory
    #LOG_DIR=/var/log/elasticsearch
    
    # Elasticsearch PID directory
    #PID_DIR=/var/run/elasticsearch
    
    # Heap size defaults to 256m min, 1g max
    # Set ES_HEAP_SIZE to 50% of available RAM, but no more than 31g
    ES_HEAP_SIZE=8g
    
    # Heap new generation
    #ES_HEAP_NEWSIZE=
    
    # Maximum direct memory
    #ES_DIRECT_SIZE=
    
    # Additional Java OPTS
    #ES_JAVA_OPTS=
    
    # Configure restart on package upgrade (true, every other setting will lead to not restarting)
    #RESTART_ON_UPGRADE=true
    
    # Path to the GC log file
    #ES_GC_LOG_FILE=/var/log/elasticsearch/gc.log
    
    ################################
    # Elasticsearch service
    ################################
    
    # SysV init.d
    #
    # When executing the init script, this user will be used to run the elasticsearch service.
    # The default value is 'elasticsearch' and is declared in the init.d file.
    # Note that this setting is only used by the init script. If changed, make sure that
    # the configured user can read and write into the data, work, plugins and log directories.
    # For systemd service, the user is usually configured in file /usr/lib/systemd/system/elasticsearch.service
    #ES_USER=elasticsearch
    #ES_GROUP=elasticsearch
    
    # The number of seconds to wait before checking if Elasticsearch started successfully as a daemon process
    ES_STARTUP_SLEEP_TIME=5
    
    ################################
    # System properties
    ################################
    
    # Specifies the maximum file descriptor number that can be opened by this process
    # When using Systemd, this setting is ignored and the LimitNOFILE defined in
    # /usr/lib/systemd/system/elasticsearch.service takes precedence
    #MAX_OPEN_FILES=65536
    
    # The maximum number of bytes of memory that may be locked into RAM
    # Set to "unlimited" if you use the 'bootstrap.memory_lock: true' option
    # in elasticsearch.yml (ES_HEAP_SIZE  must also be set).
    # When using Systemd, the LimitMEMLOCK property must be set
    # in /usr/lib/systemd/system/elasticsearch.service
    #MAX_LOCKED_MEMORY=unlimited
    
    # Maximum number of VMA (Virtual Memory Areas) a process can own
    # When using Systemd, this setting is ignored and the 'vm.max_map_count'
    # property is set at boot time in /usr/lib/sysctl.d/elasticsearch.conf
    #MAX_MAP_COUNT=262144
    i have 64 Gig Ram but i only allowed 8Gig for heap

    also from the library/XenES/_scripts folder i copied

    xf-date-weighted.groovy
    xf-date-weighted.mvel

    to /etc/elasticsearch/scripts

    also /var/elasticsearch folder

    i ran chmod 755 on it & chown -R elasticsearch:elasticsearch

    + chkconfig --add elasticsearch
    chkconfig elasticsearch on

    then service elasticsearch start

    i am on Cent OS 6.8 running WHM/Cpanel Apache 2.4, PHP 7

    and i allowed ports 9200 & 9300 in IPV4 TCP In on Config Server FireWall (CSF)

    This All Correct?
     
  6. Mike

    Mike XenForo Developer Staff Member

    Unless you have a specific reason to do otherwise, you should leave the index name blank. As is, your index name has disallowed characters (see the description; it's lowercase only). Beyond that, the configuration is mostly down to your preferences.

    You haven't explained whether you're getting any errors or what problems you're having (once you fix the index name).
     
  7. XxUnkn0wnxX

    XxUnkn0wnxX Active Member

    its working now i solved the lowercase thing.. custom index name is working fine as well..
     

Share This Page