Opendir(/var/temp): failed to open dir: Not a directory

Please help us by providing the following info. Before posting please also check the pinned "Known issues" threads and make sure that you're running the latest available version for your oC release: https://owncloud.org/changelog/

Steps to reproduce
1.I'm seeing in my logs that i'm getting the error: "Error PHP opendir(/var/temp): failed to open dir: Not a directory at /var/www/owncloud/lib/private/tempmanager.php#187"
2.Don't know where the error is coming from.
3.

Expected behaviour
Tell us what should happen
NO error? :slight_smile:

Actual behaviour
Tell us what happens instead: Don't know what the impact is, although my Music app is hanging, when i open it it freezes mostly after a few secs.

Server configuration
Operating system: Ubuntu server 16.04
Web server: apache2
Database: mysql
PHP version:7.0
ownCloud version (see ownCloud admin page):9.0.2
Updated from an older ownCloud or fresh install: updated
ownCloud log (data/owncloud.log, see https://central.owncloud.org/t/how-to-find-webserver-or-oc-logfile-enable-php-logfile/808):https://cloud.ofnie.eu/index.php/s/WaXy7K3ujzq1xyz Password = "logfile"

Special configuration (external storage, external authentication, reverse proxy, server-side-encryption): no external storage, no external authentication, no reverse proxy.

Integrity status for oC9+

Login as admin user into your ownCloud and access
http://example.com/index.php/settings/integrity/failed
No errors have been found.

@memorex Hi, maybe this comment of this issue can help you:

or the solution provided in this other issue:


Cheers, davitol

Hi,

its most likely that the following PHP directive:

https://secure.php.net/manual/en/ini.core.php#ini.upload-tmp-dir

is configured to a wrong (the /var/temp) directory which doesn't exist or which is a file as the message:

opendir(/var/temp): failed to open dir: Not a directory

is telling you.

Thank you for the reply!

I created a directory and chowned it to the user who is running PHP, also i checked the permissions so that it's writable by the user and modified the directive "upload_tmp_dir" in my php.ini config file.

I uploaded a file to owncloud via http and don't see the error.

Case closed? Or should i test it in another way?

Kind regards, Jonathan.