Language Selection

English French German Italian Portuguese Spanish

CLI Magic: Running multiple jobs with xjobs

Filed under
HowTos

Ever feel like you're not getting the most out of your multiprocessor machine? The xjobs utility allows you to schedule several processes to run simultaneously to make the most of your system's resources.

Xjobs takes a list of arguments from standard input and passes them to a utility, or takes a list of commands from a script, and then runs the jobs in parallel. If you have a multiprocessor machine, xjobs will automatically run one job per processor by default. For instance, on a dual-CPU machine, if you run ls -1 *gz | xjobs gunzip, xjobs will gunzip two files at a time by default. If you run the same command on a quad-CPU machine, it will gunzip four files at a time by default, until it runs out of files to process.

Getting xjobs

Xjobs isn't in any of the major distros, so you'll need to compile it from source. This shouldn't be difficult; just make sure that you have GNU Flex installed -- which should be available in any major Linux distro.

Full Story.

More in Tux Machines

Today in Techrights

FreeBSD-Based TrueOS Operating System Gets New Jail Tools, Automounting Feature

The developers of the FreeBSD-based TrueOS operating system (formerly PC-BSD) announced the release and general availability of a new stable build versioned 2017-02-22. Read more

Calamares 3.1 Distribution-Independent Linux Installer Officially Released

The Calamares open-source universal installer framework for Linux-based operating systems has been updated recently to version 3.1, a major release the users of the KaOS GNU/Linux distribution can already enjoy if they download the latest ISO snapshot. Read more

Reiser4 Updated For The Linux 4.10 Kernel

The out-of-tree Reiser4 file-system has been updated for the Linux 4.10 kernel. Reiser4 for the Linux 4.10.0 kernel is available as of earlier this week, managing to release their updated file-system driver code quite promptly. This port to Linux 4.10 yielded a few changes to the Reiser4 code as they re-based to this Linux kernel with the ->readlink() of inode operations being removed as well as the WRITE_FLUSH_FUA flag being removed. Read more