Name
od
Synopsis
od [-c] [-a] [-b] [-B] [-o] [-O] [-d] [-D] [-i] [-I] [-l] [-L] [-f] [-e]
[-F] [-h] [-x] [-H] [-X] [-v] [filename]Description
Prints the
contents of a file to standard
output in a variety of formats. (If no filename is specified, it acts
on the contents of standard input.) The name is an acronym for
octal dump, from its default behavior of
displaying files as series of octal numbers.
od has been deprecated in favor of
hexdump; in fact, the two binaries are
hard-linked to the same data. However, traditional
od syntax applies when invoked by that name. See
the hexdump manpage for more.
Options/Usage
- -a
Displays content in 1-byte chunks of ASCII characters, hexadecimal numbers, and short strings representing control characters.
- -b
Displays content in 1-byte chunks of octal numbers.
- -B
Displays content in 2-byte chunks of octal numbers. This option is the default.
- -c
Displays content in 1-byte chunks of ASCII characters, octal numbers, and escape sequences representing control characters. This is probably the most commonly used option.
- -d
Displays content in 2-byte chunks of unsigned decimal integers.
- -D
Displays content in 4-byte chunks of unsigned decimal integers.
- -e
Displays content in 8-byte chunks of decimal floating-point numbers.
- -f
Displays content in 4-byte chunks of decimal floating-point numbers.
- -F
Same as -
e.- -h
Displays content in 2-byte chunks of hexadecimal numbers.
- -H
Displays content in 4-byte chunks of hexadecimal numbers.
- -i
Displays content in 2-byte chunks of signed decimal ...
Become an O’Reilly member and get unlimited access to this title plus top books and audiobooks from O’Reilly and nearly 200 top publishers, thousands of courses curated by job role, 150+ live events each month,
and much more.
Read now
Unlock full access