How you configure an OpenVPN server with two public IP addresses?

Issues related to configuring your network
Locked
hack3rcon
Posts: 757
Joined: 2014/11/24 11:04:37

How you configure an OpenVPN server with two public IP addresses?

Post by hack3rcon » 2023/08/20 10:14:10

Hello,
Suppose you have an OpenVPN server. Now, you want to set two public IP addresses on it. Your public IP addresses are:

Code: Select all

1.2.3.4
1.2.3.5
Your OpenVPN server has one NIC as below:

Code: Select all

# ifconfig
enp0s3: flags=4163<UP,BROADCAST,RUNNING,MULTICAST>  mtu 1500
        inet 10.0.2.15  netmask 255.255.255.0  broadcast 10.0.2.255
        inet6 fe80::a00:27ff:feed:b47c  prefixlen 64  scopeid 0x20<link>
        ether 08:00:27:ed:b4:7c  txqueuelen 1000  (Ethernet)
        RX packets 14915  bytes 2455731 (2.3 MiB)
        RX errors 0  dropped 0  overruns 0  frame 0
        TX packets 11701  bytes 1581492 (1.5 MiB)
        TX errors 0  dropped 0 overruns 0  carrier 0  collisions 0

lo: flags=73<UP,LOOPBACK,RUNNING>  mtu 65536
        inet 127.0.0.1  netmask 255.0.0.0
        inet6 ::1  prefixlen 128  scopeid 0x10<host>
        loop  txqueuelen 1000  (Local Loopback)
        RX packets 4  bytes 336 (336.0 B)
        RX errors 0  dropped 0  overruns 0  frame 0
        TX packets 4  bytes 336 (336.0 B)
        TX errors 0  dropped 0 overruns 0  carrier 0  collisions 0

Can you show how to prepare your OpenVPN server step by step? For example, You must first create a virtual network card and...

I'm sure this thread is useful for many users.

Thank you.

User avatar
jlehtone
Posts: 4532
Joined: 2007/12/11 08:17:33
Location: Finland

Re: How you configure an OpenVPN server with two public IP addresses?

Post by jlehtone » 2023/08/20 15:47:07

Didn't you have two threads on this topic quite recently?

scottro
Forum Moderator
Posts: 2556
Joined: 2007/09/03 21:18:09
Location: NYC
Contact:

Re: How you configure an OpenVPN server with two public IP addresses?

Post by scottro » 2023/08/21 10:43:02

And, a thread on Ask Fedora, and on Rocky forums. I'm going to lock this thread.
New users should check the FAQ and Read Me First pages

Locked