diff --git a/docs/reference/setup/repositories.asciidoc b/docs/reference/setup/repositories.asciidoc index 5e1f5eeb671..ed65b929cda 100644 --- a/docs/reference/setup/repositories.asciidoc +++ b/docs/reference/setup/repositories.asciidoc @@ -25,11 +25,11 @@ Download and install the Public Signing Key: wget -qO - https://packages.elastic.co/GPG-KEY-elasticsearch | sudo apt-key add - -------------------------------------------------- -Add the repository definition to your `/etc/apt/sources.list` file: +Save the repository definition to `/etc/apt/sources.list.d/elasticsearch-{branch}.list`: ["source","sh",subs="attributes,callouts"] -------------------------------------------------- -echo "deb http://packages.elastic.co/elasticsearch/{branch}/debian stable main" | sudo tee -a /etc/apt/sources.list +echo "deb http://packages.elastic.co/elasticsearch/{branch}/debian stable main" | sudo tee -a /etc/apt/sources.list.d/elasticsearch-{branch}.list -------------------------------------------------- [WARNING] @@ -51,6 +51,17 @@ Run apt-get update and the repository is ready for use. You can install it with: sudo apt-get update && sudo apt-get install elasticsearch -------------------------------------------------- +[WARNING] +================================================== +If two entries exist for the same Elasticsearch repository, you will see an error like this during `apt-get update`: + +["literal",subs="attributes,callouts"] + +Duplicate sources.list entry http://packages.elastic.co/elasticsearch/{branch}/debian/ ...` + +Examine +/etc/apt/sources.list.d/elasticsearch-{branch}.list+ for the duplicate entry or locate the duplicate entry amongst the files in `/etc/apt/sources.list.d/` and the `/etc/apt/sources.list` file. +================================================== + Configure Elasticsearch to automatically start during bootup. If your distribution is using SysV init, then you will need to run: