Nextcloud version: 26.0.2
Operating system and version: Linux 6.1.21-v8+ aarch64
Apache or nginx version: nginx/1.18.0
PHP version : 8.1.19
The issue you are facing:
Cannot delete folders.
Is this the first time you’ve seen this error?: Y; this was working fine with NC 26.0.1
Steps to replicate it:
- Create a folder
- Try to delete it (fails).
- Try to move it (fails)
Folder deletion fails in both my ‘admin’ account and my ‘user’ account.
The output of your Nextcloud log in Admin > Logging:
Error webdav TypeError: OC\Files\Cache\QuerySearchHelper::getCachesAndMountPointsForSearch(): Argument #1 ($root) must be of type OC\Files\Node\Root, OC\Files\Node\LazyRoot given, called in /config/www/nextcloud/lib/private/Files/Node/Folder.php on line 237
Line 237 of Folder.php mentioned above is shown below in context:
216 /**
217 * search for files with the name matching $query
218 *
219 * @param string|ISearchQuery $query
220 * @return \OC\Files\Node\Node[]
221 */
222 public function search($query) {
223 if (is_string($query)) {
224 $query = $this->queryFromOperator(new SearchComparison(ISearchComparison::COMPARE_LIKE, 'name', '%' . $query . '%'));
225 }
226
227 // search is handled by a single query covering all caches that this folder contains
228 // this is done by collect
229
230 $limitToHome = $query->limitToHome();
231 if ($limitToHome && count(explode('/', $this->path)) !== 3) {
232 throw new \InvalidArgumentException('searching by owner is only allows on the users home folder');
233 }
234
235 /** @var QuerySearchHelper $searchHelper */
236 $searchHelper = \OC::$server->get(QuerySearchHelper::class);
237 [$caches, $mountByMountPoint] = $searchHelper->getCachesAndMountPointsForSearch($this->root, $this->path, $limitToHome);
238 $resultsPerCache = $searchHelper->searchInCaches($query, $caches);
239
240 // loop through all results per-cache, constructing the FileInfo object from the CacheEntry and merge them all
241 $files = array_merge(...array_map(function (array $results, string $relativeMountPoint) use ($mountByMountPoint) {
242 $mount = $mountByMountPoint[$relativeMountPoint];
243 return array_map(function (ICacheEntry $result) use ($relativeMountPoint, $mount) {
244 return $this->cacheEntryToFileInfo($mount, $relativeMountPoint, $result);
245 }, $results);
246 }, array_values($resultsPerCache), array_keys($resultsPerCache)));
247
248 // don't include this folder in the results
249 $files = array_filter($files, function (FileInfo $file) {
250 return $file->getPath() !== $this->getPath();
251 });
252
253 // since results were returned per-cache, they are no longer fully sorted
254 $order = $query->getOrder();
255 if ($order) {
256 usort($files, function (FileInfo $a, FileInfo $b) use ($order) {
257 foreach ($order as $orderField) {
258 $cmp = $orderField->sortFileInfo($a, $b);
259 if ($cmp !== 0) {
260 return $cmp;
261 }
262 }
263 return 0;
264 });
265 }
266
267 return array_map(function (FileInfo $file) {
268 return $this->createNode($file->getPath(), $file);
269 }, $files);
270 }
The output of your config.php file:
<?php
$CONFIG = array (
'memcache.local' => '\\OC\\Memcache\\APCu',
'datadirectory' => '/data',
'trusted_proxies' =>
array (
0 => 'swag',
),
'overwritewebroot' => '/nextcloud',
'overwrite.cli.url' => 'https://xxxx/nextcloud',
'trusted_domains' =>
array (
0 => 'xxxx',
1 => 'localhost',
2 => '192.168.1.25',
),
'instanceid' => 'ocmke58vu0cb',
'passwordsalt' => 'rYdWyq8CoYUcorAKjPqt161XkddHir',
'secret' => '4RbRv5fjXiGTHBGeDUxy3X9J5YcVxO369CzpbZ4whRH3J7x5',
'dbtype' => 'mysql',
'version' => '26.0.2.1',
'dbname' => 'nextcloud',
'dbhost' => 'nextclouddb',
'dbport' => '',
'dbtableprefix' => 'oc_',
'mysql.utf8mb4' => true,
'dbuser' => 'oc_admin',
'dbpassword' => '[9G86rR]7PuU<erbb503tZ*B8+*U&3',
'installed' => true,
'memories.exiftool' => '/config/www/nextcloud/apps/memories/exiftool-bin/exiftool-aarch64-musl',
'memories.vod.path' => '/config/www/nextcloud/apps/memories/exiftool-bin/go-vod-aarch64',
'memories.vod.ffmpeg' => '/usr/bin/ffmpeg',
'memories.vod.ffprobe' => '/usr/bin/ffprobe',
'updater.secret' => '$2y$10$eEIXuk1jEyuhHHCg5B.1Be8qpnNeWeduV1LR0sL76Fzz/KOUOm8Tu',
'mail_from_address' => 'x',
'mail_smtpmode' => 'smtp',
'mail_sendmailmode' => 'smtp',
'mail_domain' => 'xxxx',
'mail_smtpsecure' => 'ssl',
'mail_smtphost' => 'mail.ncf.ca',
'mail_smtpport' => '465',
'mail_smtpauth' => 1,
'mail_smtpname' => 'xxxxx',
'mail_smtppassword' => 'xxxxx',
'default_phone_region' => 'CA',
'maintenance' => false,
'loglevel' => 2,
);
~
The output of your Apache/nginx/system log in /var/log/____
:
(not sure where to find this):
find . -type f -name "system.log"
find: ‘./lost+found’: Permission denied
find: ‘./docker’: Permission denied
find: ‘./appdata/nextclouddb/databases/performance_schema’: Permission denied
find: ‘./appdata/nextclouddb/databases/mysql’: Permission denied
find: ‘./appdata/nextclouddb/databases/sys’: Permission denied
find: ‘./appdata/nextclouddb/databases/nextcloud’: Permission denied
find: ‘./appdata/swag/etc/letsencrypt/archive’: Permission denied
find: ‘./appdata/swag/etc/letsencrypt/live’: Permission denied
find: ‘./appdata/swag/etc/letsencrypt/accounts’: Permission denied
Output errors in nextcloud.log in /var/www/ or as admin user in top right menu, filtering for errors. Use a pastebin service if necessary.
{"reqId":"ILkxADsYLFau4URcQRmG","level":3,"time":"2023-05-15T21:55:01+00:00","remoteAddr":"","user":"--","app":"cron","method":"","url":"/nextcloud/cron.php","message":"Not installed","userAgent":"--","version":"","exception":{"Exception":"Exception","Message":"Not installed","Code":0,"Trace":[{"file":"/config/www/nextcloud/lib/base.php","line":697,"function":"checkInstalled","class":"OC","type":"::"},{"file":"/config/www/nextcloud/lib/base.php","line":1165,"function":"init","class":"OC","type":"::"},{"file":"/config/www/nextcloud/cron.php","line":43,"args":["/config/www/nextcloud/lib/base.php"],"function":"require_once"}],"File":"/config/www/nextcloud/lib/base.php","Line":281,"CustomMessage":"--"}}
{"reqId":"a6HXQM25qqx4oTFT2Tbs","level":3,"time":"2023-05-15T22:00:01+00:00","remoteAddr":"","user":"--","app":"cron","method":"","url":"/nextcloud/cron.php","message":"Not installed","userAgent":"--","version":"26.0.1.1","exception":{"Exception":"Exception","Message":"Not installed","Code":0,"Trace":[{"file":"/config/www/nextcloud/lib/base.php","line":697,"function":"checkInstalled","class":"OC","type":"::"},{"file":"/config/www/nextcloud/lib/base.php","line":1165,"function":"init","class":"OC","type":"::"},{"file":"/config/www/nextcloud/cron.php","line":43,"args":["/config/www/nextcloud/lib/base.php"],"function":"require_once"}],"File":"/config/www/nextcloud/lib/base.php","Line":281,"CustomMessage":"--"}}
{"reqId":"DELRi8b2f4wuezvad93t","level":2,"time":"2023-05-16T12:35:47+00:00","remoteAddr":"192.168.1.1","user":"--","app":"core","method":"PROPFIND","url":"/nextcloud/remote.php/dav/files/Ray/","message":"Login failed: 'Ray' (Remote IP: '192.168.1.1')","userAgent":"Mozilla/5.0 (Windows) mirall/3.8.1stable-Win64 (build 20230419) (Nextcloud, windows-10.0.22621 ClientArchitecture: x86_64 OsArchitecture: x86_64)","version":"26.0.1.1","data":{"app":"core"}}
{"reqId":"TigB4GpIcB17njqC3Jpd","level":2,"time":"2023-05-16T12:35:47+00:00","remoteAddr":"192.168.1.1","user":"--","app":"core","method":"PROPFIND","url":"/nextcloud/remote.php/dav/files/Ray/","message":"Login failed: 'Ray' (Remote IP: '192.168.1.1')","userAgent":"Mozilla/5.0 (Windows) mirall/3.8.1stable-Win64 (build 20230419) (Nextcloud, windows-10.0.22621 ClientArchitecture: x86_64 OsArchitecture: x86_64)","version":"26.0.1.1","data":{"app":"core"}}
Any help appreciated,
Ray