Hi,
If you made a recent change to the ocsinventory-server.conf file, did you restart Apache service ?
What is the version of your OCS server?
If you are using an SSL certificate (cacert.pem), you should communicate with the server in https, not http...
Regards, Stéphane