Git commit takes long time

Answered

Hello, 

since a few days I have extem problems with commiting. It takes many minutes until a commit is performed. Following infos from the logs:

 

"C:\Program Files\Git\cmd\git.exe" -c core.quotepath=false -c log.showSignature=false cat-file --filters 800218e7bf97b4b7aa553d0f81f811f47f8ae1ff:src/main/java/com/de/system/mailservice/services/MessageReceiver.java
2022-06-22 11:29:51,930 [6645086]   INFO - #g.c.GitHandler - git cat-file took 73121 ms. Command parameters: 
"C:\Program Files\Git\cmd\git.exe" -c core.quotepath=false -c log.showSignature=false cat-file --filters 800218e7bf97b4b7aa553d0f81f811f47f8ae1ff:src/main/java/com/de/system/mailservice/services/MessageReceiver.java
2022-06-22 11:30:11,929 [6665085]   INFO - #g.c.GitHandler - git cat-file took 75932 ms. Command parameters: 
"C:\Program Files\Git\cmd\git.exe" -c core.quotepath=false -c log.showSignature=false cat-file --filters 800218e7bf97b4b7aa553d0f81f811f47f8ae1ff:src/main/resources/application.properties
2022-06-22 11:30:11,945 [6665101]   INFO - #g.c.GitHandler - git cat-file took 67954 ms. Command parameters: 
"C:\Program Files\Git\cmd\git.exe" -c core.quotepath=false -c log.showSignature=false cat-file --filters 800218e7bf97b4b7aa553d0f81f811f47f8ae1ff:pom.xml
2022-06-22 11:30:11,945 [6665101]   INFO - #g.c.GitHandler - git cat-file took 73834 ms. Command parameters: 
"C:\Program Files\Git\cmd\git.exe" -c core.quotepath=false -c log.showSignature=false cat-file --filters 800218e7bf97b4b7aa553d0f81f811f47f8ae1ff:pom.xml
2022-06-22 11:30:11,960 [6665116]   INFO - #g.c.GitHandler - git cat-file took 75491 ms. Command parameters: 
"C:\Program Files\Git\cmd\git.exe" -c core.quotepath=false -c log.showSignature=false cat-file --filters 800218e7bf97b4b7aa553d0f81f811f47f8ae1ff:src/main/resources/application-dev.properties
2022-06-22 11:30:11,960 [6665116]   INFO - #g.c.GitHandler - git cat-file took 73533 ms. Command parameters: 
"C:\Program Files\Git\cmd\git.exe" -c core.quotepath=false -c log.showSignature=false cat-file --filters 800218e7bf97b4b7aa553d0f81f811f47f8ae1ff:pom.xml
2022-06-22 11:30:11,960 [6665116]   INFO - #g.c.GitHandler - git config took 67560 ms. Command parameters: 
"C:\Program Files\JetBrains\IntelliJ IDEA 2020.1.2\bin\runnerw.exe" "C:\Program Files\Git\cmd\git.exe" -c core.quotepath=false -c log.showSignature=false config --null --get user.name
2022-06-22 11:30:11,991 [6665147]   INFO - #g.c.GitHandler - git rev-list took 58861 ms. Command parameters: 
"C:\Program Files\JetBrains\IntelliJ IDEA 2020.1.2\bin\runnerw.exe" "C:\Program Files\Git\cmd\git.exe" -c core.quotepath=false -c log.showSignature=false rev-list --count master..master@{u}
2022-06-22 11:30:58,274 [6711430]   INFO - #g.c.GitHandler - git config took 46314 ms. Command parameters: 
"C:\Program Files\JetBrains\IntelliJ IDEA 2020.1.2\bin\runnerw.exe" "C:\Program Files\Git\cmd\git.exe" -c core.quotepath=false -c log.showSignature=false config --null --get user.email
2022-06-22 11:30:58,304 [6711460]   INFO - #g.c.GitHandler - git rev-list took 46313 ms. Command parameters: 
"C:\Program Files\JetBrains\IntelliJ IDEA 2020.1.2\bin\runnerw.exe" "C:\Program Files\Git\cmd\git.exe" -c core.quotepath=false -c log.showSignature=false rev-list --count accountig_endpoints..accountig_endpoints@{u}
2022-06-22 11:32:18,883 [6792039]   INFO - #g.c.GitHandler - git config took 80604 ms. Command parameters: 
"C:\Program Files\JetBrains\IntelliJ IDEA 2020.1.2\bin\runnerw.exe" "C:\Program Files\Git\cmd\git.exe" -c core.quotepath=false -c log.showSignature=false config core.autocrlf

 

