You should check your hrefresh.cfg file and look specifically at the line for your selected project and state. Parameters 9 and 10 on that line are the encrypted dfo files you have prepared for the Harvest login credentials that the process will use, and the Agent machine login credentials that the process will use.
- File name containing the username/password of CA Harvest SCM user (for -eh)
- File name containing the username/password of Agent user (for -er)
It is very easy to get these 2 dfo files switched or to have the wrong userid and/or password in them. But you should check to be sure that you have specified the right dfo file in the right position.
More about the topic of synchronizing reference directories is found here:
https://docops.ca.com/ca-harvest-scm/13-0/en/administrating/synchronize-reference-directories