Notes for box.com

VUMC has chosen to provide a box.com account for faculty and staff to store, share, and access files online. Box.com is an "in the cloud" file sharing service much like Dropbox. Each user's account provides 50.0GB of storage.

Please read VUMC's documentation to get started. The notes below supplement the documentation.

Note: VUMC does allow us to use box.com to store files containing certain protect health information. See http://it.vanderbilt.edu/services/box/box-data-policy.php for details.

Begin Using box.com

To begin using box.com, go to https://it.vanderbilt.edu/services/box/ and "Log in instructions" in the "Get Started" section.

After you box account has been set up it is accessed at https://vumc.box.com.

Before you will be able to use SFTP, WebDAV, or DAVFS with your VUMC Box account, you must first create an "external" password (this should be different than your Vanderbilt epassword).

  • Log into your VUMC Box account from your laptop or desktop. At the upper right, click your initials. From the drop-down menu, click Account Settings.
  • Near the bottom, under "Create External Password" or "Authentication" (depending on the version), click Edit password.
  • Click Save.

WebDAV Access using Nautilus

  1. open Nautilus file manager
  2. select "Connect to Server" from the file menu or the left navigation bar
  3. For "Server Address" enter: davs://firstname.lastname%40vumc.org@dav.box.com/dav
  4. Click Connect and, when prompted, enter your external password

The firstname.lastname%40vumc.org in step 3 is your VUMC email address using "%40" instead of "@" (%40 is the ascii hex value for "@").

Reference: See Using Box under Linux and see the section "WebDAV Access (Nautilus)".

Mounting Box (davfs2) (Ubuntu Linux)

WebDAV is used to mount the box.com file system.

Make sure you have davfs2 installed.
sudo apt-get install davfs2

Set permissions on the mount command so that regular users can mount the Box share
sudo chmod u+s /sbin/mount.davfs

Decide where you want your box.com mount point to be located. In these notes we assume the location is in your Linux home directory. In all the notes below substitute "vunetid" with your real VUnetID. If you choose a different location then make the appropriate changes.

Create a directory to be the mount point for the Box share.
mkdir ~/box

Put the following line to the /etc/fstab file.

# for box.com
https://dav.box.com/dav/ /home/vunetid/box  davfs  _netdev,user,noauto 0 0 

(both of these work for me)

Make a directory in your home area to hold the davfs2 configuration files.
mkdir ~/.davfs2/

Make a file called ~/.davfs2/secrets. Add a line like the below where "your.email@vumc.org" is your Vanderbilt email address and "expassword" is your external password created above.
/home/vunetid/box your.email@vumc.org expassword

Set permissions on the ~/.davfs2/secrets file so that only you can see it.
chmod 0600 ~/.davfs2/secrets

Mount the box share.
mount ~/box

Directory Organization

This is a note from Frank Harrell:

As VUMC has moved to box.com for the "dropbox" type of function, those of you who want to synchronize with a directory on your computer should start planning for how best to do that. On my system I created a root directory /Box and I use linux sync software. For other systems, the sync software is available from box.com. On my system, sync involves using files "in the cloud". Unlike dropbox, the files do not exist on your hard disk but the box file system is "mounted". Caching goes on behind the scene to speed things up.

Don't put your local Box area under your home structure, as we don't want system backups to include it.

