Re: [OpenIndiana-discuss] svc:/system/update-man-index is slow

2021-09-22 Thread Andy Fiddaman
On Tue, 21 Sep 2021, Richard L. Hamilton wrote: ; What's the procedure to submit something to illumos-gate? I don't have an account on illumos.org , and have no desire to assume any particular role there. The normal process is to create an issue at

Re: [OpenIndiana-discuss] svc:/system/update-man-index is slow

2021-09-21 Thread Richard L. Hamilton
The / after $p is sensible (although /usr/man and /usr/share/man are both in the path I saw, which is harmless but redundant). The formatting...ok, everybody has their conventions. Granted that wc and tr are less efficient that what you suggest, in rare cases (like if lots of man pages were

Re: [OpenIndiana-discuss] svc:/system/update-man-index is slow

2021-09-21 Thread Andy Fiddaman
On Tue, 21 Sep 2021, Richard L. Hamilton wrote: ; Most of the time, man indexes don't actually need to be rebuilt. The attached change to /lib/svc/method/update-man-index should (I think) only update the directories (if any) that are not current, so that most of the time, it finishes in a

Re: [OpenIndiana-discuss] svc:/system/update-man-index is slow

2021-09-21 Thread Richard L. Hamilton
Perhaps better, to be consistent with what I see elsewhere in method scripts, one line should be further changed to use full paths of executables: if [ -d "${p}" -a -f "${p}/whatis" ] && [ "$(/usr/bin/find "${p}" -newer "${p}/whatis" | /usr/bin/wc -l | /usr/bin/tr -d ' ')" == "0" ]; then

[OpenIndiana-discuss] svc:/system/update-man-index is slow

2021-09-21 Thread Richard L. Hamilton
Most of the time, man indexes don't actually need to be rebuilt. The attached change to /lib/svc/method/update-man-index should (I think) only update the directories (if any) that are not current, so that most of the time, it finishes in a second or so rather than a couple of minutes (less