Log In
24 votes

Suppose that in an IP-over-Ethernet network, a machine X wishes to find the MAC address of another machine Y  in its subnet. Which one of the following techniques can be used for this?

  1. X sends an ARP request packet to the local gateway’s IP address which then finds the MAC address of Y and sends to X
  2. X sends an ARP request packet to the local gateway’s MAC address which then finds the MAC address of Y and sends to X
  3. X sends an ARP request packet with broadcast MAC address in its local subnet
  4. X sends an ARP request packet with broadcast IP address in its local subnet
in Computer Networks
edited by

if this question is about RARP then option d) will be the answer. please correct me if i'm wrong!!



Two computers in an office (Computer 1 and Computer 2) are connected to each other in a local area networkby Ethernet cables and network switches, with no intervening gateways or routers. Computer 1 has a packet to send to Computer 2. Through DNS, it determines that Computer 2 has the IP address

To send the message, it also requires Computer 2's MAC address. First, Computer 1 uses a cached ARP table to look up for any existing records of Computer 2's MAC address (00:eb:24:b2:05:ac). If the MAC address is found, it sends an Ethernet frame with destination address 00:eb:24:b2:05:ac, containing the IP packet onto the link. If the cache did not produce a result for, Computer 1 has to send a broadcast ARP request message (destination FF:FF:FF:FF:FF:FF MAC address), which is accepted by all computers on the local network, requesting an answer for

Computer 2 responds with an ARP response message containing its MAC and IP addresses. As part of fielding the request, Computer 2 may insert an entry for Computer 1 into its ARP table for future use.

Computer 1 receives and caches the response information in its ARP table and can now send the packet.[7]



12 Answers

51 votes
Best answer

