Another way to get IP address information from the Netstat command.

Get IP address information using Netstat on Linux How to get IP address information using netcat and some other useful tips. user1@cloudshell:~$ netstat | awk ‘/tcp6/ { print $5 }’ 74.125.41.158:36146 173.194.93.92:48039user1@cloudshell:~$ netstat | awk ‘/tcp6/ { print $5 }’ 74.125.41.158:36146 173.194.93.92:48039 user1@cloudshell:~$ netstat | awk ‘/tcp6/ { print $5"…

Read More

How to best get IP address information with Powershell on Windows 11.

This example will get the current IP address(s) of the user`s machine. PS C:\Users\Intel i5> Get-NetIPAddress | Sort-Object -Property InterfaceIndex | where-object -FilterScript {$_.SuffixOrigin -eq "Dhcp"}     IPAddress : 192.168.1.114 InterfaceIndex : 10 InterfaceAlias : Ethernet AddressFamily : IPv4 Type : Unicast PrefixLength : 24 PrefixOrigin : Dhcp SuffixOrigin…

Read More

How to get the IP address of your computer with Powershell.

This is how to get the current IP address of the active network adapter in your Windows system. PS C:\Users\Doom> (Test-Connection -ComputerName (hostname) -Count 1).IPV4Address.IPAddressToString 192.168.1.2PS C:\Users\Doom> (Test-Connection -ComputerName (hostname) -Count 1).IPV4Address.IPAddressToString 192.168.1.2 This prints the IP address of your machine to the Powershell terminal. This is a great way…

Read More

Another way to get the actual IP address of your machine.

This is yet another way to get the actual IP address of your Linux machine on a LAN. This returns just the IP address of your Linux computer. jason@jason-Lenovo-H50-55:~$ ip a | awk ‘/inet / { print $2 }’ | sed -n 2p 192.168.1.4/24jason@jason-Lenovo-H50-55:~$ ip a | awk ‘/inet /…

Read More

How to get just the IP address of your Linux machine using curl.

To get just the IP address of your Internet facing Linux machine, use this command. jason@jason-desktop:~/Documents/ipinfo/src$ curl icanhazip.comjason@jason-desktop:~/Documents/ipinfo/src$ curl icanhazip.com This will return just your IP address. This is another way to get this information. jason@jason-desktop:~/Documents$ curl ipinfo.io/ipjason@jason-desktop:~/Documents$ curl ipinfo.io/ip To get information about a DNS server, use the dig…

Read More

More commands to get information about your network adapter.

There are a few commands available in Red Hat Linux to get information about your network adapter. Here are a couple. The ifstat command returns information about the network throughput of your adapter. [jason@darknet ~]$ ifstat #kernel Interface RX Pkts/Rate TX Pkts/Rate RX Data/Rate TX Data/Rate RX Errs/Drop TX Errs/Drop…

Read More

How to set a MAC address on a Cisco 3700 router.

This command in interface configuration mode will change the MAC address for a specific interface on the router. R1(config-if)#mac-address DE.AD.BER1(config-if)#mac-address DE.AD.BE And this is what I get when I use the show run command and view the properties of the interface. interface FastEthernet0/0 mac-address 00de.00ad.00be ip address 192.168.0.1 255.255.255.0 ip…

Read More