Hi guys,
When uploading a document to a card I get an error asking me to check permissions on my data folder.
I have set the user and group ownership of /var/www/kanboard folder recursively to www-data.
I have temporarily given 755 to the same folders.
I’ve also tried defining the temporary file manually to “/tmp” in the web-server php.ini without success.
I’ve looked at a few threads on this forum and Github and figured the above steps would work.
Can someone offer some guidance or hints on this?
Thank you,
Jim
files are uploaded to the data folder. that folder is defined in the config, and that folders permissions should be set correctly.
the default location is defined here:
Hi creecros,
So is something like this supposed to work then?
define(‘DATA_DIR’, ‘/var/www/kanboard/data’);
&
define(‘FILES_DIR’, ‘/var/www/kanboard/data/files’);
where I’ve manually created /files under /data.
Seems to return the same error so I must be off.
Jim
assuming the correct permissions and web server settings, yes, it should work. what’s your error message? can you paste it?
Sure no problem.
cat /var/log/syslog =>
php: [error] File not uploaded: 0
GUI =>
Unable to upload files, check the permissions of your data folder.
(The progress bar reaches 100% with this error message.)
ls -l /var/www/kanboard =>
drwxrwxrwx 3 www-data www-data 4096 Mar 3 19:44 data
Jim
and to be clear, you’re using apache, not nginx?
Yep, using apache for this.
Jim.
I would try:
chown -R www-data:www-data /var/www/kanboard/data
just to be sure. if that doesn’t work, confirm that www-data is the user in the web server, and if that is confirmed, I am as clueless as you.
sorry, apache is not my cup of tea
I had done that command and tried again to confirm. No dice.
Some additional info (even if only for future readers):
In Ubuntu the default temp dir is /temp and I tested that files are being created there from within /var/www/kanboard with a php script placed in that directory & run. Temp also has www-data ownerships.
So, it may be safe to conclude that this isn’t a permissions issue, somehow O.o.
Jim
take a look at this answer:
php, apache, centos
maybe?
Hi creecros and readers.
Issue is solved now and here’s the answer (for my issue at least):
I was attempting this 0 byte files. It works with >0 byte files.
The web-server and permissions issues above were likely also a factor.
Jim
1 Like