CompTIA Linux+ Powered by LPI (LX0-104) — Question 24
When issuing the command ifconfig eth0 192.168.1.20/24 up, which of the following happens? (Choose TWO correct answers.)
Answer options
- A. The address 192.168.1.20 is associated with the interface eth0.
- B. A network route to 192.168.1.0 with the netmask 255.255.255.0 pointing directly to eth0 is created.
- C. 192.168.1.1 is probed for router functionality and, in case of success, it is added to the list of default routers.
- D. The addresses from 192.168.1.20 to 192.168.1.24 are activated on the interface eth0.
- E. If eth0 was configured with a previous IP address, it is retained in addition to adding the new address.
Correct answer: A, B
Explanation
Option A is correct because the command directly assigns the IP address 192.168.1.20 to eth0. Option B is also correct as it creates a route for the specified network with the given netmask. The other options do not accurately reflect the function of the ifconfig command in this context.