Global Installation of the Sandbox Tool Suite

If a system administrator is deploying the sandbox tools suite to be used by all users on the local system, steps similar to those for a local installation are performed, except that a few files are populated to globally-visible locations.

  1. Pick a global directory into which the sandboxTools.tar.gz package will be untar'd. Often this is /opt/sandboxTools, which is the default in the configuration files. Make the chosen directory if needed and untar the contents of sandboxTools.tar.gz into it.
  2. Copy sandbox_tools.sh prototype from the etc directory to /etc/profile.d.
  3. Edit the new /etc/profile.d/sandbox_tools.sh and modify the settings of BT_ROOT_PATH and SB_TOOLS_ROOT appropriately. Verify that the file is readable by regular users, but not writeable. If necessary, fix the permissions using chown.
  4. Source the modified sandbox_tools.sh to pick up the new environment variables.
  5. Copy mksb_completion.sh and workon_completion.sh (and any other completion scripts that might be present) to /etc/bash_completion.d. Verify that these are readable by regular users, but not writeable. If necessary, fix the permissions using chown.
  6. Run the cmdSource/compileSandboxSandboxPathCommand.sh script. This will compile the performance-sensitive filesystem-related commands and place the resulting executables in the appropriate operating system/CPU architecture-specific bin directory. Verify that these are readable and executable by regular users, but not writeable. If necessary, fix the permissions using chown.
  7. If deploying on an alternate operating system, either rename the default Linux.noarch to the local operating system or (preferably) add a symbolic link, similar to this for MacOS:
            # ln -s Darwin.noarch Linux.noarch
    

Local Installation

If a developer cannot get the sandbox tools suite installed using administrator privileges, it can be installed under the user's home directory. Assuming the sandboxTools.tar.gz package was stored under $HOME:

  1. cd $HOME
  2. mkdir sandboxTools
  3. cd sandboxTools
  4. tar xvf ../sandboxTools.tar.gz
  5. If the operating system is not Linux, either make a symbolic link to Linux.noarch or simply rename it:
            ln -s `uname -s`.noarch Linux.noarch
            
    or
            mv Linux.noarch `uname -s`.noarch
        

    On Windows, one should just use the text "Windows" in place of the "`uname -s`" usage and do the rename:

            mv Linux.noarch Windows.noarch
        
  6. cd $HOME
  7. cp sandboxTools/etc/sandbox_tools.sh .
  8. Edit $HOME/sandbox_tools.sh to update BT_ROOT_PATH and SB_TOOLS_ROOT. In the fragment below, BT_ROOT_PATH uses a UNC name on Windows to reference backing trees stored on a file server named "fileserver". This would need to be set to something appropriate for the local environment, which might be $HOME/backingTrees if there is no other alternative. The setting for SB_TOOLS_ROOT will be as shown since the sandbox tool suite was installed to $HOME/sandboxTools. Other settings can be changed if desired, but there is probably no need.
    # Local preference for location of backing trees
    # ------ EDIT THIS SETTING APPROPRIATELY! ------
    BT_ROOT_PATH="${BT_ROOT_PATH:-//fileserver/backingTrees}"
    export BT_ROOT_PATH
    
    
    # Point to installation root of sandbox tools suite
    # ------ EDIT THIS SETTING APPROPRIATELY! ------
    SB_TOOLS_ROOT="${SB_TOOLS_ROOT:-${HOME}/sandboxTools}"
    export SB_TOOLS_ROOT
    
    
  9. The login profile should get updated to include the sandbox_tools.sh and pick up some of the shell completion scripts, which probably means adding the following to the end of $HOME/.bash_profile:
    SB_USE_SSH_AGENT=1; export SB_USE_SSH_AGENT
    
    source "$HOME/sandbox_tools.sh"
    source "$SB_TOOLS_ROOT/etc/mksb_completion.sh"
    source "$SB_TOOLS_ROOT/etc/workon_completion.sh"        
    

    If no SSH public keys are in use, the SB_USE_SSH_AGENT value can be set to 0 to avoid the use of the ssh-agent.

    From this point onwards, a new cygwin terminal shell will setup the desired environment during its initialization.

  10. Start a new cygwin terminal to load the prepared environment and build-and-install the performance-sensitive utilities:
    $ cd $SB_TOOLS_ROOT/cmdSource
    $ ./compileSandboxCommands.sh
                

Questions

Questions can be sent to: Geoff Carpenter http://www.fargos.net/gcc.html