I get the message : tfoerste@n22 ~ $ qsearch -c lynx search: Updating ebuild metacache ... search: initialize_flat(): opening '/usr/portage/.metadata.x' failed: Permission denied but in fact the file doesn't exist. The error msg should complain about non-existing file rather than complaining about perms. Reproducible: Always
(In reply to comment #0) > The error msg should complain about non-existing file rather than > complaining about perms. The file does not exists, thus qsearch tries to create it, but since you don't have rights to write in the portage directory, it complains about perms. So this message is correct. Now, i agree it's not very user-friendly. I will attach a patch which prints instructions to run "q -m" as root in this case.
Created attachment 113495 [details, diff] main--better-initialize_flat-warning-on-EACCES.patch
hrmm I don't think it's supposed to be trying to open that file at all. It should be trying to open $PORTDIR/metadata/cache/.metadata.x It also looks that q -m got itself broken somewhere along the way.
(In reply to comment #3) > hrmm I don't think it's supposed to be trying to open that file at all. > It should be trying to open $PORTDIR/metadata/cache/.metadata.x That's what it does indeed, it's the error message which is wrong. The attached patch fixes that too.
(In reply to comment #1) > So this message is correct. (In reply to comment #4) > it's the error message which is wrong. Err... Well, so, it is correct about perms being wrong, and wrong about the file it is about.
(In reply to comment #2) > main--better-initialize_flat-warning-on-EACCES.patch InCVS main.c revision 1.135
This is released in 0.1.25 Bug #168334 ; q -r dies with a segfault after emerge --sync Bug #168442 ; does not properly parse the profile location Bug #170795 ; add a -E/--eclass option to qgrep Bug #170797 ; add a -s/--skip-comments option to qgrep Bug #171024 ; opening '/usr/portage/.metadata.x' failed Bug #171374 ; Misc enhancements for qgrep Bug #172240 ; -A/-B options for qgrep (context lines) Bug #172338 ; qgrepping through installed ebuilds (in the VDB) Bug #173005 ; Colorized output for qgrep.
Closing