Hacker News new | ask | show | jobs
by Koahku 3637 days ago
This is a pretty good collection of small utilities but I would recommend using GNU Parallel[0] instead of the included parallel. It contains a ton of extremely useful additional features such as distributing jobs to remote computers.

[0]: https://www.gnu.org/software/parallel/

4 comments

GNU Parallel will also infloop if any process on the system (run by any user) has an empty argv[0] (which can actually happen; parallel scans /proc to find instances of itself). When I reported the bug, the author refused to fix it on the grounds that this behavior is a "malware detector". Between this weirdness and the citation-interface weirdness, I'm not keen on GNU Parallel.
Lolwut? It responds to "malware" (empty argv) by infinite looping? That's a feature?
One big turnoff with GNU parallel is that the first time it is run on a machine, you must interactively accept a EULA. There are ways around it, but as a rule of thumb I avoid command-line tools that do this, because this inconsistent runtime behavior is annoying at best and can easily break and complicate automation.

And no, I don't want to set an environment variable on a fleet of machines to suppress behavior which shouldn't be enabled by default to begin with! <cough> .NET telemetry </cough>

A real shame, because it is an otherwise useful tool IMHO.

What it actually does is to beg you to cite parallel if you use it in academic work. There's two ways to silence it:

• Run `touch ~/.parallel/will-cite`.

• Pass the flag `--will-cite`.

Still annoying, although it's easy enough to disable.

Fwiw the Debian & Ubuntu packages have disabled this behavior.
jobflow[1] is what I'd be suggesting unless there was a very specific reason to use something massive like GNU Parallel. It is used as part of Sabotage Linux's package manager.

[1]: https://github.com/rofl0r/jobflow

Suprised that nobody mentioned 'xargs -I{} -P N' yet. It is a GNU extension, but quite handy as it comes preinstalled pretty much on every Linux machine.