<?xml version="1.0" encoding="UTF-8" ?>

<bugzilla version="5.2"
          urlbase="https://bugzilla.altlinux.org/"
          
          maintainer="jenya@basealt.ru"
>

    <bug>
          <bug_id>42696</bug_id>
          <alias>sysctl</alias>
          <creation_ts>2022-05-06 09:09:21 +0300</creation_ts>
          <short_desc>Проблема с применением настроек из /etc/sysctl.conf</short_desc>
          <delta_ts>2022-05-18 14:39:11 +0300</delta_ts>
          <reporter_accessible>1</reporter_accessible>
          <cclist_accessible>1</cclist_accessible>
          <classification_id>1</classification_id>
          <classification>Unclassified</classification>
          <product>Branch p10</product>
          <component>systemd-sysctl-common</component>
          <version>не указана</version>
          <rep_platform>x86_64</rep_platform>
          <op_sys>Linux</op_sys>
          <bug_status>CLOSED</bug_status>
          <resolution>NOTABUG</resolution>
          
          
          <bug_file_loc></bug_file_loc>
          <status_whiteboard></status_whiteboard>
          <keywords></keywords>
          <priority>P5</priority>
          <bug_severity>major</bug_severity>
          <target_milestone>---</target_milestone>
          
          
          <everconfirmed>1</everconfirmed>
          <reporter name="Anton Shevtsov">shevtsov.anton</reporter>
          <assigned_to name="Alexey Shabalin">shaba</assigned_to>
          <cc>cas</cc>
          
          <qa_contact name="qa-p10@altlinux.org">qa-p10</qa_contact>

      

      

      

          <comment_sort_order>oldest_to_newest</comment_sort_order>  
          <long_desc isprivate="0" >
    <commentid>210421</commentid>
    <comment_count>0</comment_count>
    <who name="Anton Shevtsov">shevtsov.anton</who>
    <bug_when>2022-05-06 09:09:21 +0300</bug_when>
    <thetext>ОС Альт Сервер 10

Исходные данные: Обновленная система (пакеты, ядро)

Указана 1 опция в sysctl.conf, ребут.
cat /etc/sysctl.conf | grep -v &apos;^#&apos;
net.ipv4.ip_forward = 1

Смотрим, что опция не применена
sysctl -a | grep &apos;net.ipv4.ip_forward&apos;
net.ipv4.ip_forward = 0
net.ipv4.ip_forward_update_priority = 1
net.ipv4.ip_forward_use_pmtu = 0

Смотрим что systemd-sysctl работает
systemctl status systemd-sysctl
● systemd-sysctl.service - Apply Kernel Variables
     Loaded: loaded (/lib/systemd/system/systemd-sysctl.service; static)
     Active: active (exited) since Fri 2022-05-06 11:03:47 +05; 22s ago
       Docs: man:systemd-sysctl.service(8)
             man:sysctl.d(5)
    Process: 2682 ExecStart=/lib/systemd/systemd-sysctl (code=exited, status=0/SUCCESS)
   Main PID: 2682 (code=exited, status=0/SUCCESS)
        CPU: 3ms

мая 06 11:03:47 alt-server10 systemd[1]: Starting Apply Kernel Variables...
мая 06 11:03:47 alt-server10 systemd[1]: Finished Apply Kernel Variables.

делаем ему systemctl restart systemd-sysctl
и видимо, что теперь оно применилось
sysctl -a | grep &apos;net.ipv4.ip_forward&apos;
net.ipv4.ip_forward = 1
net.ipv4.ip_forward_update_priority = 1
net.ipv4.ip_forward_use_pmtu = 0

после ребута, снова в net.ipv4.ip_forward установлен в 0</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>210832</commentid>
    <comment_count>1</comment_count>
    <who name="Andrey Cherepanov">cas</who>
    <bug_when>2022-05-18 14:39:11 +0300</bug_when>
    <thetext>ip_forward выставляется также в Etcnet (/etc/net/sysctl.conf) и systemd-networkd. Они могут переопределить этот параметр.</thetext>
  </long_desc>
      
      

    </bug>

</bugzilla>