Dedicated server cache to Fast download server cache
11 replies, posted
When do i copy the cache of the server to the fast download server cache folder? since i understand the server makes the files when it boots i assume after?? I keep getting missing cache files or CrC error messages of 1 k/b files that didn't download correctly. xD
[QUOTE=darksoul69;20874732][url]http://wiki.garrysmod.com/?title=Dedicated_Server_Setup#Fastdownload_.28sv_downloadurl.29[/url][/QUOTE]
The Cache
Found under garrysmod/cache/dua, the cache contains 'all clientside files for the client to download. These files are autogenerated by your server each time it starts.
It is important that the cache is on the Fast Download server, for without it the client will not see the gamemode correctly and will see the "Base Gamemode". Every single time a change is made to a client-side OR a shared file Lua file, the cache MUST be updated no matter what.
...
How do i automatically update my cache while the server runs?
[QUOTE=vinni;20874790]The Cache
Found under garrysmod/cache/dua, the cache contains 'all clientside files for the client to download. These files are autogenerated by your server each time it starts.
It is important that the cache is on the Fast Download server, for without it the client will not see the gamemode correctly and will see the "Base Gamemode". Every single time a change is made to a client-side OR a shared file Lua file, the cache MUST be updated no matter what.
...
How do i automatically update my cache while the server runs?[/QUOTE]
A cron job would work if setup right. A symbolic link would as well.
It's not necessary for the cache to be on fastdownload. If a file isn't found on fastdl, it is normally downloaded from the server itself (If below the max file size, which dua will be)
[QUOTE=|FlapJack|;20884604]It's not necessary for the cache to be on fastdownload. If a file isn't found on fastdl, it is normally downloaded from the server itself (If below the max file size, which dua will be)[/QUOTE]
No it isn't possible to download off the server with fastdl enabled. If this was the case then I would not have to re-upload the cache to fastdl every single time I changed a client side file.
What your thinking of is when you change a server side lua file, which is true. But anything client side that is changed must be re uploaded or it will not download.
[QUOTE=darksoul69;20885739]No it isn't possible to download off the server with fastdl enabled. If this was the case then I would not have to re-upload the cache to fastdl every single time I changed a client side file.
What your thinking of is when you change a server side lua file, which is true. But anything client side that is changed must be re uploaded or it will not download.[/QUOTE]
Do you really think I don't know how my own server runs?
[editline]05:20PM[/editline]
It works fine. You must have set yours up wrong.
[QUOTE=|FlapJack|;20896970]Do you really think I don't know how my own server runs?
[editline]05:20PM[/editline]
It works fine. You must have set yours up wrong.[/QUOTE]
Obviously you don't know how your server runs. I just deleted my cache folder client side and on the fastdl server, and nothing would download from my server - including the lua files.
Let me explain FastDL a bit for you. The reason you want to use FastDL is to A: Speed up file transfers and offload some of the network transfer the server uses.
B: To prevent people from downloading anything from the server.
If people can download from your server and bypass the fastdl, then you have not configured fastdl correctly.
Either that or you have sv_allowupload and sv_allowdownload set to 1, which is a huge security risk and should always be set to 0.
darksoul69 is right. Although there might be a hidden cvar (it's not sv_allowdownload/upload) which allows to download from the server if a file doesn't exist on the fast download server.
Heres confirmation from the actual wiki as well:
[url]http://wiki.garrysmod.com/?title=Dedicated_Server_Setup#Fastdownload_.28sv_downloadurl.29[/url]
Under "So what exactly does each folder do, and why should I have them?"
"The Cache
Found under garrysmod/cache/dua, the cache contains 'all clientside files for the client to download. These files are autogenerated by your server each time it starts.
It is important that the cache is on the Fast Download server, for without it the client will not see the gamemode correctly and will see the "Base Gamemode". Every single time a change is made to a client-side OR a shared file Lua file, the cache MUST be updated no matter what."
There you go.
The OP has got a problem with his server setup. My (Newly installed server, pretty standard settings) does not have a problem. Post the server config file (Deleting the rcon password and such, of course) and we'll have a look at it.
@OP, I don't think you can (unless there's a refresh lua cvar). Closest option would be a map restart if the gamemode has been changed, or running quit via rcon/hlsw or the actual SRCDS window if it's addon based. (assuming you've got an auto-rebooter - most GSP's have this.)
Once the server/map has been restarted you need to go to your gameservers FTP (if it has one - GSP's usually give you one to use) and head to the garrysmod/cache/dua folder. Select all the contents and upload them to your fast download server, usually via ftp. Also note, the sv_downloadurl needs to be something like [url]www.myurl.com/garrysmod[/url] , where garrysmod has the materials/models/cache etc folders.
On FTP, you just need to upload the duas to the garrysmod/cache/dua directory, and make sure you CHMOD (if the webserver for the fast dl runs on linux) all the folders, subfolders and files to either 775 or 770 (775 worked for me) otherwise it wont work.
I hope I got all this right and that it helps in some way.
Sorry, you need to Log In to post a reply to this thread.