Steps in ARP Operation : 

  1. The sender (X) knows its own IP address and  MAC address. X also knows the IP address of the target (Y) . It needs to find MAC address of Y
  2. IP asks ARP to create an ARP request message, filling in X's IP and MAC address and Y's IP address. The destination MAC address is set to all 0s.
  3. The message is passed to Data Link layer where it is encapsulated in a frame using MAC address of X as the source address and physical broadcast address (all 1s)  as the destination address.
  4. Every host in subnet receives the request message because we have used broadcast MAC address in the destination address. All machines except Y (we have specified Y's IP address in our ARP request message) drop the ARP request message. 
  5. Y replies with an ARP reply message that contains its MAC address.
  6. When X receives this message, it gets to know the MAC address of Y.

Please note that, a host uses its own IP address and network mask to decide if target IP address is in its own network or not.

If it is in its network, it uses ARP to resolve the MAC address.

If target IP address is not in its network, it takes the help of default gateway to resolve MAC address using ARP.

Since in question it is clearly mentioned that X (source) and Y (destination) both are in the same subnet, we need not send ARP request message targeted at gateway and then expect it to give the MAC address of Y to X.

So the correct answer is option C.

edited by

Correct answer would be D


Address Resolution Protocol (ARP) is a protocol for mapping an Internet Protocol address (IP address) to a physical machine address (MAC) that is recognized in the local network.

ARP is used to find MAC address through IP address.

MAC Address is the physical address of the device


Hence Option D is Correct.(See MadeEasy and *** answers)

yes the resource says correctly source computer broadcasts destinations ip address to fetch MAC but it does not infer option D because option D says the packet contains an broadcast ip address example which is incorrect am i right?

@durgesh Kumar 6 ,Initially I was also thinking C is correct but seeing the question correctly I also think D is correct because Arp request packet contain empty or false MAC address source is And we achieve broad cast  by limited broadcast address. I think ie (It is used to broad cast with in a LAN) for me it make sense

I think this answer is perfect. I too marked this question incorrectly. This question teaches importance of  giving attention to each and every word in question. Here two most important words are "in its subnet" & "broadcast IP/MAC"

 If in the question instead of "in its subnet" it was given " in a different subnet" then what would have been the answer?


25 votes
In ARP request, the destination MAC is broadcasted (all 1's) and the packet is sent to the local subnet.

Do not confuse yourself that MAC is required then why IP is not broadcast? See it this way: If destination IP is broadcast, how would the destination machine ever know that its MAC has been requested by someone.

To clear confusion, you've 4 fields


Try filling these fields, if you broadcast ip (all 1's in DestIP), and you want to know the destination MAC, is there any way the destination machine can recognise that its MAC has been requested by a machine with SIP and SMAC address?

The correct answer was broadcast MAC in local subnet.

edited by
Best Explanation!
Thank you. This explains about within subnet but outside the subnet or in another network, packet will go to the gateway and using SM and IP, the network is found and then after the packet enters the network the DESTMAC is broadcast address so all bits will be 1 and then same steps? But doesn't the DESTMAC change router to router along the way so it shouldn't be all 1. Also how do we indicate that its a broadcast message  if MAC is changing and the IP should not be a broadcast as we need the original IP of the destination to get its MAC?
Nice explanation! cleared my doubt! Thanks :)
18 votes
correct answer is option c.

Since both are present in the same subnet thus an ARP request packet can be sent as bradcast MAC address, all will see but only destination will reply as a unicast reply.

reshown by
I think C is right
it is said "in local subnet" means same subnet

Option C is correct.

Check below link under "Example" section-



Won't it be broadcasting IP rather than Mac because we are trying to find MAC address using IP
Correct answer would be D

The following is a screenshot from 
Data_Communication_and_Networking_by_Behrouz.A.Forouzan from 5th.edition​​​​​​. 

So, I feel option D should be the answer.

"The query is broadcast over the link using the link-layer broadcast address"

link-layer address is MAC address.

Here is a live traffic capture where i have pinged an ip then immediately system generated arp packet with broadcast MAC address.


so i think option C is right.


@sreenivas.s1995 Now - a - days networking system is more complex . Is it a local subnet ??may be your network is connected via bridge so irrespective of the fact if you ping outside your local subnet then definitelly  destination would be broad cast mac only ,as it will go to bridge only than remaining story. may be my interpretation is wrong please correct me .


LOOK at it sir....where IP broadcast address is used

Please watch only std. Book  Kurose and ross they given MAC okk.
7 votes
Answer is Option C

If you are thinking of option D then once think like this

In option C they have give broadcast MAC address “It means FF:FF:FF:FF:FF:FF” which is true.

It will send with the destination IP address only

I also mistakenly think of it as option D and got a reward of “-2.67” marks

Don’t do the same mistake which I have faced..

edited by
6 votes
that it sends a broadcast request with having IP in local......:o
Don't remember the option but I marked the same. But, few people are saying broadcast MAC option .
It asks for MAC from IP, why will it broadcast MAC?
Ya, that's what the doubt is. Didn't remember if the option was ARP TO broadcast MAC ADDRESS. Or ARP with IP address.
Google says:
ARP stands for Address Resolution Protocol. When you try to ping an IP address on your local network, say, your system has to turn the IP address into a MAC address. ... Because it is a broadcast packet, it is sent to a special MAC address that causes all machines on the network to receive it.
How does this make the ip answer wrong??
but not sure that gateway comes in the way ornot
Can you recall option ? Was it an ARP request to broadcast MAC Address ?
Were there two options which had broadcast ip address? Or was it only one option?
two option regarding broadcast ip one its own subnet and other in its gateway
ARP request will be broadcasted in the same network using mac address FF:FF:FF:FF which is a broadcast address

No. We say Broadcasting is implemented at Network Layer but in actual, it is being implemented at Data Link Layer using MAC address (which is called Broadcast MAC address - FF:FF:FF:FF:FF:FF). 

Answer is C.

4 votes

The correct answer is C.

Refer page 467 of Computer Networking: A top down approach, attaching a screenshot here


Option D is correct....

Because the source sends ARP request packet with broadcast IP address to local subnet when the ARP packet is received by adapters then MAC Address
I think no reference book mentions that arp is sent with broadcast ip address.So answer should be c .
Some people do not care about references. They only care for their coaching.
Thats the point sir .

Because they didn't read any std Books.

Only instructor is std for them.

However in both books (kuross and ross and forouzan )this conept clearly mentioned .
3 votes

According to RFC 826 machine will create a ARP REQUEST Packet as follows: 

SOURCE IP(X's IP):(known)
TARGET MAC(Y's MAC) : 00:00:00:00:00
TARGET IP(Y's IP):(known)


This ARP requests must be sent as broadcasts. There is no way that an ARP request can be sent to the right system. After all, the whole reason for sending an ARP request is that X does not  know the Ethernet address Y . So an Ethernet address of all ones is used, i.e. FF:FF:FF:FF:FF:FF

This ARP Packet will be encapsulated inside a Ethernet frame  and broadcasted. 



By convention, every machine on the Ethernet is required to pay attention to packets with this as an address. So every machine sees every ARP requests. They all look to see whether the request is for their own address. If so, they respond. If not, they could just ignore it.

2 votes

Ans C) Please refer to the screenshot from Kurose and Ross. 


Related questions

6 votes
2 answers
Which of the following file transfer protocols use $TCP$ and establishes two virtual circuits between the local and remote server ? $FTP$ $TFTP$ $TELNET$ $NFS$
asked Sep 8, 2016 in Computer Networks makhdoom ghaya 1.1k views
7 votes
5 answers
Which of the following protocol pairs can be used to send and retrieve e-mails (in that order)? IMAP POP3 SMTP, POP3 SMTP MIME IMAP, SMTP
asked Feb 7, 2019 in Computer Networks Arjun 5.4k views
9 votes
4 answers
Consider three machines M, N, and P with IP addresses $, \:$, and $$ respectively. The subnet mask is set to $$ for all the three machines. Which one of the following is true? M, N, and P all belong to the same subnet Only M and N belong to the same subnet Only N and P belong to the same subnet M, N, and P belong to three different subnets
asked Feb 7, 2019 in Computer Networks Arjun 4.3k views
17 votes
6 answers
Consider that $15$ machines need to be connected in a LAN using $8$-port Ethernet switches. Assume that these switches do not have any separate uplink ports. The minimum number of switches needed is ______
asked Feb 7, 2019 in Computer Networks Arjun 8.1k views