{"id":1186,"date":"2021-04-12T12:12:29","date_gmt":"2021-04-12T10:12:29","guid":{"rendered":"https:\/\/devpath.pro\/?p=1186"},"modified":"2021-04-12T12:12:29","modified_gmt":"2021-04-12T10:12:29","slug":"save-yourself-from-a-disaster-4-redundancy-of-storage","status":"publish","type":"post","link":"https:\/\/fabiocicerchia.it\/web\/save-yourself-from-a-disaster-4-redundancy-of-storage","title":{"rendered":"Save yourself from a disaster #4: Redundancy of Storage"},"content":{"rendered":"
This is the fourth part of the series Save yourself from a disaster: Redundancy on a budget<\/a>.<\/p>\n How can we make sure our second most important asset is safely secured in case of a disaster?<\/p>\n We could mainly 2 things:<\/p>\n <\/p>\n Although we could use some distributed filesystem like Ceph<\/a>, DRBD<\/a>, GlusterFS<\/a>, or ZFS<\/a>, then it won’t be on a budget and also the complexity introduced by those tools will need to addressed properly. I will not cover it here due to the costs of extra nodes and extra configuration needed – you’re time have a cost too (but if your filesystem changes frequently this is your only option).<\/p>\n Ad-Hoc Solutions<\/strong><\/p>\n Quick & Dirty: Cross Sync<\/strong><\/p>\n Let’s use a simple cronjob every hour to sync the whole shared folder to all remote locations.<\/p>\n Server #1:<\/p>\n Server #2:<\/p>\n Remember, this is not a proper distributed solution, rsync looks like an old-fashioned solution, it did save me lots of times. This approach is not feasible for “real-time” synchronization, they are just for (very) infrequent changes. Distributed filesystem like GlusterFS (or Ceph, or DRBD) are solutions for the long run.<\/p>\n Security<\/strong><\/p>\n Remember to secure the connection between one host to the others (eg. with a firewall).<\/p>\n The next post will be about Redundancy of\u00a0Web Servers, Stay Tuned.<\/p>\n Check out the whole version of this post in the ebook. This is the fourth part of the series Save yourself from a disaster: Redundancy on a budget. How can we make sure our second most important asset is safely secured in case of a disaster? We could mainly 2 things: Distributed Storage Backups<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"closed","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"advgb_blocks_editor_width":"","advgb_blocks_columns_visual_guide":"","footnotes":""},"categories":[14],"tags":[122,123,124,125],"aioseo_notices":[],"author_meta":{"display_name":"fabio","author_link":"https:\/\/fabiocicerchia.it\/author\/fabio"},"featured_img":null,"coauthors":[],"tax_additional":{"categories":{"linked":["Web<\/a>"],"unlinked":["Web<\/span>"]},"tags":{"linked":["disaster recovery<\/a>","ovh<\/a>","redundancy<\/a>","sbg2<\/a>"],"unlinked":["disaster recovery<\/span>","ovh<\/span>","redundancy<\/span>","sbg2<\/span>"]}},"comment_count":"0","relative_dates":{"created":"Posted 3 years ago","modified":"Updated 3 years ago"},"absolute_dates":{"created":"Posted on April 12, 2021","modified":"Updated on April 12, 2021"},"absolute_dates_time":{"created":"Posted on April 12, 2021 12:12 pm","modified":"Updated on April 12, 2021 12:12 pm"},"featured_img_caption":"","series_order":"","_links":{"self":[{"href":"https:\/\/fabiocicerchia.it\/wp-json\/wp\/v2\/posts\/1186"}],"collection":[{"href":"https:\/\/fabiocicerchia.it\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/fabiocicerchia.it\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/fabiocicerchia.it\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/fabiocicerchia.it\/wp-json\/wp\/v2\/comments?post=1186"}],"version-history":[{"count":0,"href":"https:\/\/fabiocicerchia.it\/wp-json\/wp\/v2\/posts\/1186\/revisions"}],"wp:attachment":[{"href":"https:\/\/fabiocicerchia.it\/wp-json\/wp\/v2\/media?parent=1186"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/fabiocicerchia.it\/wp-json\/wp\/v2\/categories?post=1186"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/fabiocicerchia.it\/wp-json\/wp\/v2\/tags?post=1186"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}\n
\nThis guide won’t cover everything, it won’t be a comprehensive guide, and the steps that are shown need to be carefully reviewed and tested in your development\/pre-production environment. I don’t take any responsibility for any damage, interruption of service nor leak\/loss of data for the use of the instructions in the ebook (nor from any external website I’ve mentioned).<\/small><\/div>\nDistributed Storage<\/h2>\n
\n
rsync -e \"ssh -i $HOME\/.ssh\/somekey\" -auv --progress \/path\/to\/shared\/folder\/ syncer@<IP2>:\/path\/to\/shared\/folder<\/pre>\n
rsync -e \"ssh -i $HOME\/.ssh\/somekey\" -auv --progress \/path\/to\/shared\/folder\/ syncer@<IP1>:\/path\/to\/shared\/folder<\/pre>\n
\n
\n<\/a><\/p>\n","protected":false},"excerpt":{"rendered":"