4/2/2023 0 Comments Owncloud raspberry pi![]() The txt file you created should be there. If you want to be absolutely positive that the drive is properly mounted, unplug the drive from the RPI plug it onto a PC since the drive is formatted “NTFS” it should be easily detected by the PC, open it, create an txt file name it test, then eject it and plug it back to the RPI and run the following command: sudo ls /media/ownclouddrive If it’s an empty drive you might not see anything so don’t be surprise if nothing shows up. If there are files inside the drive you should be able to see them here. To check it enter: sudo ls /media/ownclouddrive Now the drives should automatically be mounted. Save and reboot the Raspberry Pi: sudo rebootġ2. Dont forget to replace the UUID number to yours in stead of the one you copied from here. Add the following line to the bottom of the file, updating uid, guid and the UUID with the values we got above. ![]() Now add your drive into the fstab file so it’ll boot with the proper permissions. Should look something like ( numbers&letters ->. Then copy the light blue letters and numbers of the sda1 entry usually located on the bottom. Also we meed to get the UUID of the attached external hard drive so the Pi can remember this drive even if you plug it into a different USB port.Ĩ. Now to get the uid enter the following command: id -u www-dataħ. Enter the following command for the gid: id -g www-dataĦ. Now we need to get the gid, uid and the uuid as we will need to use them so the pi will remember it even if we plug it into a different USB port. Make the user www-data owner of the mounted drive and make its permissions read, write and execute: sudo chown -R www-data:www-data /media/ownclouddrive sudo chmod -R 775 /media/ownclouddriveĥ. Create and add the www-data user to the www-data group: sudo groupadd www-data sudo usermod -a -G www-data www-dataĤ. Make a directory we can mount to: sudo mkdir /media/ownclouddriveģ. Having an NTFS drive we will need to install a NFTS package by entering the following: sudo apt-get install ntfs-3g -yĢ. Now would be a good time to plug in the external Hard Drive to the RPI.ġ. These instructions are for mounting an NTFS formatted hard drive and allowing ownCloud to store files onto it. Mounting and Setting up an external hard drive Owncloud 10 installed on Raspbian Stretch is now ready for use.ĭone! !! all is left is to configure your devices to access your ownCloud storage. Immediately underneath enter your Mariadb details as follow:ĥ. Click on S torage & database drop-down and enter your external hard drive directory: /media/data/owncloudĤ. You should be presented with a simple setup screen, Here create a username and password to create an admin account.ģ. Open your browser and enter the IP address provided, in my case is 192.168.1.114 you’ll be directed to your ownCloud storage server.Ģ. Get the IP from the Raspberry pi ifconfigġ. Restart apache: sudo systemctl restart apache2 Create data directory for ownCloud sudo mkdir /media/data sudo mkdir /media/data/owncloudĬhange owner and group permissions to www-data sudo chown www-data:www-data -R /media/data/owncloud Basic First Access Setup ![]() Once downloaded, unzip the zipped package to the /var/-d /var/www/ Set permissions chown -R www-data:www-data /var/www/owncloud/ chmod -R 755 /var/www/owncloud/ Configure ApacheĮdit the Apache default site configuration file sudo nano /etc/apache2/sites-enabled/nfĬhange DocumentRoot /var/www/html to DocumentRoot /var/www/ owncloud ![]() MariaDB > grant all privileges on owncloud.* to identified by ‘12345’ MariaDB > create user identified by ‘12345’ Then execute the underneath commands in blue: You’ll be prompted to enter the Pi user password. ![]() Update the Raspberry Pi and its packages sudo su apt update & apt upgrade Install Apache 2 and SQLite sudo apt-get install apache2 sqlite sudo service apache2 restart Install PHP sudo apt-get install php php-gd php-sqlite3 php-curl libapache2-mod-php Install SMB Client sudo apt-get install smbclient PHP extensions needed to use ownCloud sudo apt-get install php-mysql php-mbstring php-gettext php-intl php-redis php-imagick php-igbinary php-gmp php-curl php-gd php-zip php-imap php-ldap php-bz2 php-phpseclib php-xml Register ownCloud trusted key wget -nv -O Release.key sudo apt-key add - /etc/apt//owncloud.list apt-get update Enable the Apache mod_rewrite module sudo a2enmod rewrite systemctl restart apache2 Install Maria Database sudo apt install mariadb-server mariadb-client Configure the database and user: mysql -u root -p Upon re-boot you would need to update the RPI and its packages. Select “Localisation Options” –> “ Change Locale” “ For Security when accessing form the WAN” The following changes needs to be made in the Raspberry Pi configuration: ![]()
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |