Details
-
Bug
-
Status: Resolved
-
Major
-
Resolution: Duplicate
-
branch-feature-AMBARI-21348
-
None
Description
Knox fails the restart during EU with error
"""
resource_management.core.exceptions.ExecutionFailed: Execution of 'cp -R -p -f /usr/hdp/4.2.0.0/knox/data/. /usr/hdp/current/knox-server/data' returned 1. cp: cannot stat '/usr/hdp/4.2.0.0/knox/data/.': No such file or directory
"""
This is because the common service Knox Py script assumes data dir is under stack_root which is /usr/hdp by the time it's Knox to restart during EU. But it also attaches the "current_version" obtained from command json file that points to 4.2.0.0 (or 4.2.5.0-0000) for the migration cluster. So the result root dir /usr/hdp/4.2.xxxx does not exist.
"""
ambari-server\src\main\resources\common-services\KNOX\0.5.0.2.2\package\scripts\upgrade.py
- <stack-root>/2.3.0.0-1234/knox/data/.
source_data_dir = os.path.join(params.stack_root, params.upgrade_from_version, "knox", "data", ".")
ambari-server\src\main\resources\common-services\KNOX\0.5.0.2.2\package\scripts\params_linux.py
upgrade_from_version = default("/hostLevelParams/current_version", None)
"""
"""
"hostLevelParams": {
"agent_stack_retry_on_unavailability": "false",
"stack_name": "HDP",
"group_list": "[\"spark\",\"hadoop\",\"users\",\"knox\"]",
"host_sys_prepped": "false",
"ambari_db_rca_username": "mapred",
"current_version": "4.2.0.0",
"""
Attachments
Attachments
Issue Links
- duplicates
-
AMBARI-21466 Knox upgrade fails due to wrong stack root
- Resolved