Netpractice 42 Tutorial -
NetPractice 42: A Complete Tutorial to Master IP Addressing & Subnetting
NetPractice is a 42 Network project designed to teach you the fundamentals of IP addressing, subnet masks, routing, and TCP/IP configuration through small, practical exercises. No coding—just pure networking logic.
If you're struggling to make the "ping" work, this guide will walk you through the core concepts and how to solve each level type.
4. Configure Router Interfaces Correctly
Each router interface belongs to exactly one link’s subnet. That IP becomes the gateway for devices on that link. netpractice 42 tutorial
Step-by-Step Problem Solving
Let’s break down how to approach any level.
2.3 Routing
- Default route:
0.0.0.0/0via gateway - A route entry: destination network, next hop, interface
- Routers forward packets between networks.
6. Tips for success
- Draw the network on paper.
- Write down each LAN’s network address and mask.
- Assign lowest usable IP to router interface in each LAN.
- For point-to-point links (two routers directly connected), use
/30or/31(though/31not always allowed in NetPractice). - Use
pingtest after each change – it shows which connection fails.
Calculating Network ID
Given IP 10.0.0.42 and mask 255.255.255.240 (/28): NetPractice 42: A Complete Tutorial to Master IP
- Convert the last interesting octet:
.42binary =00101010 - Mask:
.240binary =11110000 - Network bits:
00100000=.32 - Network ID =
10.0.0.32/28
Level 1 – Same Subnet Communication
Scenario: Two devices (A and B) must ping each other. Only IPs are missing.
Rule: Both must be in the same subnet.
Example:
- A’s mask:
255.255.255.0(/24) - A’s IP:
192.168.1.1 - B’s mask: same
255.255.255.0
→ B’s IP must be192.168.1.x(not1, not255)
✅ Solution: 192.168.1.2 to 254
Part 7: Practice Exercises (Try These Before the Real Exam)
5. Add Static Routes Where Needed
If a router must reach a subnet that is not directly connected, you add a route:
- Destination: target network (e.g.,
192.168.5.0/24) - Next hop: the IP of the next router (must be reachable via a directly connected link)
