In my ever lengthening wait for VMware’s project octopus to be released into public beta, I’ve been trying other dropbox like applications for feature functionality. One of the ones that I’ve been most impressed by is SparkleShare. With the announcement today that they’ve released their first windows client, I thought I’d post this quick tutorial on how to get sparkleshare up and running leveraging illumian as your data repository, and also test it out with the new windows client. There’s already a mac and linux client available and both work great.
What is SparkleShare?
From the sparkleshare website: “SparkleShare is a collaboration and sharing tool that is designed to keep things simple and to stay out of your way.” Feature wise, it acts very similarly to dropbox, but provides some additional functionality. It leverages a Git repository on the back end, and is extremely flexible.
My only concern with it, or any hosted data story, is ensuring that my data is always available and more importantly, that it doesn’t corrupt over time. That’s why I’m using illumian.
What is Illumian?
illumian was started by Nexenta to create an illumos distribution with Debian style package management tools for familiarity and compatibility with existing tools. This distribution uses the same versions of externally maintained packages as the OpenIndiana project uses today. Where NCP was based on OpenSolaris and some interesting ways to get debian packages ported, illumian is a based on the work in the continued new work in the illumos project. The recent 1.0 release contains only a small number of maintained packages and a simple command line installer. No GUI required.
you can download the illumian iso from illumian.org
Base VM configuration
On the road and working in a hotel, I’m using VMware workstation for this installation and have assigned the following items to the VM:
- 2 8G disks for the syspool (OS install disks)
- 2 16G disks for data (I’ll mirror these as well)
- 2G of RAM
- 1 vCPU
Boot from your illumian ISO and start the install process.
select language, keyboard and timezone.
You’ll be prompted to select the installation drives, very similar to a Nexenta installation, I’ve selected the two 8G drives as shown below.
It will ask if you would like to add an additional drive as a hot spare. I selected no.
Next it will prompt you to make sure you want to erase all the data on the drives, select yes.
Once the installation is complete, it will prompt you to enter the root password for the system.
Enter the password twice you want to use and select next.
Create a user account.
enter the password twice for the new user, and select next.
Commit the changes for the new user.
Enter the hostname for the new system, select next, and commit the changes for the hostname.
The next step is configuring the network adapter. Illumian (and Nexenta) allow for some pretty serious network configurations out of the box, but for this one we’re going to just use dhcp for getting up and running. We can go back and change it as needed later.
You should be presented for the network interface that you’ve assigned or is installed in your system. Select Yes to configure it.
When prompted if you want to enable DHCP, select yes.
When prompted if you want to enable ipv6 I selected no.
Select yes that you’re done configuring the device and the installation will proceed.
With the installation completed, disconnect your cdrom and reboot into your new illumian installation.
Like ubuntu, the first user created has sudo privileges. First thing after logging in as your user you’ll want to do is update the system.
sudo apt-get update
Once that’s complete, we can install git
sudo apt-get install git
Before we actually get started with sparkleshare we want to create a new mirrored zpool with the additional 16G drives we added to the VM. With illumian, (and Nexenta) we can grow this zpool as needed when we need additional space. I don’t expect to need more than 16G to start, but I want to keep my options open.
First let’s get a look at what the installer did:
with that listed we can see what drives are being used by the syspool.
The easiest way to get a drive list is via format.
This shows us the initial two 8G drives that we saw in the initial zpool as well as the additional two drives that aren’t currently in use.
to exit format.
Now we’ll create our new zpool for the sparkleshare repository.
sudo zpool create sparkle mirror c1t2d0 c1t3d0
should show us our new zpool:
One thing to remember if you’re new to illumian or ZFS in general, when you create a zpool there is automatically a zfs filesystem created on it. The mountpoint defaults to the poolname. So my pool “sparkle” is mounted as a zfs filesystem at /sparkle by default.
Now we can configure illumian for hosting the sparkleshare repository.
Create our user
sudo useradd git
Set the password for the user as a value that cannot be used for login, but does not lock the account.
sudo passwd -N git
Create our project folder
sudo mkdir /sparkle/git
Change the permissions on the project folder
sudo chown -R git.staff /sparkle/git
create the project
sudo git init ––bare MyProject
create and change dir to the users home directory
sudo mdkir /home/git
create the ssh folder
sudo mkdir .ssh
create the authorized keys file
sudo touch .ssh/authorized_keys
set the permissions on git’s home directory
sudo chown -R git.staff /home/git
On the Client System
Install sparkleshare for you OS, I’m going to be testing with the new Windows client. Head over to sparkleshare.org and download the windows client.
Start the installer.
It’s a simple accept the license next, next, install, finish affair.
Start SparkleShare and enter your name and email address.
Continue through the installer to finish the installation.
Once done, you’ll see a SparkleShare icon in your taskbar.
Right click on it and open your SparkleShare folder.
During the install SparkleShare will have created a key for you to use. This key will be in your SparkleShare directory. Copy the contents of the key file.
Back on the Server
Open up the .ssh/authorized_keys file we created earlier in a text editor and paste the key that you previously copied at The client side step on a new line at the end of the file. This gives the client access to the git repository.
Now lock down the ssh directory and the authorized key file.
sudo chmod 700 .ssh
sudo chmod 600 .ssh/authorized_keys
sudo chown -R git.staff .
Add a project to the client
With that done, move or delete the key in the sparkleshare directory. Notice that before moving (or deleting) this file, the option to “Add Hosted Project” is grayed out. The key file needs to be moved or deleted before you are allowed to add a project.
Right click on the sparkleshare folder and select “Add Hosted Project”
In the Setup screen, select “On my own Server” and enter the address and remote path you created for the project.
Select Add and when complete, Finish!
You’re up and running!
From here you can add files to your project folder and it will sync the data with the server automatically.
If you want to give more people access to your project, just paste their keys on a new line at the end of the authorized_keys file. Don’t share your client key, append it. This will allow you to add a lot of users based on the project as needed.
On top of this you can add multiple projects and servers to sync to. This opens up a range of ideas, from projects down to the team level, to organization wide distribution.
On top of this you get all the benefits of ZFS at the file system layer managing your data.
Let me know if you have any questions, or if this works for you. SparkleShare is a great looking project and when you add in the data security that ZFS provides it makes a pretty solid combination.