1

From https://en.wikipedia.org/wiki/IP_address

An Internet Protocol address (IP address) is a numerical label assigned to each device connected to a computer network that uses the Internet Protocol for communication.[1][2] An IP address serves two principal functions: host or network interface identification and location addressing.

Is an IP address assigned only to something with a Mac address? Can an IP address be assigned to something without a Mac address?

How many IP addresses can be assigned to a Mac address? At most one?

Thanks.

6
  • Only the IEEE LAN protocols use MAC addresses, and some of them use 48-bit MAC addresses and some use 64--bit MAC addresses. Other layer- protocols (frame relay, ATM, etc.) may use something else (DLCI, VPI/VCI, etc.) or no addressing at all (HDLC, PPP, etc.).
    – Ron Maupin
    Commented Feb 11, 2019 at 14:04
  • Thanks. What assigns IP address to a device? I guess it is not the OS
    – Tim
    Commented Feb 11, 2019 at 14:07
  • Self configuration, manual configuration, DHCP configuration, etc.
    – Ron Maupin
    Commented Feb 11, 2019 at 14:08
  • (1) What reads the configuration and do the assignment? Is it the OS kernel (network driver in the kernel)? (2) Can IP addresses be assigned to devices in "Other layer- protocols (frame relay, ATM, etc.) may use something else (DLCI, VPI/VCI, etc.) or no addressing at all (HDLC, PPP, etc.)"?
    – Tim
    Commented Feb 11, 2019 at 14:12
  • Unfortunately, host/server configurations are off-topic here. You would need to ask that on one of the OS-specific sites. Different OSes can do it differently; there is no standard that says this is how a device must assign addresses. IP can run on many different layer-2 protocols, and it will not know or care which is used, and neither does the layer-2 protocol know or care which layer-3 protocol (IPv4, IPX, IPv6, AppleTalk, etc.) is used.
    – Ron Maupin
    Commented Feb 11, 2019 at 14:17

3 Answers 3

6

While Ethernet is a very common layer 2 protocol, it’s not the only one. Other protocols don’t use MAC addresses and some have no addressing at all.

You can have multiple IP addresses per MAC. The OS determines the maximum

1
  • Thanks. (1) What are " Other protocols don’t use MAC addresses and some have no addressing at all. "? (2) When "You can have multiple IP addresses per MAC", are the IP addresses used regardless of whether they are assigned to the same MAC or not?
    – Tim
    Commented Feb 11, 2019 at 13:37
4

Is an IP address assigned only to something with a Mac address?
Can an IP address be assigned to something without a Mac address?

If you want to send data over Ethernet: Yes.

You cannot send Ethernet packets to some device without a MAC address (such as an Ethernet HUB or a simple Switch).

What are "Other protocols don’t use MAC addresses and some have no addressing at all."?

Analogue modem connections are an example of a technology not using MAC addresses. They used PPP (or in the past: SLIP) to exchange IP packets over the telephone line.

How many IP addresses can be assigned to a Mac address?
At most one?

If you want to use the IP protocol, you need at least one IP address. (However, you can use Ethernet with other protocols instead of IP. In this case you don't need an IP address.)

One network card (MAC address) can have multiple IP addresses.

When "You can have multiple IP addresses per MAC", are the IP addresses used regardless of whether they are assigned to the same MAC or not?

Using multiple IPv4 addresses per network card is only done in a few, special scenarios.

For IPv6 however, in the most common scenarios, multiple IPv6 addresses are used per network card:

Each network card has exactly one "link-local" address which cannot be used if the data to be send has to pass a router. This address is typically used for sending network management data but it can be used as "regular" address, too.

The network card (and therefore MAC address) may have one or more "global" addresses for internet connections. Using more than one global address may be useful for privacy reasons.

The network card may have different "local" addresses if the computer is a member of different local networks.

What assigns IP address to a device?

You can manually assign IP addresses to the devices in the OS configuration. In the case of servers you should do this in any case.

Using SLAAC (IPv6) or APIPA (IPv4), the OS can automatically assign a (more or less) random IP address to the network card. This seems to be the most common variant for IPv6.

Using DHCP, a server can assign an IP address to some device. This is the most common variant for IPv4.

-2

In the most common usage, IP is a protocol over the ETH. But the ethernet layer need the MAC address of the destination on the link to transmit the packet, so IP will not be able to work if there is no MAC address. But there is some alternative to Ethernet which not use MAC and work well with IP

You can have multiple IP associated with a single MAC, it's not a recommended method, but it's can be useful in some rare cases (i used it this morning).

PS : Thanks JFL for the precision

2
  • 1
    Sorry but this is plain wrong. The Internet Layer (IP) is over the link layer. Ethernet is the predominant protocol used at the link layer, but it is far from the only one, there's many other protocol used below IP, like PPP, HDLC, etc... which doesn't use MAC addresses.
    – JFL
    Commented Feb 11, 2019 at 13:44
  • I corrected it, i'm sorry for this mistake and thank you for this very useful correction
    – redheness
    Commented Feb 11, 2019 at 14:01

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.