Git 推送到网络驱动器:无法预读包文件

Git Push to Network Drive: Cannot pread pack file

我正在尝试本地推送到网络驱动器上的共享存储库。我收到以下错误:

:~/git push origin master
Counting objects ... done
Writing objects ...
Total ....

然后:

fatal: cannot pread pack file: No Permission
error: unpack failed: index-pack abnormal exit
To /networkshare/repo.git
! [remote rejected] master -> master (n/a unpack error)

远程目录的权限是这样的:

:~/ls -all
drwxr-xr-x ndbd MyGroup  Date  Repo.Git

有线索吗?

此错误消息来自 builtin/index-pack.c#unpack_data
它调用 wrapper.c#xpread which wraps pread (man page)

If successful, the number of bytes actually read is returned.
Upon read-ing end-of-file, zero is returned.
Otherwise, a -1 is returned and the global variable errno is set to indicate the error.

权限声明只有 ndbd 用户有权写入 到已安装的文件夹。但阅读应该有效。
您需要检查网络驱动器上 git 推送操作创建的 git packfiles 的权限,以查看是否适用相同的权限。

它们在 /networkshare/repo.git/objects/networkshare/repo.git/objects/info/packs/networkshare/repo.git/objects/pack/pack-*.idx