Options for moving cache directory and rehosting service

4383
8
Jump to solution
03-18-2015 09:39 AM
BlakeTerhune
MVP Regular Contributor

I created a compact cache for aerial photorgraphy from a map service. The cache was created locally on the server in the default \arcgisserver\directores\arcgiscache but we don't have much space on the server so I moved it to a network drive. I registered the network drive location as a data store with ArcGIS Server, so now how do I create a new map service that uses this cache in the new directory?

0 Kudos
1 Solution

Accepted Solutions
JakeSkinner
Esri Esteemed Contributor

Hi Blake,

One workflow you can do is the following:

1.  Right-click on the service > Manage Tiles > Delete Cache

2.  Right-click on the service > Service Properties

3.  In the service properties, click on 'Caching' and check the option 'Use tiles from a cache'

4.  Click 'Advanced Settings' and click the dropdown to choose the Cache Directory

After setting the cache directory, click OK.  Your service will now be reading the cache from the new directory.

View solution in original post

8 Replies
JakeSkinner
Esri Esteemed Contributor

Hi Blake,

One workflow you can do is the following:

1.  Right-click on the service > Manage Tiles > Delete Cache

2.  Right-click on the service > Service Properties

3.  In the service properties, click on 'Caching' and check the option 'Use tiles from a cache'

4.  Click 'Advanced Settings' and click the dropdown to choose the Cache Directory

After setting the cache directory, click OK.  Your service will now be reading the cache from the new directory.

BlakeTerhune
MVP Regular Contributor

Thanks Jake, that was very helpful. The only extra step I needed was to add a new directory (of type Cache) in ArcGIS Server Manager (not just the data store registered folders). That allowed me to choose the new cache directory in step 4 you described. And an extra note on that, the cache directory that you add needs to be the folder containing the cache folder, not the folder that contains the cache file. The first time I added the directory in Server Manager, I went all the way down to the last folder that contained the cache file, but it actually needs to be one folder up from that.

BlakeTerhune
MVP Regular Contributor

So I just finished getting this all set up. I checked the Javascript viewer and the cached map service works fine. I tried adding the service to ArcMap and nothing shows up. The layer is in the table of contents but there is nothing in the map data view. Any ideas?

0 Kudos
RebeccaStrauch__GISP
MVP Emeritus

​when you moved your cache, did you make sure to move all the folders and config files too? they contain info on the projection and without that being valid, it may not project on the fly properly if it is different than the ArcMap frame.

...if course, you can always try the standard reboot and give it another try.  

0 Kudos
BlakeTerhune
MVP Regular Contributor

Good suggestions. It looks like all of the config files and stuff are there in the folder that was copied. I tried stopping and starting the service but the issue remains. ArcCatalog Preview doesn't show anything either. The view in ArcGIS.com Map also works.

0 Kudos
JakeSkinner
Esri Esteemed Contributor

Another suggestion is try and clear the Display Cache in ArcMap.

BlakeTerhune
MVP Regular Contributor

I tried clearing the display cache in ArcMap. Rebooting the server is not an option at this moment.

To troubleshoot, I created a new test map service with the same aerial and created a (small) new cache for it. The only difference is that I created the cache in the new location right away (no moving). The new test map service cache displays fine in ArcMap.

0 Kudos
RebeccaStrauch__GISP
MVP Emeritus

Check the connection in Catalog to your server. Maybe the credentials you are providing does not have the correct permissions to access the new location. And again, a reboot or at least relog in of the user on the arcmap/catalog machine might be necessary, since at least on some operating systems, permissions are assigned at log in.​

0 Kudos