Installation and setting up: Nextcloud as a local network storage on CentOS7

Installation and setting up: Nextcloud as a local network storage on CentOS7

Requirements for installation of Nextcloud on RHEL7 and CentOS7

1.Minimum of 512 MB RAM

2.Web Server: Apache (httpd) / Nginx

3.Database Server: MariaDB / MySQL / PostgreSQL

4.PHP 5.4 +

1.Setting up of Apache Web Server, PHP and other systems.

Launch and create service for Apache Web server’s using systemctl:

2.Installation and setting up of MariaDB for Nextcloud

 

Execute command for MariaDB installation.

Launch and create MariaDB service.

Execute the initial database configuration, set up a root password for MariaDB and other parameters. Delete a test database and remote root login.

Create a database called nextcloud_db. From the terminal, connect with the console mysql and execute commands.

Create a user nxtuser and give him all the privileges for the base nextcloud_db.

3.Downloading the latest version of Nextcloud

 

There’re two ways to download the latest version of Nextcloud.

1.To open Nextcloud official website https://download.nextcloud.com/server/releases/ and download the latest version.

2.To download Nextcloud directly to the server using wget.

Keep in mind: you should ensure that all the packages wget and bzip2 are installed on your server. If they aren’t set up, execute the following commands for their installation.

Unwrap the downloaded Nextcloud repository tar.biz2 to root catalog of your webserver /var/www/html

Install the necessary attributes for directory and files.

4. Opening of necessary ports in firewall for Nextcloud

 

In case the firewalld is used as a main firewall, execute the following commands.

Switch selinux into permissive mode.

Сheck/change file /etc/sysconfig/selinux

5. Entering Nextcloud via web browser

 

In case Nextcloud was successfully installed, we get access via browser’s link and receive the invitation window.

 

https://IP/nextcloud

 

In our case it’s IP 192.168.16.40

 

Insert a user name and admin password. Choose MariaDB data base type and fill in the fields with the name of database, user name and password. After filling in the fields, push “Finish” button.

6. Changing file upload limits in Nextcloud (upload file size)

 

By default, you can upload files up to 2 MB. If you need to upload files larger than 2 MB, change parameters in the file /etc/php.ini. For example, let’s set up 30 MB size.

Restart web server.

7. Setting up security configuration

 

Check the following in the file /var/www/owncloud/data/ :

In the file /etc/httpd/httpd.conf (or in the file of your virtual Nextcloud host), check if the directives processing of .htaccess file is on.

8. Setting up WebDAV clients

If necessary, you can use WebDAV for connecting a network drive of your Nextcloud user.

 

For OS Linux

In Nautilus (the file browser), select File > Connect to … and select WebDAV. Enter the information you need, such as a host name, a directory, port and username. Check the box to create a bookmark, and you’ll find it in your Files and Folder lense and in the left pane in Nautilus.

You’ll be able to use your WebDAV share as if it were a local folder.

 

For Windows clients

Firstly, you need to amend register, make changes in data for processing authorization policy:

 

run -> regedit

A key: BasicAuthLevel, set up a value 2

Restart the system and connect a network drive:

Choose the necessary drive and indicate the way in the field “Folder”:

Unlike Linux connection, the indicated way should be a bit different.

Now you know how to add more room for your data using the possibilities of CentOS7. Give this a try and experience the benefits of Nextcloud local network storage.

 

If you would like to speak to K&C’s DevOps transformation consultants and DevOps engineeers to discuss an upcoming project or specific need your organisation has, please do not hesitate to get in touch.

Add comment

E-mail is already registered on the site. Please use the Login form or enter another.

You entered an incorrect username or password

Sorry that something went wrong, repeat again!
Contact us