IMPORTANT ANNOUNCEMENT: On May 6, 2024, Carbon Black User eXchange (UeX) and Case Management will move to a new platform!
The Community will be in read-only mode starting April 19th, 7:00 AM PDT. Check out the blog post!
You will still be able to use the case portal to create and interact with your support cases until the transition, view more information here!

Solr Error Resulting From No Local Hostname Redirect

Solr Error Resulting From No Local Hostname Redirect

Version

Cb Response 5.x

Issue

Solr is not able to communicate with datastore. This prevents data ingress.

Symptoms

Errors seen in /var/log/cb/solr/debug.log:

2016-08-03 11:41:16,858 - [ERROR] - from org.apache.solr.core.SolrCore in http-8080-15

java.net.UnknownHostException: <SERVERNAME>: SERVERNAME: Temporary failure in name resolution

        at java.net.InetAddress.getLocalHost(InetAddress.java:1496)

        at com.carbonblack.cbfs.common.CbDataStorageConfig.getServerName(CbDataStorageConfig.java:159)

        at com.carbonblack.cbfs.solr.FeedHitHandler.buildEvent(CbStorageEventHandlerFactory.java:136)

Cause

Hosts file edit was skipped during initial install. The installer adds this section to the hosts file:

# Added by Carbon Black Enterprise Server installation:

127.0.0.1 <SERVERNAME>

Solution

1. Add hostname to local redirect (127.0.0.1 for ipv4 and ::1 for ipv6) in hosts file

vi /etc/hosts

127.0.0.1   localhost localhost.localdomain localhost4 localhost4.localdomain4 <SERVERNAME>

::1         localhost localhost.localdomain localhost6 localhost6.localdomain6

2. Restart services

service cb-enterprise stop (if it’s a cluster, use “/usr/share/cb/cbcluster stop”)

killall -KILL -u cb

service cb-enterprise start (if it’s a cluster, use “/usr/share/cb/cbcluster start”)

Labels (1)
Was this article helpful? Yes No
No ratings
Article Information
Author:
Creation Date:
‎08-12-2016
Views:
1114
Contributors