
Jan Engelhardt wrote:
On Thursday 2012-09-13 11:07, Linda Walsh wrote:
Jan Engelhardt wrote:
On Thursday 2012-09-13 07:54, Linda Walsh wrote:
Claudio Freire wrote:
On Thu, Sep 13, 2012 at 2:36 AM, Linda Walsh <suse@tlinx.org> wrote:
What environment variable do I change? alias sort="sort --parallel=N" ? So I put that where to have it in effect for my 45 minute runs of updatedb? echo -en '#!/bin/sh\nexec /usr/bin/sort --parallel=N "$@"' /usr/local/bin/sort;
Clever, but it sorta misses the point as it will be overwritten on the next update if it isn't fixed.
It won't be overwritten, it's in /usr/local.
---- Then that won't work, as many utils -- including, specifically, updatedb, set the path and do not include /usr/local/bin, as it's not an official path. updatedb looks for the location of the binary 'find' (/usr/bin on my system), and creates it's own path: PATH=/bin:/usr/bin:${BINDIR}; export PATH So the script you provided won't change the global behavior of 'sort' nor in the originally mentioned util, "updatedb". You are trying to work around a systemic bug introduced by a bug in the source. If the source used a systemic variable to base the thread limit on, then one could have a systemic solution. However, with a source that no longer supports a systemic setting, getting systemic behavior will be prone to error as the above illustrates... Note: I didn't know it wouldn't work until you mentioned it was in "/usr/local/bin". I knew that wasn't a standard system path, so it would be unlikely to be referenced in a system utility like updatedb. In checking the source, I confirmed that it is not used. The only way to test if it works in a given application is to test it with that application, since no amount of stress testing with test cases that do not accurate represent your workload or program will provide no guarantee that it will work when you run it with your workload. If only 'sort' was configurable with an ENV var, then it might be easier for it to be tested... (i.e. in the unpatched source it would be far simpler to test as the ENV only has to be modified one place -- versus finding each place that sort is called and modifying the source of each place that calls sort -- a far greater, work-intensive, task. -- To unsubscribe, e-mail: opensuse-factory+unsubscribe@opensuse.org To contact the owner, e-mail: opensuse-factory+owner@opensuse.org