Caching server not working (El Capitan server)

I have recently set up a mac server (new mac mini, OS X 10.11.3, server app 5.0.15).


In order to not interrupt the old (active) server, it was first setup with a DHCP address in the 192.168.1.x scope, and caching server was enabled and I could see content was storing on the server.


Afterwards (about a month ago) it was changed to be the active server and the IP was changed to a static in the 10.0.10.x scope.

After that change caching server hasn't worked.


I have tried:

  • Restarting the server.
  • Turning Caching server off and on.
  • Change the location where it should save the content.
  • Reset content. (So all the old content was removed).
  • Increased size of how much it can contain.
  • Made sure that the permission is set to All networks


It works flawless on the other servers I'm running (other places) but not on this one. And the status is green and says everything is fine.


Any suggestions on what to do?


TIA,

Peter

Posted on Mar 18, 2016 3:48 AM

Reply
17 replies

Mar 31, 2016 2:45 AM in response to peter_anymac

Does your organization have more than one public IP address, i.e. to load balance across multiple ISPs?


Search the caching server's log file for "Registering with" and "public IP" and make sure that info looks correct:

$ egrep "Registering with|public IP" /Library/Server/Caching/Logs/Debug.log


On a Mac or iOS device that you think should be using that caching server, open Safari and navigate to http://www.whatsmyip.net/ or any other site that will reveal your public IPv4 address. Does the IPv4 address it shows match the public IP address of the caching server above?


If the "Registering with" line shows a range of local addresses, check the network settings on the other Mac or iOS device. Does its local address lie within the range?

Mar 31, 2016 2:45 AM in response to Linc Davis

It doesn't find the caching server - reports "AssetCacheLocatorService[659]: #47e2cf6f [I:AssetCacheLocatorService.queue] found no caching servers"


But I just discovered that some network changes have been made so the clients and server are on two different public IPs. I'll look into that aspect. (I have noticed that there in Caching server is a possibility to make it useful on different public IP by creating af TXT DNS record, but I haven't succeeded in getting that to work).

Sep 29, 2016 4:14 AM in response to More Broccoli Please

I have the problem which you described . My server's public ip is x.y.z.206 but our company security policy force the server to connect through proxy server to outside . Now the "Registering with|public IP" shows proxy server ip instead of x.y.z.206 . The proxy server ip does not belong to us and i have no permission on it .


Is there a way to register with proxy server ip but use server own ip for caching ?

Sep 29, 2016 4:32 AM in response to Omid Kosari

If your devices also connect through the same proxy, it should all work because the clients and the server will have the same public address, namely, the proxy's address. Otherwise, configure both public IP addresses in Server > Caching > Permissions: Edit Permissions... > Serve clients with public addresses:, and set up a DNS TXT record to match; see the Client Configuration... button on that same page. Be sure to enter only public addresses there, and not any private 10.x.x.x, 172.16.x.x-172.31.x.x, or 192.168.x.x addresses.

Sep 29, 2016 6:04 AM in response to Omid Kosari

You can think of a computer (including a Mac running Server, and an iOS device) behind a NAT as having two addresses: a private (or "local") address on the immediate NATted network, and a public address visible to the Internet. Private addresses are almost always 10.x.x.x, 172.16.x.x-172.31.x.x, or 192.168.x.x. Public addresses are assigned to you by your ISP.


Computers and devices ("clients") on your NATted network search for caching servers by asking an Apple cloud service for them. The cloud service matches up clients with registered caching servers using public addresses (or public address ranges, if you have more than one public address). If you have more than one caching server behind the same public address, the cloud service uses the local address of the client to choose one of them.


If you have just one public IP address that both your caching server(s) and your client(s) share, it all works out of the box. The caching server(s) register with their local address(es) and the one public address automatically. The client(s) look up caching servers using the same public address, also automatically. The cloud matches them up and instructs the clients to use whichever caching server is configured for the local network the client is on.


If you have more than one public IP address, though, the caching server has to register for all of them. That's why you have to enter them all in the Server app. Clients have to match caching servers on the same public IP addresses, so you have to set up a DNS TXT record available to all clients so they have that info. The matching happens as above but with ranges of public addresses instead of single public addresses.


I'm not sure that answers your question but I hope it helps. Can you be more clear about what you mean by the "real ip of the server," given that servers (and clients) have both private and public addresses?

Oct 1, 2016 2:15 AM in response to More Broccoli Please

Thanks for reply .

User uploaded file

The public ip of macOS server is 1.1.1.206 but since it connects through a proxy server , it will register with proxy server's ip 5.6.7.8 to apple servers . So i think when clients request the update from apple servers , apple servers will send 5.6.7.8 as Cache server which is fault .

Is there a way to say to apple servers that the REAL public ip of my server is 1.1.1.206 even if it is behind proxy ?

Oct 3, 2016 5:08 AM in response to Omid Kosari

In your diagram, your clients and your caching server all have two routes to the Internet: one through the proxy and one without. If your clients and your caching server always route through the proxy, caching should work automatically with default settings because the clients and the server have the same public address 5.6.7.8, and clients will be told to download from the caching server at local address 1.1.1.206. But if your clients and your caching server route to the Internet in different ways, they might have different public (Internet-facing) addresses: sometimes 5.6.7.8, sometimes the unnumbered link in your diagram directly from the router to the Internet. In that case you will need to configure the caching server and a DNS TXT record for both public addresses.

Oct 3, 2016 12:40 PM in response to Omid Kosari

Perhaps I misunderstood. Is the router in your diagram performing NAT or not?


If your router does perform NAT then your caching server and your DNS TXT record need to specify only the public (Internet-facing) addresses, and not any addresses behind your NAT router (which are local addresses). The only public addresses are 5.6.7.8 and the address your ISP assigns to your router for the link in your diagram that does not go through the proxy but connects the router to the Internet. You do not need to add local addresses 1.1.1.206, 1.1.2.0/24, or 1.1.3.0/24 to your caching server's public address configuration or your DNS TXT record.


However if your router does not perform NAT then all of your clients and your caching server use public addresses. In that case your caching server configuration and DNS TXT record need to specify the addresses of all the clients and the proxy, but not the caching server's address 1.1.1.206 because it routes through the proxy.


Incidentally, your DNS TXT record does not need to be accessible from the Internet. It only needs to resolve inside your network.

This thread has been closed by the system or the community team. You may vote for any posts you find helpful, or search the Community for additional answers.

Caching server not working (El Capitan server)

Welcome to Apple Support Community
A forum where Apple customers help each other with their products. Get started with your Apple Account.