ExamGecko
Question list
Search
Search

List of questions

Search

Related questions











Question 28 - XK0-005 discussion

Report
Export

A systems administrator needs to reconfigure a Linux server to allow persistent IPv4 packet forwarding. Which of the following commands is the correct way to accomplish this task?

A.
echo 1 > /proc/sys/net/ipv4/ipv_forward
Answers
A.
echo 1 > /proc/sys/net/ipv4/ipv_forward
B.
sysctl -w net.ipv4.ip_forward=1
Answers
B.
sysctl -w net.ipv4.ip_forward=1
C.
firewall-cmd --enable ipv4_forwarding
Answers
C.
firewall-cmd --enable ipv4_forwarding
D.
systemctl start ipv4_forwarding
Answers
D.
systemctl start ipv4_forwarding
Suggested answer: B

Explanation:

The command sysctl -w net.ipv4.ip_forward=1 enables IPv4 packet forwarding temporarily by setting the kernel parameter net.ipv4.ip_forward to 1. To make this change persistent, the administrator needs to edit the file /etc/sysctl.conf and add the line net.ipv4.ip_forward = 1. The other options are incorrect because they either use the wrong file (/proc/sys/net/ipv4/ipv_forward), the wrong command (firewall-cmd or systemctl), or the wrong option (--enable or start). Reference: CompTIA Linux+ (XK0-005) Certification Study Guide, Chapter 12: Managing Network Connections, page 378.

asked 02/10/2024
Abraham Ermann
42 questions
User
Your answer:
0 comments
Sorted by

Leave a comment first