Member since
03-14-2016
4721
Posts
1111
Kudos Received
874
Solutions
My Accepted Solutions
| Title | Views | Posted |
|---|---|---|
| 2825 | 04-27-2020 03:48 AM | |
| 5479 | 04-26-2020 06:18 PM | |
| 4662 | 04-26-2020 06:05 PM | |
| 3704 | 04-13-2020 08:53 PM | |
| 5604 | 03-31-2020 02:10 AM |
11-20-2019
01:39 PM
@KaviTiwari Please make sure to set the "PYTHONPATH" variable to point to ambari agent lib directory as following: # export PYTHONPATH=/usr/lib/ambari-agent/lib:$PYTHONPATH
# python test_alert_disk_space.py .
... View more
11-14-2019
08:00 PM
3 Kudos
@JayZhang Until the mentioned JIRA is fixed permanently can you please try this workaround. One time One line change inside the "/usr/lib/ambari-server/web/javascripts/app.js" file should work. Step-1). Take a Safe Backup of the file "/usr/lib/ambari-server/web/javascripts/app.js" on ambari server host. # cp -f /usr/lib/ambari-server/web/javascripts/app.js /PATH/To/Backup/app.js.ORIGINAL Step-2). Also just above the "App.YarnContainersView = App.TextDashboardWidgetView.extend" line inside the above file you will see a function declaration like "counterOr" we will need to make one change there. (BEFORE CHANGE) # grep -B12 'App.YarnContainersView' /usr/lib/ambari-server/web/javascripts/app.js
var App = require('app');
function counterOrNA(key) {
var _key = 'model.{0}.length'.format(key);
return Em.computed(_key, function () {
if (Em.isNone(this.get('model.' + key)) || this.get('model.metricsNotAvailable')) {
return Em.I18n.t('services.service.summary.notAvailable');
}
return this.get(_key);
});
} Step-3). IN the above function block you will see a line as "var _key = 'model.{0}.length'.format(key);" We need to just remove the ".length" work from that string. (AFTER CHANGE) # grep -B12 'App.YarnContainersView' /usr/lib/ambari-server/web/javascripts/app.js
var App = require('app');
function counterOrNA(key) {
var _key = 'model.{0}'.format(key);
return Em.computed(_key, function () {
if (Em.isNone(this.get('model.' + key)) || this.get('model.metricsNotAvailable')) {
return Em.I18n.t('services.service.summary.notAvailable');
}
return this.get(_key);
});
} Step-4). Save the file and then Hard Refresh the Browser. On Mac (command + Shift + R)
... View more
11-13-2019
01:59 AM
@asmarz We see the sudoer error. Command start time 2019-11-13 10:43:52
bash: /var/lib/ambari-agent/tmp/ambari-sudo.sh: Permission denied So please make sure that Either you are running amabri agent as "root" user. You can verify it by looking at the following property: # grep run_as /etc/ambari-agent/conf/ambari-agent.ini
run_as_user=root OR You have configured the Sudoer permissions properly as mentioned in the doc: https://docs.cloudera.com/HDPDocuments/HDP3/HDP-3.1.4/securing-credentials/content/ambari_sec_how_to_configure_an_ambari_agent_for_non_root.html
... View more
11-13-2019
01:33 AM
@asmarz Can you try this once. Copy the "/var/lib/ambari-server/create-python-wrap.sh" file from Ambari Server node and then Place it on the problematic Agent node at "/var/lib/ambari-agent/tmp/create-python-wrap.sh" and then again try to run the same command again and then verify if it creates the link? # sh -x /var/lib/ambari-agent/tmp/create-python-wrap.sh . Also pleas verify if you are using correct ambari agent binary on the host? # rpm -qa | grep ambari
# grep ambari /var/log/yum.log .
... View more
11-13-2019
01:18 AM
@asmarz On the Ambari Agent host where you are observing this issue please try this. You will find a file like following "/var/lib/ambari-agent/tmp/create-python-wrap.sh". Can you please try to run that file manually as "root" user like? # sh -x /var/lib/ambari-agent/tmp/create-python-wrap.sh Above should create the mentioned symlink ... but if it does not work then please share the Full output of the above commend from the terminal as it is. . Once the above script is executed fine then please check if the link is created properly or not? # ls -l /usr/bin//ambari-python-wrap
... View more
11-12-2019
09:51 PM
1 Kudo
@sagittarian As we see the error "" means permission related error on the mentioned directory. Later when we look at the directory ownership then we find it as ""/user/hive/warehouse/postgres":hdfs:hive:drwxrwx--x" Usually, the "/user/hive" or "/user/hive/warehouse" directory ownership is like "hive:hdfs" (where "hdfs" is the superuser group), But in your case it is hdfs:hive (instead of hive::hdfs) Example: (please double check these dir permissions) # su - hdfs -c "hdfs dfs -ls /user/hive"
# su - hdfs -c "hdfs dfs -ls /user/hive/warehouse"
# su - hdfs -c "hdfs dfs -ls /user/hive/warehouse/postgres" So please verify that once. And also please verify if the user "nthumu" belongs to the correct Group? # id nthumu .
... View more
11-12-2019
09:15 PM
@asmarz Try reinstalling Ambari Agent Binaries once. Ideally there should be a Symlink created as following when you successfully install Ambari Agent Binary to a host. The symlink points to a Python binary installed on that host. Example: # ls -lart /usr/bin/ambari-python-wrap
lrwxrwxrwx. 1 root root 15 Feb 15 2019 /usr/bin/ambari-python-wrap -> /usr/bin/python . Try reinstalling ambari agent. # which python
# ls -l /usr/bin/python
# /usr/bin/python -V
# yum reinstall ambari-agent
# ls -lart /usr/bin/ambari-python-wrap .
... View more
11-06-2019
03:43 AM
@Kou_Bou As we see that you are getting following kind of error "certificate_unknown" in AmbariServer logs 06 Nov 2019 12:06:35,805 WARN [qtp-ambari-agent-68] nio:720 - javax.net.ssl.SSLException: Received fatal alert: certificate_unknown
06 Nov 2019 12:06:35,904 WARN [qtp-ambari-agent-67] SecurityFilter:103 - Request <a href="https://192.168.253.45:8440/" target="_blank">https://192.168.253.45:8440/</a> doesn't match any patter Hence you should try to delete the OLD certificates from agent machine and then try again. As the old Agent certificates might be having incorrect names. # rm /var/lib/ambari-agent/keys/*
# ambari-agent restart While restarting it should fetch correct certificates from ambari server. . . If your question is answered then, Please make sure to mark the answer as the accepted solution. If you find a reply useful, say thanks by clicking on the thumbs up button.
... View more
11-06-2019
02:43 AM
@Kou_Bou Your "/etc/hosts" file should have the FQDN info of AmbariServer (do not use localhost) to point to ambari server. Also please change the "ambari-agent.ini" to point to the AmbariServer FQDN instead of using "localhost" https://docs.cloudera.com/HDPDocuments/Ambari-2.7.4.0/administering-ambari/content/amb_install_the_ambari_agents_manually_on_rhel-centos-oracle_7.html On each Agent node, stop the Agent.
# ambari-agent stop
Using a text editor, edit /etc/ambari-agent/conf/ambari-agent.ini to point to the new host.
[server]
hostname=$NEW FULLY.QUALIFIED.DOMAIN.NAME
url_port=8440
secured_url_port=8441 .
... View more
11-06-2019
01:35 AM
@Kou_Bou As we see the following message: WARNING 2019-11-06 09:46:39,683 NetUtil.py:93 - Failed to connect to https://localhost:8440/ca due to [Errno 111] Connection refused Which indicates that the Ambari Agent is trying to conect to the AmbariServer running in Localmachine "localhost". Ideally it should be using the FQDN of ambari server instead of "localhost:8440". So can you please try this: 1). please edit the "/etc/ambari-agent/conf/ambari-agent.ini" hostname to point to the FQDN (fully Qualified Hostname) of AmbariServer instead of localhost. Please make sure to replace the "ambariserverhost.example.com" with the actual FQDN of your ambari server. Example: # grep -A1 '\[server\]' /etc/ambari-agent/conf/ambari-agent.ini
[server]
hostname=ambariserverhost.example.com 2. Then restart Ambari Agent. # ambari-agent restart
# cat /etc/hosts 3. Now verify iof you are able to connect to the mentioned AmbariServer FQDN and Port from the agent machine as following? # telnet ambariserverhost.example.com 8440
(OR)
# nc -v ambariserverhost.example.com 8440 4. Also please make sure that the iptables/firewall is disabled on AmbariServer host and port 8440 is listening Example: # netstat -tnlpa | grep `cat /var/run/ambari-server/ambari-server.pid`
tcp6 0 0 :::8080 :::* LISTEN 7463/java
tcp6 0 0 :::8440 :::* LISTEN 7463/java .
... View more