Apply NAT changes from command line

  • All,

    I have a weird request but a simple one.

    What command can I issue to "Apply Changes" for NAT?

    The reason I need this is the following:

    I installed VPNC on my pfsense, had to manually create NAT rules and everything like that. Everything works great after it is configured, there's scripts on which the VPN will be re-established if link goes down and all.

    The problem I have is, once I reboot my pfsense, to make traffic go through the VPN tunnel, I must log in to the web gui, go to "Firewall -> NAT -> Outbound", Hit save, and hit apply settings.

    After I do this, everything works the way it should again.

    So basically I just want to have the NAT settings applied after the VPN connectivity is established during boot.

    Any ideas on what command I should issue?

    Thanks a lot!

    David Cabrejos

  • You can run /etc/rc.filter_configure but I think it needs to be after boot or at least fairly late in the bootup scripts.

  • Efonne,

    Thanks for the prompt reply.

    Unfortunately I did not test your command since I was able to fix the NAT issue I was having and uploaded a solution to my post as well. (iptables to pfsense command line?)

    I'm sure this should help someone who was trying to accomplish the same.

    Thank you for your time!

    David Cabrejos

Log in to reply