If you get the message “Publishing failed” with WordPress 5, you most probably have to stop the firewall (the mod_security in Apache).
With OVH you can do it like this (link to the official OVH guide).
If it’s not enough, it most probably because you have the multi-site enabled.
To you have to login at the root of the FTP server, and edit the file .ovhconfig. You ha ve to edit the following rule:
And replace it by: