title: How to remove Elasticsearch from Ubuntu?
body: <p>I think that I already removed elasticsearch from my computer, and still I have some doubts. </p>
  
  <p>When I type:</p>
  
  <pre><code>$ service elasticsearch status
  </code></pre>
  
  <p>I get: </p>
  
  <blockquote>
    <p>elasticsearch.service    Loaded: not-found (Reason: No such file or
    directory)    Active: failed (Result: exit-code) since Wed 2017-08-09
    01:08:18 PDT; 38min ago  Main PID: 73249 (code=exited,
    status=1/FAILURE)</p>
    
    <p>Aug 09 01:08:18 ubuntu elasticsearch[73249]: Java HotSpot(TM) 64-Bit
    Server VM warning: INFO: os::commit_memory(0x0000000085330000,
    2060255232, 0) fai Aug 09 01:08:18 ubuntu elasticsearch[73249]: # Aug
    09 01:08:18 ubuntu elasticsearch[73249]: # There is insufficient
    memory for the Java Runtime Environment to continue. Aug 09 01:08:18
    ubuntu elasticsearch[73249]: # Native memory allocation (mmap) failed
    to map 2060255232 bytes for committing reserved memory. Aug 09
    01:08:18 ubuntu elasticsearch[73249]: # An error report file with more
    information is saved as: Aug 09 01:08:18 ubuntu elasticsearch[73249]:</p>
    
    <h1>/tmp/hs_err_pid73249.log Aug 09 01:08:18 ubuntu systemd[1]: elasticsearch.service: Main process exited, code=exited,</h1>
    
    <p>status=1/FAILURE Aug 09 01:08:18 ubuntu systemd[1]:
    elasticsearch.service: Unit entered failed state. Aug 09 01:08:18
    ubuntu systemd[1]: elasticsearch.service: Failed with result
    'exit-code'. Aug 09 01:12:38 ubuntu systemd[1]: Stopped Elasticsearch.</p>
  </blockquote>
  
  <p>However, when I type:</p>
  
  <pre><code>$ service helloworld status 
  </code></pre>
  
  <p>I get somehting much shorter: </p>
  
  <blockquote>
    <p>helloworld.service    Loaded: not-found (Reason: No such file or</p>
    
    <p>directory)    Active: inactive (dead)</p>
  </blockquote>
  
  <p>I already removed Elasticsearch by using the command: </p>
  
  <pre><code>sudo apt-get --purge autoremove elasticsearch
  </code></pre>
  
  <p>and it still looks like elasticsearch exists. </p>