On 2022-11-26 19:58, to...@tuxteam.de wrote:
On Sat, Nov 26, 2022 at 09:55:49AM -0600, David Wright wrote:
On Sat 26 Nov 2022 at 14:00:39 (+0100), email.list...@gmail.com wrote:
Doing tab completion in my user account is quite sluggish, it takes
about half a second before anything happens after pressing tab.
I've done an strace on the shell and it turns out that when I press
tab bash does a select() on stdout that times out after half a second.
When I'm logged in as root and do the same thing bash does not do
that, so I presume it has something to do with how tab completion is
configured when I'm logged in to my regular user account. I'm not sure
how to investigate this further, any help would be appreciated. I'm
still on debian 10 and my version of bash is 5.0.3(1)
Do you have a networked filesystem in your PATH? Or a directory on
a slow device, like a stick or caddy? Remember to check symlinks.
Hm. The select() seems to suggest that the bash is waiting on a
socket. Can you see in the trace how the fd select is waiting
on was opened? Perhaps that gives a clue.
No the only two calls in the trace before select are to pselect6() and
read()
pselect6(1, [0], NULL, NULL, NULL, {[], 8}) = 1 (in [0]) <4.400862>
read(0, "\t", 1) = 1 <0.000081>
select(1, [0], NULL, [0], {tv_sec=0, tv_usec=500000}) = 0
(Timeout)<0.500679>
Cheers