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.

Error encountered while installing HDF Services on HDP Cluster

Highlighted

Error encountered while installing HDF Services on HDP Cluster

New Contributor

INFO: Processing artifact hdp-addon-services of type stack-addon-service-definitions in /var/lib/ambari-server/resources/mpacks/hdf-ambari-mpack-3.1.1.0-35/hdp-addon-services/HDF/3.0 INFO: Loading properties from /etc/ambari-server/conf/ambari.properties Traceback (most recent call last): File "/usr/sbin/ambari-server.py", line 952, in <module> mainBody() File "/usr/sbin/ambari-server.py", line 922, in mainBody main(options, args, parser) File "/usr/sbin/ambari-server.py", line 874, in main action_obj.execute() File "/usr/sbin/ambari-server.py", line 78, in execute self.fn(*self.args, **self.kwargs) File "/usr/lib/python2.6/site-packages/ambari_server/setupMpacks.py", line 896, in install_mpack (mpack_metadata, mpack_name, mpack_version, mpack_staging_dir, mpack_archive_path) = _install_mpack(options, replay_mode) File "/usr/lib/python2.6/site-packages/ambari_server/setupMpacks.py", line 794, in _install_mpack process_stack_addon_service_definitions_artifact(artifact, artifact_source_dir, options) File "/usr/lib/python2.6/site-packages/ambari_server/setupMpacks.py", line 554, in process_stack_addon_service_definitions_artifact sudo.symlink(source_service_version_path, dest_link) File "/usr/lib/python2.6/site-packages/resource_management/core/sudo.py", line 123, in symlink os.symlink(source, link_name) OSError: [Errno 17] File exists

I also tried one of the solutions as below , but it didnt work.

Cause:
This issue occurs when the Symlink for NiFi and other HDF related services are present in the Resource Directories.
Solution:
To resolve this issue, do the following:

  1. Remove (preferred to backup) the directories which was created while installing HDF-mpacks using the following command:
    1. rm -rf /var/lib/ambari-server/resources/common-services/NIFI
    2. rm -rf /var/lib/ambari-server/resources/common-services/REGISTRY
    3. rm -rf /var/lib/ambari-server/resources/common-services/STREAMLINE
    4. rm -rf /var/lib/ambari-server/resources/mpacks /var/lib/ambari-server/resources/stacks/HDF
  2. Run the the command to install-mpacks for HDF.
5 REPLIES 5

Re: Error encountered while installing HDF Services on HDP Cluster

Hi @ASIF Khan,

from the exception

os.symlink(source, link_name) OSError: [Errno 17] File exists

it looks like some of the services you are trying to install exists .i think you should compare

/var/lib/ambari-server/resources/mpacks/hdf-ambari-mpack-3.1.1.0-35/hdp-addon-services/HDF/3.0 
and
/var/lib/ambari-server/resources/common-services/ 

and see which symlink already exists they are talking about.

you should analyze the contents of /var/lib/ambari-server/resources/common-services/ folder

Re: Error encountered while installing HDF Services on HDP Cluster

New Contributor

Tried again with HDF mpack 3.0 version , but still getting the same "File Exist" Error, i have deleted everything as below :

    1. rm -rf /var/lib/ambari-server/resources/common-services/NIFI
    2. rm -rf /var/lib/ambari-server/resources/common-services/REGISTRY
    3. rm -rf /var/lib/ambari-server/resources/common-services/STREAMLINE
    4. rm -rf /var/lib/ambari-server/resources/mpacks /var/lib/ambari-server/resources/stacks/HDF
  1. Run the the command to install-mpacks for HDF.

Error as below :

