NextCloud is a very excellent open source private cloud storage system. I have installed and used NextCloud on the VPS host before. At the same time, I used Aria2 offline download to turn the server into a film and television download center, and then used a video player that supports the WebDAV protocol, so You can watch videos anytime and anywhere.

I happen to have a Raspberry Pi 2 in my hand these days, which has been sitting there useless, and the SMB sharing enabled by the router at home is stuck terribly when watching high-definition videos. So I decided to use the Raspberry Pi to make a sharing system, and I happened to have If the 500GB mobile hard drive is idle, you can mount the mobile hard drive to the Raspberry Pi and use it as a hard drive.

Since the operating system installed on Raspberry Pi is a modified Linux Debian, many problems were discovered during testing. Originally, installing NextCloud on Linux was a very simple matter, but Raspberry Pi file permission issues, mounting mobile hard drives, and Linux and Windows hard drive format issues were all pitfalls.

Raspberry Pi Installation NextCloud Tutorial-Self-built home private cloud for LAN file sharing

If you are interested in building personal cloud storage, you can also try these:

  1. VPS mounts domestic and foreign network disks to achieve free expansion tools: Rclone, COS-Fuse and OSSFS
  2. Self-built Nextcloud audio and video center: Aria2 offline download + PotPlayer and Kodi local viewing
  3. Linux VPS mounts Google Drive and Dropbox-realizes VPS host data synchronization and backup

PS: Updated on December 13, 2017, You may encounter some problems when building a NAS with Raspberry Pi. Here is a collection of problems and solutions: Raspberry Pi Ten problems in building a low-cost NAS storage home server with Raspberry Pi tidy.

PS: Updated on November 14, 2017, If you want to build a simple online file management system, you can try: Comparison of three excellent online file managers (directory list) - Directory Lister, h5ai and FileRun.

1. Install NextCloud on Raspberry Pi

1.1  Simple method: directly flash the NextCloudPi image

NextCloudPi is a NextCloud image specifically for Raspberry Pi. The images already include Raspbian 9, Nextcloud 12.0.2, Apache 2.4.25, HTTP2, etc., as follows:

Raspbian 9 stretch

Nextcloud 12.0.2

Apache 2.4.25, with HTTP2 enabled

PHP 7.0 (double the speed of PHP5!)

MariaDB 10

4.9 Linux Kernel

nextcloudpi-config for easy setup (RAM logs, USB drive and more)

Automatic redirection to HTTPS

ACPU PHP cache

PHP Zend OPcache enabled with file cache

HSTS

Cron jobs for Nextcloud

Sane configuration defaults

Full emoji support

NextCloudPi installation instructions can be found on the official website: https://ownyourbits.com/2017/02/13/nextcloud-ready-raspberry-pi-image/, alternative download: https://do.wzfou.net/wzfou/NextCloudPi_08-20- 17.tar.bz2. After the installation is complete, you can access it through https://<rpi_ip_or_url>:4443.

6. Summary

From my experience, it is best to directly flash the NextCloudPi image to install NextCloud on Raspberry Pi, because manually installing LNMP and configuring NextCloudPi tends to consume a lot of resources and runs a bit laggy.

Raspberry Pi runs Aria2 alone and does not take up much resources. If you use Aria2 to download magnet links and there is no speed, you can try adding the bt-tracker server to the configuration file and wait patiently for a while.

Today, I also encountered during use. After the Raspberry Pi was powered off and restarted, an error message appeared when mounting the mobile hard disk : "error mounting exited with non-zero exit status 32, Can't Read Superblock". Solved Method: First use the command: sudo fdisk -l to find /dev/sdxxx, and then repair: sudo fsck /dev/sdxxx. If you find that the download task is empty after restarting Aria2 , it is most likely that the session file in /root/.aria2 has not been changed to read and write permissions. Please change all the files in it to 755 permissions.

Leave a Reply