pagesize command not found

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

Introduction

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

pagesize: command not found

or when using sudo you get the following error message

sudo: pagesize: command not found

Solutions to pagesize: command not found

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

In Ubuntu pagesize is provided by libhugetlbfs-bin package.

libhugetlbfs-bin is:

libhugetlbfs is a library which provides easy access to huge pages of memory. It is a wrapper for the hugetlbfs file system. Applications can use huge pages to fulfill malloc() requests without being recompiled by using LD_PRELOAD.

The package provies the following userspace tools to help with huge page usability, environment setup, and control:

hugeadm: Configure the system huge page pools. hugectl: Control policy for backing text, data and malloc() with hugepages. hugeedit: Set default policy for backing text and data with hugepages. pagesize: Print supported system page sizes.

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

sudo apt-get -y install libhugetlbfs-bin

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

You can also use apt command to install libhugetlbfs-bin.

sudo apt -y install libhugetlbfs-bin

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

sudo aptitude install libhugetlbfs-bin

Summary

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