If you see the xxd
command not found while running some script or apps on a Linux / Unix system that means the xxd command is not installed.
Basically, the xxd command is a Unix command that can be used to display or edit binary files in hexadecimal format. It can also be used to convert between hexadecimal and binary formats.
The xxd
command is a utility that comes with the Vim text editor, and it is often used in Linux or Unix-based systems. The xxd
command creates a hex dump of a given file or standard input. It can also convert a hex dump back to its original binary form.
When you use xxd
, it displays the hexadecimal representation of the data, along with the printable ASCII characters (if any are present). This can be useful when you’re working with binary files, and you need to see the data in a human-readable form.
If the xxd command is not found on your system then the command is not present.
How to fix xxd Command Not Found error
The simplest solution is install it. Based on your Linux distro you are using, use one of the command:
apt-get install xxd
apt-get install xxd
pacman -S xxd
apt-get install xxd
yum install xxd
dnf install vim-common-2
sudo apt-get update
sudo apt-get install xxd
apt-get install xxd
Conclusion
When a command not found error comes on a linux system, it is most likely that the command is not present or it is not added to the PATH variable.