https://lwn.net/Articles/777595/
LWN (Linux Weekly News) provides a written account of Benno Rice's talk. The former FreeBSD core developer gives some context around systemd and what FreeBSD should learn from it. He compares the affair to a Greek tragedy which contains much suffering followed by catharsis. His attitude toward systemd is generally not negative, but I won't cherry-pick any specific sections; you'll have to actually read the article for once.
(Score: 3, Interesting) by MichaelDavidCrawford on Friday February 08 2019, @09:22AM (3 children)
Consider such a command line as the following, which I use all the damn time:
$ find . -name "index\.html" -exec grep -q "US-ASCII" {} \; -print
I use such command lines as I bring all my sites into The UNICODE Reality.
Note the backslash before the ".html". That's because the -name argument to find takes a regular expression; just "index.html" would slow the entire runtime down a bit.
Consider what, were I - or you sorry lot - to lift but a finger:
$ mdc_find . -fname -grep -q "US-ASCII" {} -print
Now consider how much grep and find are run on all the boxes on the planet put together - _especially_ on mobile devices!
It's this kind of stuff that leads me to assert that through no other means than straightforward - often trivial - code refactoring, us coders could save far far more energy than all the electrical engineers _combined_.
Oddly, Kuro5hin's every member was so delusional as to regard _me_ as delusional for believing we could save any energy at all!
"I'm a physicist and you're a computer scientist. Riddle me this, Batman? Why does your box have a power cord."
Instead of systemd, we need stuff like "find -grep".
Doubtlessly there already _is_ a "find -grep". What we so-desperately require is not systemd, but for "find -grep" to completely _replace_ what find is now.
Yes I Have No Bananas. [gofundme.com]
(Score: 1, Insightful) by Anonymous Coward on Friday February 08 2019, @05:47PM (1 child)
Sure, but that way madness lies.
For instance, with -exec you're spawning a new process for every file found. That's woefully inefficient when many files are found. Were you to `find wherever | xargs grep search_string` you'd only invoke one grep process for every hundred or so files found (don't recall the default but it's configurable via xargs).
Then were you to pass -F to grep to disable the regex you'd squeeze slightly more performance out of the process. Or, conversely, waste slightly less electricity running it.
And all the machine time and electricity I've saved by dogmatically passing -F to my greps and using xargs where appropriate has probably been overshadowed by the time it took me to learn about those optimizations, type them out repeatedly (sometimes when unnecessary), and make posts like these were I to have just turned my computer off that much sooner instead.
(Score: 2) by MichaelDavidCrawford on Friday February 08 2019, @08:52PM
Were _all_ the distro- or package-supplied scripts to use stuff like xargs.
My whole point with _refactoring_ widely-used code is that huge energy savings would result from having that refactored code come from the original upstream sources, or at least from each of the distros.
Yes I Have No Bananas. [gofundme.com]
(Score: 0) by Anonymous Coward on Sunday February 10 2019, @08:39AM
No, it does not. -name takes a shell pattern.
Please at least learn some UNIX basics before trying to talk about whether something like systemd might be useful or not.
Maybe even dare to read a man page or two.