---
title: "Parallel"
url: https://perrotta.dev/2024/07/parallel/
last_updated: 2025-09-05
---


Apparently there are two Unix-y ways to run commands in parallel:

- GNU parallel: https://www.gnu.org/software/parallel/
- moreutils parallel: https://www.gnu.org/software/parallel/

A simple example with `wc -l`:

GNU receives input from stdin:

```shell
find . -type f | parallel wc -l
```

Moreutils receives input from command-line arguments:

```shell
parallel wc -l -- $(find . -type f)
```

Style aside, the annoyance is that they are not compatible in Debian, Ubuntu and
macOS (homebrew), due to both having the `parallel` executable:

- https://superuser.com/questions/917577/how-can-i-install-gnu-parallel-alongside-moreutils-on-ubuntu-debian
- https://askubuntu.com/questions/1191516/what-happens-to-usr-bin-parallel-if-i-install-the-moreutils-on-top-of-the-paral

Debian thread wherein no consensus is achieved:
https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=597050

I will stick to `moreutils` due to its simplicity and richer suite.
Nonetheless, it would be better if we didn't have binary clashes like this. It
is really annoying and developer-unfriendly.

Of course, my favorite Linux distributions do not have this issue:

```shell
% apk info -L moreutils | grep parallel
usr/bin/parallel-moreutils
```

...Alpine just installs `parallel` from `moreutils` with another name.

Arch Linux [does the
same](https://gitlab.archlinux.org/archlinux/packaging/packages/moreutils/-/blob/main/PKGBUILD?ref_type=heads):

```
mv "$pkgdir"/usr/bin/parallel "$pkgdir"/usr/bin/parallel-moreutils
```

Moreover, GNU Parallel has an annoying citation notice, which the Arch Linux
package [helpfully
removes](https://gitlab.archlinux.org/archlinux/packaging/packages/parallel/-/blob/main/0001-Remove-citation-things.patch?ref_type=heads)[^1].

[^1]: [Some](https://bugs.launchpad.net/ubuntu/+source/parallel/+bug/1779764)
    [context](https://news.ycombinator.com/item?id=15319715). Not everyone works
    in academia. Also it's quite weird that the program is called "GNU
    parallel", is published under the GPL, and yet does not seemingly follow the
    [GPL
    guidelines](https://www.gnu.org/licenses/gpl-faq.en.html#RequireCitation).
    [This](https://git.savannah.gnu.org/cgit/parallel.git/tree/doc/citation-notice-faq.txt#n27)
    is the official FAQ of the program.

