Uploaded image for project: 'Jenkins'
  1. Jenkins
  2. JENKINS-50471

Linux /tmp directory mounted noexec breaks git clone

    • Icon: Bug Bug
    • Resolution: Fixed
    • Icon: Minor Minor
    • None
    • Jenkins ver. 2.107.1
      git-plugin 2.7.1
      kubernetes-plugin 1.4

      When I try to build something I always got this error:

       > git fetch --no-tags --progress git@bitbucket.org:xxxxxx/xxxxx.git +refs/heads/*:refs/remotes/origin/*
      ERROR: Error cloning remote repo 'origin'
      hudson.plugins.git.GitException: Command "git fetch --no-tags --progress git@bitbucket.org:xxxxxx/xxxxx.git +refs/heads/*:refs/remotes/origin/*" returned status code 128:
      stdout: 
      stderr: fatal: cannot exec '/home/jenkins/workspace/service-skeleton_master-7JMZPV5GKPYJ7FXGSQK6YYEOA6VIRJOEPUFA5ATSGLP5FPZSOMBA@tmp/ssh6122672630332030715.sh': Permission denied
      fatal: unable to fork
      
      

      It seems to look like what's described in Git plugin wiki: https://plugins.jenkins.io/git-client

       

      I just connected to my slave to check folder rights and everything belongs to the "jenkins" user... so I don't understand what is the problem.

       

      May it be a problem from Kubernetes?

       

      I'm looking for a solution for 2 days... But still blocked with this issue. Could you help me please? Thanks.

       

      NB: I've already ask help on IRC but no concluent solution

      PS: Additionnal info in comments

          [JENKINS-50471] Linux /tmp directory mounted noexec breaks git clone

          Thomas Ramé created issue -
          Thomas Ramé made changes -
          Description Original: When I try to build something I always got this error:
          {code:java}
           > git fetch --no-tags --progress git@bitbucket.org:xxxxxx/xxxxx.git +refs/heads/*:refs/remotes/origin/*
          ERROR: Error cloning remote repo 'origin'
          hudson.plugins.git.GitException: Command "git fetch --no-tags --progress git@bitbucket.org:xxxxxx/xxxxx.git +refs/heads/*:refs/remotes/origin/*" returned status code 128:
          stdout:
          stderr: fatal: cannot exec '/home/jenkins/workspace/service-skeleton_master-7JMZPV5GKPYJ7FXGSQK6YYEOA6VIRJOEPUFA5ATSGLP5FPZSOMBA@tmp/ssh6122672630332030715.sh': Permission denied
          fatal: unable to fork

          {code}
          It seems to look like what's described in Git plugin wiki: [https://plugins.jenkins.io/git-client]

           

          I just connected to my slave to check folder rights and everything belongs to the "jenkins" user... so I don't understand what is the problem.

           

          May it be a problem from Kubernetes?

           

          I'm looking for a solution for 2 days... But still blocked with this issue. Could you help me please? Thanks.

           

          NB: I've already ask help on IRC but no concluent solution :(
          New: When I try to build something I always got this error:
          {code:java}
           > git fetch --no-tags --progress git@bitbucket.org:xxxxxx/xxxxx.git +refs/heads/*:refs/remotes/origin/*
          ERROR: Error cloning remote repo 'origin'
          hudson.plugins.git.GitException: Command "git fetch --no-tags --progress git@bitbucket.org:xxxxxx/xxxxx.git +refs/heads/*:refs/remotes/origin/*" returned status code 128:
          stdout:
          stderr: fatal: cannot exec '/home/jenkins/workspace/service-skeleton_master-7JMZPV5GKPYJ7FXGSQK6YYEOA6VIRJOEPUFA5ATSGLP5FPZSOMBA@tmp/ssh6122672630332030715.sh': Permission denied
          fatal: unable to fork

          {code}
          It seems to look like what's described in Git plugin wiki: [https://plugins.jenkins.io/git-client]

           

          I just connected to my slave to check folder rights and everything belongs to the "jenkins" user... so I don't understand what is the problem.

           

          May it be a problem from Kubernetes?

           

          I'm looking for a solution for 2 days... But still blocked with this issue. Could you help me please? Thanks.

           

          NB: I've already ask help on IRC but no concluent solution :(

          PS: Additionnal info in comments
          Mark Waite made changes -
          Link New: This issue is related to JENKINS-26993 [ JENKINS-26993 ]
          Mark Waite made changes -
          Assignee Original: Mark Waite [ markewaite ]
          Mark Waite made changes -
          Summary Original: Insufficient permissions on the temp .sh file would make git commands fail with a stacktrace similar to the following New: Linux /tmp directory mounted noexec fails git clone
          Mark Waite made changes -
          Summary Original: Linux /tmp directory mounted noexec fails git clone New: Linux /tmp directory mounted noexec breaks git clone
          Thomas Ramé made changes -
          Resolution New: Fixed [ 1 ]
          Status Original: Open [ 1 ] New: Closed [ 6 ]
          Mark Waite made changes -
          Link New: This issue is duplicated by JENKINS-71453 [ JENKINS-71453 ]

            Unassigned Unassigned
            sneko Thomas Ramé
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

              Created:
              Updated:
              Resolved: