Support Questions
Find answers, ask questions, and share your expertise
Announcements
Alert: Welcome to the Unified Cloudera Community. Former HCC members be sure to read and learn how to activate your account here.

Getting the following RANGER ADMIN installation error whilst installing on Oracle 12c DB. The Cluster is Kerberized against Active Directory 2012

Getting the following RANGER ADMIN installation error whilst installing on Oracle 12c DB. The Cluster is Kerberized against Active Directory 2012

New Contributor

esource_management.core.exceptions.Fail: Execution of 'python /usr/hdp/current/ranger-admin/db_setup.py' returned 1. 2016-05-06 20:01:17,108 [I] DB FLAVOR :ORACLE 2016-05-06 20:01:17,108 [I] --------- Verifying Ranger DB connection --------- 2016-05-06 20:01:17,108 [I] Checking connection 2016-05-06 20:01:17,109 [JISQL] /usr/java/jdk1.8.0_91/bin/java -Djava.security.egd=file:///dev/urandom -cp /usr/share/java/ojdbc7.jar:/usr/hdp/current/ranger-admin/jisql/lib/* org.apache.util.sql.Jisql -driver oraclethin -cstring jdbc:oracle:thin:@ora12cad2012.hortonworks.com -u 'rangeradmin' -p '********' -noheader -trim -c \; -query "select * from v$version;" Cannot find the driver class "oracle.jdbc.driver.OracleDriver" in the current classpath. 2016-05-06 20:01:17,298 [E] Can't establish connection! stdout: 2016-05-06 20:01:15,825 - The hadoop conf dir /usr/hdp/current/hadoop-client/conf exists, will call conf-select on it for version 2.4.0.0-169 2016-05-06 20:01:15,826 - Checking if need to create versioned conf dir /etc/hadoop/2.4.0.0-169/0 2016-05-06 20:01:15,826 - call['conf-select create-conf-dir --package hadoop --stack-version 2.4.0.0-169 --conf-version 0'] {'logoutput': False, 'sudo': True, 'quiet': False, 'stderr': -1} 2016-05-06 20:01:15,875 - call returned (1, '/etc/hadoop/2.4.0.0-169/0 exist already', '') 2016-05-06 20:01:15,876 - checked_call['conf-select set-conf-dir --package hadoop --stack-version 2.4.0.0-169 --conf-version 0'] {'logoutput': False, 'sudo': True, 'quiet': False} 2016-05-06 20:01:15,925 - checked_call returned (0, '/usr/hdp/2.4.0.0-169/hadoop/conf -> /etc/hadoop/2.4.0.0-169/0') 2016-05-06 20:01:15,926 - Ensuring that hadoop has the correct symlink structure 2016-05-06 20:01:15,926 - Using hadoop conf dir: /usr/hdp/current/hadoop-client/conf 2016-05-06 20:01:15,929 - Group['spark'] {} 2016-05-06 20:01:15,931 - Group['ranger'] {} 2016-05-06 20:01:15,931 - Group['hadoop'] {} 2016-05-06 20:01:15,932 - Group['users'] {} 2016-05-06 20:01:15,932 - User['hive'] {'gid': 'hadoop', 'fetch_nonlocal_groups': True, 'groups': ['hadoop']} 2016-05-06 20:01:15,935 - User['storm'] {'gid': 'hadoop', 'fetch_nonlocal_groups': True, 'groups': ['hadoop']} 2016-05-06 20:01:15,937 - User['zookeeper'] {'gid': 'hadoop', 'fetch_nonlocal_groups': True, 'groups': ['hadoop']} 2016-05-06 20:01:15,939 - User['oozie'] {'gid': 'hadoop', 'fetch_nonlocal_groups': True, 'groups': ['users']} 2016-05-06 20:01:15,941 - User['ams'] {'gid': 'hadoop', 'fetch_nonlocal_groups': True, 'groups': ['hadoop']} 2016-05-06 20:01:15,943 - User['ranger'] {'gid': 'hadoop', 'fetch_nonlocal_groups': True, 'groups': ['ranger']} 2016-05-06 20:01:15,945 - User['tez'] {'gid': 'hadoop', 'fetch_nonlocal_groups': True, 'groups': ['users']} 2016-05-06 20:01:15,946 - User['spark'] {'gid': 'hadoop', 'fetch_nonlocal_groups': True, 'groups': ['hadoop']} 2016-05-06 20:01:15,948 - User['ambari-qa'] {'gid': 'hadoop', 'fetch_nonlocal_groups': True, 'groups': ['users']} 2016-05-06 20:01:15,950 - User['hdfs'] {'gid': 'hadoop', 'fetch_nonlocal_groups': True, 'groups': ['hadoop']} 2016-05-06 20:01:15,952 - User['yarn'] {'gid': 'hadoop', 'fetch_nonlocal_groups': True, 'groups': ['hadoop']} 2016-05-06 20:01:15,955 - User['mapred'] {'gid': 'hadoop', 'fetch_nonlocal_groups': True, 'groups': ['hadoop']} 2016-05-06 20:01:15,957 - User['hbase'] {'gid': 'hadoop', 'fetch_nonlocal_groups': True, 'groups': ['hadoop']} 2016-05-06 20:01:15,959 - User['hcat'] {'gid': 'hadoop', 'fetch_nonlocal_groups': True, 'groups': ['hadoop']} 2016-05-06 20:01:15,961 - File['/var/lib/ambari-agent/tmp/changeUid.sh'] {'content': StaticFile('changeToSecureUid.sh'), 'mode': 0555} 2016-05-06 20:01:15,965 - Execute['/var/lib/ambari-agent/tmp/changeUid.sh ambari-qa /tmp/hadoop-ambari-qa,/tmp/hsperfdata_ambari-qa,/home/ambari-qa,/tmp/ambari-qa,/tmp/sqoop-ambari-qa'] {'not_if': '(test $(id -u ambari-qa) -gt 1000) || (false)'} 2016-05-06 20:01:15,973 - Skipping Execute['/var/lib/ambari-agent/tmp/changeUid.sh ambari-qa /tmp/hadoop-ambari-qa,/tmp/hsperfdata_ambari-qa,/home/ambari-qa,/tmp/ambari-qa,/tmp/sqoop-ambari-qa'] due to not_if 2016-05-06 20:01:15,974 - Directory['/tmp/hbase-hbase'] {'owner': 'hbase', 'recursive': True, 'mode': 0775, 'cd_access': 'a'} 2016-05-06 20:01:15,976 - File['/var/lib/ambari-agent/tmp/changeUid.sh'] {'content': StaticFile('changeToSecureUid.sh'), 'mode': 0555} 2016-05-06 20:01:15,979 - Execute['/var/lib/ambari-agent/tmp/changeUid.sh hbase /home/hbase,/tmp/hbase,/usr/bin/hbase,/var/log/hbase,/tmp/hbase-hbase'] {'not_if': '(test $(id -u hbase) -gt 1000) || (false)'} 2016-05-06 20:01:15,988 - Skipping Execute['/var/lib/ambari-agent/tmp/changeUid.sh hbase /home/hbase,/tmp/hbase,/usr/bin/hbase,/var/log/hbase,/tmp/hbase-hbase'] due to not_if 2016-05-06 20:01:15,989 - Group['hdfs'] {} 2016-05-06 20:01:15,990 - User['hdfs'] {'fetch_nonlocal_groups': True, 'groups': ['hadoop', 'hdfs']} 2016-05-06 20:01:15,993 - Directory['/etc/hadoop'] {'mode': 0755} 2016-05-06 20:01:16,023 - File['/usr/hdp/current/hadoop-client/conf/hadoop-env.sh'] {'content': InlineTemplate(...), 'owner': 'root', 'group': 'hadoop'} 2016-05-06 20:01:16,025 - Directory['/var/lib/ambari-agent/tmp/hadoop_java_io_tmpdir'] {'owner': 'hdfs', 'group': 'hadoop', 'mode': 0777} 2016-05-06 20:01:16,056 - Repository['HDP-2.4'] {'base_url': 'http://hdprepo2012.hortonworks.com/centos6/HDP/HDP-2.4.0.0/', 'action': ['create'], 'components': ['HDP', 'main'], 'repo_template': '[{{repo_id}}]\nname={{repo_id}}\n{% if mirror_list %}mirrorlist={{mirror_list}}{% else %}baseurl={{base_url}}{% endif %}\n\npath=/\nenabled=1\ngpgcheck=0', 'repo_file_name': 'HDP', 'mirror_list': None} 2016-05-06 20:01:16,074 - File['/etc/yum.repos.d/HDP.repo'] {'content': '[HDP-2.4]\nname=HDP-2.4\nbaseurl=http://hdprepo2012.hortonworks.com/centos6/HDP/HDP-2.4.0.0/\n\npath=/\nenabled=1\ngpgcheck=0'} 2016-05-06 20:01:16,076 - Repository['HDP-UTILS-1.1.0.20'] {'base_url': 'http://hdprepo2012.hortonworks.com/centos6/HDP/HDP-UTILS-1.1.0.20/', 'action': ['create'], 'components': ['HDP-UTILS', 'main'], 'repo_template': '[{{repo_id}}]\nname={{repo_id}}\n{% if mirror_list %}mirrorlist={{mirror_list}}{% else %}baseurl={{base_url}}{% endif %}\n\npath=/\nenabled=1\ngpgcheck=0', 'repo_file_name': 'HDP-UTILS', 'mirror_list': None} 2016-05-06 20:01:16,081 - File['/etc/yum.repos.d/HDP-UTILS.repo'] {'content': '[HDP-UTILS-1.1.0.20]\nname=HDP-UTILS-1.1.0.20\nbaseurl=http://hdprepo2012.hortonworks.com/centos6/HDP/HDP-UTILS-1.1.0.20/\n\npath=/\nenabled=1\ngpgcheck=0'} 2016-05-06 20:01:16,082 - Package['unzip'] {} 2016-05-06 20:01:16,249 - Skipping installation of existing package unzip 2016-05-06 20:01:16,249 - Package['curl'] {} 2016-05-06 20:01:16,278 - Skipping installation of existing package curl 2016-05-06 20:01:16,278 - Package['hdp-select'] {} 2016-05-06 20:01:16,305 - Skipping installation of existing package hdp-select 2016-05-06 20:01:16,679 - Package['ranger_2_4_*-admin'] {} 2016-05-06 20:01:16,854 - Skipping installation of existing package ranger_2_4_*-admin 2016-05-06 20:01:16,855 - Package['ranger_2_4_*-usersync'] {} 2016-05-06 20:01:16,883 - Skipping installation of existing package ranger_2_4_*-usersync 2016-05-06 20:01:16,888 - File['/var/lib/ambari-agent/tmp/ojdbc6.jar'] {'content': DownloadSource('http://snglsgn2012.hortonworks.com:8080/resources//oracle-jdbc-driver.jar'), 'mode': 0644} 2016-05-06 20:01:16,889 - Not downloading the file from http://snglsgn2012.hortonworks.com:8080/resources//oracle-jdbc-driver.jar, because /var/lib/ambari-agent/tmp/oracle-jdbc-driver.jar already exists 2016-05-06 20:01:16,901 - Directory['/usr/share/java'] {'recursive': True, 'mode': 0755, 'cd_access': 'a'} 2016-05-06 20:01:16,902 - Execute[('cp', '--remove-destination', '/var/lib/ambari-agent/tmp/ojdbc6.jar', '/usr/share/java/ojdbc6.jar')] {'path': ['/bin', '/usr/bin/'], 'sudo': True} 2016-05-06 20:01:16,918 - File['/usr/share/java/ojdbc6.jar'] {'mode': 0644} 2016-05-06 20:01:16,919 - Execute[('cp', '--remove-destination', '/var/lib/ambari-agent/tmp/ojdbc6.jar', '/usr/hdp/current/ranger-admin/ews/lib')] {'path': ['/bin', '/usr/bin/'], 'sudo': True} 2016-05-06 20:01:16,935 - File['/usr/hdp/current/ranger-admin/ews/lib/ojdbc6.jar'] {'mode': 0644} 2016-05-06 20:01:16,936 - ModifyPropertiesFile['/usr/hdp/current/ranger-admin/install.properties'] {'owner': 'ranger', 'properties': ...} 2016-05-06 20:01:16,938 - Modifying existing properties file: /usr/hdp/current/ranger-admin/install.properties 2016-05-06 20:01:16,961 - File['/usr/hdp/current/ranger-admin/install.properties'] {'owner': 'ranger', 'content': ..., 'group': None, 'mode': None, 'encoding': 'utf-8'} 2016-05-06 20:01:16,961 - Writing File['/usr/hdp/current/ranger-admin/install.properties'] because contents don't match 2016-05-06 20:01:16,962 - Separate DBA property not set. Assuming Ranger DB and DB User exists! 2016-05-06 20:01:16,963 - Execute['python /usr/hdp/current/ranger-admin/db_setup.py'] {'logoutput': True, 'environment': {'RANGER_ADMIN_HOME': '/usr/hdp/current/ranger-admin', 'JAVA_HOME': '/usr/java/jdk1.8.0_91'}, 'user': 'ranger'} 2016-05-06 20:01:17,108 [I] DB FLAVOR :ORACLE 2016-05-06 20:01:17,108 [I] --------- Verifying Ranger DB connection --------- 2016-05-06 20:01:17,108 [I] Checking connection 2016-05-06 20:01:17,109 [JISQL] /usr/java/jdk1.8.0_91/bin/java -Djava.security.egd=file:///dev/urandom -cp /usr/share/java/ojdbc7.jar:/usr/hdp/current/ranger-admin/jisql/lib/* org.apache.util.sql.Jisql -driver oraclethin -cstring jdbc:oracle:thin:@ora12cad2012.hortonworks.com -u 'rangeradmin' -p '********' -noheader -trim -c \; -query "select * from v$version;" Cannot find the driver class "oracle.jdbc.driver.OracleDriver" in the current classpath. 2016-05-06 20:01:17,298 [E] Can't establish connection! 016-05-10 15:16:40,606 - Writing File['/usr/hdp/current/ranger-admin/install.properties'] because contents don't match 2016-05-10 15:16:40,607 - Changing owner for /usr/hdp/current/ranger-admin/install.properties from 0 to ranger 2016-05-10 15:16:40,608 - Setting up Ranger DB and DB User 2016-05-10 15:16:40,608 - Execute['python /usr/hdp/current/ranger-admin/dba_script.py -q'] {'logoutput': True, 'environment': {'RANGER_ADMIN_HOME': '/usr/hdp/current/ranger-admin', 'JAVA_HOME': '/usr/java/jdk1.8.0_91'}, 'user': 'ranger'} 2016-05-10 15:16:40,805 [I] Running DBA setup script. QuiteMode:True 2016-05-10 15:16:40,805 [I] Using Java:/usr/java/jdk1.8.0_91/bin/java 2016-05-10 15:16:40,805 [I] DB FLAVOR:ORACLE 2016-05-10 15:16:40,805 [I] DB Host:ora12cad2012.hortonworks.com 2016-05-10 15:16:40,806 [I] ---------- Verifing DB root password ---------- 2016-05-10 15:16:40,806 [I] DBA root user password validated 2016-05-10 15:16:40,806 [I] ---------- Verifing Ranger Admin db user password ---------- 2016-05-10 15:16:40,807 [I] admin user password validated 2016-05-10 15:16:40,807 [I] ---------- Creating Ranger Admin db user ---------- 2016-05-10 15:16:40,807 [I] Checking connection 2016-05-10 15:16:40,808 [JISQL] /usr/java/jdk1.8.0_91/bin/java -Djava.security.egd=file:///dev/urandom -cp /usr/share/java/ojdbc7.jar:/usr/hdp/current/ranger-admin/jisql/lib/* org.apache.util.sql.Jisql -driver oraclethin -cstring jdbc:oracle:thin:@ora12cad2012.hortonworks.com -u 'sys as sysdba' -p '********' -noheader -trim -c \; -query "select * from v$version;" SQLException : SQL state: 08006 java.sql.SQLRecoverableException: IO Error: Invalid connection string format, a valid format is: "host:port:sid" ErrorCode: 17002 2016-05-10 15:16:42,139 [E] Can't establish connection,Change configuration or Contact Administrator!!

2 REPLIES 2

Re: Getting the following RANGER ADMIN installation error whilst installing on Oracle 12c DB. The Cluster is Kerberized against Active Directory 2012

Hi there @Prijan Kurup could you check the Oracle side too and see what the error messages (if any?) are there?

Re: Getting the following RANGER ADMIN installation error whilst installing on Oracle 12c DB. The Cluster is Kerberized against Active Directory 2012

@Prijan Kurup

Check your /usr/hdp/current/ranger-admin/install.properties file and make sure that your db_host like is defined properly for an Oracle database:

#db_host=host:port:SID          # for DB_FLAVOR=ORACLE                          #for SID example: db_host=localhost:1521:ORCL
#db_host=host:port/ServiceName  # for DB_FLAVOR=ORACLE                          #for Service example: db_host=localhost:1521/XE
Don't have an account?
Coming from Hortonworks? Activate your account here