A host is configured as 192.168.1.130/25. What network does it belong to and what is the broadcast address?
BeginnerScenarioAddressing, CIDR & Routing
Answer
Situation read → A /25 splits the last octet into two halves of 128 addresses: .0-.127 and .128-.255.
What I'd do →
- Block size is 128, and 130 falls in the second block
- Network is
192.168.1.128, first usable.129, last usable.254, broadcast192.168.1.255 - Verify with
ipcalc 192.168.1.130/25orpython3 -c "import ipaddress as i; print(i.ip_network('192.168.1.130/25', strict=False))"
Why → Network address is the host address ANDed with the mask; doing it by block size is faster than binary in an interview.
Interview tip → Mention that cloud providers reserve extra addresses, so usable hosts differ from the textbook 2^n - 2.
More on Addressing, CIDR & Routing
You own 10.0.0.0/16 for a new VPC and need separate /24 subnets for dev, QA and prod across two AZs. How do you carve it up?BeginnerHow many usable IPs does an AWS subnet of /28 have?BeginnerA route table has 10.0.0.0/16 -> local and 10.0.1.0/24 -> vpn-gw. Where does a packet to 10.0.1.5 go?BeginnerA newly built server can ping everything in its subnet but nothing outside. What is the first thing you check?BeginnerYou are picking a private range for a new company network. Which RFC 1918 range do you choose and why?BeginnerA server has two NICs and traffic to 10.20.0.0/16 is leaving through the wrong one. How do you see and fix the route?Beginner