Uploaded image for project: 'Slider'
  1. Slider
  2. SLIDER-1120

tomcat app package starting fails with exception wheh copy war resources to install dir

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Open
    • Major
    • Resolution: Unresolved
    • None
    • None
    • app-package
    • None
    • slider-0.91.0-incubating-SNAPSHOT
      hadoop 2.6

    Description

      I create tomcat app on my cluster using user yarn.but when starting tomcat component, throws Exception when copy application.resources to install webapps.

      Traceback (most recent call last):
      File "/hadoop/yarn/local/usercache/fys/appcache/application_1463037266860_0003/filecache/114/slider-tomcat-app-package-0.91.0-incubating-SNAPSHOT.zip/package/scripts/tomcat.py", line 80, in <module>
      Tomcat().execute()
      File "/hadoop/yarn/local/usercache/fys/appcache/application_1463037266860_0003/filecache/25/slider-agent.tar.gz/slider-agent/resource_management/libraries/script/script.py", line 116, in execute
      method(env)
      File "/hadoop/yarn/local/usercache/fys/appcache/application_1463037266860_0003/filecache/114/slider-tomcat-app-package-0.91.0-incubating-SNAPSHOT.zip/package/scripts/tomcat.py", line 47, in start
      self.configure(env)
      File "/hadoop/yarn/local/usercache/fys/appcache/application_1463037266860_0003/filecache/114/slider-tomcat-app-package-0.91.0-incubating-SNAPSHOT.zip/package/scripts/tomcat.py", line 40, in configure
      shutil.copy(full_resource_path, webapps_dir)
      File "/usr/lib64/python2.6/shutil.py", line 84, in copy
      copyfile(src, dst)
      File "/usr/lib64/python2.6/shutil.py", line 51, in copyfile
      with open(dst, 'wb') as fdst:
      IOError: [Errno 13] Permission denied: u'/hadoop/yarn/local/usercache/fys/appcache/application_1463037266860_0003/container_1463037266860_0003_01_000004/app/install/apache-tomcat-8.0.30/webapps/slider-test.war'

      belows is the sources file and dst file
      [root@sgserver004 resources]# ll slider-test.war
      lrwxrwxrwx 1 yarn hadoop 102 May 12 19:27 slider-test.war -> /hadoop/yarn/local/usercache/fys/appcache/application_1463037266860_0007/filecache/113/slider-test.war

      dst file:
      [root@sgserver004 webapps]# ll slider-test.war
      -r-x------ 1 yarn hadoop 0 May 12 19:27 slider-test.war

      I think errors is that , shutil.copy(src,dist) with src file with permission rwxrwxrwx,but dst file is -r-x------, but why?
      by the way , user yarn and root's umask is 0022

      Attachments

        Activity

          People

            Unassigned Unassigned
            fengyongshe Yongshe Feng
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

            Dates

              Created:
              Updated: