<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Re: Docker image search cluster configuration fails in splunk-ansible: 'FAILED - RETRYING: Destructive sync search head' in Deployment Architecture</title>
    <link>https://community.splunk.com/t5/Deployment-Architecture/Docker-image-search-cluster-configuration-fails-in-splunk/m-p/463936#M16225</link>
    <description>&lt;P&gt;We were very much hoping to use the official splunk images, so we can avoid the support burden. However if we can't get them working, I will do, thanks &lt;span class="lia-unicode-emoji" title=":slightly_smiling_face:"&gt;🙂&lt;/span&gt;&lt;/P&gt;</description>
    <pubDate>Tue, 07 Jan 2020 11:33:00 GMT</pubDate>
    <dc:creator>platformred</dc:creator>
    <dc:date>2020-01-07T11:33:00Z</dc:date>
    <item>
      <title>Docker image search cluster configuration fails in splunk-ansible: 'FAILED - RETRYING: Destructive sync search head'</title>
      <link>https://community.splunk.com/t5/Deployment-Architecture/Docker-image-search-cluster-configuration-fails-in-splunk/m-p/463927#M16216</link>
      <description>&lt;P&gt;We're using the docker images at &lt;A href="https://hub.docker.com/r/splunk/splunk"&gt;https://hub.docker.com/r/splunk/splunk&lt;/A&gt; to install splunk in kubernetes. We're currently using 7.2.4, and are preparing to upgrade to 7.2.9.1.&lt;/P&gt;

&lt;P&gt;The configuration stage (using splunk-ansible) of the search cluster is failing for at least the following versions:&lt;/P&gt;

&lt;UL&gt;
&lt;LI&gt;7.2.9&lt;/LI&gt;
&lt;LI&gt;7.3.3&lt;/LI&gt;
&lt;/UL&gt;

&lt;P&gt;The log for each of the search cluster members shows:&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;FAILED - RETRYING: Destructive sync search head
&lt;/CODE&gt;&lt;/PRE&gt;

&lt;P&gt;We have tested the following versions and found that they do not exhibit this behaviour, and deploy a working search cluster:&lt;/P&gt;

&lt;UL&gt;
&lt;LI&gt;7.2.4&lt;/LI&gt;
&lt;LI&gt;7.2.5&lt;/LI&gt;
&lt;LI&gt;7.2.6&lt;/LI&gt;
&lt;LI&gt;7.2.7&lt;/LI&gt;
&lt;/UL&gt;

