Overview
Customers may experience issues with the integration of KerioConnect to the AppManager, where the appliance seems to disconnect with the following messages in the GFI agent logs:
[WARNING] ... failed to get hasLicense because it failed to get license expiration metrics. reason: Post "http://localhost:4040/admin/api/jsonrpc/": dial tcp [::1]:4040: connect: connection refused
[WARNING] ... Skipping publishing appliance info because there is no valid product license
[WARNING] ... Skipping syncing ip because there is not valid product license
[WARNING] ... Skipping publishing insights because there is no valid product license
These errors indicate that the GFIAgent connection to the appliance over Port 4040 is being refused and it cannot check the license and relevant metrics for AppManager.
Solution
This failure prevents the GFIAgent from detecting the license on the appliance, causing a disconnection issue.
- Verify the connection to port 4040 using the command
nc -v localhost 4040
. The output should be: **Connection to localhost port 4040 [tcp/yo-main] succeeded!** If it fails, verify the network configuration to identify anything that could be causing this connection to be refused. - Once you ensure the connection succeeds, restart the agent service depending on the OS:
- For Windows, use services.msc to restart the GFIAgent service
- For Linux, use
sudo systemctl restart gfiagent
- For MacOS, use
sudo launchctl unload -w /Library/LaunchDaemons/gfiagent.plist
to stop the service then commandsudo launchctl load -w /Library/LaunchDaemons/gfiagent.plist
to start the service
- If the integration still fails, the root cause can be different now. Check the agent logs for any Warnings and Errors and action accordingly. Try Resetting KerioConnect's Connection to GFI AppManager: A Step-by-Step Guide.
- If the issue persists, provide GFI support with the information requested in the article Gathering information for troubleshooting AppManager issues.
Summary
Customers using Kerio Connect may encounter disconnection issues when integrating with the AppManager when connections to port 4040 are being refused, which is essential for the GFI Agent to access license and appliance information. To resolve this, customers should first check the connection to port 4040 using appropriate network commands. If the connection fails, network configurations should be reviewed and corrected. Subsequent steps involve restarting the GFIAgent service on the operating system in use (Windows, Linux, or MacOS). If problems persist after these steps, further troubleshooting with the agent logs and GFI support may be necessary.
FAQ
-
How can I verify if port 4040 is open on my system?
Use the command nc -v localhost 4040 to check the connection. A successful connection will display: "Connection to localhost port 4040 [tcp/yo-main] succeeded!" -
What should I do if my connection to port 4040 is refused?
First, check and adjust your network configuration to ensure nothing is blocking the connection to port 4040. After adjustments, verify the connection again. - How do I restart the GFIAgent service on different operating systems?
- For Windows, use services.msc to restart the GFIAgent service
- For Linux, use
sudo systemctl restart gfiagent
- For MacOS, use
sudo launchctl unload -w /Library/LaunchDaemons/gfiagent.plist
to stop the service then commandsudo launchctl load -w /Library/LaunchDaemons/gfiagent.plist
to start the service