You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@ambari.apache.org by "Ruslan (JIRA)" <ji...@apache.org> on 2018/01/15 12:18:00 UTC

[jira] [Commented] (AMBARI-22580) Streaming Analytics Manager (SAM) not working with PostgreSQL

    [ https://issues.apache.org/jira/browse/AMBARI-22580?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16326180#comment-16326180 ] 

Ruslan commented on AMBARI-22580:
---------------------------------

Hi. I have similar problem. After upgrade Ambari to 2.6.0.0 and have installed hdf-ambari-mpack-3.0.2.0-76

Of course i have configured jdbc-driver 
{code:java}
 ambari-server setup --jdbc-db=postgres --jdbc-driver=/usr/lib/ambari-server/postgresql-42.0.0.jar{code}
 

But i can't reboot or run self check from SAM
{code:java}
Traceback (most recent call last):
  File "/var/lib/ambari-agent/cache/common-services/STREAMLINE/0.5.0/package/scripts/service_check.py", line 84, in <module>
    ServiceCheck().execute()
  File "/usr/lib/python2.6/site-packages/resource_management/libraries/script/script.py", line 367, in execute
    method(env)
  File "/var/lib/ambari-agent/cache/common-services/STREAMLINE/0.5.0/package/scripts/service_check.py", line 33, in service_check
    import params
  File "/var/lib/ambari-agent/cache/common-services/STREAMLINE/0.5.0/package/scripts/params.py", line 211, in <module>
    connector_curl_source = format("{jdk_location}/{jdbc_driver_jar}")
  File "/usr/lib/python2.6/site-packages/resource_management/libraries/functions/format.py", line 95, in format
    return ConfigurationFormatter().format(format_string, args, **result)
  File "/usr/lib/python2.6/site-packages/resource_management/libraries/functions/format.py", line 59, in format
    result_protected = self.vformat(format_string, args, all_params)
  File "/usr/lib64/python2.7/string.py", line 549, in vformat
    result = self._vformat(format_string, args, kwargs, used_args, 2)
  File "/usr/lib64/python2.7/string.py", line 571, in _vformat
    obj, arg_used = self.get_field(field_name, args, kwargs)
  File "/usr/lib64/python2.7/string.py", line 632, in get_field
    obj = self.get_value(first, args, kwargs)
  File "/usr/lib64/python2.7/string.py", line 591, in get_value
    return kwargs[key]
  File "/usr/lib/python2.6/site-packages/resource_management/core/utils.py", line 63, in __getitem__
    return self._convert_value(self._dict[name])
KeyError: 'jdbc_driver_jar'

stdout:   /var/lib/ambari-agent/data/output-6292.txt

2018-01-15 12:07:52,054 - Stack Feature Version Info: Cluster Stack=2.6, Command Stack=None, Command Version=2.6.3.0-235 -> 2.6.3.0-235

Command failed after 1 tries
{code}
 

 

> Streaming Analytics Manager (SAM) not working with PostgreSQL
> -------------------------------------------------------------
>
>                 Key: AMBARI-22580
>                 URL: https://issues.apache.org/jira/browse/AMBARI-22580
>             Project: Ambari
>          Issue Type: Bug
>          Components: ambari-server
>            Reporter: Unai P. Mendizabal
>            Priority: Major
>
> Hi!
> I was trying to install SAM on my Ambari cluster and trying to use the same PostgreSQL database I use for Ambari server. The installation fails though, with error "KeyError: 'jdbc_driver_jar" coming from the params.py file of the Streamline service. I dived into it and realized that variable 'jdbc_driver_jar' is never initialized for PostgreSQL databases, while it does when it comes to Oracle or MySQL.
> The file is /var/lib/ambari-server/resources/common-services/STREAMLINE/0.5.0/package/scripts/params.py, you can see the problem from line 192 on. As a workaround, I think it should be possible to manually set 'jdbc_driver_jar' to the path to the jdbc driver on that same file.



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)