fatal: unable to get credential storage lock: File exists

后端 未结 9 1735
难免孤独
难免孤独 2021-02-05 00:24

I am using git-scm and tried to push to a repository. Upon doing so, I was greeted with the following message:

fatal: unable to get credential storage lock: File         


        
相关标签:
9条回答
  • 2021-02-05 00:58

    in my case on windows there was a git credentials .lock added in my c:\users\xxxx directory where all global git config lives.

    i deleted the lock file which also removed the git credentials file that stored my password in clear text

    0 讨论(0)
  • 2021-02-05 01:02

    I followed the instructions listed before in this thread and excecute this command: git config --list --show-origin, after that it shows the locations where git has any type of configuration, like this: file:"C:\ProgramData/Git/config" , "file:C:/Users/User/.gitconfig" , "file:.git/config".

    Then I dive into the folder file:C:/Users/User/ and remove the file called: .git-credentials.lock , then excecute "git pull origin branch" again and it works !!

    0 讨论(0)
  • 2021-02-05 01:05

    The error message comes from git credential-store (click for documentation page). It indicates that another instance of the credential storage program is currently running and has locked the file that (insecurely, in plain-text) stores your password.

    If no other instance of git credential-store is actually running, the lock file is no doubt left over from a previous run, and you can simply remove it. Unfortunately the program fails to tell you the location of the specific credentials file (but see the documentation for likely locations).

    0 讨论(0)
提交回复
热议问题