SOLVED How to Maintain Snapins Folders on 10 Storage Nodes

  • Server
    • FOG Version: 1.5.0-RC-8 v12
    • OS: CentOS

    I’m working on a deployment that involves images and snapins at 10 sites, each site with it’s own FOG Storage Node. We’ve been working on testing for some time and have created and deleted many snapins, renamed snapins and changed the name for the file that’s uploaded to FOG for snapins.

    I’ve known for a while that FOG replication only replicates the file associated with a Snapin, thereby orphaning files if I should rename a file. In previous versions of FOG, deleting a snapin resulted in the deleting of the file associated with the snapin. In 1.5.0, it appears this doesn’t occur, and that nothing is deleted from the snapin folder when a snapin is deleted.

    So, what’s the recommended process for cleaning up the snapins folder on the default node and storage nodes?

    It’s a pain to manually cross-reference every snapin to verify you can delete a specific file, AND it’s a pain to have to delete these files on all storage nodes (of which I’ll have 9).

    Any assistance would be appreciated.



  • @wayne-workman

    Agreed on all counts, plus I don’t have images that need deleting at present to test, nor time to create images just to test deletion (at this point). I’ll check this as the opportunity presents itself.

    thanks to all.


  • @sebastian-roth It’s possible that the files @Jim-Graczyk needed to cleanup were left un-deleted from a previous version of fog that had this problem, and it’s also entirely possible that the people that work where @Jim-Graczyk works just didn’t click the box to “delete files too” when they deleted snapins.

    Either way, Tom stated he’s not seeing the issue in the current version.

  • @sebastian-roth
    I’m ok with closing this.

    I’ll do more testing and see what I can see. Of the problems I have with the current Latest version, this is not high on my list - hence my request for advice on how to maintain a large number of storage nodes. I’m thinking we’ll look at a periodic cleanup process.


  • Senior Developer

    @Jim-Graczyk @Wayne-Workman What to do with this? Still a bug or did Tom’s note clear it up? Shall we move it back to FOG problems and mark it solved?

  • I’m not seeing the problem with deleting the files. I understand that the folders thing, but no “data” deletion has ever deleted the “data” just when the definition was deleted. If you delete a definition, the data still remains more as a safety net.

    There is the “checkbox” to delete “and data” but this only appears, for now, on the individual delete of an item.

  • @wayne-workman Thanks…

  • @jim-graczyk

    mysql -D fog
    SELECT `sFilePath` FROM `snapins`;

    That will get you a list of all the snapin filenames. Just go from node to node and delete ones not in this list.

  • Senior Developer


  • @wayne-workman

    Do I need to post this again under Bug Reports? I don’t see a way to move this to a different section of the forum.


  • @jim-graczyk said in How to Maintain Snapins Folders on 10 Storage Nodes:

    In 1.5.0, it appears this doesn’t occur, and that nothing is deleted from the snapin folder when a snapin is deleted.

    That’s a bug report.

    for the rest, scripting and ssh certificates are your friends. I understand the pain fully, I once administrated a 15 node fog setup and pushed through every single problem between Trunk 1.3 and release 1.4. It’s a pain yeah, but your on a release candidate also - so some forgiveness is in order.

    I can get you some SQL commands that will ease the comparison process, I’ll post them in a minute.