“git status -z -u”内存使用率过高?

“git status -z -u”内存使用率过高?

我运行的是 Ubuntu 16.04。最近我经常发现一两个“ git status -z -u”进程,每个进程都占用了5GB以上的内存。所以我试图弄清楚出了什么问题。 pstree 给了我一些像这样的输出:

systemd──lightdm──lightdm──upstart──2*[git]

显然暴发户启动了这些 git 进程。所以我尝试列出暴发户的所有工作

$ initctl list
indicator-application start/running, process 2364
unicast-local-avahi stop/waiting
update-notifier-crash stop/waiting
upstart-udev-bridge start/running, process 1773
update-notifier-hp-firmware stop/waiting
xsession-init stop/waiting
dbus start/running, process 1774
no-pinentry-gnome3 stop/waiting
update-notifier-cds stop/waiting
gnome-keyring-ssh stop/waiting
gnome-session (Unity) start/running, process 2007
ssh-agent stop/waiting
unity7 start/running, process 2132
upstart-dbus-session-bridge start/running, process 1812
gpg-agent start/running
indicator-messages start/running, process 2343
logrotate stop/waiting
indicator-bluetooth start/running, process 2344
unity-panel-service start/running, process 2009
hud start/running, process 1969
im-config start/running
unity-gtk-module stop/waiting
session-migration stop/waiting
upstart-dbus-system-bridge start/running, process 1811
at-spi2-registryd start/running, process 1999
indicator-power start/running, process 2345
update-notifier-release stop/waiting
indicator-datetime start/running, process 2346
indicator-keyboard start/running, process 2347
unity-settings-daemon start/running, process 1971
indicator-sound start/running, process 2348
upstart-file-bridge start/running, process 1817
bamfdaemon start/running, process 1828
gnome-keyring stop/waiting
window-stack-bridge start/running, process 1786
indicator-printers start/running, process 2349
re-exec stop/waiting
upstart-event-bridge stop/waiting
unity-panel-service-lockscreen stop/waiting
indicator-session start/running, process 2350

并且

$ initctl status
unity7 start/running, process 2132

我没有看到任何与这些 git 进程相关的内容。谁能给我一些提示,告诉我出了什么问题以及我应该如何定位我的问题?谢谢。

答案1

@DopeGhoti 的评论是正确的。就我而言,事实证明,这是 Visual Studio Code 从已安装的网络位置处理字典的问题。在 Visual Studio Code 中禁用 git 后,问题就消失了。

相关内容