Author Topic: CWP Using 2 Private IP Addresses  (Read 753 times)

0 Members and 1 Guest are viewing this topic.

Offline
*
CWP Using 2 Private IP Addresses
« on: July 28, 2023, 02:11:10 AM »
I started getting return emails from Google today when sending to any gmail email. The error from Google said that my PTR record did not match the IP the email was coming from. I do have a block of 5 IP's from my ISP so I did a little digging. Found out that all I needed to do was go into my router and do a little Outbound NAT so the CWP server always used the correct public IP associated with the correct PTR record. My CWP server uses the private IP of 192.168.50.250 so all I had to do was create the NAT rule and everything should work right?...not so much.

I created the NAT rule for 192.168.50.250 and used the command
Code: [Select]
curl ifconfig.me in CWP to check if it worked and nope. Was still using the wrong public IP. I then used the command
Code: [Select]
ifconfig to find what IP address CWP was using and sure enough it was using 192.168.50.64

I went back to my NAT rules and created the same rule but used the IP 192.168.50.64 and boom! It started working.

So my question is...how is CWP using both 192.168.50.250 (which is what CWP says is its IP in the GUI and where all port forwarding is routed) and 192.168.50.64 (which is apparently what the CWP mail server is using)?

Is there a way I can delete 192.168.50.64 without breaking something?


Offline
*
Re: CWP Using 2 Private IP Addresses
« Reply #1 on: July 28, 2023, 03:23:44 AM »
I figured it out....

Go to
Code: [Select]
nano /etc/sysconfig/network-scripts/your-eth
Change line
Code: [Select]
BOOTPROTO="dhcp" to
Code: [Select]
BOOTPROTO="none"
Restart network
Code: [Select]
systemctl restart network