od
Options
--help
-
od-help-help
--address-radix=<RADIX>
,-A <RADIX>
-
od-help-address-radix
--skip-bytes=<BYTES>
,-j <BYTES>
-
od-help-skip-bytes
--read-bytes=<BYTES>
,-N <BYTES>
-
od-help-read-bytes
--endian=<big|little>
-
od-help-endian
--strings=<BYTES>
,-S <BYTES>
-
NotImplemented: output strings of at least BYTES graphic chars. 3 is assumed when BYTES is not specified.
-a
-
od-help-a
-b
-
od-help-b
-c
-
od-help-c
-d
-
od-help-d
-D
-
od-help-d4
-o
-
octal 2-byte units
-I
-
decimal 8-byte units
-L
-
decimal 8-byte units
-i
-
decimal 4-byte units
-l
-
decimal 8-byte units
-x
-
hexadecimal 2-byte units
-h
-
hexadecimal 2-byte units
-O
-
octal 4-byte units
-s
-
decimal 2-byte units
-X
-
hexadecimal 4-byte units
-H
-
hexadecimal 4-byte units
-e
-
floating point double precision (64-bit) units
-f
-
floating point double precision (32-bit) units
-F
-
floating point double precision (64-bit) units
--format=<TYPE>
,-t <TYPE>
-
od-help-format
--output-duplicates
,-v
-
od-help-output-duplicates
--width=<BYTES>
,-w <BYTES>
-
od-help-width
--traditional
-
od-help-traditional
Examples
Display file using default settings: octal format, 8 bytes per line, byte offsets in octal, and duplicate lines replaced with *
:
od {{path/to/file}}
Display file in verbose mode, i.e. without replacing duplicate lines with *
:
od {{[-v|--output-duplicates]}} {{path/to/file}}
Display file in hexadecimal format (2-byte units), with byte offsets in decimal format:
od {{[-t|--format]}} {{x}} {{[-A|--address-radix]}} {{d}} {{[-v|--output-duplicates]}} {{path/to/file}}
Display file in hexadecimal format (1-byte units), and 4 bytes per line:
od {{[-t|--format]}} {{x1}} {{[-w|--width=]}}4 {{[-v|--output-duplicates]}} {{path/to/file}}
Display file in hexadecimal format along with its character representation, and do not print byte offsets:
od {{[-t|--format]}} {{xz}} {{[-A|--address-radix]}} {{n}} {{[-v|--output-duplicates]}} {{path/to/file}}
Read only 100 bytes of a file starting from the 500th byte:
od {{[-N|--read-bytes]}} 100 {{[-j|--skip-bytes]}} 500 {{[-v|--output-duplicates]}} {{path/to/file}}
The examples are provided by the tldr-pages project under the CC BY 4.0 License.
Please note that, as uutils is a work in progress, some examples might fail.