As you can see some commands like git config needs more than one minute. Running same comands in cmd or IntelliJ Terminal works much faster

1
19 comments

Do you have an antivirus software installed by any chance? What git executables are used in IDE (Preferences | Version Control | Git) and in cmd.exe?

0

I’m experiencing the same issue — it seems to have started with version 2025.2.1.
I’m currently using version 2025.2.3, and the problem still occurs. Commits in the IDE take 2–3 minutes, while from the command line they complete in just a few seconds. Previously commits were very fast.

 

0

Szopal69 
Thank you for the report!

Could you please share a screenshot of the Commit options (see image below)? To see which commit checks are enabled. It could be that some checks are taking a long time which results in Commit operation being slow. You can share it via our FTP server: https://uploads.jetbrains.com, just provide the uploaded file ID.

Commits in the IDE take 2–3 minutes, while from the command line they complete in just a few seconds.

Are you using the same git executable in the IDE (Settings (⌘ + , or Ctrl + Alt + S) > Version Control > Git > Path to git executable) and when running the commands in command line (e.g. git bash)?

0

Yes:
 

 

However, even if I disable all the options, nothing changes. Below I’m attaching the IDE settings.
 

# custom IntelliJ IDEA VM options (expand/override 'bin\idea64.exe.vmoptions')
-Dide.usages.page.size=1000

-Xms4G
-Xmx12G
-XX:MaxMetaspaceSize=4096m
-XX:+UseG1GC
-XX:+UseStringDeduplication
-XX:ReservedCodeCacheSize=1024m
-Xss2m
-Dfile.encoding=UTF-8
-XX:+AlwaysPreTouch
-XX:ErrorFile=$USER_HOME/java_error_in_idea_%p.log
-XX:HeapDumpPath=$USER_HOME/java_error_in_idea.hprof
-XX:+HeapDumpOnOutOfMemoryError
-XX:+ExitOnOutOfMemoryError

$ where git
C:\Program Files\Git\mingw64\bin\git.exe
C:\Program Files\Git\cmd\git.exe
0

Thank you for the information.

Could you please enable debug logging by adding the following lines to Help > Diagnostic Tools > Debug Log Settings..:

time.git4idea

restart IDE, reproduce the issue again and share your IDE logs (Help > Collect Logs and Diagnostic Data)?
Logs contain useful information about your environment and potentially some errors/exceptions related to the issue.

0

Which files should I send? Due to company policy, I cannot share files that might contain sensitive data, so I need to verify them for this before sending. Additionally, sometimes even though a file has been modified, IntelliJ takes a very long time (several minutes) to show the changes in the Commit tab, even though the git status command indicates that the file has changed. Only after a few minutes does the modified file appear in the Commit tab. Similarly, performing a rollback through the IDE also takes a long time.

 

0

Thank you for the update. Could you please share the idea.log file? Only JetBrains team will have access to it if you upload to our secure FTP server.

0

Ok. How can I upload the file to that server?

0

Oh sorry. It is the same as I shared in my first note - you can share it via our FTP server: https://uploads.jetbrains.com, just provide the uploaded file ID. Thank you!

0

Thanks!

Upload id: 2025_10_20_NCmbDbjfhEjBEWer4dWd8N (files: idea.log, 2025-10-20 10-18-37.mp4)

0

