Support Questions
Find answers, ask questions, and share your expertise
Announcements
Alert: Please see the Cloudera blog for information on the Cloudera Response to CVE-2021-4428

Can't upgrade from 2.6.4 to 2.6.5 because of SOLR

New Contributor

Trying to upgrade HDP 2.6.4 to HDP 2.6.5. Gets 99% done and then I get an error about Solr.

{"hosts":["hadoopmgmt2.bet.fiscnet.ihost.com"],"host_detail":{"hadoopmgmt2.bet.fiscnet.ihost.com":[{"service":"SOLR","component":"SOLR_SERVER","version":"UNKNOWN","targetVersion":"2.6.5.0-292"}]}}

We tried setting the version in the Ambari database, didn't seem to make any difference.

If I try to start Solr now I get the following error.

Traceback (most recent call last):
  File "/var/lib/ambari-agent/cache/common-services/SOLR/5.5.2.2.5/package/scripts/solr.py", line 101, in <module>
    Solr().execute()
  File "/usr/lib/ambari-agent/lib/resource_management/libraries/script/script.py", line 375, in execute
    method(env)
  File "/var/lib/ambari-agent/cache/common-services/SOLR/5.5.2.2.5/package/scripts/solr.py", line 46, in start
    self.configure(env)
  File "/usr/lib/ambari-agent/lib/resource_management/libraries/script/script.py", line 120, in locking_configure
    original_configure(obj, *args, **kw)
  File "/var/lib/ambari-agent/cache/common-services/SOLR/5.5.2.2.5/package/scripts/solr.py", line 22, in configure
    setup_solr()
  File "/var/lib/ambari-agent/cache/common-services/SOLR/5.5.2.2.5/package/scripts/setup_solr.py", line 28, in setup_solr
    content=InlineTemplate(params.solr_config_in_sh),
  File "/usr/lib/ambari-agent/lib/resource_management/core/source.py", line 150, in __init__
    super(InlineTemplate, self).__init__(name, extra_imports, **kwargs) 
  File "/usr/lib/ambari-agent/lib/resource_management/core/source.py", line 137, in __init__
    self.template = self.template_env.get_template(self.name)     
  File "/usr/lib/ambari-agent/lib/ambari_jinja2/environment.py", line 716, in get_template
    return self._load_template(name, self.make_globals(globals))
  File "/usr/lib/ambari-agent/lib/ambari_jinja2/environment.py", line 686, in _load_template
    template = self.cache.get(name)
  File "/usr/lib/ambari-agent/lib/ambari_jinja2/utils.py", line 405, in get
    return self[key]
  File "/usr/lib/ambari-agent/lib/ambari_jinja2/utils.py", line 448, in __getitem__
    rv = self._mapping[key]
  File "/usr/lib/ambari-agent/lib/resource_management/libraries/script/config_dictionary.py", line 73, in __getattr__
    raise Fail("Configuration parameter '" + self.name + "' was not found in configurations dictionary!")
resource_management.core.exceptions.Fail: Configuration parameter 'content' was not found in configurations dictionary!
<br>

Anyone have any idea what's going on and how we might get past this?

4 REPLIES 4

@joel patterson,

What error are you getting at 99% stage?

Please attach a screenshot. also see if there is any errors in ambari-server.log file

New Contributor

This is all it shows me when looking at details. We tried setting the version in the Ambari database, but made no difference.

{"hosts":["hadoopmgmt2.bet.fiscnet.ihost.com"],"host_detail":{"hadoopmgmt2.bet.fiscnet.ihost.com":[{"service":"SOLR","component":"SOLR_SERVER","version":"UNKNOWN","targetVersion":"2.6.5.0-292"}]}}

Hi @Joel Patterson ,

It seems like some of requried configs of SOLR is missing .

So my question is are you Actually Using SOLR as a ambari managed service and SOLR i shown in ambari Services UI ?

If not you can actually follow this Blog to delete the Service from database : https://community.hortonworks.com/articles/79546/how-to-cleanup-service-from-ambari-database.html

(My assumption is your SOLR is not visible in UI and cannot delete service as you mentioned you have version unknown in database )

Before Deleting, Stop upgrade and revert back upgrade .

If you have SOLR running and everything is fine , try to give the missing parameter to ambari using : https://community.hortonworks.com/questions/174776/how-to-use-configpy.html

# /var/lib/ambari-server/resources/scripts/configs.py --user=admin --password=admin --port=8080 --action=set --host=localhost --cluster=<Enter_your_cluster_name> --config-type=<CONFIG_TYPE>