2012/08/25

Into the Box

Mounting a box account as a file system on gentoo - as root:
  1. unmask net-fs/davfs2-1.4.7 in portage
  2. emerge -av davfs2
  3. gpasswd -a ${your_user} davfs2
  4. mkdir -p /dav/${your_user}
  5. chown ${your_user}:${your_user} /dav/${your_user}
  6. echo 'https://www.box.com/dav /dav/${your_user} davfs rw,user,noauto 0 0' >> /etc/fstab
Then as ${your_user}:
  1. mkdir -p ~/.davfs2
  2. echo "https://www.box.com/dav ${box_username} ${box_password}" >> ~/.davfs2/secrets
  3. chmod 0600 ~/.davfs2/secrets
  4. echo "use_locks 0" >> ~/.davfs2/davfs2.conf
  5. mount /dev/${your_user}
The output from from df is wrong, but whatever... from the davfs2 README:

- If the server does not support RFC 4331 (most servers don't), davfs2 cannot
  calculate the free disk space on the server. ... So davfs can't help but lie. I tried to
  make the numbers look funny, so you will notice they are faked.