Profile sync after change web-console port

Hello,

We recently changed the port value for web-console from default 443 to 8443 using command

# pritunl set app.server_port 8443

and restarted the pritunl process. But when connecting the Pritunl client an error occurs - it tries to use the previous old port value and the log contains:

[2024-10-29 13:5:48][ERROR] Profiles: Failed to sync profile configuration
RequestError: Request:  Client error ssl=true hostname=IP-address port=old_value method=GET path=/key/sync/61ff20cbc1e709c149fd0572/63fa174a90ebae054ae4fd56/653644b488c49b9109058421/c82dad22605b05dd854ebefe8c5a05db ttl=5000
Error: connect ECONNREFUSED IP:old_value
Error: connect ECONNREFUSED IP:old_value
    at TCPConnectWrap.afterConnect [as oncomplete] (node:net:1607:16)

i.e. profile not synced. Due to the large number of client profiles, it is not convenient to import profiles manually each time. Is there any way for profile synchronization to work?

Here mentioned “Users using a Pritunl client will sync all configuration changes before connecting and will not need to update the configuration”. Does this also include change of web-console port value?

The client will need to access the web server to sync the changes. Running sudo iptables -t nat -A PREROUTING -p tcp --dport 443 -j REDIRECT --to-port 8443 should make the web server available on both ports. This can be done temporarily until all clients have synced the changes to the new port.

1 Like

thank you! You mean run this iptables command on server temporarily?

Yes that will allow the clients to access the web server on both ports to be able to sync the changes.

1 Like

Thank you so much! it’s really works…