Setting up new, large fog setup
I work for a sheriff’s office with over 1500 emplyees, with about 600 or more desktops. We have many precincts, a jail, and our main IT office. What we would like to do is setup a FOG server at our main IT office and then setup additional servers at our different precincts. What I would like help with is developing and drawing up a network drawing.
What would be the best setup? I was thinking, install 1 FOG server at our main IT office, and then setup a storage node at each precinct. What I am struggling with is, we would need to make sure that our WAN does not get saturated with traffic from the images. Can I install 1 FOG server and then setup different “Locations” in the fog server, 1 for each precinct? How would we setup the replication of images? would I have to have a different group for each location? If I create an image for a desktop, it uploads to our main IT office and then replicates to all the other precincts for all the other precincts to use. Is there a way to schedule the replication of the images so that it only replicates at night, say midnight?
@chris.dees I started to create a POC document of what you might be looking for in this tutorial. https://forums.fogproject.org/topic/9449/dynamic-fog-replicator-transfer-rates The mechanics of the script work on my test system.
The idea is to create the ability to change the transfer (bit) rates used by the replicator service based on the time of day. While this isn’t exactly what you want the same concepts can be applied to start and stop the replicator service based on time of day.
The follow commands to stop and start the replicator service.
On a sysv based system
service FOGImageReplicator stop
service FOGImageReplicator start
Or on a systemd based system
systemctl stop FOGImageReplicator.service
systemctl start FOGImageReplicator.service
@george1421 do you know the command to start or stop the fog image replicator service? It may very well just end up that we set the limit to 1 or 2 Mbps and then just let it run until complete, so it may never end up being an issue. Its just, until the network engineers get our new WAN speed up and running, we are stuck with a max 40Mbps between our precincts.
Wayne Workman last edited by Wayne Workman
The drawback to this would be there is a potential for an incomplete image being setup on a remote storage node.
@Tom-Elliott I thought that replication puts images onto the destination in /images/dev first and when the transfer is complete, it moves them from /images/dev to /images - for the purpose of avoiding the potential to use a partially transferred image on the other end. Correct me if I’m wrong please?
Wayne Workman last edited by Wayne Workman
@chris.dees You’ll also find this to be helpful: https://wiki.fogproject.org/wiki/index.php?title=Location_Plugin
I wouldn’t recommend trying to control when replication happens. You can set it to run once a day and limit it’s rate quite a bit all from the web interface. Manually stopping the replicator risks chopping a transfer, which will just be re-started from zero the next time the replicator runs.
@chris.dees Replication happens right away. There isn’t a way to control the replicator in the way you want from inside FOG. You can do what you want if you use cron to start and stop the fog image replicator service.
So basically you would setup a cron job to launch the replicator at 11p and stop it at 6am. The drawback to this would be there is a potential for an incomplete image being setup on a remote storage node. Because the cron job runs asynchronous of the replicator service. The replicator would finish on the next cycle, but just be aware of this.
The same concept could be used if you want to throttle the replication speed during the day, but want 100% over night. You would setup a cron job to update the bandwidth setting in the sql server then restart the fog image replicator service, and so on.
It would be grand if FOG supported this internally, but with FOG 1.3.x its not possible. Possibly FOG 2.0 will support this capability, but that version is a few years away.
@Tom-Elliott does the replication happen on its own or is this something’s by that can be scheduled? If I made an image for a new desktop today at say 9am, would it immediately replicate to all the nodes or does it wait for a pre-scheduled time? I was hoping I could tell the server to start to replicate at say 11pm at night. We are a 24 hour agency and other than users on the network at night, we have all our other scheduled backups and snapshots all happening at night starting at various times.
I should mention this saturation is not all the time, just when the files need to be replicated due to update
This is exactly what the location plugin was created for.
Yes, there is still some saturation across the wan links to the storage nodes as you will want to replicate the images between the other nodes. (And possibly snapins), but this can be semi automated.