I have some trouble with xcopy or maybe with windows/drivers/etc/hosts
DNS file.
If I add my xcopy command in a windows scheduled task, xcopy can not resolve server's name stored in hosts file, infact, if I change the command with ip address instead of names everything works..
can you tell me why?
This is the hosts file:
10.1.1.200 diskstation
10.1.1.201 rackstation
This is the not working command:
xcopy \\diskstation\bck\VHD \\rackstation\backup\vhd /e /y /I
This is the working command:
xcopy \\10.1.1.200\bck\VHD \\rackstation\backup\vhd /e /y /I
NB: the first command works if i run it from console, my trouble is only when it is call by scheduled task. NB2: a "ping diskstation" test is successful