Thank you for the logs and screen recording. I see that not only git operations from the IDE are slow, but even the Commit tool window refresh action takes a long time. As a test, could you please temporarily disable all downloaded/non-bundled plugins? To check if it will affect the behavior in any way.

It is possible to re-enable downloaded plugins easily when required - the same way as disabling them.

0

Unfortunately, after disabling the downloaded plugins, the same issue still occurs.

 

Upload id: 2025_10_20_8XFAPd7tAzc6aF4wzRR6n6 (files: 2025-10-20 15-22-07.mp4, 2025-10-20 15-25-21.mp4)

0

Thank you for the additional screen recordings.

Could you please record and share a CPU snapshot while the IDE is performing slowly?

If you don't have the option to record a CPU snapshot, please check if Performance Testing plugin is installed and enabled.

0

Due to the extremely slow performance of IDE version 2025.3.2, I decided to uninstall it and install an older version

IntelliJ IDEA 2024.3.7 (Ultimate Edition)
Build #IU-243.28141.18, built on September 10, 2025
Licensed to ************

Runtime version: 21.0.7+9-b631.52 amd64 (JCEF 122.1.9)
VM: OpenJDK 64-Bit Server VM by JetBrains s.r.o.
Toolkit: sun.awt.windows.WToolkit
Windows 11.0
GC: G1 Young Generation, G1 Concurrent GC, G1 Old Generation
Memory: 10240M
Cores: 20
Registry:
 ide.experimental.ui=true
Non-Bundled Plugins:
 EclipseCodeFormatter (23.5.241.000.0-Eclipse_2024-09)
 software.xdev.saveactions (1.4.2)
 org.jetbrains.plugins.spotbugs (1.2.8)
 izhangzhihao.rainbow.brackets (2025.3.5)
 com.github.copilot (1.5.58-243)
 org.sonarlint.idea (11.3.1.82568)
 com.mallowigi (101.2.0)
 zielu.gittoolbox (600.1.12+243)
 com.baomidou.plugin.idea.mybatisx (1.7.3)
Kotlin: 243.28141.18-IJ
 

In version 2024, everything returned to normal — Git-related operations are now very fast, Maven projects are properly linked, and Java classes are correctly detected (in 2025 there was an issue with recognizing the sources, resources, test sources, and test resources directories).

I should add that I performed the same steps with version 2025.2.1 — I uninstalled it, cleared the caches, and then installed 2025.2.3 — but the issue still persisted. It seems that something changed between versions 2024 and 2025, as I noticed that the IDE started running slowly and encountering problems right after upgrading to the 2025 release.

Unfortunately, due to the nature of my work, I couldn’t afford to continue using such a slow IDE, so I’m unable to provide CPU profiling results at this time.

0

Szopal69 
I'm sorry to hear it. 

Unfortunately, without additional diagnostic information (such as CPU snapshot) it is hard to investigate the issue further and find the root cause. If you find some time in the future and if you're willing - you can install the latest version of the IDE in parallel to the previous one (2024.3.x), without updating it, and try to record the CPU snapshot while the IDE is performing slowly. It would help us to analyze the issue further. Thank you for your patience and collaboration.

0

Ok, I'll try it.

1

I have the same problem and recorded a CPU snapshot: Upload id: 2025_11_06_MnfYzLKx2nN1pNM2C7tVZx (file: IU-252.27397.103_05.11.2025_12.05.10.zip)

0

Ivan Pajic was my CPU snapshot helpful?
The issue is really annoying.

0

Hello Aalexx Albrecht ,
Unfortunately, we couldn't find anything suspicious in the shared snapshot. Could you please create a new issue report in YT: https://youtrack.jetbrains.com/newIssue?project=IJPL and provide more details, such as:

  • steps to reproduce
  • debug logs for git4idea.commands.GitHandler , time.git4idea
  • screen recording of the issue in your IDE
  • when you execute a commit command from the command line (outside of IDE), does the issue occur?

Many thanks in advance!

0

Please sign in to leave a comment.