&lt;P&gt;(7.2.8 is broken in a totally different way; all the containers die almost immediately with 'ERROR: Couldn't read "/opt/splunk/etc/splunk-launch.conf" ')&lt;/P&gt;

&lt;P&gt;My question is - does anyone here have 7.2.9 or 7.3.3 working using the docker containers and with a search cluster, and can they please share the secret?&lt;/P&gt;

&lt;P&gt;Thanks,&lt;BR /&gt;
Rich&lt;/P&gt;</description>
      <pubDate>Tue, 10 Dec 2019 11:00:07 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Deployment-Architecture/Docker-image-search-cluster-configuration-fails-in-splunk/m-p/463927#M16216</guid>
      <dc:creator>platformred</dc:creator>
      <dc:date>2019-12-10T11:00:07Z</dc:date>
    </item>
    <item>
      <title>Re: Docker image search cluster configuration fails in splunk-ansible: 'FAILED - RETRYING: Destructive sync search head'</title>
      <link>https://community.splunk.com/t5/Deployment-Architecture/Docker-image-search-cluster-configuration-fails-in-splunk/m-p/463928#M16217</link>
      <description>&lt;P&gt;I think the problem is related to the mgmt_uri parameter in server.conf.&lt;/P&gt;

&lt;P&gt;In 7.2.4:&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;root@search-0:/opt/splunk# grep mgmt_uri etc/system/local/server.conf
mgmt_uri = &lt;A href="https://search-0.search:8089" target="test_blank"&gt;https://search-0.search:8089&lt;/A&gt;
&lt;/CODE&gt;&lt;/PRE&gt;

&lt;P&gt;In 7.2.9:&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;root@search-0:/opt/splunk# grep mgmt_uri etc/system/local/server.conf
mgmt_uri = &lt;A href="https://search-0.search.splunk-mycompany-internal-stg-3.svc.cluster.local:8089" target="test_blank"&gt;https://search-0.search.splunk-mycompany-internal-stg-3.svc.cluster.local:8089&lt;/A&gt;
&lt;/CODE&gt;&lt;/PRE&gt;

&lt;P&gt;And also in 7.2.9:&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;root@search-0:/opt/splunk# grep ERROR var/log/splunk/splunkd.log  | tail -n 1
12-11-2019 12:07:33.953 +0000 ERROR SHCRaftConsensus - Mismatch in mgmt_uri and server URI provided to LEADER. Check URI strings in set_configuration mgmt_uri = &lt;A href="https://search-0.search.splunk-mycompany-internal-stg-3.svc.cluster.local:8089" target="test_blank"&gt;https://search-0.search.splunk-mycompany-internal-stg-3.svc.cluster.local:8089&lt;/A&gt; remote_server_name = &lt;A href="https://search-0.search:8089" target="test_blank"&gt;https://search-0.search:8089&lt;/A&gt;
&lt;/CODE&gt;&lt;/PRE&gt;

&lt;P&gt;So the problem becomes - how do we set this correctly during the container creation process, given that the configmap used by the deploy container doesn't seem to be able to do that.&lt;/P&gt;</description>
      <pubDate>Wed, 11 Dec 2019 12:14:23 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Deployment-Architecture/Docker-image-search-cluster-configuration-fails-in-splunk/m-p/463928#M16217</guid>
      <dc:creator>platformred</dc:creator>
      <dc:date>2019-12-11T12:14:23Z</dc:date>
    </item>
    <item>
      <title>Re: Docker image search cluster configuration fails in splunk-ansible: 'FAILED - RETRYING: Destructive sync search head'</title>
      <link>https://community.splunk.com/t5/Deployment-Architecture/Docker-image-search-cluster-configuration-fails-in-splunk/m-p/463929#M16218</link>
      <description>&lt;P&gt;I does NOT work for me on 7.3.3 either. It fails running this ansible task (splunk-ansible/roles/splunk_common/tasks/wait_for_splunk_instance.yml) :&lt;/P&gt;

&lt;HR /&gt;

&lt;UL&gt;
&lt;LI&gt;name: Check Splunk instance is running
uri:
url: "{{ cert_prefix }}://{{ splunk_instance_address }}:{{ splunk.svc_port }}/services/server/info?output_mode=json"
method: GET
user: "{{ splunk.admin_user }}"
password: "{{ splunk.password }}"
validate_certs: false
register: task_response
until:

&lt;UL&gt;
&lt;LI&gt;task_response.status == 200&lt;/LI&gt;
&lt;LI&gt;lookup('pipe', 'date +"%s"')|int - task_response.json.entry[0].content.startup_time &amp;gt; 10
retries: "{{ retry_num }}"
delay: 30
ignore_errors: true
no_log: "{{ hide_password }}"&lt;/LI&gt;
&lt;/UL&gt;&lt;/LI&gt;
&lt;/UL&gt;</description>
      <pubDate>Wed, 30 Sep 2020 03:23:16 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Deployment-Architecture/Docker-image-search-cluster-configuration-fails-in-splunk/m-p/463929#M16218</guid>
      <dc:creator>schplunk_meiste</dc:creator>
      <dc:date>2020-09-30T03:23:16Z</dc:date>
    </item>
    <item>
      <title>Re: Docker image search cluster configuration fails in splunk-ansible: 'FAILED - RETRYING: Destructive sync search head'</title>
      <link>https://community.splunk.com/t5/Deployment-Architecture/Docker-image-search-cluster-configuration-fails-in-splunk/m-p/463930#M16219</link>
      <description>&lt;P&gt;I can at least solve the 'ERROR: Couldn't read "/opt/splunk/etc/splunk-launch.conf' error for you.&lt;/P&gt;

&lt;P&gt;The Docker image assumes the Splunk user has r/w access to the /opt directory. Unless you're running Splunk as root, or a user with sudo privs, this is almost never the case. In order to resolve it you'll need to update the Makefile and rebuild the image. Below are the settings that I currently use, you can diff them against yours (or defaults).  &lt;/P&gt;

&lt;P&gt;Note: my build is based on Centos 7.6 and may vary on other flavors. This is not the complete Makefile, but contains the lines needed to resolve the error you are getting. (and my IP is redacted, obviously)&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;ENV SPLUNK_HOME /opt/splunk
ENV SPLUNK_GROUP splunk
ENV SPLUNK_USER splunk
ENV SPLUNK_BACKUP_DEFAULT_ETC /var/opt/splunk
ARG CENTOS_FRONTEND=noninteractive

# add splunk:splunk user
RUN groupadd -r ${SPLUNK_GROUP} \
    &amp;amp;&amp;amp; useradd -r -m -g ${SPLUNK_GROUP} ${SPLUNK_USER}

# make the "en_US.UTF-8" locale so splunk will be utf-8 enabled by default
ENV LANG en_US.utf8

# Download Splunk release from local server, it is too big to be part of the repo
# Also backup etc folder, so it will be later copied to the linked volume
RUN mkdir -p ${SPLUNK_HOME} \
    &amp;amp;&amp;amp; wget -qO /tmp/${SPLUNK_FILENAME} &lt;A href="http://xx.xxx.xx.xx/splunk/${SPLUNK_FILENAME}" target="test_blank"&gt;http://xx.xxx.xx.xx/splunk/${SPLUNK_FILENAME}&lt;/A&gt; \
    &amp;amp;&amp;amp; tar xzf /tmp/${SPLUNK_FILENAME} --strip 1 -C ${SPLUNK_HOME} \
    &amp;amp;&amp;amp; rm /tmp/${SPLUNK_FILENAME} \
    &amp;amp;&amp;amp; rm /tmp/${SPLUNK_FILENAME}.md5 \
    &amp;amp;&amp;amp; mkdir -p /var/opt/splunk \
    &amp;amp;&amp;amp; cp -R ${SPLUNK_HOME}/etc ${SPLUNK_BACKUP_DEFAULT_ETC} \
    &amp;amp;&amp;amp; rm -fR ${SPLUNK_HOME}/etc \
    &amp;amp;&amp;amp; chown -R ${SPLUNK_USER}:${SPLUNK_GROUP} ${SPLUNK_HOME} \
    &amp;amp;&amp;amp; chown -R ${SPLUNK_USER}:${SPLUNK_GROUP} ${SPLUNK_BACKUP_DEFAULT_ETC} \
COPY entrypoint.sh /sbin/entrypoint.sh
RUN chmod +x /sbin/entrypoint.sh

# Ports Splunk Web, Splunk Daemon, KVStore, Splunk Indexing Port, Network Input, HTTP Event Collector
EXPOSE 8000/tcp 8089/tcp 8191/tcp 9997/tcp 1514 8088/tcp

WORKDIR /opt/splunk

# Configurations folder, var folder for everything (indexes, logs, kvstore)
VOLUME [ "/opt/splunk/etc", "/opt/splunk/var" ]
&lt;/CODE&gt;&lt;/PRE&gt;

&lt;P&gt;These are basically the two most critical lines from above:&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt; &amp;amp;&amp;amp; chown -R ${SPLUNK_USER}:${SPLUNK_GROUP} ${SPLUNK_HOME} \
 &amp;amp;&amp;amp; chown -R ${SPLUNK_USER}:${SPLUNK_GROUP} ${SPLUNK_BACKUP_DEFAULT_ETC} \
&lt;/CODE&gt;&lt;/PRE&gt;

&lt;P&gt;Run docker build and redeploy your image. This should fix it for you.&lt;/P&gt;</description>
      <pubDate>Tue, 17 Dec 2019 22:10:09 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Deployment-Architecture/Docker-image-search-cluster-configuration-fails-in-splunk/m-p/463930#M16219</guid>
      <dc:creator>codebuilder</dc:creator>
      <dc:date>2019-12-17T22:10:09Z</dc:date>
    </item>
    <item>
      <title>Re: Docker image search cluster configuration fails in splunk-ansible: 'FAILED - RETRYING: Destructive sync search head'</title>
      <link>https://community.splunk.com/t5/Deployment-Architecture/Docker-image-search-cluster-configuration-fails-in-splunk/m-p/463931#M16220</link>
      <description>&lt;P&gt;@codebuilder thanks for your answer - does that only apply for 7.2.8, or will it work for 7.2.9 or 7.3.3?&lt;/P&gt;</description>
      <pubDate>Wed, 18 Dec 2019 11:37:37 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Deployment-Architecture/Docker-image-search-cluster-configuration-fails-in-splunk/m-p/463931#M16220</guid>
      <dc:creator>platformred</dc:creator>
      <dc:date>2019-12-18T11:37:37Z</dc:date>
    </item>
    <item>
      <title>Re: Docker image search cluster configuration fails in splunk-ansible: 'FAILED - RETRYING: Destructive sync search head'</title>
      <link>https://community.splunk.com/t5/Deployment-Architecture/Docker-image-search-cluster-configuration-fails-in-splunk/m-p/463932#M16221</link>
      <description>&lt;P&gt;It should apply to all versions.&lt;/P&gt;</description>
      <pubDate>Wed, 18 Dec 2019 15:06:14 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Deployment-Architecture/Docker-image-search-cluster-configuration-fails-in-splunk/m-p/463932#M16221</guid>
      <dc:creator>codebuilder</dc:creator>
      <dc:date>2019-12-18T15:06:14Z</dc:date>
    </item>
    <item>
      <title>Re: Docker image search cluster configuration fails in splunk-ansible: 'FAILED - RETRYING: Destructive sync search head'</title>
      <link>https://community.splunk.com/t5/Deployment-Architecture/Docker-image-search-cluster-configuration-fails-in-splunk/m-p/463933#M16222</link>
      <description>&lt;P&gt;It will likely resolve your k8s clustering issues as well. But if not, don't forget to expose your deployment via ingress or NodePort. I prefer the latter.&lt;/P&gt;</description>
      <pubDate>Wed, 18 Dec 2019 15:18:32 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Deployment-Architecture/Docker-image-search-cluster-configuration-fails-in-splunk/m-p/463933#M16222</guid>
      <dc:creator>codebuilder</dc:creator>
      <dc:date>2019-12-18T15:18:32Z</dc:date>
    </item>
    <item>
      <title>Re: Docker image search cluster configuration fails in splunk-ansible: 'FAILED - RETRYING: Destructive sync search head'</title>
      <link>https://community.splunk.com/t5/Deployment-Architecture/Docker-image-search-cluster-configuration-fails-in-splunk/m-p/463934#M16223</link>
      <description>&lt;P&gt;The problem still exists in the 7.2.9.1 image. Does anyone use these images?&lt;/P&gt;</description>
      <pubDate>Mon, 06 Jan 2020 14:46:37 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Deployment-Architecture/Docker-image-search-cluster-configuration-fails-in-splunk/m-p/463934#M16223</guid>
      <dc:creator>platformred</dc:creator>
      <dc:date>2020-01-06T14:46:37Z</dc:date>
    </item>
    <item>
      <title>Re: Docker image search cluster configuration fails in splunk-ansible: 'FAILED - RETRYING: Destructive sync search head'</title>
      <link>https://community.splunk.com/t5/Deployment-Architecture/Docker-image-search-cluster-configuration-fails-in-splunk/m-p/463935#M16224</link>
      <description>&lt;P&gt;Rebuild your image using the Makefile suggestions in my reply below. It will correct any permission issues and expose the necessary ports.&lt;/P&gt;</description>
      <pubDate>Mon, 06 Jan 2020 21:12:35 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Deployment-Architecture/Docker-image-search-cluster-configuration-fails-in-splunk/m-p/463935#M16224</guid>
      <dc:creator>codebuilder</dc:creator>
      <dc:date>2020-01-06T21:12:35Z</dc:date>
    </item>
    <item>
      <title>Re: Docker image search cluster configuration fails in splunk-ansible: 'FAILED - RETRYING: Destructive sync search head'</title>
      <link>https://community.splunk.com/t5/Deployment-Architecture/Docker-image-search-cluster-configuration-fails-in-splunk/m-p/463936#M16225</link>
      <description>&lt;P&gt;We were very much hoping to use the official splunk images, so we can avoid the support burden. However if we can't get them working, I will do, thanks &lt;span class="lia-unicode-emoji" title=":slightly_smiling_face:"&gt;🙂&lt;/span&gt;&lt;/P&gt;</description>
      <pubDate>Tue, 07 Jan 2020 11:33:00 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Deployment-Architecture/Docker-image-search-cluster-configuration-fails-in-splunk/m-p/463936#M16225</guid>
      <dc:creator>platformred</dc:creator>
      <dc:date>2020-01-07T11:33:00Z</dc:date>
    </item>
  </channel>
</rss>

