致命错误:在“.git/objects/pack/tmp_idx_xxxx”上出现文件同步错误:权限被拒绝

fcg9iug3  于 2022-12-17  发布在  Git
关注(0)|答案(1)|浏览(277)

使用SCM中的Jenkins Pipeline脚本沿着git URL和凭据,但在构建后出现错误,
致命错误:在“.git/objects/pack/tmp_idx_9TRDF9”上出现文件同步错误:权限被拒绝致命错误:索引包失败

[BFA] Scanning build for known causes...
[BFA] No failure causes found
[BFA] Done. 0s
hudson.plugins.git.GitException: Command "git fetch --tags --progress origin +refs/heads/d11-packer:refs/remotes/origin/d11-packer --prune" returned status code 128:
stdout: 
stderr: remote: Enumerating objects: 65, done.        
remote: Counting objects:   1% (1/65)           
remote: Counting objects:   3% (2/65)           
remote: Counting objects:   4% (3/65) 
,
,

fatal: fsync error on '.git/objects/pack/tmp_idx_9TRDF9': Permission denied
fatal: index-pack failed

    at org.jenkinsci.plugins.gitclient.CliGitAPIImpl.launchCommandIn(CliGitAPIImpl.java:2042)
    at org.jenkinsci.plugins.gitclient.CliGitAPIImpl.launchCommandWithCredentials(CliGitAPIImpl.java:1761)
    at org.jenkinsci.plugins.gitclient.CliGitAPIImpl.access$400(CliGitAPIImpl.java:72)
    at org.jenkinsci.plugins.gitclient.CliGitAPIImpl$1.execute(CliGitAPIImpl.java:442)
    at jenkins.plugins.git.GitSCMFileSystem$BuilderImpl.build(GitSCMFileSystem.java:351)
    at jenkins.scm.api.SCMFileSystem.of(SCMFileSystem.java:198)
    at jenkins.scm.api.SCMFileSystem.of(SCMFileSystem.java:174)
    at org.jenkinsci.plugins.workflow.cps.CpsScmFlowDefinition.create(CpsScmFlowDefinition.java:108)
    at org.jenkinsci.plugins.workflow.cps.CpsScmFlowDefinition.create(CpsScmFlowDefinition.java:67)
    at org.jenkinsci.plugins.workflow.job.WorkflowRun.run(WorkflowRun.java:293)
    at hudson.model.ResourceController.execute(ResourceController.java:97)
    at hudson.model.Executor.run(Executor.java:429)
Finished: FAILURE
1wnzp6jl

1wnzp6jl1#

如果您试图以root用户身份添加或提交更改,则某些.git文件的所有者可能已设置为root用户。

相关问题