Our Community is getting an upgrade! To get everything ready for the relaunch, we’ll be placing the site in read-only mode starting September 21st.
We really appreciate your understanding while we get things set up behind the scenes. Catch up on all the exciting details about the move here.
Need help or have questions? Drop us a line at [email protected]
Created on 12-21-2016 05:23 PM - edited 09-16-2022 01:37 AM
We get below error while installing new HDP version packages before upgrading to latest HDP version on SUSE linux.
2016-12-21 13:46:47,919 - Package Manager failed to install packages. Error: Execution of '/usr/bin/zypper --quiet install --auto-agree-with-licenses --no-confirm livy_2_3_2_0_2950' returned 104. File 'repomd.xml' from repository 'AMBARI-2.4.1.0.repo' is unsigned, continue? [yes/no] (no): no Error building the cache: [|] Valid metadata not found at specified URL(s) Warning: Disabling repository 'AMBARI-2.4.1.0.repo' because of the above error. File 'repomd.xml' from repository 'HDP.repo' is unsigned, continue? [yes/no] (no): no Error building the cache: [|] Valid metadata not found at specified URL(s) Warning: Disabling repository 'HDP.repo' because of the above error. No provider of 'livy_2_3_2_0_2950' found. Traceback (most recent call last): File "/var/lib/ambari-agent/cache/custom_actions/scripts/install_packages.py", line 376, in install_packages retry_count=agent_stack_retry_count File "/usr/lib/python2.6/site-packages/resource_management/core/base.py", line 155, in __init__ self.env.run() File "/usr/lib/python2.6/site-packages/resource_management/core/environment.py", line 160, in run self.run_action(resource, action) File "/usr/lib/python2.6/site-packages/resource_management/core/environment.py", line 124, in run_action provider_action() File "/usr/lib/python2.6/site-packages/resource_management/core/providers/package/__init__.py", line 58, in action_upgrade self.upgrade_package(package_name, self.resource.use_repos, self.resource.skip_repos) File "/usr/lib/python2.6/site-packages/resource_management/core/providers/package/zypper.py", line 62, in upgrade_package return self.install_package(name, use_repos, skip_repos, is_upgrade) File "/usr/lib/python2.6/site-packages/resource_management/core/providers/package/zypper.py", line 57, in install_package self.checked_call_with_retries(cmd, sudo=True, logoutput=self.get_logoutput()) File "/usr/lib/python2.6/site-packages/resource_management/core/providers/package/__init__.py", line 83, in checked_call_with_retries return self._call_with_retries(cmd, is_checked=True, **kwargs) File "/usr/lib/python2.6/site-packages/resource_management/core/providers/package/__init__.py", line 91, in _call_with_retries code, out = func(cmd, **kwargs) File "/usr/lib/python2.6/site-packages/resource_management/core/shell.py", line 71, in inner result = function(command, **kwargs) File "/usr/lib/python2.6/site-packages/resource_management/core/shell.py", line 93, in checked_call tries=tries, try_sleep=try_sleep) File "/usr/lib/python2.6/site-packages/resource_management/core/shell.py", line 141, in _call_wrapper result = _call(command, **kwargs_copy) File "/usr/lib/python2.6/site-packages/resource_management/core/shell.py", line 294, in _call raise Fail(err_msg) Fail: Execution of '/usr/bin/zypper --quiet install --auto-agree-with-licenses --no-confirm livy_2_3_2_0_2950' returned 104. File 'repomd.xml' from repository 'AMBARI-2.4.1.0.repo' is unsigned, continue? [yes/no] (no): no Error building the cache: [|] Valid metadata not found at specified URL(s) Warning: Disabling repository 'AMBARI-2.4.1.0.repo' because of the above error. File 'repomd.xml' from repository 'HDP.repo' is unsigned, continue? [yes/no] (no): no Error building the cache:
.
ROOT CAUSEThis is a BUG reported under https://issues.apache.org/jira/browse/AMBARI-19186 for SUSE linux if we are using unsigned repo.
. WORKAROUNDN/A
.
RESOLUTIONApply patch given at https://issues.apache.org/jira/browse/AMBARI-19186
Steps to Apply the patch:
1. Take a backup of /usr/lib/ambari-agent/lib/resource_management/libraries/functions/packages_analyzer.py
2. Edit /usr/lib/ambari-agent/lib/resource_management/libraries/functions/packages_analyzer.py with your favorite editor(I use vim)
3. Find the line with "--installed-only"
E.g
["sudo", "zypper", "search", "--installed-only", "--details"],
4. Replace it with:
["sudo", "zypper", "--no-gpg-checks", "search", "--installed-only", "--details"],
5. Find the line with "--uninstalled-only"
["sudo", "zypper", "search", "--uninstalled-only", "--details"],
6. Replace it with:
["sudo", "zypper", "--no-gpg-checks", "search", "--uninstalled-only", "--details"],
.
Note -If the host where you are having this issue is a ambari-agent, you only need to apply patch on below file:
/usr/lib/ambari-agent/lib/resource_management/libraries/functions/packages_analyzer.py
If the host where you are having an issue is ambari-server, you need to apply patch on below files:
/usr/lib/ambari-server/lib/resource_management/libraries/functions/packages_analyzer.py
/usr/lib/ambari-agent/lib/resource_management/libraries/functions/packages_analyzer.py
.