iprange command not found

In this troubleshooting guide we learn how to fix iprange command not found error message

Introduction

When you run more command in linux terminal / console, you get the following error message

iprange: command not found

or when using sudo you get the following error message

sudo: iprange: command not found

Solutions to iprange: command not found

How To Fix iprange: command not found in Ubuntu / Debian / Kali Linux / Raspbian

In Ubuntu iprange is provided by iprange package.

iprange is:

This tool is capable of managing sets of IPs.

Why to use iprange over any other aggregate ?

  • simpler
  • supports many input formats, all together in the same file
  • faster, actually a lot faster (thanks to the original design by Gabriel Somlo)
  • can reduce the subnets/prefixes to produce high-performing netfilter/iptables ipsets
  • can compare files with IPs to find if they overlap and to what degree
  • can find the IPs common to a set of files
  • can exclude IPs (merge a set of files while excluding all IPs matched by another set of files)

To fix this problem, we can install more using the command below.

sudo apt-get -y install iprange

This command might take some time to finish depending on your machine internet connection.

You can also use apt command to install iprange.

sudo apt -y install iprange

Or if you have aptitude installed you can use the following command.

sudo aptitude install iprange

Summary

In this tutorial we learn how to fix iprange command not found error in Ubuntu / Debian / Kali Linux or Raspbian distribution.