Disclaimer:
Educational Use Only:
The website links provided are to be used strictly for educational and knowledge-gaining purposes only.
No Misuse:
Do not misuse the links or the information contained therein for any commercial, illegal, or unethical activities.
Respect for Websites and Businesses:
Respect the intellectual property and business interests of the websites and their owners. Do not attempt to alter, copy, or redistribute content without proper authorization.
Acknowledge Value of Knowledge:
Recognize and value the knowledge and resources shared by these websites. Use the information responsibly and ethically.
No Endorsement:
The provision of these links does not imply endorsement of the linked sites, their content, or their products and services. Users are responsible for evaluating the suitability and accuracy of the information.
User Responsibility:
By accessing these links, you agree to use the information at your own risk and to comply with all applicable laws and website terms of use.
- Which of the following commands displays all active network interfaces on a Linux system?
a. ifstat
b. netstat
c. ifconfig
d. ping
Answer: c. ifconfig
geeksforgeeks+1 - What does the “ifconfig eth0 up” command do?
a. Deactivates the eth0 interface
b. Updates the IP address of eth0
c. Activates the eth0 interface
d. Shows the MAC address of eth0
Answer: c. Activates the eth0 interface
phoenixnap+1 - Which command is used to assign an IP address to an interface using ifconfig?
a. ifconfig eth0 add 192.168.1.10
b. ifconfig eth0 setip 192.168.1.10
c. ifconfig eth0 192.168.1.10
d. ifconfig 192.168.1.10 eth0
Answer: c. ifconfig eth0 192.168.1.10
geeksforgeeks+1 - What does “ifconfig eth0 down” accomplish?
a. Disables the eth0 network interface
b. Updates interface statistics
c. Deletes the eth0 interface
d. Displays eth0 configuration
Answer: a. Disables the eth0 network interface
phoenixnap+1 - Which option in ifconfig displays all network interfaces, even inactive ones?
a. -v
b. -a
c. -all
d. -s
Answer: b. -a
phoenixnap - How can the netmask be set for a network interface using ifconfig?
a. ifconfig eth0 netmask 255.255.255.0
b. ifconfig eth0 mask 255.255.255.0
c. ifconfig eth0 subnet 255.255.255.0
d. ifconfig set eth0 netmask 255.255.255.0
Answer: a. ifconfig eth0 netmask 255.255.255.0
geeksforgeeks+1 - Which of the following can be configured via ifconfig?
a. IP address
b. Netmask
c. Broadcast address
d. All of these
Answer: d. All of these
geeksforgeeks+1 - What information can the basic “ifconfig” command show?
a. Network statistics only
b. IP address, MAC address, MTU, etc.
c. Only the interface name
d. Interface speed
Answer: b. IP address, MAC address, MTU, etc.
includehelp+2 - Which command sets the broadcast address of eth0 to 192.168.1.255?
a. ifconfig eth0 broadcast 192.168.1.255
b. ifconfig eth0 set-broadcast 192.168.1.255
c. ifconfig broadcast 192.168.1.255 eth0
d. ifconfig eth0 -broadcast 192.168.1.255
Answer: a. ifconfig eth0 broadcast 192.168.1.255
phoenixnap+1 - How do you change the Maximum Transmission Unit (MTU) of an interface using ifconfig?
a. ifconfig eth0 set mtu 1400
b. ifconfig eth0 mtu 1400
c. ifconfig mtu eth0 1400
d. ifconfig eth0 –mtu 1400
Answer: b. ifconfig eth0 mtu 1400
includehelp+2 - Which option disables promiscuous mode on an interface?
a. promisc
b. -promisc
c. promisc off
d. no-promisc
Answer: b. -promisc
phoenixnap - Which command is used to display a concise summary of all active interfaces?
a. ifconfig -v
b. ifconfig -short
c. ifconfig -s
d. ifconfig -summary
Answer: c. ifconfig -s
phoenixnap - The command “ifconfig eth0 hw ether 00:1a:2b:3c:4d:5e” is used for:
a. Setting the interface speed
b. Changing the MAC address
c. Assigning a gateway
d. Setting the netmask
Answer: b. Changing the MAC address
geeksforgeeks - What address family does ifconfig primarily use to configure IP interfaces?
a. inet
b. unix
c. nsap
d. link
Answer: a. inet
sites.ualberta - How is a network interface alias added in ifconfig?
a. ifconfig eth0-1 192.168.1.20
b. ifconfig eth0:0 192.168.1.20
c. ifconfig eth0.alias 192.168.1.20
d. ifconfig add eth0 192.168.1.20
Answer: b. ifconfig eth0:0 192.168.1.20
geeksforgeeks - Which command shows all currently configured interfaces, including those that are down?
a. ifconfig -down
b. ifconfig -a
c. ifconfig show all
d. ifconfig -list
Answer: b. ifconfig -a
phoenixnap - What must be true for ifconfig to modify network settings?
a. No privileges required
b. User must be root or use sudo
c. Must be called from /root
d. Only on Mondays
Answer: b. User must be root or use sudo
phoenixnap - Which command disables the ARP protocol on a specific interface?
a. ifconfig eth0 -arp
b. ifconfig eth0 noarp
c. ifconfig eth0 arp off
d. ifconfig -arp eth0
Answer: a. ifconfig eth0 -arp
phoenixnap - Which command enables all-multicast mode for an interface?
a. ifconfig eth0 multi
b. ifconfig eth0 allmulti
c. ifconfig allmulti eth0
d. ifconfig eth0 -multi
Answer: b. ifconfig eth0 allmulti
phoenixnap - Which field is NOT displayed by default via “ifconfig”?
a. Broadcast address
b. Link speed
c. MTU
d. MAC address
Answer: b. Link speed
geeksforgeeks+1 - If “ifconfig” is run without arguments, what does it display?
a. System processes
b. DNS records
c. Configuration of active interfaces
d. Routing table
Answer: c. Configuration of active interfaces
geeksforgeeks+1 - Which command brings down the alias “eth0:0”?
a. ifconfig eth0:0 stop
b. ifconfig eth0:0 disable
c. ifconfig eth0:0 down
d. ifconfig down eth0:0
Answer: c. ifconfig eth0:0 down
geeksforgeeks - What does “ifconfig eth0” alone (with no arguments) do?
a. Brings eth0 up
b. Shows eth0 interface configuration
c. Assigns a random IP
d. Disables eth0
Answer: b. Shows eth0 interface configuration
geeksforgeeks+1 - How do you enable the ARP protocol on eth0?
a. ifconfig eth0 arp
b. ifconfig arp eth0
c. ifconfig eth0 +arp
d. ifconfig eth0 enable arp
Answer: a. ifconfig eth0 arp
phoenixnap - What will “ifconfig lo” output?
a. Configuration of Ethernet0 interface
b. Loopback interface configuration
c. List of all interfaces
d. No output
Answer: b. Loopback interface configuration
geeksforgeeks+1 - What does the MTU field in ifconfig represent?
a. Maximum Transfer Upload
b. Maximum Trusted Unit
c. Maximum Transmission Unit
d. Main Transmission Upstream
Answer: c. Maximum Transmission Unit
includehelp+1 - The flag IFF_MULTICAST in ifconfig output means the interface:
a. Is using point-to-point
b. Supports multicast
c. Is in promiscuous mode
d. Has hardware offload
Answer: b. Supports multicast
sites.ualberta - How does ifconfig help in troubleshooting?
a. By providing firewall logs
b. By showing interface status and IP
c. By viewing routing tables
d. By displaying system errors
Answer: b. By showing interface status and IP
geeksforgeeks+1 - Which protocol’s address can ifconfig assign on interface setup?
a. HTTP
b. ICMP
c. IP
d. SSL
Answer: c. IP
sites.ualberta - When configuring a new interface, what must be specified with ifconfig apart from interface name?
a. A valid IP address
b. A password
c. A routing protocol
d. DNS server
Answer: a. A valid IP address
sites.ualberta+2 - If no output is shown for an interface using ifconfig, what is likely true?
a. The interface is down
b. The interface has an IP
c. The interface is up
d. The interface is not configured
Answer: d. The interface is not configured
sites.ualberta+1 - What effect does “ifconfig eth0 promisc” have?
a. Enables ARP
b. Enables promiscuous mode
c. Disables interface
d. Enables multicast
Answer: b. Enables promiscuous mode
phoenixnap - To change both IP address and netmask for eth0, the correct command is:
a. ifconfig eth0 192.168.1.10 netmask 255.255.255.0
b. ifconfig eth0 set 192.168.1.10 mask 255.255.255.0
c. ifconfig eth0 assign 192.168.1.10 netmask 255.255.255.0
d. ifconfig 192.168.1.10 255.255.255.0 eth0
Answer: a. ifconfig eth0 192.168.1.10 netmask 255.255.255.0
geeksforgeeks+1 - Which command prints only the configuration for the specified interface eth1?
a. ifconfig eth1
b. ifconfig show eth1
c. ifconfig -i eth1
d. ifconfig -e eth1
Answer: a. ifconfig eth1
phoenixnap+1 - Which mode receives all packets for analysis in network forensics?q
a. Multicast mode
b. Broadcast mode
c. Promiscuous mode
d. Simplex mode
Answer: c. Promiscuous mode
phoenixnap - Why might a modern Linux system not have ifconfig installed by default?
a. ifconfig is obsolete; replaced by ip command
b. ifconfig is not open source
c. ifconfig is only for Windows
d. ifconfig is slow
Answer: a. ifconfig is obsolete; replaced by ip command
blackdown+1 - Which of these fields appears in ifconfig output?
a. Interface name
b. IP address
c. MAC address
d. All of these
Answer: d. All of these
blackdown+2 - Which command removes an alias from the eth0 interface?
a. ifconfig eth0:0 remove
b. ifconfig eth0:0 down
c. ifconfig eth0:0 del
d. ifconfig eth0:0 alias remove
Answer: b. ifconfig eth0:0 down
geeksforgeeks - Setting the ARP protocol on eth0 with ifconfig is done using:
a. ifconfig eth0 arp
b. ifconfig arp eth0
c. ifconfig eth0 enarp
d. ifconfig eth0 +arp
Answer: a. ifconfig eth0 arp
phoenixnap - To set the netmask and broadcast address for eth0 at once, the proper command is:
a. ifconfig eth0 netmask 255.255.255.0 broadcast 192.168.1.255
b. ifconfig eth0 255.255.255.0 192.168.1.255
c. ifconfig set eth0 netmask 255.255.255.0 broadcast 192.168.1.255
d. ifconfig eth0 mask 255.255.255.0 bcast 192.168.1.255
Answer: a. ifconfig eth0 netmask 255.255.255.0 broadcast 192.168.1.255
geeksforgeeks+1 - The “inet addr” field in ifconfig output displays:
a. IPv4 address
b. MAC address
c. DNS server
d. Interface name
Answer: a. IPv4 address
blackdown+1 - What does the “lo” interface represent in “ifconfig” output?
a. Ethernet0
b. Loopback
c. Wi-Fi
d. Virtual LAN
Answer: b. Loopback
blackdown+1 - Which value can be changed by running “ifconfig eth0 mtu 1400”?
a. Interface speed
b. MTU
c. Subnet mask
d. Interface index
Answer: b. MTU
includehelp+2 - When would “ifconfig -v” be useful?
a. To show minimal information
b. To display more detailed config for interfaces
c. It lists interfaces briefly
d. To activate an interface
Answer: b. To display more detailed config for interfaces
phoenixnap - To see the summary of interfaces with minimal details, use:
a. ifconfig -s
b. ifconfig -v
c. ifconfig -summary
d. ifconfig -min
Answer: a. ifconfig -s
phoenixnap - Which protocol does ifconfig NOT handle directly?
a. IP
b. ARP
c. TCP
d. Ethernet
Answer: c. TCP
sites.ualberta+1 - Assigning a new MAC address via ifconfig can be done with which keyword?
a. mac
b. hardware
c. hw ether
d. addr
Answer: c. hw ether
geeksforgeeks - How can ifconfig facilitate the creation of a virtual interface?
a. By creating eth0:1 with ifconfig eth0:1 192.168.0.5
b. By running ifconfig virtual eth0
c. By using ifconfig eth0 virtual 192.168.0.5
d. By ifconfig create virtual eth0
Answer: a. By creating eth0:1 with ifconfig eth0:1 192.168.0.5
geeksforgeeks - What issue might ifconfig -a help diagnose?
a. Unlisted but active interfaces
b. Duplicate interfaces only
c. Overloaded interfaces only
d. Interface speed mismatches
Answer: a. Unlisted but active interfaces
phoenixnap - Why is ifconfig still taught, despite newer tools like “ip”?
a. ifconfig is cross-platform
b. Legacy systems still use it, and it is still found in many tutorials and documentation
c. ifconfig replaces all other tools
d. ip is deprecated
Answer: b. Legacy systems still use it, and it is still found in many tutorials and documentation
- https://www.geeksforgeeks.org/linux-unix/ifconfig-command-in-linux-with-examples/
- https://phoenixnap.com/kb/linux-ifconfig
- https://www.includehelp.com/linux/network-commands-aptitude-questions-and-answers.aspx
- https://sites.ualberta.ca/dept/chemeng/AIX-43/share/man/info/C/a_doc_lib/cmds/aixcmds3/ifconfig.htm
- https://www.blackdown.org/linux-network-commands/
- https://www.redhat.com/en/blog/ifconfig-vs-ip
- https://www.sanfoundry.com/computer-networks-mcqs-network-utilities/
- https://www.placementpreparation.io/mcq/computer-network/
- https://www.sanfoundry.com/computer-network-questions-answers/
- https://www.uninets.com/blog/computer-networks-mcq
- https://scholarexpress.com/computer-networks-multiple-choice-questions/
- https://www.ibm.com/docs/ssw_aix_72/i_commands/ifconfig.html
- https://www.gdcramban.in/MCQ/networkmcq.pdf
- https://manage.accuwebhosting.com/knowledgebase/4809/Explain-ifconfig-Command-in-Linux.html
- https://www.interviewbit.com/computer-network-mcq/
- https://www.tecmint.com/ifconfig-command-examples/
- https://pubs.lenovo.com/imm2/dw1lm_r_ifconfigcommand
- https://www.youtube.com/watch?v=Y9paMPlq7NM
- https://docs.oracle.com/cd/E19683-01/817-0573/solimpconcepts-41/index.html
- https://reck.ac.in/wp-content/uploads/2023/04/DCN_MCQ-Ashwini-.pdf