xkbcomp command not found

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

Introduction

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

xkbcomp: command not found

or when using sudo you get the following error message

sudo: xkbcomp: command not found

Solutions to xkbcomp: command not found

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

In Ubuntu xkbcomp is provided by x11-xkb-utils package.

x11-xkb-utils is:

xkbutils contains a number of client-side utilities for XKB, the X11 keyboard extension.

setxkbmap is a tool to query and change the current XKB map.

xkbbell generates a bell event through the keyboard.

xkbcomp is a tool to compile XKB definitions into map files the server can use.

xkbevd is an experimental tool to listen for certain XKB events and execute defined triggers when actions occur.

xkbprint is a tool to generate an image with the physical representation of the keyboard as XKB sees it.

xkbvleds shows the changing status of keyboard LEDs.

xkbwatch shows the changing status of modifiers and LEDs.

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

sudo apt-get -y install x11-xkb-utils

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

You can also use apt command to install x11-xkb-utils.

sudo apt -y install x11-xkb-utils

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

sudo aptitude install x11-xkb-utils

Summary

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