Para ver el progreso de algunos trabajos paralelos, pruebe--tmuxpane --fg
:
parallel --tmuxpane --fg seq {} 10000000 ::: {1..100}
También podría estar buscando -u
o (más probablemente)--lb
. deman parallel
:
--line-buffer
--lb
Buffer output on line basis. --group will keep the output together
for a whole job. --ungroup allows output to mixup with half a line
coming from one job and half a line coming from another job.
--line-buffer fits between these two: GNU parallel will print a full
line, but will allow for mixing lines of different jobs.
--line-buffer takes more CPU power than both --group and --ungroup,
but can be much faster than --group if the CPU is not the limiting
factor.
Normally --line-buffer does not buffer on disk, and can thus process
an infinite amount of data, but it will buffer on disk when combined
with: --keep-order, --results, --compress, and --files. This will
make it as slow as --group and will limit output to the available
disk space.
With --keep-order --line-buffer will output lines from the first job
while it is running, then lines from the second job while that is
running. It will buffer full lines, but jobs will not mix. Compare:
parallel -j0 'echo {};sleep {};echo {}' ::: 1 3 2 4
parallel -j0 --lb 'echo {};sleep {};echo {}' ::: 1 3 2 4
parallel -j0 -k --lb 'echo {};sleep {};echo {}' ::: 1 3 2 4
See also: --group --ungroup
[...]
--ungroup
-u Ungroup output. Output is printed as soon as possible and by passes
GNU parallel internal processing. This may cause output from
different commands to be mixed thus should only be used if you do not
care about the output. Compare these:
seq 4 | parallel -j0 \
'sleep {};echo -n start{};sleep {};echo {}end'
seq 4 | parallel -u -j0 \
'sleep {};echo -n start{};sleep {};echo {}end'
It also disables --tag. GNU parallel outputs faster with -u. Compare
the speeds of these:
parallel seq ::: 300000000 >/dev/null
parallel -u seq ::: 300000000 >/dev/null
parallel --line-buffer seq ::: 300000000 >/dev/null
Can be reversed with --group.
See also: --line-buffer --group
Un ejemplo donde -u
brilla es donde stdout y stderr se mezclan en la misma línea:
echo -n 'This is stdout (';echo -n stderr >&2 ; echo ')'
Esto tendrá un formato incorrecto con --lb
y --group
.
Pero incluso -u
no garantiza que se formateará correctamente debido a la mezcla de media -línea entre procesos:http://mywiki.wooledge.org/BashPitfalls#Non-atomic_writes_with_xargs_-P
Моя проблема была полностью связана с виртуальной машиной, но я использовал "пользовательскую" сеть. Решение:
su
# <root pwd>
/usr/sbin/dhclient
# problem solved
Я установил debian -mips отсюда и сразу же столкнулся со следующими -из -проблемами -коробки:
wget http://http.us.debian.org/debian/dists/buster/main/installer-mips/current/images/malta/netboot/initrd.gz
wget http://http.us.debian.org/debian/dists/buster/main/installer-mips/current/images/malta/netboot/vmlinux-4.19.0-16-4kc-malta
# Installed...
# Copy /boot files out of vm...
# Run with:
qemu-system-mips -M malta -m 256 -hda hda.img \
-kernel vmlinux-4.19.0-16-4kc-malta \
-initrd initrd.img-4.19.0-16-4kc-malta \
-append "root=/dev/sda1 console=ttyS0 nokaslr" \
-nographic \
-device e1000-82545em,netdev=user.0 \
-netdev user,id=user.0,hostfwd=tcp::5555-:22
sudo
не установлен. Используйте su
вместо PATH
не включает sbin. Бегиexport PATH=$PATH:/usr/sbin
ifconfig
не существует. Используйте ip a
вместо ifup: unknown interface enp0s19
. Alt :ip link set dev enp0s19 up
(, но, как указано выше, реальная проблема заключалась в том, что dhclient не работал )