This guide is written specifically for Ubuntu, minor changes may be needed for other distros.

I.  Alternate Storage Location On Local Server

This assumes you have already setup a share from the install documentation and now want to change it.

From the diagram, we can see that this setup is very simple.  All traffic from the client computer goes directly to the CloneDeploy Server.  The CloneDeploy Server is acting as both the SMB server and the Multicast server.

 

 

 

 

 

 

  1. Create a new directory at your desired location with a name of your choice.  I will use /mystorage for this example.
  2. Inside that directory, create two more directories – images and resources
  3. You should now have a directory structure that includes /mystorage/images and /mystorage/resources
  4. Set permission:
    chown -R www-data:cdsharewriters /mystorage
    chmod -R 2775 /mystorage
  5. Edit /etc/samba/smb.conf and update the path to /mystorage
  6. Restart samba – service smbd restart
  7. Open the CloneDeploy Web Interface and go to Admin -> Distribution Points
  8. Select View on the primary distribution point
  9. Update the physical path to your shared directory, in this example it would be /mystorage
  10. Click Update Distribution Point

 

II.  Alternate Storage Location On Remote Server

A.  Block Level (iSCSI , Fibre Channel)

Not much to this one, just mount the block device to your CloneDeploy server and follow the previous guide for Alternate Storage On Local Server.  In this scenario CloneDeploy will still remain as the SMB server for your clients.

B.  File Level (SMB)

From this diagram we can see that setting up a Remote Distribution Point changes the behavior of the Client Computer.  The Client Computer now connects directly to the remote SMB server, bypassing the CloneDeploy server.  However, multicasts still connect to the CloneDeploy server.  The CloneDeploy Application Server is unaware that the Distribution Point is Remote.  When using Linux, the Distribution Point Location must ALWAYS be set to Local.  The remote option uses native Windows libraries that don’t exist for Mono.  We will work around this by mounting the remote share on the CloneDeploy server.

 

 

 

I cannot give exact advice on how on how to setup the remote share since they are so many different devices that can provide SMB services.  Here is a generalization.

  1. Create a new SMB share on your remote NAS, SAN, File Server, etc.
  2. There should be two levels of access, a read only user and a read write user – this can sometimes be complicated to setup, if you cannot achieve this, a single read write user will work but isn’t recommended
  3. The share must have two sub directories – images and resources
  4. Get the Apache uid on your CloneDeploy server
    id -u www-data
  5. Install cifs-utils
    apt-get install cifs-utils
  6. Mount the share on your CloneDeploy server
    mount -t cifs //[remote-ip]/[share-name] [destination] -o user=[write-user],pass=[write-user-password],uid=[apache-uid],dom=[domain]
    Example: mount -t cifs //192.168.1.30/cd_images /remoteshare/ -o user=cd_share_rw,pass=write,uid=33,dom=workgroup
  7. Open the CloneDeploy Web Interface and go to Admin -> Distribution Points
  8. Select View on the primary distribution point or create a new one, don’t forget to make it primary
  9. Update all fields to match the settings for your SMB share
  10. Set the Location to Local
  11. Update the Physical Path to the mounted share
  12. Click Update Distribution Point
  13. After all tests are done and successful, set the share to auto mount at startup, place the following example in /etc/fstab
    //192.168.1.30/cd_images /remoteshare/ cifs user=cd_share_rw,pass=write,uid=33,dom=workgroup 0 0
in