IPv4
ping hostname_or_ip
IPv6
ping6 hostname_or_ip
Prerequisite:
apt-get install dnsutils
dig hostname
dig hostname any
//there are many other things which dig allows to check
Prerequisite:
apt-get install netcat netcat6
IPv4
nc -vvv hostname_or_ip port
IPv6
nc -6 -vvv hostname_or_ip port
Prerequisite:
apt-get install openssl nmap
IPv4
ncat --ssl -v hostname_or_ip port
IPv6
ncat -6 --ssl -v hostname_or_ip port