This site is a testing version, but all data is shared with the live forum.


Raised This Month: $ Target: $400
 0% 

[SUG] Duplicate Files


Post New Thread Reply   
 
Thread Tools Display Modes
Author Message
Colex
Senior Member
Join Date: Feb 2014
Old 10-28-2014 , 21:24   [SUG] Duplicate Files
Reply With Quote #1

On same dedicated server, i have tree:

-cstrikeserver(snapshoot)
--cstrike
---sounds
----defaultsounds
---sprites
----defaultsprites
---maps
----de_dust2.bsp
----defaultmaps.bsp
--valve
---etc

And I have several servers on the machine in different folders with the same files that the snapshot.

Is there any plugin to prevent this?
Rather than having each copy your file, it defaults to read files from snapshot.

Basically a "ln -s"

This will save very more disk space.

Last edited by Colex; 10-28-2014 at 21:26.
Colex is offline
fysiks
Veteran Member
Join Date: Sep 2007
Location: Flatland, USA
Old 10-28-2014 , 21:36   Re: [SUG] Duplicate Files
Reply With Quote #2

A plugin cannot do that. The only way that I know of is to use symlinks on the OS (which you already know about).
__________________

Last edited by fysiks; 10-28-2014 at 21:37.
fysiks is offline
Sylwester
Veteran Member
Join Date: Oct 2006
Location: Poland
Old 10-28-2014 , 22:19   Re: [SUG] Duplicate Files
Reply With Quote #3

I did it on windows with mklink and it works. I recommend creating shell script that will set it up for you since doing everything manually would take a lot of time.
__________________
Impossible is Nothing
Sylwester is offline
Kia
AlliedModders Donor
Join Date: Apr 2010
Location: In a world of madness
Old 10-29-2014 , 06:35   Re: [SUG] Duplicate Files
Reply With Quote #4

On Debian you can do this:

cp -rs /cs_master/* /cs_slave/

It re-creates the folder structure from cs_master, but makes symlinks for all files. So, if you want to edit e.g. server.cfg you delete the server.cfg symlink and create a new file called server.cfg.
__________________
Kia is offline
Colex
Senior Member
Join Date: Feb 2014
Old 10-29-2014 , 06:39   Re: [SUG] Duplicate Files
Reply With Quote #5

Quote:
Originally Posted by Kia View Post
On Debian you can do this:

cp -rs /cs_master/* /cs_slave/

It re-creates the folder structure from cs_master, but makes symlinks for all files. So, if you want to edit e.g. server.cfg you delete the server.cfg symlink and create a new file called server.cfg.

I will use symlink files only for patterns that exist on all servers.

example:

CS1.6/cstrike/defaultmaps.bsp
CS1.6/valve

I'll do it to save disk space.
Colex is offline
Kia
AlliedModders Donor
Join Date: Apr 2010
Location: In a world of madness
Old 10-29-2014 , 07:53   Re: [SUG] Duplicate Files
Reply With Quote #6

That is what the command I gave you is doing.
__________________
Kia is offline
Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT -4. The time now is 04:28.


Powered by vBulletin®
Copyright ©2000 - 2024, vBulletin Solutions, Inc.
Theme made by Freecode