[Bug]: Allowed memory size of X bytes exhausted (tried to allocate Y bytes) while running LDAP update groups job
@come-nc is already working on this.
Since Sep 12, 2023.
- Dominant language
- PHP
- Stars
- 36.9k
- Forks
- 5.2k
- Avg merge
- 2d 3h
- Merged PRs (30d)
- 713
Description
⚠️ This issue respects the following points: ⚠️
- This is a bug, not a question or a configuration/webserver/proxy issue.
- This issue is not already reported on Github OR Nextcloud Community Forum (I've searched it).
- Nextcloud Server is up to date. See Maintenance and Release Schedule for supported versions.
- I agree to follow Nextcloud's Code of Conduct.
Bug description
The background job to update LDAP group membership crashes if there are too many users/groups in the LDAP, with a memory exhaustion.
This happens on the first run of the service with https://github.com/juliushaertl/nextcloud-docker-dev , because users are all non-mapped and they get mapped and announced during the job.
It seems to indicate that avatars are read from LDAP but somehow the memory is not freed between each user announce?
In this job we should only have 1 user object in memory at a time, so this is unexpected.
nextcloud_1 | PHP Fatal error: Allowed memory size of 536870912 bytes exhausted (tried to allocate 3145728 bytes) in /var/www/html/lib/private/legacy/OC_Image.php on line 784
nextcloud_1 | PHP Stack trace:
nextcloud_1 | PHP 1. {main}() /var/www/html/cron.php:0
nextcloud_1 | PHP 2. OCP\BackgroundJob\TimedJob->execute($jobList = class OC\BackgroundJob\JobList { protected OCP\IDBConnection $connection = class OC\DB\ConnectionAdapter { private $inner = class OC\DB\Connection { ... } }; protected OCP\IConfig $config = class OC\AllConfig { private OC\SystemConfig $systemConfig = class OC\SystemConfig { ... }; private ?OCP\IDBConnection $connection = class OC\DB\ConnectionAdapter { ... }; private OCP\Cache\CappedMemoryCache $userCache = class OCP\Cache\CappedMemoryCache { ... } }; protected OCP\AppFramework\Utility\ITimeFactory $timeFactory = class OC\AppFramework\Utility\TimeFactory { protected DateTimeZone $timezone = class DateTimeZone { ... } }; protected Psr\Log\LoggerInterface $logger = class OC\Log\PsrLoggerAdapter { private $logger = class OC\Log { ... } } }, $logger = class OC\Log { private OCP\Log\IWriter $logger = class OC\Log\File { protected $logFile = '/var/www/html/data/nextcloud.log'; protected $logFileMode = 416; private $config = class OC\SystemConfig { ... }; private ${OC\Log\LogDetails}config = class OC\SystemConfig { ... } }; private ?OC\SystemConfig $config = class OC\SystemConfig { protected $sensitiveValues = [...]; private $config = class OC\Config { ... } }; private ?bool $logConditionSatisfied = FALSE; private ?Nextcloud\LogNormalizer\Normalizer $normalizer = class Nextcloud\LogNormalizer\Normalizer { private $maxRecursionDepth = 4; private $maxArrayItems = 20; private $dateFormat = 'Y-m-d H:i:s' }; private ?OCP\Support\CrashReport\IRegistry $crashReporters = class OC\Support\CrashReport\Registry { private $lazyReporters = [...]; private $reporters = [...]; private $serverContainer = class OC\Server { ... } }; private ?OCP\EventDispatcher\IEventDispatcher $eventDispatcher = class OC\EventDispatcher\EventDispatcher { private $dispatcher = class Symfony\Component\EventDispatcher\EventDispatcher { ... }; private $container = class OC\Server { ... }; private $logger = class OC\Log\PsrLoggerAdapter { ... } } }) /var/www/html/cron.php:152
nextcloud_1 | PHP 3. OCP\BackgroundJob\TimedJob->start($jobList = class OC\BackgroundJob\JobList { protected OCP\IDBConnection $connection = class OC\DB\ConnectionAdapter { private $inner = class OC\DB\Connection { ... } }; protected OCP\IConfig $config = class OC\AllConfig { private OC\SystemConfig $systemConfig = class OC\SystemConfig { ... }; private ?OCP\IDBConnection $connection = class OC\DB\ConnectionAdapter { ... }; private OCP\Cache\CappedMemoryCache $userCache = class OCP\Cache\CappedMemoryCache { ... } }; protected OCP\AppFramework\Utility\ITimeFactory $timeFactory = class OC\AppFramework\Utility\TimeFactory { protected DateTimeZone $timezone = class DateTimeZone { ... } }; protected Psr\Log\LoggerInterface $logger = class OC\Log\PsrLoggerAdapter { private $logger = class OC\Log { ... } } }) /var/www/html/lib/public/BackgroundJob/TimedJob.php:92
nextcloud_1 | PHP 4. OCP\BackgroundJob\Job->start($jobList = class OC\BackgroundJob\JobList { protected OCP\IDBConnection $connection = class OC\DB\ConnectionAdapter { private $inner = class OC\DB\Connection { ... } }; protected OCP\IConfig $config = class OC\AllConfig { private OC\SystemConfig $systemConfig = class OC\SystemConfig { ... }; private ?OCP\IDBConnection $connection = class OC\DB\ConnectionAdapter { ... }; private OCP\Cache\CappedMemoryCache $userCache = class OCP\Cache\CappedMemoryCache { ... } }; protected OCP\AppFramework\Utility\ITimeFactory $timeFactory = class OC\AppFramework\Utility\TimeFactory { protected DateTimeZone $timezone = class DateTimeZone { ... } }; protected Psr\Log\LoggerInterface $logger = class OC\Log\PsrLoggerAdapter { private $logger = class OC\Log { ... } } }) /var/www/html/lib/public/BackgroundJob/TimedJob.php:102
nextcloud_1 | PHP 5. OCA\User_LDAP\Jobs\UpdateGroups->run($argument = NULL) /var/www/html/lib/public/BackgroundJob/Job.php:81
nextcloud_1 | PHP 6. OCA\User_LDAP\Service\UpdateGroupsService->updateGroups() /var/www/html/apps/user_ldap/lib/Jobs/UpdateGroups.php:59
nextcloud_1 | PHP 7. OCA\User_LDAP\Service\UpdateGroupsService->handleCreatedGroups($createdGroups = [0 => 'Admin staff', 1 => 'Ship crew', 2 => 'Everyone', 3 => 'Accounting', 4 => 'Engineering', 5 => 'Design', 6 => 'UX', 7 => 'Sales', 8 => 'Testing', 9 => 'QA', 10 => 'Sysadmin', 11 => 'HR', 12 => 'Management', 13 => 'Robots 0', 14 => 'Robots 1', 15 => 'Robots 2', 16 => 'Robots 3', 17 => 'Robots 4', 18 => 'Robots 5', 19 => 'Robots 6', 20 => 'Robots 7', 21 => 'Robots 8', 22 => 'Robots 9', 23 => 'Robots 10', 24 => 'Robots 11', 25 => 'Robots 12', 26 => 'Robots 13', 27 => 'Robots 14', 28 => 'Robots 15', 29 => 'Robots 16', 30 => 'Robots 17', 31 => 'Robots 18', 32 => 'Robots 19', 33 => 'Robots 20', 34 => 'Robots 21', 35 => 'Robots 22', 36 => 'Robots 23', 37 => 'Robots 24', 38 => 'Robots 25', 39 => 'Robots 26', 40 => 'Robots 27', 41 => 'Robots 28', 42 => 'Robots 29', 43 => 'Robots 30', 44 => 'Robots 31', 45 => 'Robots 32', 46 => 'Robots 33', 47 => 'Robots 34', 48 => 'Robots 35', 49 => 'Robots 36', 50 => 'Robots 37', 51 => 'Robots 38', 52 => 'Robots 39', 53 => 'Robots 40', 54 => 'Robots 41', 55 => 'Robots 42', 56 => 'Robots 43', 57 => 'Robots 44', 58 => 'Robots 45', 59 => 'Robots 46', 60 => 'Robots 47', 61 => 'Robots 48', 62 => 'Robots 49']) /var/www/html/apps/user_ldap/lib/Service/UpdateGroupsService.php:75
nextcloud_1 | PHP 8. OCA\User_LDAP\Group_Proxy->usersInGroup($gid = 'Robots 3', $search = *uninitialized*, $limit = *uninitialized*, $offset = *uninitialized*) /var/www/html/apps/user_ldap/lib/Service/UpdateGroupsService.php:151
nextcloud_1 | PHP 9. OCA\User_LDAP\Group_LDAP->usersInGroup($gid = 'Robots 3', $search = '', $limit = -1, $offset = 0) /var/www/html/apps/user_ldap/lib/Group_Proxy.php:185
nextcloud_1 | PHP 10. OCA\User_LDAP\Access->dn2username($fdn = 'cn=robotunit3-43,ou=people,dc=planetexpress,dc=com', $ldapName = *uninitialized*) /var/www/html/apps/user_ldap/lib/Group_LDAP.php:923
nextcloud_1 | PHP 11. OCA\User_LDAP\Access->dn2ocname($fdn = 'cn=robotunit3-43,ou=people,dc=planetexpress,dc=com', $ldapName = NULL, $isUser = TRUE, $newlyMapped = *uninitialized*, $record = *uninitialized*) /var/www/html/apps/user_ldap/lib/Access.php:481
nextcloud_1 | PHP 12. OCA\User_LDAP\Access->mapAndAnnounceIfApplicable($mapper = class OCA\User_LDAP\Mapping\UserMapping { private OCP\Support\Subscription\IAssertion $assertion = class OC\Support\Subscription\Assertion { private OCP\Support\Subscription\IRegistry $registry = class OC\Support\Subscription\Registry { ... }; private OCP\L10N\IFactory $l10nFactory = class OC\L10N\Factory { ... }; private OCP\Notification\IManager $notificationManager = class OC\Notification\Manager { ... } }; protected $dbc = class OC\DB\ConnectionAdapter { private $inner = class OC\DB\Connection { ... } }; protected $cache = ['cn=hubert j. farnsworth,ou=people,dc=planetexpress,dc=com' => 'professor', 'cn=hermes conrad,ou=people,dc=planetexpress,dc=com' => 'hermes', 'cn=ship_crew,ou=groups,dc=planetexpress,dc=com' => FALSE, 'cn=philip j. fry,ou=people,dc=planetexpress,dc=com' => 'fry', 'cn=turanga leela,ou=people,dc=planetexpress,dc=com' => 'leela', 'cn=bender bending rodríguez,ou=people,dc=planetexpress,dc=com' => 'bender', 'cn=admin_staff,ou=groups,dc=planetexpress,dc=com' => FALSE, 'cn=cheryl kirsch,ou=people,dc=planetexpress,dc=com' => 'CherylKirsch', 'cn=oda johnston,ou=people,dc=planetexpress,dc=com' => 'OdaJohnston', 'cn=heinz-gunther parsons,ou=people,dc=planetexpress,dc=com' => 'Heinz-GuntherParsons', 'cn=susan bendel,ou=people,dc=planetexpress,dc=com' => 'SusanBendel', 'cn=leopoldine hofmann,ou=people,dc=planetexpress,dc=com' => 'LeopoldineHofmann', 'cn=ramon eickhoff,ou=people,dc=planetexpress,dc=com' => 'RamonEickhoff', 'cn=silvester woods,ou=people,dc=planetexpress,dc=com' => 'SilvesterWoods', 'cn=uwe burghardt,ou=people,dc=planetexpress,dc=com' => 'UweBurghardt', 'cn=horst linn,ou=people,dc=planetexpress,dc=com' => 'HorstLinn', 'cn=kate steinberg,ou=people,dc=planetexpress,dc=com' => 'KateSteinberg', 'cn=marion gebhardt,ou=people,dc=planetexpress,dc=com' => 'MarionGebhardt', 'cn=nurten tolksdorf,ou=people,dc=planetexpress,dc=com' => 'NurtenTolksdorf', 'cn=cengiz crawford,ou=people,dc=planetexpress,dc=com' => 'CengizCrawford', 'cn=francis roberts,ou=people,dc=planetexpress,dc=com' => 'FrancisRoberts', 'cn=stephen link,ou=people,dc=planetexpress,dc=com' => 'StephenLink', 'cn=ingeburg henke,ou=people,dc=planetexpress,dc=com' => 'IngeburgHenke', 'cn=otmar bayer,ou=people,dc=planetexpress,dc=com' => 'OtmarBayer', 'cn=juan wieland,ou=people,dc=planetexpress,dc=com' => 'JuanWieland', 'cn=betti kehrer,ou=people,dc=planetexpress,dc=com' => 'BettiKehrer', 'cn=valeska aschenbrenner,ou=people,dc=planetexpress,dc=com' => 'ValeskaAschenbrenner', 'cn=martine kessler,ou=people,dc=planetexpress,dc=com' => 'MartineKessler', 'cn=brigitte scheerer,ou=people,dc=planetexpress,dc=com' => 'BrigitteScheerer', 'cn=catharina eisenmann,ou=people,dc=planetexpress,dc=com' => 'CatharinaEisenmann', 'cn=laszlo andrews,ou=people,dc=planetexpress,dc=com' => 'LaszloAndrews', 'cn=samantha weyand,ou=people,dc=planetexpress,dc=com' => 'SamanthaWeyand', 'cn=eva-marie grau,ou=people,dc=planetexpress,dc=com' => 'Eva-MarieGrau', 'cn=rabea eichner,ou=people,dc=planetexpress,dc=com' => 'RabeaEichner', 'cn=annerose rucker,ou=people,dc=planetexpress,dc=com' => 'AnneroseRucker', 'cn=bernhard ley,ou=people,dc=planetexpress,dc=com' => 'BernhardLey', 'cn=hans-otto rudolph,ou=people,dc=planetexpress,dc=com' => 'Hans-OttoRudolph', 'cn=robby meusel,ou=people,dc=planetexpress,dc=com' => 'RobbyMeusel', 'cn=irma weitz,ou=people,dc=planetexpress,dc=com' => 'IrmaWeitz', 'cn=nuri hey,ou=people,dc=planetexpress,dc=com' => 'NuriHey', 'cn=imre brix,ou=people,dc=planetexpress,dc=com' => 'ImreBrix', 'cn=priscilla schlichting,ou=people,dc=planetexpress,dc=com' => 'PriscillaSchlichting', 'cn=ingetraud pauls,ou=people,dc=planetexpress,dc=com' => 'IngetraudPauls', 'cn=renata nachtigall,ou=people,dc=planetexpress,dc=com' => 'RenataNachtigall', 'cn=georgine heppner,ou=people,dc=planetexpress,dc=com' => 'GeorgineHeppner', 'cn=leah busch,ou=people,dc=planetexpress,dc=com' => 'LeahBusch', 'cn=anatolij link,ou=people,dc=planetexpress,dc=com' => 'AnatolijLink', 'cn=traugott majewski,ou=people,dc=planetexpress,dc=com' => 'TraugottMajewski', 'cn=melanie woods,ou=people,dc=planetexpress,dc=com' => 'MelanieWoods', 'cn=jens felber,ou=people,dc=planetexpress,dc=com' => 'JensFelber', 'cn=mirco pawlowski,ou=people,dc=planetexpress,dc=com' => 'MircoPawlowski', 'cn=sigurd hubner,ou=people,dc=planetexpress,dc=com' => 'SigurdHubner', 'cn=harold aschenbrenner,ou=people,dc=planetexpress,dc=com' => 'HaroldAschenbrenner', 'cn=imke kupka,ou=people,dc=planetexpress,dc=com' => 'ImkeKupka', 'cn=laila neuber,ou=people,dc=planetexpress,dc=com' => 'LailaNeuber', 'cn=chantal hengst,ou=people,dc=planetexpress,dc=com' => 'ChantalHengst', 'cn=uta wilson,ou=people,dc=planetexpress,dc=com' => 'UtaWilson', 'cn=freia holl,ou=people,dc=planetexpress,dc=com' => 'FreiaHoll', 'cn=christel jasper,ou=people,dc=planetexpress,dc=com' => 'ChristelJasper', 'cn=hulda wolff,ou=people,dc=planetexpress,dc=com' => 'HuldaWolff', 'cn=miroslaw munch,ou=people,dc=planetexpress,dc=com' => 'MiroslawMunch', 'cn=alexander ammon,ou=people,dc=planetexpress,dc=com' => 'AlexanderAmmon', 'cn=franco weinreich,ou=people,dc=planetexpress,dc=com' => 'FrancoWeinreich', 'cn=kordula busing,ou=people,dc=planetexpress,dc=com' => 'KordulaBusing', 'cn=sigmar sedlmeier,ou=people,dc=planetexpress,dc=com' => 'SigmarSedlmeier', 'cn=andres sanders,ou=people,dc=planetexpress,dc=com' => 'AndresSanders', 'cn=melinda graham,ou=people,dc=planetexpress,dc=com' => 'MelindaGraham', 'cn=hertha mohring,ou=people,dc=planetexpress,dc=com' => 'HerthaMohring', 'cn=paulina theil,ou=people,dc=planetexpress,dc=com' => 'PaulinaTheil', 'cn=karlfried grohmann,ou=people,dc=planetexpress,dc=com' => 'KarlfriedGrohmann', 'cn=heini booth,ou=people,dc=planetexpress,dc=com' => 'HeiniBooth', 'cn=eileen frost,ou=people,dc=planetexpress,dc=com' => 'EileenFrost', 'cn=kristin fletcher,ou=people,dc=planetexpress,dc=com' => 'KristinFletcher', 'cn=brandy turner,ou=people,dc=planetexpress,dc=com' => 'BrandyTurner', 'cn=hiltraud hasse,ou=people,dc=planetexpress,dc=com' => 'HiltraudHasse', 'cn=jasmina marx,ou=people,dc=planetexpress,dc=com' => 'JasminaMarx', 'cn=holger menges,ou=people,dc=planetexpress,dc=com' => 'HolgerMenges', 'cn=ingeburg preston,ou=people,dc=planetexpress,dc=com' => 'IngeburgPreston', 'cn=agata bormann,ou=people,dc=planetexpress,dc=com' => 'AgataBormann', 'cn=viktoria grothe,ou=people,dc=planetexpress,dc=com' => 'ViktoriaGrothe', 'cn=mohammed ringel,ou=people,dc=planetexpress,dc=com' => 'MohammedRingel', 'cn=ria walton,ou=people,dc=planetexpress,dc=com' => 'RiaWalton', 'cn=klaus-peter eickhoff,ou=people,dc=planetexpress,dc=com' => 'Klaus-PeterEickhoff', 'cn=sofia kahlert,ou=people,dc=planetexpress,dc=com' => 'SofiaKahlert', 'cn=balthasar hornung,ou=people,dc=planetexpress,dc=com' => 'BalthasarHornung', 'cn=agathe haubler,ou=people,dc=planetexpress,dc=com' => 'AgatheHauBler', 'cn=milos schimmelpfennig,ou=people,dc=planetexpress,dc=com' => 'MilosSchimmelpfennig', 'cn=delores boning,ou=people,dc=planetexpress,dc=com' => 'DeloresBoning', 'cn=heinz dahlmann,ou=people,dc=planetexpress,dc=com' => 'HeinzDahlmann', 'cn=conrad gartner,ou=people,dc=planetexpress,dc=com' => 'ConradGartner', 'cn=luitgard krull,ou=people,dc=planetexpress,dc=com' => 'LuitgardKrull', 'cn=reza wurst,ou=people,dc=planetexpress,dc=com' => 'RezaWurst', 'cn=fredy klocke,ou=people,dc=planetexpress,dc=com' => 'FredyKlocke', 'cn=christina breu,ou=people,dc=planetexpress,dc=com' => 'ChristinaBreu', 'cn=magdalena stober,ou=people,dc=planetexpress,dc=com' => 'MagdalenaStober', 'cn=agathe meixner,ou=people,dc=planetexpress,dc=com' => 'AgatheMeixner', 'cn=sergei schleicher,ou=people,dc=planetexpress,dc=com' => 'SergeiSchleicher', 'cn=mesut kraemer,ou=people,dc=planetexpress,dc=com' => 'MesutKraemer', 'cn=margarete ladwig,ou=people,dc=planetexpress,dc=com' => 'MargareteLadwig', 'cn=giorgio steigerwald,ou=people,dc=planetexpress,dc=com' => 'GiorgioSteigerwald', 'cn=katrin menzel,ou=people,dc=planetexpress,dc=com' => 'KatrinMenzel', 'cn=marie-louise bosch,ou=people,dc=planetexpress,dc=com' => 'Marie-LouiseBosch', 'cn=anne rose,ou=people,dc=planetexpress,dc=com' => 'AnneRose', 'cn=laszlo pongratz,ou=people,dc=planetexpress,dc=com' => 'LaszloPongratz', 'cn=valentin ebner,ou=people,dc=planetexpress,dc=com' => 'ValentinEbner', 'cn=klaus prinz,ou=people,dc=planetexpress,dc=com' => 'KlausPrinz', 'cn=gernot schluter,ou=people,dc=planetexpress,dc=com' => 'GernotSchluter', 'cn=michel buchmann,ou=people,dc=planetexpress,dc=com' => 'MichelBuchmann', 'cn=annekatrin walker,ou=people,dc=planetexpress,dc=com' => 'AnnekatrinWalker', 'cn=marius wunsche,ou=people,dc=planetexpress,dc=com' => 'MariusWunsche', 'cn=beverly behling,ou=people,dc=planetexpress,dc=com' => 'BeverlyBehling', 'cn=hermine brucker,ou=people,dc=planetexpress,dc=com' => 'HermineBrucker', 'cn=imelda reimann,ou=people,dc=planetexpress,dc=com' => 'ImeldaReimann', 'cn=heinz-gunther weidemann,ou=people,dc=planetexpress,dc=com' => 'Heinz-GuntherWeidemann', 'cn=mabel kaufmann,ou=people,dc=planetexpress,dc=com' => 'MabelKaufmann', 'cn=debbie gaul,ou=people,dc=planetexpress,dc=com' => 'DebbieGaul', 'cn=knut schmiedel,ou=people,dc=planetexpress,dc=com' => 'KnutSchmiedel', 'cn=eckart borchert,ou=people,dc=planetexpress,dc=com' => 'EckartBorchert', 'cn=vadim wegener,ou=people,dc=planetexpress,dc=com' => 'VadimWegener', 'cn=tanja thone,ou=people,dc=planetexpress,dc=com' => 'TanjaThone', 'cn=sofie mohring,ou=people,dc=planetexpress,dc=com' => 'SofieMohring', 'cn=desiree rautenberg,ou=people,dc=planetexpress,dc=com' => 'DesireeRautenberg', 'cn=stella hohne,ou=people,dc=planetexpress,dc=com' => 'StellaHohne', 'cn=diethard nies,ou=people,dc=planetexpress,dc=com' => 'DiethardNies', 'cn=elfriede wendel,ou=people,dc=planetexpress,dc=com' => 'ElfriedeWendel', 'cn=theobald sutherland,ou=people,dc=planetexpress,dc=com' => 'TheobaldSutherland', 'cn=wanda buschmann,ou=people,dc=planetexpress,dc=com' => 'WandaBuschmann', 'cn=kara maack,ou=people,dc=planetexpress,dc=com' => 'KaraMaack', ...] }, $fdn = 'cn=robotunit3-43,ou=people,dc=planetexpress,dc=com', $name = 'robotunit3-43', $uuid = '66f2f366-e588-103d-855c-e349803fde27', $isUser = TRUE) /var/www/html/apps/user_ldap/lib/Access.php:582
nextcloud_1 | PHP 13. OC\Hooks\PublicEmitter->emit($scope = '\\OC\\User', $method = 'assignedUserId', $arguments = [0 => 'robotunit3-43']) /var/www/html/apps/user_ldap/lib/Access.php:621
nextcloud_1 | PHP 14. OC\Hooks\BasicEmitter->emit($scope = '\\OC\\User', $method = 'assignedUserId', $arguments = [0 => 'robotunit3-43']) /var/www/html/lib/private/Hooks/PublicEmitter.php:40
nextcloud_1 | PHP 15. call_user_func_array:{/var/www/html/lib/private/Hooks/EmitterTrait.php:105}($callback = class Closure { virtual $closure = "$this->OCA\DAV\{closure}", public $this = class OCA\DAV\HookManager { private $userManager = class OC\User\Manager { ... }; private $syncService = class OCA\DAV\CardDAV\SyncService { ... }; private $usersToDelete = [...]; private $calDav = class OCA\DAV\CalDAV\CalDavBackend { ... }; private $cardDav = class OCA\DAV\CardDAV\CardDavBackend { ... }; private $calendarsToDelete = [...]; private $subscriptionsToDelete = [...]; private $addressBooksToDelete = [...]; private $themingDefaults = class OCP\Defaults { ... } }; public $parameter = ['$uid' => '<required>'] }, $args = [0 => 'robotunit3-43']) /var/www/html/lib/private/Hooks/EmitterTrait.php:105
nextcloud_1 | PHP 16. OCA\DAV\HookManager->OCA\DAV\{closure:/var/www/html/apps/dav/lib/HookManager.php:86-88}($uid = 'robotunit3-43') /var/www/html/lib/private/Hooks/EmitterTrait.php:105
nextcloud_1 | PHP 17. OCA\DAV\HookManager->postCreateUser($params = ['uid' => 'robotunit3-43']) /var/www/html/apps/dav/lib/HookManager.php:87
nextcloud_1 | PHP 18. OCA\DAV\CardDAV\SyncService->updateUser($user = class OC\User\User { protected $accountManager = NULL; private $uid = 'robotunit3-43'; private $displayName = 'robotunit3-43'; private $backend = class OCA\User_LDAP\User_Proxy { private array $backends = [...]; private ?OCA\User_LDAP\User_LDAP $refBackend = class OCA\User_LDAP\User_LDAP { ... }; private bool $isSetUp = TRUE; private OCA\User_LDAP\Helper $helper = class OCA\User_LDAP\Helper { ... }; private OCP\IConfig $ocConfig = class OC\AllConfig { ... }; private OCP\Notification\IManager $notificationManager = class OC\Notification\Manager { ... }; private OCP\IUserSession $userSession = class OC\User\Session { ... }; private OCA\User_LDAP\UserPluginManager $userPluginManager = class OCA\User_LDAP\UserPluginManager { ... }; private Psr\Log\LoggerInterface $logger = class OC\AppFramework\ScopedPsrLogger { ... }; private OCA\User_LDAP\User\DeletedUsersIndex $deletedUsersIndex = class OCA\User_LDAP\User\DeletedUsersIndex { ... }; private OCA\User_LDAP\ILDAPWrapper ${OCA\User_LDAP\Proxy}ldap = class OCA\User_LDAP\LDAP { ... }; private ?bool ${OCA\User_LDAP\Proxy}isSingleBackend = TRUE; private ?OCP\ICache ${OCA\User_LDAP\Proxy}cache = class OC\Memcache\ProfilerWrapperCache { ... }; private OCA\User_LDAP\AccessFactory ${OCA\User_LDAP\Proxy}accessFactory = class OCA\User_LDAP\AccessFactory { ... } }; private $dispatcher = class OC\EventDispatcher\EventDispatcher { private $dispatcher = class Symfony\Component\EventDispatcher\EventDispatcher { ... }; private $container = class OC\Server { ... }; private $logger = class OC\Log\PsrLoggerAdapter { ... } }; private $enabled = TRUE; private $emitter = class OC\User\Manager { private $backends = [...]; private $cachedUsers = [...]; private $config = class OC\AllConfig { ... }; private $cache = class OC\Memcache\WithLocalCache { ... }; private $eventDispatcher = class OC\EventDispatcher\EventDispatcher { ... }; private OC\User\DisplayNameCache $displayNameCache = class OC\User\DisplayNameCache { ... }; protected $listeners = [...] }; private $home = NULL; private $lastLogin = NULL; private $config = class OC\AllConfig { private OC\SystemConfig $systemConfig = class OC\SystemConfig { ... }; private ?OCP\IDBConnection $connection = class OC\DB\ConnectionAdapter { ... }; private OCP\Cache\CappedMemoryCache $userCache = class OCP\Cache\CappedMemoryCache { ... } }; private $avatarManager = class OC\Avatar\AvatarManager { private $userSession = class OC\User\Session { ... }; private $userManager = class OC\User\Manager { ... }; private $appData = class OC\Files\AppData\AppData { ... }; private $l = class OC\L10N\LazyL10N { ... }; private $logger = class OC\Log\PsrLoggerAdapter { ... }; private $config = class OC\AllConfig { ... }; private $accountManager = class OC\Accounts\AccountManager { ... }; private $knownUserService = class OC\KnownUser\KnownUserService { ... } }; private $urlGenerator = class OC\URLGenerator { private $config = class OC\AllConfig { ... }; public $userSession = class OC\User\Session { ... }; private $cacheFactory = class OC\Memcache\Factory { ... }; private $request = class OC\AppFramework\Http\Request { ... }; private $router = class OC\Route\CachingRouter { ... }; private $baseUrl = NULL; private ?OCP\App\IAppManager $appManager = NULL } }) /var/www/html/apps/dav/lib/HookManager.php:108
nextcloud_1 | PHP 19. OCA\DAV\CardDAV\SyncService->atomic($fn = class Closure { virtual $closure = "$this->OCA\DAV\CardDAV\{closure}", public $static = ['addressBookId' => '1', 'cardId' => 'LDAP:robotunit3-43.vcf', 'user' => class OC\User\User { ... }]; public $this = class OCA\DAV\CardDAV\SyncService { private OCA\DAV\CardDAV\CardDavBackend $backend = class OCA\DAV\CardDAV\CardDavBackend { ... }; private OCP\IUserManager $userManager = class OC\User\Manager { ... }; private OCP\IDBConnection $dbConnection = class OC\DB\ConnectionAdapter { ... }; private Psr\Log\LoggerInterface $logger = class OC\AppFramework\ScopedPsrLogger { ... }; private ?array $localSystemAddressBook = [...]; private OCA\DAV\CardDAV\Converter $converter = class OCA\DAV\CardDAV\Converter { ... }; protected string $certPath = '' } }, $db = class OC\DB\ConnectionAdapter { private $inner = class OC\DB\Connection { protected $tablePrefix = 'oc_'; protected $adapter = class OC\DB\AdapterMySQL { ... }; private $systemConfig = class OC\SystemConfig { ... }; private Psr\Log\LoggerInterface $logger = class OC\Log\PsrLoggerAdapter { ... }; protected $lockedTable = NULL; protected $queriesBuilt = 8303; protected $queriesExecuted = 24353; protected $dbDataCollector = class OC\DB\DbDataCollector { ... }; protected $_conn = class Doctrine\DBAL\Driver\PDO\Connection { ... }; protected $_config = class Doctrine\DBAL\Configuration { ... }; protected $_eventManager = class Doctrine\Common\EventManager { ... }; protected $_expr = class Doctrine\DBAL\Query\Expression\ExpressionBuilder { ... }; private ${Doctrine\DBAL\Connection}autoCommit = TRUE; private ${Doctrine\DBAL\Connection}transactionNestingLevel = 1; private ${Doctrine\DBAL\Connection}transactionIsolationLevel = 2; private ${Doctrine\DBAL\Connection}nestTransactionsWithSavepoints = FALSE; private ${Doctrine\DBAL\Connection}params = [...]; private ${Doctrine\DBAL\Connection}platform = class Doctrine\DBAL\Platforms\MariaDb1027Platform { ... }; private ${Doctrine\DBAL\Connection}exceptionConverter = NULL; private ${Doctrine\DBAL\Connection}parser = class Doctrine\DBAL\SQL\Parser { ... }; protected $_schemaManager = NULL; protected $_driver = class Doctrine\DBAL\Driver\PDO\MySQL\Driver { ... }; private ${Doctrine\DBAL\Connection}isRollbackOnly = FALSE } }) /var/www/html/apps/dav/lib/CardDAV/SyncService.php:244
nextcloud_1 | PHP 20. OCA\DAV\CardDAV\SyncService->OCA\DAV\CardDAV\{closure:/var/www/html/apps/dav/lib/CardDAV/SyncService.php:229-244}() /var/www/html/lib/public/AppFramework/Db/TTransactional.php:63
nextcloud_1 | PHP 21. OCA\DAV\CardDAV\Converter->createCardFromUser($user = class OC\User\User { protected $accountManager = NULL; private $uid = 'robotunit3-43'; private $displayName = 'robotunit3-43'; private $backend = class OCA\User_LDAP\User_Proxy { private array $backends = [...]; private ?OCA\User_LDAP\User_LDAP $refBackend = class OCA\User_LDAP\User_LDAP { ... }; private bool $isSetUp = TRUE; private OCA\User_LDAP\Helper $helper = class OCA\User_LDAP\Helper { ... }; private OCP\IConfig $ocConfig = class OC\AllConfig { ... }; private OCP\Notification\IManager $notificationManager = class OC\Notification\Manager { ... }; private OCP\IUserSession $userSession = class OC\User\Session { ... }; private OCA\User_LDAP\UserPluginManager $userPluginManager = class OCA\User_LDAP\UserPluginManager { ... }; private Psr\Log\LoggerInterface $logger = class OC\AppFramework\ScopedPsrLogger { ... }; private OCA\User_LDAP\User\DeletedUsersIndex $deletedUsersIndex = class OCA\User_LDAP\User\DeletedUsersIndex { ... }; private OCA\User_LDAP\ILDAPWrapper ${OCA\User_LDAP\Proxy}ldap = class OCA\User_LDAP\LDAP { ... }; private ?bool ${OCA\User_LDAP\Proxy}isSingleBackend = TRUE; private ?OCP\ICache ${OCA\User_LDAP\Proxy}cache = class OC\Memcache\ProfilerWrapperCache { ... }; private OCA\User_LDAP\AccessFactory ${OCA\User_LDAP\Proxy}accessFactory = class OCA\User_LDAP\AccessFactory { ... } }; private $dispatcher = class OC\EventDispatcher\EventDispatcher { private $dispatcher = class Symfony\Component\EventDispatcher\EventDispatcher { ... }; private $container = class OC\Server { ... }; private $logger = class OC\Log\PsrLoggerAdapter { ... } }; private $enabled = TRUE; private $emitter = class OC\User\Manager { private $backends = [...]; private $cachedUsers = [...]; private $config = class OC\AllConfig { ... }; private $cache = class OC\Memcache\WithLocalCache { ... }; private $eventDispatcher = class OC\EventDispatcher\EventDispatcher { ... }; private OC\User\DisplayNameCache $displayNameCache = class OC\User\DisplayNameCache { ... }; protected $listeners = [...] }; private $home = NULL; private $lastLogin = NULL; private $config = class OC\AllConfig { private OC\SystemConfig $systemConfig = class OC\SystemConfig { ... }; private ?OCP\IDBConnection $connection = class OC\DB\ConnectionAdapter { ... }; private OCP\Cache\CappedMemoryCache $userCache = class OCP\Cache\CappedMemoryCache { ... } }; private $avatarManager = class OC\Avatar\AvatarManager { private $userSession = class OC\User\Session { ... }; private $userManager = class OC\User\Manager { ... }; private $appData = class OC\Files\AppData\AppData { ... }; private $l = class OC\L10N\LazyL10N { ... }; private $logger = class OC\Log\PsrLoggerAdapter { ... }; private $config = class OC\AllConfig { ... }; private $accountManager = class OC\Accounts\AccountManager { ... }; private $knownUserService = class OC\KnownUser\KnownUserService { ... } }; private $urlGenerator = class OC\URLGenerator { private $config = class OC\AllConfig { ... }; public $userSession = class OC\User\Session { ... }; private $cacheFactory = class OC\Memcache\Factory { ... }; private $request = class OC\AppFramework\Http\Request { ... }; private $router = class OC\Route\CachingRouter { ... }; private $baseUrl = NULL; private ?OCP\App\IAppManager $appManager = NULL } }) /var/www/html/apps/dav/lib/CardDAV/SyncService.php:232
nextcloud_1 | PHP 22. OCA\DAV\CardDAV\Converter->getAvatarImage($user = class OC\User\User { protected $accountManager = NULL; private $uid = 'robotunit3-43'; private $displayName = 'robotunit3-43'; private $backend = class OCA\User_LDAP\User_Proxy { private array $backends = [...]; private ?OCA\User_LDAP\User_LDAP $refBackend = class OCA\User_LDAP\User_LDAP { ... }; private bool $isSetUp = TRUE; private OCA\User_LDAP\Helper $helper = class OCA\User_LDAP\Helper { ... }; private OCP\IConfig $ocConfig = class OC\AllConfig { ... }; private OCP\Notification\IManager $notificationManager = class OC\Notification\Manager { ... }; private OCP\IUserSession $userSession = class OC\User\Session { ... }; private OCA\User_LDAP\UserPluginManager $userPluginManager = class OCA\User_LDAP\UserPluginManager { ... }; private Psr\Log\LoggerInterface $logger = class OC\AppFramework\ScopedPsrLogger { ... }; private OCA\User_LDAP\User\DeletedUsersIndex $deletedUsersIndex = class OCA\User_LDAP\User\DeletedUsersIndex { ... }; private OCA\User_LDAP\ILDAPWrapper ${OCA\User_LDAP\Proxy}ldap = class OCA\User_LDAP\LDAP { ... }; private ?bool ${OCA\User_LDAP\Proxy}isSingleBackend = TRUE; private ?OCP\ICache ${OCA\User_LDAP\Proxy}cache = class OC\Memcache\ProfilerWrapperCache { ... }; private OCA\User_LDAP\AccessFactory ${OCA\User_LDAP\Proxy}accessFactory = class OCA\User_LDAP\AccessFactory { ... } }; private $dispatcher = class OC\EventDispatcher\EventDispatcher { private $dispatcher = class Symfony\Component\EventDispatcher\EventDispatcher { ... }; private $container = class OC\Server { ... }; private $logger = class OC\Log\PsrLoggerAdapter { ... } }; private $enabled = TRUE; private $emitter = class OC\User\Manager { private $backends = [...]; private $cachedUsers = [...]; private $config = class OC\AllConfig { ... }; private $cache = class OC\Memcache\WithLocalCache { ... }; private $eventDispatcher = class OC\EventDispatcher\EventDispatcher { ... }; private OC\User\DisplayNameCache $displayNameCache = class OC\User\DisplayNameCache { ... }; protected $listeners = [...] }; private $home = NULL; private $lastLogin = NULL; private $config = class OC\AllConfig { private OC\SystemConfig $systemConfig = class OC\SystemConfig { ... }; private ?OCP\IDBConnection $connection = class OC\DB\ConnectionAdapter { ... }; private OCP\Cache\CappedMemoryCache $userCache = class OCP\Cache\CappedMemoryCache { ... } }; private $avatarManager = class OC\Avatar\AvatarManager { private $userSession = class OC\User\Session { ... }; private $userManager = class OC\User\Manager { ... }; private $appData = class OC\Files\AppData\AppData { ... }; private $l = class OC\L10N\LazyL10N { ... }; private $logger = class OC\Log\PsrLoggerAdapter { ... }; private $config = class OC\AllConfig { ... }; private $accountManager = class OC\Accounts\AccountManager { ... }; private $knownUserService = class OC\KnownUser\KnownUserService { ... } }; private $urlGenerator = class OC\URLGenerator { private $config = class OC\AllConfig { ... }; public $userSession = class OC\User\Session { ... }; private $cacheFactory = class OC\Memcache\Factory { ... }; private $request = class OC\AppFramework\Http\Request { ... }; private $router = class OC\Route\CachingRouter { ... }; private $baseUrl = NULL; private ?OCP\App\IAppManager $appManager = NULL } }) /var/www/html/apps/dav/lib/CardDAV/Converter.php:58
nextcloud_1 | PHP 23. OC\User\User->getAvatarImage($size = 512) /var/www/html/apps/dav/lib/CardDAV/Converter.php:185
nextcloud_1 | PHP 24. OC\Avatar\Avatar->get($size = 512, $darkTheme = *uninitialized*) /var/www/html/lib/private/User/User.php:583
nextcloud_1 | PHP 25. OC\Avatar\UserAvatar->getFile($size = 512, $darkTheme = FALSE) /var/www/html/lib/private/Avatar/Avatar.php:93
nextcloud_1 | PHP 26. OC\Avatar\Avatar->generateAvatarFromSvg($size = 1024, $darkTheme = FALSE) /var/www/html/lib/private/Avatar/UserAvatar.php:244
nextcloud_1 | PHP 27. OC_Image->loadFromData($str = '�PNG\r\n\032\n\000\000\000\rIHDR\000\000\004\000\000\000\004\000\020\002\000\000\000��`�\000\000\000\004gAMA\000\000��\v�a\005\000\000\000 cHRM\000\000z&\000\000��\000\000�\000\000\000��\000\000u0\000\000�`\000\000:�\000\000\027p��Q<\000\000\000\006bKGD������\tX��\000\000\000\atIME\a�\t\f\a\031\f\027���\000\000\\�IDATx���g����m�S\031�\016C�H\023\024\020�(QQ,�J�D\021\021��l[�1�4�v�l��\030c�Q�؉-�\032��$6b��R���P���\003y��Ύ��5�����\001\017��O�~���҂���\004\000\000\000\000\000�Hz�\001\000\000\000\000\000@�\023\000\000\000\000\000\000 B\002\000\000\000\000\000\000DH\000\000\000\000\000\000�\b\t\000\000\000\000\000\000\020!\001\000\000\000\000\000\000"$\000\000\000\000\000\000@�\004\000\000\000\000\000\000��\000\000\000\000\000\000\000\021\022\000\000\000\000\000\000 B\002\000\000\000\000\000\000DH\000\000\000\000\000\000�\b\t\000\000\000\000\000\000\020!\001\000\000\000\000\000\000"$\000\000\000\000\000\000@�\004\000\000\000\000\000\000��\000\000\000\000\000\000\000\021\022\000\000\000\000\000\000 B\002\000\000\000\000\000\000DH\000\000\000\000\000\000�\b\t\000\000\000\000\000\000\020!\001\000\000\000\000\000\000"$\000\000\000\000\000\000@�\004\000\000\000\000\000\000��\000\000\000\000\000\000\000\021\022\000\000\000\000\000\000 B\002\000\000\000\000\000\000DH\000\000\000\000\000\000�\b\t\000\000\000\000\000\000\020!\001\000\000\000\000\000\000"'...) /var/www/html/lib/private/Avatar/Avatar.php:145
nextcloud_1 | PHP 28. imagecreatefromstring($data = '�PNG\r\n\032\n\000\000\000\rIHDR\000\000\004\000\000\000\004\000\020\002\000\000\000��`�\000\000\000\004gAMA\000\000��\v�a\005\000\000\000 cHRM\000\000z&\000\000��\000\000�\000\000\000��\000\000u0\000\000�`\000\000:�\000\000\027p��Q<\000\000\000\006bKGD������\tX��\000\000\000\atIME\a�\t\f\a\031\f\027���\000\000\\�IDATx���g����m�S\031�\016C�H\023\024\020�(QQ,�J�D\021\021��l[�1�4�v�l��\030c�Q�؉-�\032��$6b��R���P���\003y��Ύ��5�����\001\017��O�~���҂���\004\000\000\000\000\000�Hz�\001\000\000\000\000\000@�\023\000\000\000\000\000\000 B\002\000\000\000\000\000\000DH\000\000\000\000\000\000�\b\t\000\000\000\000\000\000\020!\001\000\000\000\000\000\000"$\000\000\000\000\000\000@�\004\000\000\000\000\000\000��\000\000\000\000\000\000\000\021\022\000\000\000\000\000\000 B\002\000\000\000\000\000\000DH\000\000\000\000\000\000�\b\t\000\000\000\000\000\000\020!\001\000\000\000\000\000\000"$\000\000\000\000\000\000@�\004\000\000\000\000\000\000��\000\000\000\000\000\000\000\021\022\000\000\000\000\000\000 B\002\000\000\000\000\000\000DH\000\000\000\000\000\000�\b\t\000\000\000\000\000\000\020!\001\000\000\000\000\000\000"$\000\000\000\000\000\000@�\004\000\000\000\000\000\000��\000\000\000\000\000\000\000\021\022\000\000\000\000\000\000 B\002\000\000\000\000\000\000DH\000\000\000\000\000\000�\b\t\000\000\000\000\000\000\020!\001\000\000\000\000\000\000"'...) /var/www/html/lib/private/legacy/OC_Image.php:784
Steps to reproduce
- Start https://github.com/juliushaertl/nextcloud-docker-dev with LDAP backend
- Watch the output and log
- Wait for the job to crash
Expected behavior
No crash, memory is freed
Installation method
None
Nextcloud Server version
master
Operating system
None
PHP engine version
None
Web server
None
Database engine version
None
Is this bug present after an update or on a fresh install?
Fresh Nextcloud Server install
Are you using the Nextcloud Server Encryption module?
None
What user-backends are you using?
- Default user-backend (database)
- LDAP/ Active Directory
- SSO - SAML
- Other
Configuration report
No response
List of activated Apps
No response
Nextcloud Signing status
No response
Nextcloud Logs
No response
Additional info
No response
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Assessment
This issue has not been assessed yet.