MSYS2-packages icon indicating copy to clipboard operation
MSYS2-packages copied to clipboard

pacman startup is very slow

Open jaykrell opened this issue 3 years ago • 4 comments

Run pacman, with no parameters, it takes a long time

jaykrell avatar Jun 23 '21 07:06 jaykrell

What is the output of time pacman command? Here is mine

$ time pacman
error: no operation specified (use -h for help)

real    0m1.283s
user    0m0.060s
sys     0m0.136s

Biswa96 avatar Jun 23 '21 07:06 Biswa96

$ time pacman

real 0m2.428s user 0m0.198s sys 0m0.631s

Earlier runs were slower though.

Also, run it under a debugger, it prints some garbage.

\bin\amd64\cdb /g /G C:\msys\usr\bin\pacman.exe

ModLoad: 00007ffac55b0000 00007ffac561a000 C:\WINDOWS\system32\mswsock.dll cYgSiGw00f 20 0x5B0C 0xFFFFDE50cYgSiGw00f 20 0x5B0C 0xFFFFDE50cYgSiGw00f 20 0x5B0C 0xFFFFDE50cYgSiGw00f 20 0x5B0C 0xFFFFDE50cYgSiGw00f 20 0x5B0C 0xFFFFDE50cYgSiGw00f 20 0x5B0C 0xFFFFDE50cYgSiGw00f 20 0x5B0C 0xFFFFDE50cYgSiGw00f 20 0x5B0C 0xFFFFDE50cYgSiGw00f 20 0x5B0C 0xFFFFDE50cYgSiGw00f 20 0x5B0C 0xFFFFDE50cYgSiGw00f 20 0x5B0C 0xFFFFDE50cYgSiGw00f 20 0x5B0C 0xFFFFDE50cYgSiGw00f 20 0x5B0C 0xFFFFDE50cYgSiGw00f 20 0x5B0C 0xFFFFDE50cYgSiGw00f 20 0x5B0C 0xFFFFDE50cYgSiGw00f 20 0x5B0C 0xFFFFDE50cYgSiGw00f 20 0x5B0C 0xFFFFDE50cYgSiGw00f 20 0x5B0C 0xFFFFDE50cYgSiGw00f 20 0x5B0C 0xFFFFDE50cYgSiGw00f 20 0x5B0C 0xFFFFDE50cYgSiGw00f 20 0x5B0C 0xFFFFDE50error: no operation specified (use -h for help)

jaykrell avatar Jun 23 '21 07:06 jaykrell

Found this report trying to ascertain if pacman -Ss taking a long time was normal. It's instantaneous on Arch.

$ time pacman
error: no operation specified (use -h for help)

real    0m8.255s
user    0m0.091s
sys     0m0.230s

$ time pacman -Ss asdf

real    0m8.850s
user    0m0.559s
sys     0m0.154s

Trying to run pacman under strace results in an endless loop eventually of:

--- Process 6660 (pid: 2321), exception c0000005 at 00000002ffeeffee

mosteo avatar Apr 27 '22 18:04 mosteo

$ time pacman -Q mingw
error: package 'mingw' was not found

real    0m4.288s
user    0m0.587s
sys     0m1.456s

$ time pacman
error: no operation specified (use -h for help)

real    0m3.484s
user    0m0.339s
sys     0m1.208s

goyalyashpal avatar Jul 01 '22 11:07 goyalyashpal