Hello, I am a coop student trying to use elastic search for the first time. However, I ran into a few problem while trying to initially use elastic search after installation and also during the uninstall process. I am using a Ubuntu 14.04 with 6.6.1 elastic search.
When I initially installed and started the elastic search service, I can see the default ports 9200 and 9300 listening but when I used
the return is simply empty, like when you run a long script with no progress outputs, and I have to ctrl-z out of it. No errors or any outputs. However, currently I wish to reinstall an older version of elasticsearch but during uninstall using
sudo apt-get --purge autoremove elasticsearch
I get an error message:
Removing elasticsearch (6.6.1) ...
Stopping elasticsearch service...Failed to issue method call: Unit elasticsearch.service not loaded.
dpkg: error processing package elasticsearch (--remove):
subprocess installed pre-removal script returned error exit status 5
Failed to issue method call: Unit systemd-sysctl.service failed to load: No such file or directory. See system logs and 'systemctl status systemd-sysctl.service' for details.
### NOT starting on installation, please execute the following statements to configure elasticsearch service to start automatically using systemd
sudo systemctl daemon-reload
sudo systemctl enable elasticsearch.service
### You can start elasticsearch service by executing
sudo systemctl start elasticsearch.service
chown: cannot access ‘/var/lib/elasticsearch’: No such file or directory
dpkg: error while cleaning up:
subprocess installed post-installation script returned error exit status 1
Errors were encountered while processing:
elasticsearch
I did post this question on askubuntu but no luck yet:
Thanks for the suggestion but this is still the result:
xuyou@MBMORDA646277D:/usr/lib/systemd$ sudo apt-get --purge remove elasticsearch
Reading package lists... Done
Building dependency tree
Reading state information... Done
The following packages will be REMOVED:
elasticsearch*
0 upgraded, 0 newly installed, 1 to remove and 346 not upgraded.
1 not fully installed or removed.
After this operation, 168 MB disk space will be freed.
Do you want to continue? [Y/n] Y
(Reading database ... 236574 files and directories currently installed.)
Removing elasticsearch (6.6.1) ...
Stopping elasticsearch service...Failed to issue method call: Unit elasticsearch.service not loaded.
dpkg: error processing package elasticsearch (--purge):
subprocess installed pre-removal script returned error exit status 5
Failed to issue method call: Unit systemd-sysctl.service failed to load: No such file or directory. See system logs and 'systemctl status systemd-sysctl.service' for details.
### NOT starting on installation, please execute the following statements to configure elasticsearch service to start automatically using systemd
sudo systemctl daemon-reload
sudo systemctl enable elasticsearch.service
### You can start elasticsearch service by executing
sudo systemctl start elasticsearch.service
chown: cannot access ‘/var/lib/elasticsearch’: No such file or directory
dpkg: error while cleaning up:
subprocess installed post-installation script returned error exit status 1
Errors were encountered while processing:
elasticsearch
E: Sub-process /usr/bin/dpkg returned an error code (1)
and when I check is elasticsearch is still there:
xuyou@MBMORDA646277D:/usr/lib/systemd$ dpkg -l | grep elasticsearch
pF elasticsearch 6.6.1 all Elasticsearch is a distributed RESTful search engine built for the cloud. Reference documentation can be found at https://www.elastic.co/guide/en/elasticsearch/reference/current/index.html and the 'Elasticsearch: The Definitive Guide' book can be found at https://www.elastic.co/guide/en/elasticsearch/guide/current/index.html
Apache, Apache Lucene, Apache Hadoop, Hadoop, HDFS and the yellow elephant
logo are trademarks of the
Apache Software Foundation
in the United States and/or other countries.