Format of IPv6 addresses in the netstat output

9,113

Solution 1

Because of "ss" is still buggy in some systems, I prefer netstat too.

The solution for the problem is the option -W(Ubuntu) or -T (Opensuse).

Solution 2

The reason is that the complete IP address doesn't fit in the width of the 80 column terminal, so the address is abbreviated. You generally don't see this with legacy IPv4 addresses as these are usually short enough to fit.

Anyway netstat is long deprecated for years, and for most common purposes shouldn't be used anymore.

Today you should use ss instead. This displays the full IP address, but will wrap beyond the width of an 80 column terminal.

Share:
9,113

Related videos on Youtube

sykatch
Author by

sykatch

Updated on September 18, 2022

Comments

  • sykatch
    sykatch almost 2 years

    When I use netstat -n, it won't display the whole IPv6 addresses. The local ip address is in this format xxxx:xxxx:xxxx:xxxx:portNum, so just a part of the address is displayed. Also the foreign addresses aren't displayed in the full format. Why is that? Is it some kind of convention or is it a bug or is there a way of displaying the whole IPv6 addresses with netstat?