- on doing
pacman -Syu
, the checking available disk space
is almost always the slowest step
- and i always wonder why? like what makes it take sooo much time? and if it can be improved
- it’s performing nothing like downloading, extracting, copying, searching etc…
:: Starting full system upgrade...
resolving dependencies...
looking for conflicting packages...
Packages (63) ...
Total Download Size: 138.77 MiB
Total Installed Size: 886.21 MiB
Net Upgrade Size: -1.71 MiB
:: Proceed with installation? [Y/n]
:: Retrieving packages...
...
Total (63/63) ...
(63/63) checking keys in keyring ...
(63/63) checking package integrity ...
(63/63) loading package files ...
(63/63) checking for file conflicts ...
(63/63) checking available disk space ...
:: Processing package changes...
Years ago when I had checked it on very old HDD it was caused by Microsoft Defender. Even though I had added MSYS2 directory to the exceptions. Temporarily disabling the Defender made it much faster. I think Pacman might be doing something that is normal on Unix but slow when emulated by Cygwin on Windows/NTFS and also causes AV software to do a lot of unnecessary work.
I’ve posted very short tests results at https://github.com/msys2/msys2-pacman/issues/32#issuecomment-1973629270 TL;DR I recommend installing MSYS2 inside Dev Drives.
PS. Pressing
Alt
-Enter
for this directory in the Explorer exhibits calculation times around 26 seconds:This timing is more similar to Midipix (which uses NTAPI to get the metadata) than to MSYS2 (or Cygwin for that matter).
@goyalyashpal, here goes my results – one minute and a half:
Note that rerunning the command instantly didn’t change timing:
Maybe that’s due to MP Realtime Protection being off here at the moment:
Maybe you should check that and disable it if it’s enabled:
Note also, that run of an eleveated
du
is a bit shorter:I used gsudo for that.
We have had these reports before, but the problem is that it is only slow for some users. Here it is instant for example.
We need to find a way to reproduce.