Skip to content

[Bug]: occ files:transfer-ownership fails with error "Could not get proper share mount" #33176

@solracsf

Description

@solracsf

⚠️ 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 (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

While transferring ownership of files, it fails with Could not get proper share mount (see below)

Steps to reproduce

  1. Execute OCC command (see below)
  2. Error

Nextcloud Logs

~$ occ files:transfer-ownership --transfer-incoming-shares=1 source.user dest.user

Validating quota
Analysing files of source.user ...
 42778 [============================]
Collecting all share information for files and folders of source.user ...
    9 [============================]
Transferring files to dest.user/files/transferred from source.user on 2022-07-08 17-23-25 ...
Restoring shares ...
Could not restore share with id 29588:Could not get proper share mount for 60602450. Failing since else the next calls are called with null : #0 /lib/private/Share20/Manager.php(972): OC\Share20\Manager->generalCreateChecks()
#1 /apps/files/lib/Service/OwnershipTransferService.php(421): OC\Share20\Manager->updateShare()
#2 /apps/files/lib/Service/OwnershipTransferService.php(185): OCA\Files\Service\OwnershipTransferService->restoreShares()
#3 /apps/files/lib/Command/TransferOwnership.php(150): OCA\Files\Service\OwnershipTransferService->transfer()
#4 /3rdparty/symfony/console/Command/Command.php(255): OCA\Files\Command\TransferOwnership->execute()
#5 /3rdparty/symfony/console/Application.php(1009): Symfony\Component\Console\Command\Command->run()
#6 /3rdparty/symfony/console/Application.php(273): Symfony\Component\Console\Application->doRunCommand()
#7 /3rdparty/symfony/console/Application.php(149): Symfony\Component\Console\Application->doRun()
#8 /lib/private/Console/Application.php(209): Symfony\Component\Console\Application->run()
#9 /console.php(99): OC\Console\Application->run()
#10 /occ(11): require_once('...')
#11 {main}
 1/9 [===>------------------------]  11%Could not restore share with id 33797:Could not get proper share mount for 60218539. Failing since else the next calls are called with null : #0 /lib/private/Share20/Manager.php(972): OC\Share20\Manager->generalCreateChecks()
#1 /apps/files/lib/Service/OwnershipTransferService.php(421): OC\Share20\Manager->updateShare()
#2 /apps/files/lib/Service/OwnershipTransferService.php(185): OCA\Files\Service\OwnershipTransferService->restoreShares()
#3 /apps/files/lib/Command/TransferOwnership.php(150): OCA\Files\Service\OwnershipTransferService->transfer()
#4 /3rdparty/symfony/console/Command/Command.php(255): OCA\Files\Command\TransferOwnership->execute()
#5 /3rdparty/symfony/console/Application.php(1009): Symfony\Component\Console\Command\Command->run()
#6 /3rdparty/symfony/console/Application.php(273): Symfony\Component\Console\Application->doRunCommand()
#7 /3rdparty/symfony/console/Application.php(149): Symfony\Component\Console\Application->doRun()
#8 /lib/private/Console/Application.php(209): Symfony\Component\Console\Application->run()
#9 /console.php(99): OC\Console\Application->run()
#10 /occ(11): require_once('...')
#11 {main}
 9/9 [============================] 100%
Collecting all incoming share information for files and folders of source.user ...
    5 [============================]
Collecting all incoming share information for files and folders of dest.user ...
    1 [============================]
Restoring incoming shares ...
 5/5 [============================] 100%

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions