user_ldap icon indicating copy to clipboard operation
user_ldap copied to clipboard

Transfer users local to users ldap

Open wixaw opened this issue 7 years ago • 8 comments

Hi I wish migrate users local to users ldap. But if user exist, a new user is created with firstname.name_1234 id. How can I transfer our users ?

Thank you in advance

wixaw avatar Mar 09 '18 07:03 wixaw

Any idea please ?

wixaw avatar May 22 '18 14:05 wixaw

Create a new user in LDAP and sync the user with "occ user:sync", then use the "occ files:transfer-ownership" command to migrate the files to the new account.

Note that not everything will be migrated by this command.

There is currently no support for converting user accounts directly between backends. I heard some discussion about this lately but not sure if there are tickets for that yet @butonic

PVince81 avatar May 22 '18 15:05 PVince81

Thank's @PVince81 We have a special use of local user, they only have access to the files shared with them. Does the "occ files:transfer-ownership" command also synchronize the shares?

Thanks

wixaw avatar Jul 17 '18 07:07 wixaw

the "occ files:transfer-ownership" also transfers outgoing user shares and public link shares. Not incoming shares.

PVince81 avatar Jul 17 '18 10:07 PVince81

Hello, I'm working on this migration again. I have owncloud 10.0.10 in production. When you say "Not incoming shares" you mean: not what is in the oc_share table with the share_with attribute? If so, it's a shame, it's exactly the function I need

wixaw avatar Nov 05 '18 12:11 wixaw

I have managed to transfer most of my user accounts into an LDAP server using the attached script. Use at your own risk and make sure you have backups

owncloud-to-ldap.txt

troyrollo avatar Oct 03 '21 11:10 troyrollo

thank you so much @troyrollo what versions of oc and ldap plugin did you do this with? in case the tables are not the same

wixaw avatar Oct 04 '21 06:10 wixaw

10.8

troyrollo avatar Oct 04 '21 06:10 troyrollo