Hello, I hope you are doing well!
If I understood properly, you have one server for Wazuh Manager, and another one for PostgreSQL engine. In such case, you need to copy the file you found on your Wazuh server to the PostgreSQL server and execute the following command setting the proper postresql.schema file path. For example:
psql -U PostgreSQLadmin -d Alerts_DB -f path/where/the/file/is/stored/postgresql.schema
Then add the proper settings for sending alerts to the PostgreSQL server on the /var/ossec/etc/ossec.conf configuration file on the Wazuh server:
<database_output>
<hostname>192.168.1.122</hostname>
<username>PostgreSQLadmin</username>
<password>secret1234</password>
<database>Alerts_DB</database>
<type>postgresql</type>
</database_output>
There you must set the PostgreSQL server IP address, and the username and password you set up on PostgreSQL.
Finally, restart your Wazuh Manager by executing:
systemctl restart wazuh-manager
Please, let me know if this information helps out.
Looking forward to your reply. Best regards.
Juan