Owncloud

-------

Install ownCloud Storage in Linux

In order to setup your own personal cloud storage (ownCloud), you must have LAMP (Linux, Apache, MySQL/MariaDB, PHP) stack installed. Other than LAMP stack you might need Perl and Python based upon your use.

On Debian/Ubuntu/Linux Mint

---------------------- For MySQL Server ---------------------- # apt-get install apache2 apache2-doc apache2-utils mysql-server mysql-client php5 php5-mysql php5-curl  ---------------------- For MariaDB Server ---------------------- # apt-get install apache2 apache2-doc apache2-utils mariadb-server php5 php5-mysql php5-curl

On RedHat/CentOS/Fedora

---------------------- For MySQL Server ---------------------- # yum install httpd mysql-server mysql-client php php-mysql php-curl  ---------------------- For MariaDB Server ---------------------- # yum install httpd mariadb-server php php-mysql php-curl

Step 2: Create Cloud Database

Once you setup LAMP stack on your personal box, just login to your database (MySQL, here).

# mysql -u root -p

Enter mysql root password. Now we will be creating a database (say cloud).

mysql> create database cloud ;  Query OK, 1 row affected (0.00 sec)

It is not a good idea to access your database from root, hence grant all the permission to a normal user (say tecmint).

mysql> grant all on cloud.* to tecmint@localhost identified by 'my_password';  Query OK, 0 rows affected (0.00 sec)

Step 3: Download and Install ownCloud Application

Now its time to Download latest ownCloud (i.e version 8.0.0) application using below link.

Alternatively, you may use wget command to download the source tar-ball package.

# wget https://download.owncloud.org/community/owncloud-9.0.0.tar.bz2

You may alternatively install from binary package using APT or YUM. The installation instruction can be found at:

However we choose the TAR package which is universally accepted and works on most of the known system.

After Downloading the owncloud package, move it to your Apache working directory, which is /var/www (for Debian) and /var/www/html (for RedHat).

# cp owncloud-9.0.0.tar.bz2 /var/www/ [For Debian based Systems] # cp owncloud-9.0.0.tar.bz2 /var/www/html/ [For RedHat based Systems]

Next, extract the package using tar command as shown below.

# tar -jxvf owncloud-9.0.0.tar.bz2

Since the TAR Archive is extracted you may remove the Archive.

# rm -rf owncloud-9.0.0.tar.bz2

We might need to change the file permission of owncloud, in our Apache working directory.

# chmod -R 777 owncloud/

Note: Remember we are giving read, write and execute permission to all, which is although risky but this time needed since several configuration file would be written automatically. We later need to change permission to 755, once the setup is finished.

Step 4: Configuring Apache for ownCloud

For security purpose ownCloud uses Apache‘s .htaccess files, in order to use them. We need to enable two Apache modules mod_rewrite and mod_headers for ownCloud to function properly. Type the following command to enable these modules under Debian based systems only, for RedHat systems they are enabled by default.

# a2enmod rewrite # a2enmod headers

Additionally, we need to enable mod_rewrite rules to work properly under Apache‘s main configuration file. Open the Apache global configuation file.

# nano /etc/apache2/sites-available/default [For Debian based Systems] # vi /etc/httpd/conf/httpd.conf [For RedHat based Systems]

There, find “AllowOverride None” and change this to “AllowOverride All” as shown.

AllowOverride None

Change this to:

AllowOverride All

Now we need to restart Apache to reload new changes.

# service apache2 restart [For Debian based Systems] # service httpd restart [For RedHat based Systems]

Step 5: Access ownCloud Application

Now you can acess your very personal cloud storage at:

http://localhost/owncloud OR http://your-ip-address/owncloud

Once you get the Owncloud page, you need to create an admin account and a Data folder location, where all files/folders will be stored (or leave default location i.e. /var/www/owncloud/data or /var/www/html/owncloud/data). Next, you need to enter mysql database username, password and database name, refer the screenshot below.

OwnCloud 9 Installation Wizard

Once all the correct values are entered, click Finish and your private cloud storage is ready, you are greeted with the working interface:

OwnCloud 9 Admin Dashboard

Notice the Favorites, edit, share, download, upload and new file options available for a file.

Upload Files to OwnCloud Storage

Activities log of oneself and others.

Owncloud Activity Log

Pictures library.

My Owncloud Picture Library

Apps enable and disable interface as well as recommendation with brief introduction.

Enabled Application

Inbuilt PDF reader.

PDF Reader

From this admin panel you can view security and setup warnings, Fedrated cloud sharing, Mail Templates,

Updater, Cron, sharing, Security, Email Server, Log, etc.

Security Setup Warning

User and Group information with quota.

User Group Quota

-----