As you can read, OCS is 2 server (services) :
- Communication Server (/ocsinventory) : to receive inventory from agents, based on Perl module
- Administrative Server (/ocsreports) : to manage, search, deploy, based on Php module
Each of this 2 servives write and read the database (MySQL/MariaDB).
So you need to have ALL prerequesites for Apache2, MySQL/MariaDB, Perl, Php.
After installation of OCS, you need to (in this order)
- create database, user, rights
- install tables in database = first launch of ocsreports (Administrative Server)
- set the database identifiants in the conf for Communication Server (z-ocsinventory.conf)
- install an agent and launch it (the agent connect to Communication Server)