I'm looking for opinions/options for how to best rebuild cache on our production server services. What I would like to do is rebuild the cache on a staging server and then copy the cache over to the production services. I have a python script that will do this but it seems to be hit and miss on when it works. The main hang-up on when it fails seems to be because it can't remove a .bundle file.
Does anyone know what causes a lock on a .bundle file? As part of my script I stop the map service before copying over the cache. Is this not enough?...does the entire ArcGIS Server service need to be stopped?
Is it better/more likely to not have any incidents if I just rebuild the cache on the production server? The main reason I don't want to do this is to keep the computer resources available (CPU/RAM) on our production machine. Rebuilding cache usually sucks up most of the available CPU and RAM which is why I am trying to rebuild the cache on a staging server then copy over.
Just wondering what others have tried and had success with.
Thanks in advance!!