[root@sidchadoop01 tmp]# ambari-server install-mpack \ > --mpack=/tmp/hdf-ambari-mpack-3.0.1.0-43.tar.gz \ > --verbose Using python /usr/bin/python Installing management pack INFO: Loading properties from /etc/ambari-server/conf/ambari.properties INFO: Installing management pack /tmp/hdf-ambari-mpack-3.0.1.0-43.tar.gz INFO: Loading properties from /etc/ambari-server/conf/ambari.properties INFO: Download management pack to temp location /var/lib/ambari-server/data/tmp/hdf-ambari-mpack-3.0.1.0-43.tar.gz INFO: Loading properties from /etc/ambari-server/conf/ambari.properties INFO: Expand management pack at temp location /var/lib/ambari-server/data/tmp/hdf-ambari-mpack-3.0.1.0-43/ INFO: Loading properties from /etc/ambari-server/conf/ambari.properties INFO: Loading properties from /etc/ambari-server/conf/ambari.properties INFO: Stage management pack hdf-ambari-mpack-3.0.1.0-43 to staging location /var/lib/ambari-server/resources/mpacks/hdf-ambari-mpack-3.0.1.0-43 INFO: Processing artifact hdf-service-definitions of type service-definitions in /var/lib/ambari-server/resources/mpacks/hdf-ambari-mpack-3.0.1.0-43/common-services INFO: Loading properties from /etc/ambari-server/conf/ambari.properties INFO: Symlink: /var/lib/ambari-server/resources/common-services/NIFI/1.0.0 INFO: Symlink: /var/lib/ambari-server/resources/common-services/NIFI/1.1.0 INFO: Symlink: /var/lib/ambari-server/resources/common-services/NIFI/1.2.0 Traceback (most recent call last): File "/usr/sbin/ambari-server.py", line 952, in <module> mainBody() File "/usr/sbin/ambari-server.py", line 922, in mainBody main(options, args, parser) File "/usr/sbin/ambari-server.py", line 874, in main action_obj.execute() File "/usr/sbin/ambari-server.py", line 78, in execute self.fn(*self.args, **self.kwargs) File "/usr/lib/python2.6/site-packages/ambari_server/setupMpacks.py", line 896, in install_mpack (mpack_metadata, mpack_name, mpack_version, mpack_staging_dir, mpack_archive_path) = _install_mpack(options, replay_mode) File "/usr/lib/python2.6/site-packages/ambari_server/setupMpacks.py", line 792, in _install_mpack process_service_definitions_artifact(artifact, artifact_source_dir, options) File "/usr/lib/python2.6/site-packages/ambari_server/setupMpacks.py", line 515, in process_service_definitions_artifact create_symlink(src_service_definitions_dir, dest_service_definitions_dir, file, options.force) File "/usr/lib/python2.6/site-packages/ambari_server/setupMpacks.py", line 235, in create_symlink create_symlink_using_path(src_path, dest_link, force) File "/usr/lib/python2.6/site-packages/ambari_server/setupMpacks.py", line 247, in create_symlink_using_path sudo.symlink(src_path, dest_link) File "/usr/lib/python2.6/site-packages/resource_management/core/sudo.py", line 123, in symlink os.symlink(source, link_name) OSError: [Errno 17] File exists

Re: Error encountered while installing HDF Services on HDP Cluster

New Contributor
  1. @Akhil S Naik I tried to analyse but unable to understand which file exist, because i m deleting mpacks , hdf and all hdfs new services from common services from /var/lib/ambari-server/commonservices.

Re: Error encountered while installing HDF Services on HDP Cluster

New Contributor
  1. @Akhil S Naik I tried to analyse but unable to understand which file exist, because i m deleting mpacks , hdf and all hdfs new services from common services from /var/lib/ambari-server/commonservices.

Re: Error encountered while installing HDF Services on HDP Cluster

Cloudera Employee

Had same issue, i had to delete the following the resolve the mpack installation error:

NIFI and NIFI_REGISTRY from

/var/lib/ambari-server/resources/mpacks/hdf-ambari-mpack-3.1.2.0-7/hdp-addon-services/HDF/3.1/

Don't have an account?
Coming from Hortonworks? Activate your account here