(upbeat music)
- [Anthony] Your modern computing device uses many addresses
to be able to properly communicate on the network
to other devices and services.
But certainly one of the most important addresses
is the internet protocol or IP address.
You have an IP address or many IP addresses
on your modern computer.
And this IP address will also come with a subnet mask.
It'll also be associated
with other very important IP addresses,
like the default gateway IP address and the DNS IP address.
The IP address in subnet mask on your system define a lot.
They define what network you're located on
and they also define what is your particular
host identification number?
A nice common analogy that works well
is to compare this to your street address
and your house number.
The street address is like the network
and your house number is like the host identifier.
Or an IP address can easily be compared
to a U.S. telephone number.
In the United States system,
there's one component that's called an area code,
and then there's the phone number.
The area code would convey the network in our example.
So the subnet mask tells us what portion
of the IP address is our street address.
And the subnet mask also indicates
what portion of the IP address identifies our house number,
to use, of course, the house and the street name
and house number analogy from earlier.
In order to make this as practical as possible,
let's demonstrate how easy it is to find your IP address,
your subnet mask and your default gateway address.
Let's take the two most popular desktop operating systems
in the world, Microsoft Windows and the Apple macOS.
And let's determine how to learn
the relevant IP address information
using both the graphical user interface
and the command line interface
on each of these two different operating systems.
And just to really drive the point home,
we'll also look at this information on an iPhone.
So let's begin on the Mac.
And if we go into System Preferences,
there is this Network applet right here.
And if you struggle to find it
by scanning with your eyes like I do,
then you can go up to the Search remember.
Let's click here
and if we go into the graphical user interface here,
it's really pretty cool.
You can see the different options that I would have
for making network connections,
and you can see I'm currently connected via Wi-Fi.
Now notice right here is this Advanced button.
So if I click Advanced, it's going to show me
the Advanced properties for that connection.
In this case, it's Wi-Fi.
These are different networks around me
that I could potentially connect to.
This is the TCP/IP settings that we're interested in.
And notice that we are using something called DHCP
to get the IP address onto the system.
And the IPV4 address that I have currently received
is 172.20.6.50.
So when speaking to another network engineer,
I would simply go, yeah,
my IPV4 address is 172.20.6.50
and I would just use those dramatic pauses
to indicate the decimal values
that are in each of those octets later on.
Notice the subnet mask, 255.255.240.0
and then the router,
which is the default gateway of 172.20.0.1.
So all that information that we might need
regarding the IPV4 addressing for this client
is right here inside the graphical user interface.
Thanks to the network app and the advanced properties of,
in my case, the Wi-Fi connection,
we can see our IPV4 address,
the subnet mask that goes with that address
and the default gateway.
Now, I must admit,
when I need my IP address information quickly on the Mac,
I would not go into System Preferences
and use the graphical user interface.
Instead, I would bring up a terminal window
and I would simply type ifconfig and we hit enter,
and we can see the IP address information
for all of the interfaces on our device,
all of the network interfaces.
So if I highlight this one right here,
we can see the en0 interface,
is the interface that is going to be associated
with the wireless card on this laptop.
And look at this, the inet address is 172.20.6.50.
Look at that right there. There's the address.
And the netmask is presented to us here
in hexadecimal format.
You can see the broadcast for the network we're on
is 172.20.15.255.
Also, what's interesting here is that
when you first look at the output,
there's this loop back zero right here.
This is a internal virtual interface
and it's for testing purposes.
So if we ever just want to like quickly go in
and test that our own IP is functioning properly,
we can ping our internal loop back address at 127.0.0.1.
I would love to see the official count
of the number of ways we can find our IP address
on a Windows system at the graphical user interface.
There would be lots of ways that you could do this.
Here you can see we're going very old school.
And if you go to the Network and Sharing Center,
here we can see there's our connection.
And if I go to Change adapter settings,
we can see my Wi-Fi adapter right here.
And if we go into the Properties of that Wi-Fi adapter,
there is the IP version 4 setting here.
And if we look at the Properties of that,
we could see that we're set
to obtain our IP address automatically
and get our DNS information automatically
from a DHCP server.
But the question here is what is our IP address?
We're still not seeing that.
So if I just right click and go to Status,
we're getting closer here.
We can see the information about the Wi-Fi connection.
And if we go to the Details here, there we have it.
We can see the IP address and subnet mask,
as well as the DHCP server address
and the DNS servers and the default gateway
and all those important IP address information components.
For a long time, even folks that are non-technical,
like my father, he has looked at his smartphone
and he's realized that his smartphone
is really a computer in his pocket.
And sure enough, just like one of our Mac systems
or our Windows systems or iPhone or Android phone
or whatever kind of phone that we're using
is going to have an IP address.
So here you can see me, once I enter the Settings,
I'm going to go ahead and select the option
for my Wi-Fi connection.
And when I go into that Wi-Fi connection,
notice that there is an i icon,
that's for getting more information.
If I select that i icon, I'm going to go into the information
about this Wi-Fi connection and look at that,
underneath the IPV4 address section,
you can see that we are configured on this iPhone
to receive our IP address information
from a DHCP server automatically,
and that I've gotten the IP address of 192.168.0.40
with a 255.255.255 mask,
and a default gateway at 192.168.0.1.
(upbeat music)