redhat:other-redhat:wireguard-redhat

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revision Previous revision
Next revision
Previous revision
redhat:other-redhat:wireguard-redhat [2020/01/31 22:29] michaelredhat:other-redhat:wireguard-redhat [2020/01/31 22:56] (current) michael
Line 10: Line 10:
  
  
-===== Install VPN-Server on CentOS 7.x =====+===== Install VPN-Server on CentOS 7 / 8 =====
  
 ''<wrap hi>For the **Debian** installation Tutorial klick **[[debian:other-debian:wireguard-debian|here]]**</wrap>'' ''<wrap hi>For the **Debian** installation Tutorial klick **[[debian:other-debian:wireguard-debian|here]]**</wrap>''
Line 23: Line 23:
 </WRAP> </WRAP>
  
-<wrap em>For CentOS 7:</wrap>+<wrap em>For CentOS 7 ONLY:</wrap>
 <code> <code>
 # yum install epel-release # yum install epel-release
Line 32: Line 32:
 </code> </code>
  
-<wrap em>For CentOS 8:</wrap>+<wrap em>For CentOS 8 ONLY:</wrap>
 <code> <code>
 # yum install epel-release # yum install epel-release
Line 41: Line 41:
 </code> </code>
  
 +<wrap em>continue here:</wrap>
 <code> <code>
 # mkdir /etc/wireguard && cd /etc/wireguard/ # mkdir /etc/wireguard && cd /etc/wireguard/
Line 74: Line 75:
 <WRAP center box 100%> <WRAP center box 100%>
 <code> <code>
-vim /etc/sysctl.d/99-sysctl.conf+echo "net.ipv4.ip_forward=1" >> /etc/sysctl.d/99-sysctl.conf 
 +# echo "net.ipv4.conf.all.forwarding=1" >> /etc/sysctl.d/99-sysctl.conf 
 +# echo "net.ipv6.conf.all.forwarding=1" >> /etc/sysctl.d/99-sysctl.conf 
 + 
 +# cat /etc/sysctl.d/99-sysctl.conf
 </code> </code>
  
-<sxh bash; highlight: [11]>+<sxh bash; highlight: [11-13]>
 # sysctl settings are defined through files in # sysctl settings are defined through files in
 # /usr/lib/sysctl.d/, /run/sysctl.d/, and /etc/sysctl.d/. # /usr/lib/sysctl.d/, /run/sysctl.d/, and /etc/sysctl.d/.
Line 89: Line 94:
 # For more information, see sysctl.conf(5) and sysctl.d(5). # For more information, see sysctl.conf(5) and sysctl.d(5).
 net.ipv4.ip_forward=1 net.ipv4.ip_forward=1
 +net.ipv4.conf.all.forwarding=1
 +net.ipv6.conf.all.forwarding=1
 </sxh> </sxh>
 </WRAP> </WRAP>
Line 97: Line 104:
 # systemctl enable wg-quick@wg0.service # systemctl enable wg-quick@wg0.service
 </code> </code>
 +
 +<WRAP center round important 100%>
 +''Setup POSTROUTING, do this ONLY if you don't want to setup routing!
 +''
 +<code>
 +# firewall-cmd --permanent --direct --add-rule ipv4 nat POSTROUTING 0 -s 192.168.100.0/24 ! -d 192.168.100.0/24 -j SNAT --to 192.168.1.8
 +# firewall-cmd --reload
 +</code>
 +</WRAP>
 +
  
 <WRAP center box 100%> <WRAP center box 100%>
Line 141: Line 158:
 ==== Fritzbox - Routing Konfigurieren ==== ==== Fritzbox - Routing Konfigurieren ====
  
-<wrap em>Nur falls kein Masquarading als Inrtface Forewarding eingesetzt wird. (So wie in diesem Tutorial)</wrap>+<wrap em>Nur falls kein POSTROUTING als Interface Forewarding eingesetzt wird. (So wie in diesem Tutorial)</wrap>
  
  
  • redhat/other-redhat/wireguard-redhat.1580506154.txt.gz
  • Last modified: 2020/01/31 22:29
  • by michael