Start planning, and think about organizing your Box subdirectories in a logical hierarchical manner (suggestions at http://biostat.mc.vanderbilt.edu/FolderOrg) so that directories can be shared in the best way for collaboration. Over the years I've found that the structure in FolderOrg is easier to maintain, e.g., /projects has major area then individual project directories, self-contained with data etc., and generics are put in general areas such as /R, /doc, /doc/latex, etc.

Notes

  • Log on problems: If you are having trouble logging on with the Windows or Mac client check this:
    • log on to the web client (https://vumc.box.com)
    • click on the gear icon and then "Account Settings"
    • look in the "Login and Email Addresses" section and see if the email address you are using is there
    • if necessary, add another email address using the "Add more emails" link
  • has versioning built in
  • Comments may be added to files
  • Documents and tutorials at https://success.box.com/
  • Clients exist for Windows, Macintosh, iPhone/iPad, Android, and mobile browsers. There is no box.com supported client for Linux. However, tools do exist for using box.com on Linux computers. See below.
  • Besides the "Syncing in Linux" method below, Box can be used on Linux computers via the web site https://vanderbilt.box.com
  • Is Box HIPAA compliant? The short answer is "no". Vanderbilt Box.com Policy
  • We are provided with enterprise accounts controlled by Vanderbilt. The logon is a "single-sign-on" (SSO) process that uses Vanderbilt credentials. This causes problems with authentication in third party applications like ftp. See https://support.box.com/hc/en-us/articles/200520058-I-m-having-trouble-using-FTP-with-Box.
    • The relevant section says "FTP does not support SSO login credentials. You will need to create a Box specific password to supplement your SSO login. You can do so by visiting https://vanderbilt.app.box.com/settings and selecting Create External Password. This password can be used for external applications that do not support SSO."
    • If you want to use something like box-linux-sync to sync from a Linux computer you will need to use Box specific credentials.
  • FileZilla settings for connecting to Box account. Uses Vanderbilt email address as the username. The password is the Box external password described in the previous bullet point. This note is included as an example of working with a third party application.
    boxfilezilla.png
  • File types blocked by Sync. The following file types are blocked and unsupported by Sync:
    • Temporary files and folders (.tmp and files/folders starting with ~ character)
    • System and hidden files
    • Windows shortcuts
    • Box WebDocs
    • Outlook PST files
    • QuickBook files
    • Google Docs/Spreadsheets
  • Even though the box web app can be used to create Box WebDoc and Google Doc files, those files are not handled by the installed box-sync application! They just don't show up in the box sync folder.

Syncing in Linux

  • Running box-sync start (see below) will start syncing and it will continue until box-sync stop or you reboot
  • Current versions of all files on box.com will be available
  • These are "remote mounted" so you are actually accessing the cloud dynamically and no space is taken up on your hard disk
  • Files are cache so access is faster on repeated use
  • See https://github.com/noiselabs/box-linux-sync
  • Linux installation (let uid be your user name)
sudo apt-get install davfs2 cd ~/bin git clone git://github.com/noiselabs/box-linux-sync.git cd ~/bin/box-linux-sync/bin ./box-sync check Edit ~/.noiselabs/box/box-sync.cfg to make box_dir=/Box sudo mkdir /Box sudo chown uid.uid /Box Add to ~/.bashrc: path to ~/bin/box-linux-sync/bin/ source ~/.bashrc to incorporate new path box-sync setup sudo chmod u+s /sbin/mount.davfs box-sync --help box-sync start to mount /Box box-sync stop to dismount /Box file system

Accessing from R

You can access files from your Box account in R by using the curl and XML packages via the WebDAV protocol. To do this, you first need to generate an external password for Box. The external password may be created by visiting the following location on the Box website: Account Settings > Account tab > Create External Password. Once you have your external password, you can use the following R function to list files in your Box folder:

library(curl) library(XML)

listFiles <- function(username, password, relPath = "/", dav = "https://dav.box.com/dav") { uri <- URLencode(paste(dav, relPath, sep=""))

# fetch directory listing via curl and parse XML response h <- new_handle() handle_setopt(h, customrequest = "PROPFIND") handle_setopt(h, username = username) handle_setopt(h, password = password) response <- curl_fetch_memory(uri, h) text <- rawToChar(response$content) doc <- xmlParse(text, asText=TRUE)

# calculate relative paths base <- paste(paste("/", strsplit(uri, "/")1[-1:-3], sep="", collapse=""), "/", sep="") result <- unlist( xpathApply(doc, "//d:response/d:href", function(node) { sub(base, "", URLdecode(xmlValue(node)), fixed=TRUE) }) ) result[result = ""] }

The username parameter for this function refers to your Vanderbilt e-mail address. The password parameter refers to your external Box password. Do not save your external Box password in an R source file. For more information about Box's WebDAV support, see https://community.box.com/t5/Managing-Your-Content/Does-Box-support-WebDAV/ta-p/310
Topic attachments
I Attachment Action Size Date Who Comment
boxfilezilla.pngpng boxfilezilla.png manage 40.0 K 18 Mar 2014 - 14:48 DalePlummer  
rocket-slideshow.pdfpdf rocket-slideshow.pdf manage 1745.0 K 19 Mar 2014 - 09:22 DalePlummer  
Edit | Attach | Print version | History: r23 | r22 < r21 < r20 < r19 | Backlinks | View wiki text | Edit WikiText | More topic actions...
Topic revision: r21 - 15 May 2019, DalePlummer
 

This site is powered by FoswikiCopyright © 2013-2022 by the contributing authors. All material on this collaboration platform is the property of the contributing authors.
Ideas, requests, problems regarding Vanderbilt Biostatistics Wiki? Send feedback