Setup your personal Cloud server in minutes using ownCloud On RHEL, CentOS, Scientific Linux 6.5

Setup your personal Cloud server in minutes using ownCloud On RHEL, CentOS, Scientific Linux 6.5

ownCloud is a free Open Source software, used to setup your own personal cloud for file sharing, Calender, Contact and Bookmark sharing and Personal Audio/Video Streaming. It is pretty easy to setup and manage.


In this tutorial i am using CentOS 6.5 minimal server to setup ownCloud. My testbox details are given below.

Operating system: CentOS 6.5 Minimal Installation
IP Address:

While it was tested on CentOS 6.5, it is applicable for all RPM based distros.

Then your server should have a working LAMP stack. Refer the following link to setup LAMP server.

Install LAMP server on RHEL/CentOS/Scientific Linux

Install following necessary PHP extensions:

# yum install php-mysql php-json php-xml php-mbstring php-zip php-gd curl php-curl php-pdo

Setting up database for ownCloud

Let us create a database called ‘ownclouddb’ and database user ‘ownclouduser’ with passwor ‘centos’.

# mysql -u root -p
Enter password: 
Welcome to the MariaDB monitor.  Commands end with ; or \g.
Your MariaDB connection id is 66
Server version: 5.5.34-MariaDB MariaDB Server

Copyright (c) 2000, 2013, Oracle, Monty Program Ab and others.

Type 'help;' or '\h' for help. Type '\c' to clear the current input statement.

MariaDB [(none)]> CREATE DATABASE ownclouddb;
Query OK, 1 row affected (0.04 sec)

MariaDB [(none)]> GRANT ALL ON ownclouddb.* TO ownclouduser@localhost IDENTIFIED BY 'centos';
Query OK, 0 rows affected (0.01 sec)

MariaDB [(none)]> flush privileges;
Query OK, 0 rows affected (0.01 sec)

MariaDB [(none)]> exit

Getting owncloud

Switch to your apache root folder and download ownCloud latest version

Goto to Apache root document folder and download the latest version of owncloud.

# wget

Extract the tar package using command:

# tar xvf owncloud-6.0.0a.tar.bz2

Move the extracted folder to your apache root folder (i.e /var/www/html/)

# mv owncloud/ /var/www/html/

Set the ownership and permissions to the following folders:

# chown -R apache:apache /var/www/html/owncloud/
# chmod 777 /var/www/html/owncloud/config/

Enable apache rewrite mode.

Edit file “/etc/httpd/conf/httpd.conf”,

# vi /etc/httpd/conf/httpd.conf

Find the following section and Change AllowOverride None to Allowoverride All.

     AllowOverride All

Finally, restart the apachehttpd and mysql services.

# service mysql restart
# service httpd restart

Begin ownCloud Installation

Navigate to http://ip-address/owncloud or http://domain-name/owncloud from your web browser.

Note: If encountered with any permission errors, disable SELinux and try again.

The index page of own cloud will shown up. You will asked be to create a new admin account. Enter the admin account details.

Then, Click on the Advanced drop-down box, select mysql and enter the mysal database name, database user name and password. Finally click Finish setup to complete installation.

ownCloud - Mozilla Firefox_001This is how my ownCloud dashboard looks:

