ownCloud is a quite simple and effective way to synchronize files and folders over LAN / internet, especially if you want to access them from mobile devices like Android phones / tablets, or via web interface.
The problem of ready-to-use cloud services like Dropbox, Skydrive etc. is, you never really know what the service provider does with your data, even if it is encrypted. ownCloud can run locally on your hardware and it is open source, so this way should be much safer.
This tutorial shows you how to install a Ubuntu VM on Hyper-V (or any other Hypervisor, or PC / server) in combination with LDAP / Active Directory.
First, create a new virtual computer in your Hyper-V environment, e.g. with 512 MB RAM or more. Ubuntu and ownCloud do not need too much resources. Choose a disk size according to how much space you need for your ownCloud storage.
Install the official Ubuntu ISO image, e.g. the server version of 12.04. It should work with default settings. Additionally, install SSH during the setup.
When the installation is finished, open http://[your-owncloud-server-ip]/owncloud in your browser and follow the wizard.
If you want to, you can do a first test now, e.g. use the ownCloud Windows client and try to connect with the Admin user.
If your ownCloud server is accessible from the internet, you should use SSL encryption to secure your data.
In the settings, also force ownCloud to use TLS.
Digicert has a good guide for creating the certificate request with your local Apache Server and how to integrate the final certificate.
LDAP / Active Directory access
Enable the ownCloud LDAP module via the web admin interface.
Run (with sudo/root permissions):
apt-get install php5-ldap
service apache2 restart
Check your /etc/resolv.conf, it should contain your FQDN, e.g. “search domainexample.local”, and your DNS server(s).
In Windows AD configuration, create a group “ownCloudAccess” and place your users in there who should be able to use it.
Important: The current ownCloud seems to have problems with hierarchical AD user groups. So you should put your user names directly into this group and not another user group.
The AD connection configuration itself can be quite tricky, but you can compare your settings to the following screenshots.
As soon as you have finished LDAP configuration, you should see your AD users in the list.
Your ownCloud installation should work now.
If not, have a look at the log in the web interface (or via console).
For debugging purposes, you can also install sqlite3 to access the database.