You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Setup (please complete the following information):
Distribution: pkgsrc
Distribution release: HEAD
Geeqie version 3.1
Describe the bug
I've just updated the package to 3.1.
Pressing 'delete' seems to delete a file - the preview of the file is replaced with the gray checkerboard
pattern. However, in previous versions (2.9) the deleted file was also removed from the file list in the directory
view on the left, and the next file in the list was displayed.
To reproduce
delete a file (in a directory with multiple files).
Expected behavior
see above
Screenshots
I can provide some but I hope the description is clear enough.
Image sources
any
Error logs or seg. fault files
no visible error
Additional context
That's on NetBSD 11.99.7/x86_64, but I was using 2.9 in the same environment, so it shouldn't matter, I hope.
Just went back to 2.9 (so same basic dependencies except for what changed between 2.9 and 3.1, i.e. gtk3 vs. gtk4) to confirm and yes, deletion is quick, the file is removed from the list and the next file is shown.
@przepompownia's observation here (selection of 2+ files survives the deletion, 100% CPU) is the same loop as in #2569: the GPS map pane re-reads the metadata of the deleted files in an idle callback, which triggers NOTIFY_REREAD again and starves the file list refresh. #2641 fixes that.
@0-wiz-0, if your setup also has the GPS map pane in the sidebar, #2641 will most likely fix your case too. If not, it may be a different cause. Thanks for Geeqie, everyone!
No, my slowdown is not related to that. I've tried git head and it was the same speed.
The files are on NFS, the directory has > 1000 files of around 4-8MB each; deleting a file and showing the next one takes around 5 seconds each. I'm not sure if uses a trash on this file system; I don't think so, a .Trash-1000 directory exists at the mount point but the files in there are from 2025.
Reading the ktrace a bit, I think the slowdown is mostly because geeqie really likes to stat files.
After the delete, it stats every file in the directory again; each of the stats takes around 1.5 ms (because the files are on NFS), so in total that's already 1.5 seconds. However, it not only does an stat, but also an lstat - for every file - so we're up to 3s for this alone.
typical ktrace example for one of the files in the directory (in NetBSD kdump -e format, i.e. timestamp is column 4):
The first diff is a hack, it checks if the file name starts with a dot to decide if the file is "hidden" - but this gets rid of half of the stats - only one stat per file instead of two. Perhaps it gives you some idea how to speed this up?
The second diff (same file) updates the directory metadata after every refresh. This avoids that the regular file system monitor immediately re-checks the same directory after a file was deleted and its corresponding information in memory was already updated.
So the second diff removes a hang of about ~3s shortly after every delete.
Another idea (that is too big for me to implement) is to update the in-memory file list when a file is deleted directly - remove the file there too, instead of triggering a full rescan of the directory. That would save 3s again (if the directory state for the monitor is updated similar to what happens in the second diff) and be a big speedup.
Sorry, I just tried again and it's slow with gtk3 too.
Can you please look at the code paths I pointed out? They are based on what I found with the timings looking at ktrace here.
geeqie does two stats per file after a delete, and that is just slow. Can these stats be reduced, please?
I am a bit reluctant to make a blind fix when I cannot see the problem.
If you can make the edits you suggest to your system and verify that it solves the problem for you, I will check there are no adverse effects on my system - and if so, make the commit to the main repo.
I also am experiencing extreme slowness on NetBSD 11 with geeqie 3.2. I am building from pkgsrc. My images are on ZFS on ssd. Even in a directory with 14 images, after pagedown through all and clicking back to the top, I am finding pagedown very laggy. Sometimes it is perceptible, just, and sometimes it feels like a whole second. This is not deleting - this is just pageup/pagdown. It could be that what I'm seeing is different from what 0-wiz-0 is seing.
My image files are jpg (earlier processed from raw), ranging from 140KB to 2.4MB. The biggest dimension is 2149 pixels. These are really not big files these days.
I'm guessing that you don't see it because your NFS implementation (Linux?) caches file attributes by default. Can you try turning that off? Reading the nfs man page I think that 'noac' or 'actimeo=0' might be relevant options for that.
Even in a directory with 14 images, after pagedown through all and clicking back to the top, I am finding pagedown very laggy. Sometimes it is perceptible, just, and sometimes it feels like a whole second. This is not deleting - this is just pageup/pagdown. It could be that what I'm seeing is different from what 0-wiz-0 is seing.
Could this be suggesting that we need debouncing to avoid expensive operations of loading intermediate files too quickly when navigating forward or backward?
I have just been reading over ktrace from starting geeqie, watiting, pushing page down once, waiting, ^Q. At the time of pushing pagedown, there are a huge number (264) of NAMI invocations in the kernel (file name to inode translation, corresponding to some system call). Most of them look duplicative, and many don't make sense - moving to the next file should simply display that file, which would be open/read/close of it. or open/mmap/close. and it could be not that file, but the next one, if there's pre-caching.
The system calls each seem pretty fast, but 10 us here, 50 us here, times a big number, plus whatever was really needed, seems to have added up to 300 ms.
If you do this, with strace or whatever the "log system calls" tool is, do you see only system calls that make sense, or do you see a lot?
Activity
0-wiz-0 commentedon Aug 9, 2026
Just went back to 2.9 (so same basic dependencies except for what changed between 2.9 and 3.1, i.e. gtk3 vs. gtk4) to confirm and yes, deletion is quick, the file is removed from the list and the next file is shown.
0-wiz-0 commentedon Aug 12, 2026
Another NetBSD users reports it works fine in his setup, so this might be limited to setups using VNC as display.
przepompownia commentedon Sep 15, 2026
przepompownia commentedon Sep 17, 2026
przepompownia commentedon Sep 17, 2026
alfonx commentedon Sep 26, 2026
@przepompownia's observation here (selection of 2+ files survives the deletion, 100% CPU) is the same loop as in #2569: the GPS map pane re-reads the metadata of the deleted files in an idle callback, which triggers
NOTIFY_REREADagain and starves the file list refresh. #2641 fixes that.@0-wiz-0, if your setup also has the GPS map pane in the sidebar, #2641 will most likely fix your case too. If not, it may be a different cause. Thanks for Geeqie, everyone!
0-wiz-0 commentedon Sep 26, 2026
I don't have the libshumate dependency installed when building, so I think I see a different issue.
przepompownia commentedon Sep 26, 2026
caclark commentedon Oct 1, 2026
Is this fixed by 1492d3e ?
0-wiz-0 commentedon Oct 4, 2026
No, my slowdown is not related to that. I've tried git head and it was the same speed.
The files are on NFS, the directory has > 1000 files of around 4-8MB each; deleting a file and showing the next one takes around 5 seconds each. I'm not sure if uses a trash on this file system; I don't think so, a .Trash-1000 directory exists at the mount point but the files in there are from 2025.
0-wiz-0 commentedon Oct 5, 2026
Reading the ktrace a bit, I think the slowdown is mostly because geeqie really likes to stat files.
After the delete, it stats every file in the directory again; each of the stats takes around 1.5 ms (because the files are on NFS), so in total that's already 1.5 seconds. However, it not only does an stat, but also an lstat - for every file - so we're up to 3s for this alone.
typical ktrace example for one of the files in the directory (in NetBSD kdump -e format, i.e. timestamp is column 4):
[-]delete: removed file still in list[/-][+]delete: slow on NFS[/+]0-wiz-0 commentedon Oct 6, 2026
Here's some ideas how to make it faster.
The first diff is a hack, it checks if the file name starts with a dot to decide if the file is "hidden" - but this gets rid of half of the stats - only one stat per file instead of two. Perhaps it gives you some idea how to speed this up?
The second diff (same file) updates the directory metadata after every refresh. This avoids that the regular file system monitor immediately re-checks the same directory after a file was deleted and its corresponding information in memory was already updated.
So the second diff removes a hang of about ~3s shortly after every delete.
Another idea (that is too big for me to implement) is to update the in-memory file list when a file is deleted directly - remove the file there too, instead of triggering a full rescan of the directory. That would save 3s again (if the directory state for the monitor is updated similar to what happens in the second diff) and be a big speedup.
caclark commentedon Oct 7, 2026
Which sort method do you have selected? Sorting on exif data will slow things down.
0-wiz-0 commentedon Oct 7, 2026
I have 'sort by name'.
caclark commentedon Oct 7, 2026
Is there a difference in speed between view-as-list and view-as-icon?
0-wiz-0 commentedon Oct 7, 2026
From my quick impression, view-as-icon is even slower.
caclark commentedon Oct 7, 2026
This is confusing.
I see no difference in the relevant code between v2.9 and v3.x
I set up a sub-dir with 1,000 40MB jpegs on a NFS drive.
Deleting an image is instantaneous.
0-wiz-0 commentedon Oct 7, 2026
Sorry, I just tried again and it's slow with gtk3 too.
Can you please look at the code paths I pointed out? They are based on what I found with the timings looking at ktrace here.
geeqie does two stats per file after a delete, and that is just slow. Can these stats be reduced, please?
caclark commentedon Oct 7, 2026
Are you compiling from sources?
0-wiz-0 commentedon Oct 7, 2026
Yes, I'm one of the pkgsrc maintainers of geeqie and am currently using the 3.2 sources, with dependencies from pkgsrc, on NetBSD 11.99.9/x86_64.
caclark commentedon Oct 7, 2026
I am a bit reluctant to make a blind fix when I cannot see the problem.
If you can make the edits you suggest to your system and verify that it solves the problem for you, I will check there are no adverse effects on my system - and if so, make the commit to the main repo.
gdt commentedon Oct 7, 2026
I also am experiencing extreme slowness on NetBSD 11 with geeqie 3.2. I am building from pkgsrc. My images are on ZFS on ssd. Even in a directory with 14 images, after pagedown through all and clicking back to the top, I am finding pagedown very laggy. Sometimes it is perceptible, just, and sometimes it feels like a whole second. This is not deleting - this is just pageup/pagdown. It could be that what I'm seeing is different from what 0-wiz-0 is seing.
My image files are jpg (earlier processed from raw), ranging from 140KB to 2.4MB. The biggest dimension is 2149 pixels. These are really not big files these days.
I have no memory of this behavior with 2.9.
0-wiz-0 commentedon Oct 7, 2026
I'm guessing that you don't see it because your NFS implementation (Linux?) caches file attributes by default. Can you try turning that off? Reading the nfs man page I think that 'noac' or 'actimeo=0' might be relevant options for that.
przepompownia commentedon Oct 7, 2026
Could this be suggesting that we need debouncing to avoid expensive operations of loading intermediate files too quickly when navigating forward or backward?
gdt commentedon Oct 7, 2026
I have just been reading over ktrace from starting geeqie, watiting, pushing page down once, waiting, ^Q. At the time of pushing pagedown, there are a huge number (264) of NAMI invocations in the kernel (file name to inode translation, corresponding to some system call). Most of them look duplicative, and many don't make sense - moving to the next file should simply display that file, which would be open/read/close of it. or open/mmap/close. and it could be not that file, but the next one, if there's pre-caching.
The system calls each seem pretty fast, but 10 us here, 50 us here, times a big number, plus whatever was really needed, seems to have added up to 300 ms.
If you do this, with strace or whatever the "log system calls" tool is, do you see only system calls that make sense, or do you see a lot?
caclark commentedon Oct 7, 2026
b034e1f
Might help. Might not.