Welcome to ExamTopics
ExamTopics Logo
- Expert Verified, Online, Free.

Unlimited Access

Get Unlimited Contributor Access to the all ExamTopics Exams!
Take advantage of PDF Files for 1000+ Exams along with community discussions and pass IT Certification Exams Easily.

Exam EX200 topic 1 question 57 discussion

Actual exam question from RedHat's EX200
Question #: 57
Topic #: 1
[All EX200 Questions]

SIMULATION -
Your System is going to use as a Router for two networks. One Network is 192.168.0.0/24 and Another Network is 192.168.1.0/24. Both network's IP address has assigned. How will you forward the packets from one network to another network?

Show Suggested Answer Hide Answer
Suggested Answer: See explanation below.
echo "1" >/proc/sys/net/ipv4/ip_forward
vi /etc/sysctl.conf
net.ipv4.ip_forward = 1
If you want to use the Linux System as a Router to make communication between different networks, you need enable the IP forwarding. To enable on running session just set value 1 to
/proc/sys/net/ipv4/ip_forward. As well as automatically turn on the IP forwarding features on next boot set on /etc/sysctl.conf file.

Comments

Chosen Answer:
This is a voting comment (?) , you can switch to a simple comment.
Switch to a voting comment New
syed2020
1 year, 8 months ago
If you want your change to survive the reboot, insert below line vi /etc/sysctl.conf net.ipv4.ip_forward=1 reboot the machine and check cat /proc/sys/net/ipv4/ip_foward
upvoted 2 times
wizojlo
1 month, 1 week ago
Directly editing sysctl.conf is not recommended anymore, configs now go to /etc/sysctl.d directory. echo 'net.ipv4.ip_forward=1' >> /etc/sysctl.d/ipforward.conf sysctl -p reboot sysctl net.ipv4.ip_forward (to verify; should return a value of 1)
upvoted 1 times
...
...
badguy001djh
2 years, 8 months ago
Firewalld had been added a new option,--add-forward, in version 0.9.0 .With this option packects from one interface can be forwarded to another interface. https://firewalld.org/2020/04/intra-zone-forwarding
upvoted 2 times
badguy001djh
2 years, 8 months ago
By the way, two interfaces must be in the same zone.
upvoted 2 times
...
...
QuangTruong
2 years, 10 months ago
sysctl -w net.ipv4.ip_forward=1 sysctl net.ipv4.ip_forward
upvoted 4 times
...
Community vote distribution
A (35%)
C (25%)
B (20%)
Other
Most Voted
A voting comment increases the vote count for the chosen answer by one.

Upvoting a comment with a selected answer will also increase the vote count towards that answer by one. So if you see a comment that you already agree with, you can upvote it instead of posting a new comment.

SaveCancel
Loading ...