Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

I get "fatal: unable to create threaded lstat" error when I run "git status" command

Tags:

git

linux

ssh

Hi StackOverflow Team!

Recently I got strange responses from git I use on my SiteGround hosting. When I run the git status command in my repository I get the following error:

serv01.ams38.siteground.eu [~/www/cledu (cart-editor)] git status
fatal: unable to create threaded lstat
serv01.ams38.siteground.eu [~/www/cledu (cart-editor)]

On the net I found few people having similar issues and I tried these commands:

git config --global pack.windowMemory "100m"
git config --global pack.packSizeLimit "100m"
git config --global pack.threads "1"
git config --global pack.deltaCacheSize "512MiB"

But it didn't solve the issue.

Can you help me to solve this?

Best, Chris.

like image 807
Chris Kepinski Avatar asked Oct 21 '15 09:10

Chris Kepinski


2 Answers

Increasing the virtual memory limit may help. We have fixed several such cases by increasing ulimit -v to 1048576 (1024M). This is an arbitrary value, which I believe is not unreasonably high and yet enough.

like image 37
Vladimir Kirov Avatar answered Nov 20 '22 00:11

Vladimir Kirov


If the resource limit can't be removed by the hosting provider, you could consider using git config to disable preloading of the index (threaded lstat).

git config core.preloadIndex false

If you need that setting when cloning the initial repository, then you will need to set it globally.

git config --global core.preloadIndex false
like image 152
Mark Waite Avatar answered Nov 19 '22 22:11

Mark Waite