Files - ownCloud - Mozilla Firefox_002Thats it. Our cloud server is ready. From here, you can upload/download your images, files, Audio, Video and also can access them from your client systems over LAN/WAN.

  • thiyagi

    I am just asking out of curiosity why Owncloud, why not just ftp or samba file server. If there is any advantage, plz mention it.. Pardon my stupidity if it is so..

  • Alan McAlexander

    Hi Thiyagi,
    I’ll take a stab as I just stumbled upon this article and am in the process of setting up Owncloud (will wait for 5.0 though). Owncloud is like Dropbox, if you’re familiar with that. I’m implementing Owncloud for the company I work for. It will allow us to share files through a web browser, instead of ftp (which isn’t very secure) or samba (which again, has security problems if not configured properly). Owncloud enables you to sync data between your smartphone, tablet, computer AND share that same data with people, whether it is with teammates, business partners or clients. There’s a lot more to Owncloud than that by the way, but that is what I’m using it for.

    Also, check out, they have a .run file that will install Owncloud, it’s quick and very easy!

  • Pingback: Setup your personal Cloud server in minutes using ownCloud | Linux A.I()

  • Nick Heywood

    I apologise if the answer to my question is obvious, but it aint to me :) Why do we have to setup a DNS server? Can we not access ownCloud through http://ip_address/owncloud

  • Pingback: Setup your personal Cloud server in minutes using ownCloud | Thelinuxgeek()

  • Alan McAlexander

    Hi Nick,
    You are correct, you can just access it through your solution…. BUT, DNS would make it so that you can access it through a name, not a bunch of numbers. With IPV6 coming on board, this will be VERY important. DNS is fairly easy to get going. If you haven’t yet, please check out, this is a firewall/router downloadable ISO that is based on BSD. I use it at home, at work and several friend’s houses. It does DHCP and DNS, is gui driven and very easy to get going. I run pfsense as VM’s in pretty much all my infrastructure.

  • Nick

    Thanks Alan. Speaking of VMs It seems using VMs is also a handy way to run ownCloud.

  • Alan McAlexander

    That’s what I do at work and home, Owncloud runs as a VM on a Debian Linux base. If I need the extra space, it’s quite easy to mount NFS mount from a NAS or SAN (I use Mythbuntu that exports mounts at home) to the main storage directory that Owncloud uses. BTW, Owncloud 5.0 was released this morning!

  • pocoO

    Hi Alan,

    What virtualization software do you use? i use pfsense as well, but im thinking in use it as a vm too..any recomendations?

    thanks in advance

  • Nick Heywood

    pocoO, for your info I now keep a VM image of a Ubuntu 12.04LTS Server constantly updated so I can deploy a, in my case and for my testing use, 768mb ram Ubuntu SSH/LAMP VM in minutes. Having one of these setups lying around on a hard drive or USB is invaluable if your unsure of how to or the value of an install on your system. The ip address asignment can get confusing though ;-) “HHHmm have I used .1.80 anywhere”? :)

  • Nick Heywood

    Really thyagi, it’s just the Automatic syncronisation of files and services amongst invited users through a common framework or environment. Sort of like rsync on cronjob steroids. :)

  • Alan McAlexander

    I use Proxmox, minus the reboot for the 2.2 update, I’ve been running for over 1 1/2 year with pfSense as a VM. My server has 32G RAM (a used Dell 2950) and the amount of VM’s I have on her pegs the used RAM at around 25G. No lag on my network, even with all this load. I’ve been happy with this setup. If you have 3+ servers, Proxmox also works well in a cluster setup, it’s quite easy to do and their Wiki is really nice.

  • pocoO

    Thanks for the quick and nice answer. Im using proxmox in and old computer as well :) but only i’m starting to test it with some “test” virtual machines … how many physical network cards do you use, and for the virtual pfsense? any special configuration in the virtual network switch of proxmox? thank you very much in advance. Tomorrow im going to test a pfsense in a spare server that i have at work..with proxmox too…(we need to change and old smoothwall sooner or later) (sorry for my bad english ;)

  • pocoO

    Thanks for the info…

  • Alan McAlexander

    I have 6 Network Interfaces on my 2950, 2 onboard the MB, and 2 – dual port add in cards…. I couldn’t justify spending over $200 on a 4port and went with 2 dual ports for $35/each :) I try to keep it simple with my configuration on Proxmox. Eth0 maps to vmbr0, eth1 maps to vmbr1, etc. That comes in real handy when you’re dealing with something like pfSense, then em0 maps to vmbr0, which maps to eth0… nice and easy! The only interface in Proxmox that has an IP is vmbr0, which I use for internal traffic, vmbr1 is external.

  • Alan McAlexander

    Nick, You should check out, I use to setup Nginx or apache, mysql, all that stuff by hand… now I just deploy a turnkey .iso Nginx, Mysql, php and cgi for everything. It’s good to learn by doing it from scratch…. but man does it save time just throwing a ready to rock .iso or VM. I hadn’t deployed Owncloud yet to the masses at work yet, was waiting for 5.0 to rollout, now that it has, I’m getting ready to rollout this at work and the turnkey basic distro is a time saver.

  • pocoO

    Thank you very much for the info…i see. If i understand correctly, if you want two interfaces in pfsense: the internal one goes to the “internal” virtual bridge (vmbr0 for example..eth0 in proxmox) and the external one to vmbr1..eth1 in proxmox. The rest of the vm can go into the same vmbr0. So, the bridges are only connected throw the firewall interfaces…isn’t it? thanks again…and sorry for too many questions ;)

  • Alan McAlexander

    You’re right on. Now let’s say that you build a VLAN on em2 (the pfSense interface), which is connected to vmbr2 on Proxmox – and now you want to put a VM on that VLAN, just assign vmbr2 to that VM and you’re done. No worries on the questions. I was that way about a year ago, once it’s sorted out in your mind it makes sense.

  • pocoO

    I see it much clear now…ill try with the vlans too…thanks.

  • Pingback: Setting up your ownCloud | 0ddn1x: tricks with *nix()

  • Nick Heywood

    I’ve had a look at turnkey a few times, and baulked at it. A lack of understanding I suspect. I like my independence :) But now? I have the confidence level to give it a fair run. Done! :) Good thought Alan, ‘ta

  • Nick Heywood

    I’m not totally convinced about rolling ownCloud 5.0 out to the “great unwashed”. Been playing with it for a few weeks, and don’t seem to be able to some of the apps to install with out throwing errors. I’ll admit I haven’t chased down the problem in any depth at all. But the “great unwashed” are going to want to know everything is Kosher before it gets deployed, and I can’t do that right right now with out a “but” attached to any proposal :)

    I think it’s awesome. But then we’re not the sort of people to throw our hands up in the air, or bash the desk when something’s not behaving :)

  • andrew

    hello I have this error

    [root@cloud html]# /etc/init.d/httpd restart

    then this appears

    Starting httpd: httpd: Syntax error on line 350 of /etc/httpd/conf/httpd.conf: without matching section.

    plz tell how to fix this.

  • SK

    Andrew look into your httpd.conf file at line no 350. There might be a syntax error.

  • CandleForex

    We tested out OwnCloud but after a day or testing we dumped it.

    It just dosent have all the features we were looking for.

    It might be suitable for someone who wants a bunch of files and mucic in once place but its not good enough for a company. Its just too minimal

  • Amithabh
  • Pingback: 使用ownCloud在Linux安装你的个人云服务 | 学习记录()


    Hey would you mind stating which blog platform you’re using?
    I’m going to start my own blog in the near future but I’m having a tough time deciding between BlogEngine/Wordpress/B2evolution and Drupal.

    The reason I ask is because your design and style seems different then most blogs and I’m looking for something
    completely unique. P.S My apologies for being
    off-topic but I had to ask!