Running Elasticsearch in Windows PS


(Rodel) #1

Hi guys! I'm running ES using Windows PS. Executing the basic
.\bin\elasticsearch.bat is working fine. But when I try to run it with configuration using -E syntax, I'm getting an error.


(Russ Cam) #2

This is related to how PowerShell parses arguments.

You have a few different options

  1. Including a space between the switch and value

    .\elasticsearch.bat -E path.data=C:\temp -E path.logs=C:\temp -E node.name=node_1
    
  2. Depending on the argument values, you may also need to use quotes

    .\elasticsearch.bat -E "path.data=C:\temp" -E "path.logs=C:\temp" -E "node.name=node_1"
    
  3. Or you can quote each switch and value

    .\elasticsearch.bat "-Epath.data=C:\temp" "-Epath.logs=C:\temp" "-Enode.name=node_1"
    

(Rodel) #3

Nice it works! Thanks @forloop Russ


(system) #4

This topic was automatically closed 28 days after the last reply. New replies are no longer allowed.