[How-To] ownCloud using NGINX, PHP-FPM, and MySQL

adrianwi

Guru
Joined
Oct 15, 2013
Messages
1,231
the memory cache has been added to the guide. you just need to edit the config.php

I don't personally use HSTS, probably should though.

I've added the following at the end of my config.php file but as soon as I save the file I loose connection to the server:

Code:
'memcache.local' => '\OC\Memcache\APCu'


When I # the line out and save it comes back up. Am I missing something else having come from some older instuctions?
 

Joshua Parker Ruehlig

Hall of Famer
Joined
Dec 5, 2011
Messages
5,949
I've added the following at the end of my config.php file but as soon as I save the file I loose connection to the server:

Code:
'memcache.local' => '\OC\Memcache\APCu'


When I # the line out and save it comes back up. Am I missing something else having come from some older instuctions?
I think it's because I forgot the trailing comma. thanks for the catch!
 

adrianwi

Guru
Joined
Oct 15, 2013
Messages
1,231
Nothing so simple, as I'd spotted that and added a comma at the end!
 

kwessel

Dabbler
Joined
Mar 30, 2015
Messages
44
Joshua,

I used your tutorial and had OwnCloud working on a FreeNAS machine. After loading 2TB of data, I moved the machine from my home to my office. I reset IP address so that my router would reserve specific addresses for FreeNAS and the OwnCloud jail. Everything was working. After moving the box to my server room and a reboot, I get the following error when I attempt to login to OwnCloud:

Cannot create “data” directory (/mnt/files ) This can usually be fixed by giving the webserver write access to the root directory.

Would you be willing to help me trouble shoot this issue?

Thanks,

Keith
 

Joshua Parker Ruehlig

Hall of Famer
Joined
Dec 5, 2011
Messages
5,949
Joshua,

I used your tutorial and had OwnCloud working on a FreeNAS machine. After loading 2TB of data, I moved the machine from my home to my office. I reset IP address so that my router would reserve specific addresses for FreeNAS and the OwnCloud jail. Everything was working. After moving the box to my server room and a reboot, I get the following error when I attempt to login to OwnCloud:

Cannot create “data” directory (/mnt/files ) This can usually be fixed by giving the webserver write access to the root directory.

Would you be willing to help me trouble shoot this issue?

Thanks,

Keith
can you check your Jails > Storage tab and see if you have a dataset mounted to your owncloud jail?
this setup relies on having a files and database dataset mounted to your jail.
 

kwessel

Dabbler
Joined
Mar 30, 2015
Messages
44
Yes, I believe the datasets I originally created are mounted. It shows "true" under the mounted tab. It shows "false" under read only.
 

Joshua Parker Ruehlig

Hall of Famer
Joined
Dec 5, 2011
Messages
5,949
from the owncloud jail can you show the output of the following
ls -l /mnt/files
 

kwessel

Dabbler
Joined
Mar 30, 2015
Messages
44
This is what I see when I run that command. All of my 2TB of data are accessible in sub directories of kwessel.

upload_2015-9-3_20-36-11.png
 

Joshua Parker Ruehlig

Hall of Famer
Joined
Dec 5, 2011
Messages
5,949
This is what I see when I run that command. All of my 2TB of data are accessible in sub directories of kwessel.

View attachment 8585
By default the php-fpm process in run by the 'www' user (UID=80). It looks like you changed ownership of this dataset.
Either change ownership back to 'www', or run the php-fpm process as a user with UID=666.
 

kwessel

Dabbler
Joined
Mar 30, 2015
Messages
44
I changed everything in the /mnt/files directory to www and still the same error message. I do not recall changing anything to 666. As previously mentioned everything was working and then after a reboot I started getting this error.

upload_2015-9-3_23-19-42.png
 

kwessel

Dabbler
Joined
Mar 30, 2015
Messages
44
If I ran the tutorial from the beginning, could I re establish a link to this dataset that has all of my data?
 

Joshua Parker Ruehlig

Hall of Famer
Joined
Dec 5, 2011
Messages
5,949
If I ran the tutorial from the beginning, could I re establish a link to this dataset that has all of my data?
yes, but there's no need to. It shouldn't be too difficult to get your current setup working.
did you change the permissions of the folder itself?
chown -R www:www /mnt/files
 

kwessel

Dabbler
Joined
Mar 30, 2015
Messages
44
I used Bitvise SFTP to change the permissions on the folder. I just ran chown -R www:www /mnt/files without an error message and still the same error message when I try to access owncloud.
 

Joshua Parker Ruehlig

Hall of Famer
Joined
Dec 5, 2011
Messages
5,949
I used Bitvise SFTP to change the permissions on the folder. I just ran chown -R www:www /mnt/files without an error message and still the same error message when I try to access owncloud.
not sure what bitvise sftp is...
From reading around your "open_basedir" setting could affect it as well. Can you show the output of the following?
Code:
php -i | grep open_basedir
 

Joshua Parker Ruehlig

Hall of Famer
Joined
Dec 5, 2011
Messages
5,949
Ok, I'm officially stumped.

You can try deleting the jail and doing the tutorial again. if your database and files are on seperate datasets as specified it should pick back up right where it left off.
Or you could ask for help on the owncloud forums/github.
 
Top