I am trying to create a new publication on a SQL 2008R2 instance that already has two publications running successfully. When the snapshot agent kicks in it is failing. The job created has the following in the history:
Step 2:
The replication agent encountered a failure. See the previous job step history message or Replication Monitor for more information. The step failed.
Step 3:
Executed as user: domain\user. Agent shutdown. For more information, see the SQL Server Agent job history for job 'instance-publication-20'. [SQLSTATE 01000] (Message 20557) Replication-Replication Snapshot Subsystem: agentinstance-publication-20 failed. The replication agent encountered a failure. See the previous job step history message or Replication Monitor for more information. The step failed. [SQLSTATE 42000] (Error 14151). The step failed.
I have tried turning on logging by adding the relevant params to the job step, running from the command line, switching the NT user to myself (a sysadmin), changing snapshot from network path back to default path and publishing other databases. None of this has made any difference, the folder/files for the snapshot do not get created and I can't get any useful output.
I also switched the owner of the database to be my own account and ran checkdb (no errors). It's compatibility level is 90.