Dear Mohammed Hinwani,
We had the same issue, we were able to trouble shoot it after changing the username to c4agent in the tomcat-users.xml, restarting the tomcat and maintaining the same in the SAP cloud for analytics.
Please check the username,role you have assigned in the tomcat-users.xml
Please let me know if the issue is resolved.
Regards,
Qadir