cache files on a remote server ?

PHP programming forum. Ask questions or help people concerning PHP code. Don't understand a function? Need help implementing a class? Don't understand a class? Here is where to ask. Remember to do your homework!

Moderator: General Moderators

Post Reply
tomek
Forum Newbie
Posts: 5
Joined: Mon Jul 12, 2004 3:51 pm

cache files on a remote server ?

Post by tomek »

Hi!

If I have 2 servers (A and B) - is it possible to run a script on server A which reads/writes cache files from/to server B?

so server B would be my "cache-server"...

does anyone know a class that can do this?

up until now I used cacheLite and had the cache on the same server as the script...

It would be perfect if I could make cacheLite work the way I want. Actually I think it should be possible. Cache Lite uses the "opendir" function.

the documentation says:

As of PHP 4.3.0 path can also be any URL which supports directory listing, however only the file:// URL wrapper supports this in PHP 4.3.

do I specifiy the path like that?
$cachDir = 'file://www.domain.com/dircetory';

my tests don't work...

any Input would be great!
User avatar
Buddha443556
Forum Regular
Posts: 873
Joined: Fri Mar 19, 2004 1:51 pm

Post by Buddha443556 »

Network the servers. Maybe use something like Samba? Have no idea if that would work just an idea. Should.

Does not seem like a good idea to add a bottleneck (local network) to the caching system though.
Post Reply