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

Linux Kernel and Linux Event

Red Hat News

Leftovers: Software and HowTos

  • Top Software
    The number of open source applications and tools that are available on today’s popular operating systems is simply mind-blowing. They come in all forms. Small scripts and console tools that can be easily integrated into large projects, feature-rich applications that offer everything a complete solution, well designed tools, games that encourage real participation, and eye catching candy. Open source software holds many compelling advantages over proprietary software. Open source improves the quality of the code, keeps costs down, encourages innovation and collaboration, combined with superior security, freedom, flexibility, interoperability, business agility, and much more.
  • Kodi 17.0 "Krypton" Release Candidate 3 Updates Estuary Skin, Fixes More Bugs
    The wait is almost over, and you'll finally be able to enjoy a much modern, improved, and full of new technologies Kodi media center on your PC or HTPC device, be it an Apple TV or Raspberry Pi. Martijn Kaijser announced the third Release Candidate (RC) development version for the Kodi 17.0 "Krypton" media center, and it looks to us like these pre-releases are getting smaller by the day, the RC3 build including only seven changes listed on the release notes attached to the official announcement.
  • Accessing Bingo Sites through Linux
  • Fedora - linux and shell.
  • Getting started with shell scripting