Symptoms
Sometimes, you will get a notification from CloudLinux about your JWT token being missing or expired similar to this:
Check existing JWT token:
FAILED: JWT token expired. Please check for JWT token in path "/etc/sysconfig/rhn/jwt.token". Try running "rhn_check" for getting a new token if it is absent. Server can't collect and send statistics to Centralized Monitoring if you don't have a correct JWT token. Link to FAQ and troubleshooting https://docs.cloudlinux.com/cloudlinux-os-plus/#faq-2. Please write to support https://cloudlinux.zendesk.com/ if you can't resolve the issue.
Command for disabling this cron checker: "cldiag --disable-cron-checkers check-jwt-token"
Description
This can happen when the token set up by CloudLinux has expired and hasn't been updated yet. You can generally remove the token and regenerate it.
Workaround
- Access the server's command line as the 'root' user via SSH or "Terminal" in WHM.
- Move the
jwt.token
out of the way.mv -v /etc/sysconfig/rhn/jwt.token{,.$(date +%s)}
- Ensure the CloudLinux is registered.
clnreg_ks --force
- Generate another token with the
rhn_check
command.rhn_check
- Verify that the token has been recreated.
cat /etc/sysconfig/rhn/jwt.token