kolathaya123
asked on
Task Schedule not working in windows 2012
Hi,
I have some application installed in windows 2012 server and I am taking backup using below command.
pg_dump -h localhost -p 5432 -U adempiere adempiere 1>D:\Adempiere\Data\ExpDat .dmp
I created a .bat file and copied these commands. If I run the .bat file manually, it works fine and backup happens.
If I schedule a task to run the .bat file, the task shows completed, but there is no backup happens. I tested this in windows 2008 server, there also the same issue.
But in windows 2003 server, task scheduler works fine. What might be the issue
I have some application installed in windows 2012 server and I am taking backup using below command.
pg_dump -h localhost -p 5432 -U adempiere adempiere 1>D:\Adempiere\Data\ExpDat
I created a .bat file and copied these commands. If I run the .bat file manually, it works fine and backup happens.
If I schedule a task to run the .bat file, the task shows completed, but there is no backup happens. I tested this in windows 2008 server, there also the same issue.
But in windows 2003 server, task scheduler works fine. What might be the issue
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
You should add error logging to your script, like with
pg_dump -h localhost -p 5432 -U adempiere adempiere 1>D:\Adempiere\Data\ExpDat.dmp 2>D:\Adempiere\Data\Errors.log
ASKER
Excellent.. Thanks alot
run the schedule task using system account and let us know the status.
Thanks,
Manoj