Member-only story

DevOps in Linux — od Command

Deep dive into Linux file system

Tony
4 min readAug 31, 2023

Note, full mind map is available at: “DevOps in Linux Mind Map

What is “od” Command

The od command in Linux stands for "octal dump". This command allows you to display the contents of a file or input in various formats including octal, decimal, hexadecimal, and more. It's often used for debugging, to analyze and verify the exact contents of a file, particularly in cases when the file might not contain human-readable text.

For example:

$ od test.txt
0000000 062564 072163 000012
0000005

The above command displays the contents of test.txt in octal format by default. However, you can specify a different format using various options. For instance, to display the contents in hexadecimal:

$ od -x test.txt
0000000 6574 7473 000a
0000005

od is part of the core set of utilities that are essential and standard on Unix and Unix-like operating systems, including Linux distributions.

The initial purpose of od was to provide a way to dump the contents of a file in octal (base 8) format, which was useful for debugging and analysis purposes, particularly when dealing with non-text files. Since its inception, od has been expanded to support…

--

--

Tony
Tony

No responses yet