git checkout file permission denied error

git switch to switch, a file is modified, and then execute git checkout, the following problems occur,

The environment is a local file mounted on the server

1. Check the permissions and find no problems.

2. Execute rm to delete on git, no error is reported, but the file still exists, and the file is modified as usual when git status is executed.

3. To delete the report locally requires administrator authority error, shift + delete force deletion, execution of git status is still an error, and then go to the local to see the file and come back.

4. Check on the server, the file does not exist.

5. The final solution: umount the local file, delete that file locally, and then mount it to the server, and it's back to normal. Permission denied is a permission problem. It may also be occupied by another program, and an error will be reported when another program operates.

Guess you like

Origin blog.csdn.net/u014608280/article/details/103496937