0% found this document useful (0 votes)
36 views2 pages

OwnCloud in Ubuntu

This document provides steps to install and configure OwnCloud on a server. It involves installing prerequisites like Apache, PHP and MariaDB database. A database is created and a user with privileges is configured. OwnCloud is downloaded, extracted and configured to use the MariaDB database. Finally optional configurations like patching for compatibility and securing MySQL are described.

Uploaded by

Htun Aung Lynn
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as TXT, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
36 views2 pages

OwnCloud in Ubuntu

This document provides steps to install and configure OwnCloud on a server. It involves installing prerequisites like Apache, PHP and MariaDB database. A database is created and a user with privileges is configured. OwnCloud is downloaded, extracted and configured to use the MariaDB database. Finally optional configurations like patching for compatibility and securing MySQL are described.

Uploaded by

Htun Aung Lynn
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as TXT, PDF, TXT or read online on Scribd
You are on page 1/ 2

Step 1: Installing Prerequisites

----------------------------------
# sudo apt install apache2
# sudo a2enmod rewrite
# sudo a2enmod headers
# sudo a2enmod env
# sudo a2enmod dir
# sudo a2enmod mime
# sudo systemctl restart apache2
# sudo apt-get update
# sudo apt-get install mariadb-server mariadb-client

Step 2: Configuring Database


-------------------------------
# sudo mysql -u root -p
Enter Password: **Enter**

> CREATE DATABASE imuowncloud;


> CREATE USER 'imuclouduser'@'localhost' IDENTIFIED BY 'Imu12345';
> GRANT ALL ON imuowncloud.* TO 'imuclouduser'@'localhost' WITH GRANT OPTION;
> FLUSH PRIVILEGES;
> EXIT;

Step 3: Installing PHP


------------------------
# sudo apt-get install software-properties-common
# sudo add-apt-repository ppa:ondrej/php
# sudo apt update
# sudo apt install php7.4
# sudo apt-get install php7.4-cli php7.4-common php7.4-mbstring php7.4-gd php7.4-
intl php7.4-xml php7.4-mysql php7.4-zip php7.4-curl php7.4-xmlrpc

# sudo nano /etc/php/7.4/apache2/php.ini


**Edit the following line
memory_limit = 256M
**Add the following line below of the memory_limit
upload_max_file_size = 100M
** save and exit (Crtl+O enter Ctrl+X)

# sudo systemctl restart apache2

Step 4: Installing OwnCloud


-----------------------------
# mkdir tmp
# cd tmp
# wget https://download.owncloud.com/server/stable/owncloud-complete-latest.zip
# sudo apt install unzip
# unzip owncloud-complete-latest.zip
# sudo mv owncloud /var/www/html/owncloud/
# sudo chown -R www-data:www-data /var/www/html/owncloud/
# sudo chmod -R 755 /var/www/html/owncloud

Step 5: Configuring OwnCloud


------------------------------
*** Allow HTTP protocol in Azure vFirewall ***
Open Broswer
Type==> http://localhost/owncloud <OR> http://VM PublicIP/owncloud
=> Creat admin account (e.g. admin, 1234)
=> Create database user, password, db name (e.g. imuclouduser, Imu12345,
imuowncloud, localhost)
=> Finish Setup

Login by using admin account


UserName: admin
Password: 1234
-----------------------------------------------------------------------------------
-------------
Optional Configuration
----------------------

Owncloud Register Error Fix


#cd /var/www/html/owncloud
#sudo wget https://gist.github.com/VicDeo/bb0689104baeb5ad2371d3fdb1a013ac/raw/
04bb98e08719a04322ea883bcce7c3e778e3afe1/DoctrineMariaDB102.patch
#sudo patch -p0 < DoctrineMariaDB102.patch
--------------------------------------------
Delete Database and User
mysql -u root -p
SHOW DATABASES;
DROP DATABASE database_name;

SELECT User,Host FROM mysql.user;


DROP USER 'user'@'localhost';
------------------------------
Secure mysql
# sudo mysql_secure_installation

**Enter** current password for root


Set root password **Y**
Type New Password:
Re-enter new Password:

Remove anonymous users? **Y**


Disallow root login remotely? **Y**
Remove test database and access to it? **Y**
Reload privilege tables now? **Y**
------------------------------------------------------------------------------

You might also like