Uploaded image for project: 'Ambari'
  1. Ambari
  2. AMBARI-22966

ambari-agent fails to start

    XMLWordPrintableJSON

Details

    Description

      ambari-agent start gives the following exception:

      Traceback (most recent call last):
       File "/usr/lib/ambari-agent/lib/ambari_agent/main.py", line 92, in <module>
       import ProcessHelper
       File "/usr/lib/ambari-agent/lib/ambari_agent/ProcessHelper.py", line 25, in <module>
       from ambari_commons.shell import getTempFiles
       File "/usr/lib/ambari-agent/lib/ambari_commons/shell.py", line 30, in <module>
       from resource_management.core import sudo
       File "/usr/lib/ambari-agent/lib/resource_management/__init__.py", line 23, in <module>
       from resource_management.libraries import *
       File "/usr/lib/ambari-agent/lib/resource_management/libraries/__init__.py", line 23, in <module>
       from resource_management.libraries.functions import *
       File "/usr/lib/ambari-agent/lib/resource_management/libraries/functions/__init__.py", line 48, in <module>
       from resource_management.libraries.functions.log_process_information import *
       File "/usr/lib/ambari-agent/lib/resource_management/libraries/functions/log_process_information.py", line 22, in <module>
       from ambari_commons.shell import shellRunner
      ImportError: cannot import name shellRunner
      

      Most likely because of a circular dependency that was added by AMBARI-22888. Removing the sudo import from shell makes the problem go away.

      sudo -> resource_management.libraries.* -> resource_management.libraries.functions.* -> esource_management.libraries.functions.log_process_information.* -> ambari_commons.shell.shellRunner -> resource_management.core.sudo

      Attachments

        Issue Links

          Activity

            People

              hapylestat Dmytro Grinenko
              hapylestat Dmytro Grinenko
              Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved:

                Time Tracking

                  Estimated:
                  Original Estimate - Not Specified
                  Not Specified
                  Remaining:
                  Remaining Estimate - 0h
                  0h
                  Logged:
                  Time Spent - 1h
                  1h