I tried to write a manual agent job with the Management Tools 2012, essentially copy paste from the job that the replication wizard created. I then got the error as stated in the title of this post.
The problem is solved by manually editing the agent job script. Have I missed something obvious in the GUI or is it not possible to use it to create this kind of job?
My solution: It turns out that the GUI tool does not configure the @server parameter.
@os_run_priority=0, @subsystem=N'Snapshot',
@command=N'-Publisher [MYSERVER] -PublisherDB [db_vs] -Distributor [MYSERVER] -Public......
@server=N'MYSERVER', <--- MISSING! -----
@database_name=N'master'
With the @server parameter added it works like a charm.