Member since
01-19-2017
3676
Posts
632
Kudos Received
372
Solutions
My Accepted Solutions
| Title | Views | Posted |
|---|---|---|
| 609 | 06-04-2025 11:36 PM | |
| 1173 | 03-23-2025 05:23 AM | |
| 579 | 03-17-2025 10:18 AM | |
| 2182 | 03-05-2025 01:34 PM | |
| 1373 | 03-03-2025 01:09 PM |
08-26-2017
04:25 PM
2 Kudos
@L Hurley Great to hear it worked for you 🙂 Now you ought to reward the best answer so members can promptly help other members to resolve issues instantly @HCC Have a great weekend
... View more
08-26-2017
04:20 PM
@@Alexander Carreño How did you create your Postgres database? what was your choice Select n at Enter advanced database configuration? That shows it isn't the embedded but create manually right? There are 4 scripts in /var/lib/ambari-server/resources/ Ambari-DDL-Postgres-CREATE.sql
Ambari-DDL-Postgres-DROP.sql
Ambari-DDL-Postgres-EMBEDDED-CREATE.sql
Ambari-DDL-Postgres-EMBEDDED-DROP.sql So you have 2 choices Ambari-DDL-Postgres-EMBEDDED-DROP.sql and Ambari-DDL-Postgres-DROP.sql to use evidently, you can see the difference and run a new ambari setup.. Below is a silent option setup for embedded database option. ambari-server setup-s
--database=embedded|oracle|mysql|postgres
--databasehost=Hostname of database server
--databaseport=Database port
--databasename=Database/Schema/Service name or ServiceID
--databaseusername=Database user login
--databasepassword=Database user password Please drop and recreate the ambari database to enable you to continue. If you prefer Mysql or MariaDB follow the below steps ################################################
# Install MySQL or MariaDB database for Ambari on Centos/RHEL 7
###############################################
# yum install -y ambari-server or yum install -y mariadb-server
# chkconfig mysqld --level 345 on
# yum install -y mysql-connector-java
# service mysqld start
# service mysqld status
# ls /usr/share/java/mysql-connector-java.jar
################################################
# Startup at server bootup for MySQL or MariaDB database for Ambari on Centos/RHEL 7
###############################################
sudo systemctl enable mariadb
sudo systemctl start mariadb
sudo ambari-server setup --jdbc-db=mysql --jdbc-driver=/usr/share/java/mysql-connector-java.jar
#############################################
# Install MySQL database for Ambari
##############################################
# mysql -u root
UPDATE mysql.user SET Password=PASSWORD('welcome1') WHERE User='root';
flush privileges;
##############################
# Using Ambari user for MySQL
###################################
mysql -u root -pwelcome1
CREATE USER 'ambari'@'%' IDENTIFIED BY 'ambari';
GRANT ALL PRIVILEGES ON *.* TO 'ambari'@'%';
CREATE USER 'ambari'@'localhost' IDENTIFIED BY 'ambari';
GRANT ALL PRIVILEGES ON *.* TO 'ambari'@'localhost';
grant all privileges on *.* to 'ambari'@'localhost' identified by 'ambari';
CREATE USER 'ambari'@'bombo.uganda.com' IDENTIFIED BY 'ambari';
GRANT ALL PRIVILEGES ON *.* TO 'ambari'@'FQDN_for_Ambari';
FLUSH PRIVILEGES;
##################################################3
# Create the Ambari DB as user Ambari
###################################################
mysql -u ambari -pambari
CREATE DATABASE ambari;
USE ambari;
SOURCE /var/lib/ambari-server/resources/Ambari-DDL-MySQL-CREATE.sql; Now you can proceed with the ambari setup ##################################################
# Ambari setup
##################################################
# ambari-server setup --jdbc-db=mysql --jdbc-driver=/usr/share/java/mysql-connector-java.jar
##################################################
# Setup ambari-server for Mysql database.
##################################################
# ambari-server setup
Using python /usr/bin/python
Setup ambari-server
Checking SELinux...
SELinux status is 'enabled'
SELinux mode is 'permissive'
WARNING: SELinux is set to 'permissive' mode and temporarily disabled.
OK to continue [y/n] (y)? y
Customize user account for ambari-server daemon [y/n] (n)?
Adjusting ambari-server permissions and ownership...
Checking firewall status...
Checking JDK...
[1] Oracle JDK 1.8 + Java Cryptography Extension (JCE) Policy Files 8
[2] Oracle JDK 1.7 + Java Cryptography Extension (JCE) Policy Files 7
[3] Custom JDK
==============================================================================
Enter choice (1):
To download the Oracle JDK and the Java Cryptography Extension (JCE) Policy Files you must accept the license terms found at http://www.oracle.com/technetwork/java/javase/terms/license/index.html and not accepting will cancel the Ambari Server setup and you must install the JDK and JCE files manually.
Do you accept the Oracle Binary Code License Agreement [y/n] (y)?
Downloading JDK from http://public-repo-1.hortonworks.com/ARTIFACTS/jdk-8u77-linux-x64.tar.gz to /var/lib/ambari-server/resources/jdk-8u77-linux-x64.tar.gz
jdk-8u77-linux-x64.tar.gz... 100% (173.0 MB of 173.0 MB)
Successfully downloaded JDK distribution to /var/lib/ambari-server/resources/jdk-8u77-linux-x64.tar.gz
Installing JDK to /usr/jdk64/
Successfully installed JDK to /usr/jdk64/
Downloading JCE Policy archive from http://public-repo-1.hortonworks.com/ARTIFACTS/jce_policy-8.zip to /var/lib/ambari-server/resources/jce_policy-8.zip
Successfully downloaded JCE Policy archive to /var/lib/ambari-server/resources/jce_policy-8.zip
Installing JCE policy...
Completing setup...
Configuring database...
Enter advanced database configuration [y/n] (n)? y
Configuring database...
==============================================================================
Choose one of the following options:
[1] - PostgreSQL (Embedded)
[2] - Oracle
[3] - MySQL / MariaDB
[4] - PostgreSQL
[5] - Microsoft SQL Server (Tech Preview)
[6] - SQL Anywhere
[7] - BDB
==============================================================================
Enter choice (1): 3
Hostname (localhost):
Port (3306):
Database name (ambari):
Username (ambari):
Enter Database Password (bigdata):
Re-enter password:
Configuring ambari database...
Copying JDBC drivers to server resources...
Configuring remote database connection properties...
WARNING: Before starting Ambari Server, you must run the following DDL against the database to create the schema: /var/lib/ambari-server/resources/Ambari-DDL-MySQL-CREATE.sql
Proceed with configuring remote database connection properties [y/n] (y)?
Extracting system views...
ambari-admin-2.4.1.0.22.jar
...........
Adjusting ambari-server permissions and ownership...
Ambari Server 'setup' completed successfully. Hope that helps
... View more
08-26-2017
06:01 AM
@Alexander Carreño Check metainfo data in the databases psql -U ambari -d ambari;
Password for user ambari
psql (8.4.20) Type "help" for help.
ambari=> SELECT "metainfo_key", "metainfo_value" FROM metainfo; If you get 0 rows then continue with the below That's because the postgres table/db corruption.Please run the below command to reset postgres ambari DB # ambari-server reset
Using python /usr/bin/python Resetting ambari-server **** WARNING **** You are about to reset and clear the Ambari Server database.
This will remove all cluster host and configuration information from the database.
You will be required to re-configure the Ambari server and re-run the cluster wizard.
Are you SURE you want to perform the reset [yes/no] (no)? yes
Confirm server reset [yes/no](no)? yes
Resetting the Server database... Connecting to local database...done.
WARNING: Non critical error in DDL, use --verbose for more information Ambari Server 'reset' completed with warnings. Restart Ambari #ambari-server start All should run successfully and you should be able to log on. Please revert
... View more
08-25-2017
09:43 PM
1 Kudo
@L Hurley Then you need to start it to load the Ambari UI login page # ambari-server start Thats it
... View more
08-25-2017
09:21 PM
@Sam Red Panic NOT 🙂 Just to be sure of the step you took. 1. Did the Ambari kerberization succeed with errors? 2. Can you paste the contents of /etc/security/keytabs/* 3. Can you list principals in the KDC database? # kadmin.local
kadmin.local: listprincs 4.Did you make the changes I pointed out earlier 5. Can you share the files the below files remember to scramble the private details /etc/krb5.conf
/var/kerberos/krb5kdc/kdc.conf
/var/kerberos/krb5kdc/kadm5.acl 6. Can you validate that service keytabs were create on all host in /etc/security/keytabs/* where service like YARN,Zookeeper or ranger are installed. Please revert
... View more
08-25-2017
07:56 PM
1 Kudo
@Alexander Carreño I assume you referenced this official document The database creation script has to run as user awv_user and this user doesn't exist !! Did you run this step CREATE USER awv_user WITH PASSWORD 'xxxx'; Can you check that the permission is correct for the script in /var/lib/ambari-server/resources/Ambari-DDL-Postgres-CREATE.sql Please create the above user following the document above and retry.
... View more
08-25-2017
06:47 PM
@Sam Red 1) By the looks your /etc/krb5.conf doesn't look right. In the case your REALM is RELAY please follow strictly the below notice some are upper and lower case and also the .relay in teh domain_realm section. [libdefaults]
renew_lifetime = 7d
forwardable = true
default_realm = RELAY.COM
ticket_lifetime = 24h
dns_lookup_realm = false
dns_lookup_kdc = false
default_ccache_name = /tmp/krb5cc_%{uid}
#default_tgs_enctypes = aes des3-cbc-sha1 rc4 des-cbc-md5
#default_tkt_enctypes = aes des3-cbc-sha1 rc4 des-cbc-md5
[domain_realm]
relay.com = RELAY.COM
.relay.com = RELAY.COM
[logging]
default = FILE:/var/log/krb5kdc.log
admin_server = FILE:/var/log/kadmind.log
kdc = FILE:/var/log/krb5kdc.log
[realms]
RELAY.COM = {
admin_server = gulu.relay.com
kdc = gulu.relay.com
} 2) I see many entries where do the come from its wrong, there shouldn't be any entries except if you have a kerberos HA setup for the failover KDC kdc = IP
kdc = IP
kdc = IP
kdc = IP
kdc = IP
kdc = IP 3) Were the keytabs created correctly in /etc/security/keytabs/* ? Can you grab a valid kerberos ticket in the below example I first list the principal available for user opera1 whos keytab is opera1.keytab List principal for opera1 # klist -kt /etc/security/keytabs/opera1.keytab
Keytab name: FILE:/etc/security/keytabs/opera1.keytab
KVNO Timestamp Principal ---- -------------------
1 08/24/2017 18:28:26 opera1@RELAY.COM Grab a kerberos ticket # kinit -kt /etc/security/keytabs/opera1.keytab opera1@RELAY.COM List the kerberos ticket to see validity # klist
Ticket cache: FILE:/tmp/krb5cc_0
Default principal: opera1@RELAY.COM
Valid starting Expires Service principal
08/25/2017 20:33:43 08/26/2017 20:33:42 krbtgt/RELAY.COM@RELAY.COM Please let me know
... View more
08-25-2017
05:38 PM
@Sam Red if you are root the remove the sudo ! What is the output of # systemctl status krb5kdc.service The result should be # systemctl status krb5kdc.service
● krb5kdc.service - Kerberos 5 KDC
Loaded: loaded (/usr/lib/systemd/system/krb5kdc.service; enabled; vendor preset: disabled)
Active: active (running) since Thu 2017-08-24 15:30:12 CEST; 1 day 4h ago
Main PID: 23781 (krb5kdc)
CGroup: /system.slice/krb5kdc.service
└─23781 /usr/sbin/krb5kdc -P /var/run/krb5kdc.pid
Aug 24 15:30:12 bombay.test.com systemd[1]: Starting Kerberos 5 KDC...
Aug 24 15:30:12 bombay.test.com systemd[1]: Started Kerberos 5 KDC Please let me know
... View more
08-25-2017
02:48 PM
@Kasim Shaik In the cluster_config.json change the following Stack_version to match your version "2.x" In the hostmap.json change the masterx,datanodex or ambari-server to match FQDN of the machines. Make sure you have internal repos to match the entries in repo.json and dputil-repo.jso Cli.txt change the "ambari-server" to match your FQDN of your Ambai server and launch them in that order Remeber to rename the *.json.txt to *.json as HCC doesn't accept .json file type upload
... View more
08-25-2017
02:30 PM
@Kasim Shaik With 6 machines you could have 2 master nodes for HDFS HA
1 edge node with clients/Ambari server
3 data nodes What version of HDP? Will you use Mysql for hive/ranger/oozie ? Is that fine for you
... View more