Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Backing up to S3: symlinks

I'm trying to figure out right now how to backup some data to S3.

We have a local backup system implemented using rsnapshot and that works perfectly. We're trying to use s3cmd with the --sync option to mimic rsync to transfer the files.

The problem we're having is that symlinks aren't created as symlinks, it seems to be resolving them to the physical file and uploading that instead. Does anyone have any suggestions as to why this would happen?

I'm wondering if I'm missing something obvious or that S3 just isn't suited to this sort of operation. I could setup an EC2 instance and attach some EBS but it'd be preferable to use S3.

like image 714
Iain Mckay Avatar asked Jan 31 '13 08:01

Iain Mckay


1 Answers

Amazon S3 itself doesn't have the concept of symlinks, which is why I suspect s3cmd uploads the physical file. Its a limitation of S3, not s3cmd.

I'm assuming that you need the symlink itself copied though? If that's the case, can you gzip/tar your directory with symlink and upload that?

like image 192
Suman Avatar answered Oct 04 '22 03:10

Suman