Sunday, February 10, 2013

Box Cloud on Linux

Ref Link :

http://linuxfordummies.org/mount-your-box-com-account-in-linux/



Mount Your Box.com Account In Linux

 
Apr
9
10

Box BannerBox.net (box.com actually now) is a service that enables you to have a place to put files that you want to access from anywhere. Some people use it to back up their workstations. Did your box.net mount start failing recently? They’ve changed a couple things.. use this guide to set it up again. First thing we need to do is to install davfs. You can do that with one of the following commands, depending on what package manager you use on your Linux distro: RedHat based systems:
yum install davfs2
Debian based systems:
apt-get install davfs2
Now, add the mount point:
mkdir /box
Add this line to your /etc/fstab:
https://www.box.com/dav /box davfs rw,user,noauto 0 0
Add this line to the bottom of the /etc/davfs2/secrets file (replace with your email address and password)
https://www.box.com/dav user@email.com password
Edit the /etc/davfs2/davfs2.conf and change the following line:
# use_locks 1
And change it to this:
use_locks 0
Now we can mount it. To do that, use the following command:
mount /box
Show that it’s there with ‘mount’ or with ‘df’ Now, rsync something to it. Here, i’m rsyncing a 1gb tar.gz file:
[root@britannia home]# rsync -avz --progress somefile.tar.gz /box/
sending incremental file list
rob-test.tgz
  1154875454 100%   61.06MB/s    0:00:18 (xfer#1, to-check=0/1)
sent 1155263231 bytes  received 31 bytes  59244269.85 bytes/sec
total size is 1154875454  speedup is 1.00
[root@britannia home]#
And that’s it. You should be good to go at this point.

10 Responses to “Mount Your Box.com Account In Linux”

  1. eric says:
    Add this line to your /etc/fstab:
    https://www.box.com/dav /box davfs rw,user,noauto 0 0
    how do I do that? I am REALLY ubuntu dummy :)
    many thanks
    e
    Reply
    • Cliff says:
      You need to edit the file as root user, or use sudo. Just make sure you make a backup copy of the original file BEFORE you edit the file.
      If you are on IRC in #Ubuntu on irc.freenode.net someone there can help you or you could join my #LFD channel and someone there can possibly help you.
      Reply
  2. WallStud says:
    Awesome! Works like a champ! Thanks!
    Reply
  3. Ian says:
    Your upload bandwith is about 1000 times mine :-(
    Obviously, there is no way to cheat during the initial upload. But what about incremental updates? Is there any way to “really” use rsync with box.com, that is, a rsync server to connect to, rather than using it as a completely dumb and extremely slow hard drive?
    Reply
    • Pawel says:
      To use rsync for real incremental backups (that is – updating only the files which changed) with box.net mounted as a davfs an additional option –size-only has to be used, as I found here: http://tomalison.com/reference/2010/04/03/webdav/
      The command would be then:
      rsync -rvz –size-only “~/myfolder/” “~/box.net/”
      With the standard -u (for update) it will not work – it will always copy all the files from scratch.
      Reply
      • CBee says:
        Nice to see box.com uses standards like webdav / davfs. That leaves openings for opensource to work on. Meanwhile users can scan the internet for nice combinations like rsync and davfs.
        Next thing is an extension to rsync to be able to coop with webdav / davfs issues and use them to lean and mean the transfer.
        Reply
  4. Brian says:
    like linux, let’s go open source guys…
    Reply
  5. edd says:
    thannks, work very well but i can not copy a file directly in /box with tunar xfce4
    Reply
  6. qm-b says:
    Awesome! Thanks for help! Works great..
    Reply
  7. Mike says:
    Should this still be working? I am getting “rejected Basic challenge” errors.
    Reply

No comments:

Post a Comment