Posts Tagged backups
Guest Blogger Brad Zobrist – How he would implement a Bitcasa
Posted by bradzobrist in Backups, internet, Startups, Technology, Uncategorized on September 14, 2011
First I think it’s good to clarify what I understand Bitcasa is trying to do and if I was their architect how I would do it.
This of course is all guessing and speculation.
They are trying to store all clients data for ever and cache all recently accessed data locally & predictively cache other data. All while expiring from the cache old infrequently accessed data.
Features they have or will be implementing are:
- All data is backed up to a cloud. All data is deduplicated with all other client data
- All data is NOT accessible by any other client or them
- Files and / or folders can be shared seamlessly with other users.
- Local hard drive space is used as a cache by predictive algorithms
Here is how I would implement each one of these to create an overall architecture similar to what I think Bitcasa is providing. At a high level I would follow the process of deduplicating all data at the block level across ALL clients, have each client encrypt (with client’s key) the reference to what blocks that make up their files and folders, store those encrypted references in a users file database or key->value store, compress and encrypt (with Bitcasa’s master key) new unknown blocks, then write those blocks back to the Bitcasa cloud storage. Bitcasa would retain a master hash table of all known blocks and each clint would send a list of it’s blocks and then Bitcasa master block hash table would respond and tell the client to only send new, unknown, blocks back to the storage compressed and encrypted.
So breaking it down here is how the address each feature:
- All data is backed up to a cloud & All data is deduplicated with all other client data.
All un-encrypted blocks (not files) are hashed and those hashes are sent back to the master hash table at Bitcasa and then you get a list of what “new” blocks need to be backed up and duplicate blocks can be thrown away.
- All data is NOT accessible by any other client.
The next level is to take the blocks / hashes that make up a file and create an encrypted user client key hash of what blocks make up that hash. You may even need to take the block level down to a sector level to get away files that could fit in a single block or segment size.
- Files and / or folders can be shared seamlessly with other users.
Because file / folder references are only stored with an encrypted reference to what blocks make up those files you simple need to give the new client the list of those blocks.
- Local hard drive space is used as a cache by predictive algorithms
An additional piece of code is monitoring what files / hashes / blocks are being accessed and knows if they’re cached locally or need to be pulled remotely. I believe the predictive part is where most of their patents are but unfortunately we won’t be able to find out about them for ~18 months, read Bitcasa gets an early start on IP acquisition.
Well, that’s what I think?
Thoughts?
Automatic WordPress Database Backups Are Awesome
Posted by Jon Zobrist in internet, Technology, Wordpress on April 25, 2011
I recently re-posted a link to 15 Incredible WordPress Plugins but wanted to note that I have been enjoying one in particular.
The WordPress DB Manager (WP-DBManager) is awesome at scheduling and executing backups or your WordPress database.
The database is where all of your valuable data is, with the only exception of custom graphics you have uploaded.
Restoring a WordPress site is easy if you have the database!
It will even send you a scheduled e-mail with the backup file attached.
MySQL backup sript – more info
Posted by Jon Zobrist in Linux, MySQL Server Support on April 2, 2007
Please email me updates you make and I will post them here. My email is kgb@bluesun.net
More “in depth” installation:
passwd mysqldump
mysql -p
GRANT select,lock tables on *.* to mysqldump@localhost identified by ‘p@ssword’;
flush privileges;
su – mysqldump
mkdir ~/bin
mkdir ~/logs
mkdir ~/bkup
cd ~/bin
wget http://www.submarinefund.com/backup_mysql/backup_mysql
chmod u+x backup_mysql
vi backup_mysql
make changes to config
– change passwd to the same one you used on the
GRANT instead of p@ssword
– change num_days_keep to the number of days you want to keep around
– change all the commands to match your system, these
should be the same on most linux systems, BSD’s may
need to change some paths
test the script
add a line to your crontab like this
0 3 * * * /home/mysqldump/bin/backup_mysql >> /home/mysqldump/logs/cron.log 2>&1
MySQL backup script
Posted by Jon Zobrist in Linux, MySQL Server Support on April 1, 2007
I wrote this script because I needed to have each table in all databases backed up separately.
If you have hundreds or thousands of tables and and want to back them up separately then this script could help. It also names and rolls files by unix timestamp, and allows you to specify
how long a file is kept, regardless of number of backups made. So, say you want 2 days of backups, and you make one every hour (48 total) it will auto roll them after 2 days, suppose then you manually run the script to create a backup before some important change or event, this will still keep that backup for 2 days.
Here’s my script to backup mysql
To install it on a linux/freebsd box just edit the top parts for configuration. If you make a user mysqldump with home directory of /home/mysqldump and a mysql password of p@assword, make a /home/mysqldump/logs and /home/mysqldump/bkup directories, this should just work. Hack it up, it’s GPL’d.
Please email me updates you make and I will post them here. If you have questions you can email me, or post them on my LCoD message board. My email iskgb@bluesun.net, but I don’t really check it that much
More “in depth” installation:
adduser mysqldump
passwd mysqldump
mysql -p
GRANT select,lock tables on *.* to mysqldump@localhost identified by ‘p@ssword’;
flush privileges;
su – mysqldump
mkdir ~/bin
mkdir ~/logs
mkdir ~/bkup
cd ~/bin
wget http://www.submarinefund.com/backup_mysql/backup_mysql
chmod u+x backup_mysql
vi backup_mysql
make changes to config
- change passwd to the same one you used on the
GRANT instead of p@ssword
- change num_days_keep to the number of days you want to keep around
- change all the commands to match your system, these
should be the same on most linux systems, BSD’s may
need to change some paths
test the script
add a line to your crontab like this
0 3 * * * /home/mysqldump/bin/backup_mysql >> /home/mysqldump/logs/cron.log 2>&1