Author Topic: AD sync only transfers some users  (Read 5006 times)

technema

  • Zen Apprentice
  • *
  • Posts: 19
  • Karma: +0/-0
    • View Profile
Re: AD sync only transfers some users
« Reply #15 on: February 11, 2010, 02:39:48 pm »
It does work. You have a group over 32 characters and maybe that's just some arbitrary limit or something, for compatibility reasons, with older versions of Windows Server. Maybe it's to be compliant with older Linux Samba versions. The main thing is, if Windows Server has no 32-character limitation, then there should be a checkbox somewhere to enable or disable the 32-character limit.

Ok but this group is created by Windows at the installation ...

Thx for you help by the way  :)

pixeldrift

  • Zen Apprentice
  • *
  • Posts: 6
  • Karma: +0/-0
    • View Profile
Re: AD sync only transfers some users
« Reply #16 on: February 11, 2010, 09:56:28 pm »
Ok, I fixed the initial error by editing /usr/share/perl5/EBox/UsersAndGroups.pm and set MAXGROUPLENGTH to be 40. However, now it is giving another one:

Quote
2010/02/11 14:45:12 DEBUG> ebox-ad-sync:296 main::getPrincipalName - [ad-sync] can't get userPrincipalName for...

And it says that about a number of users. Still now change otherwise, I still am only getting the same few users imported as before. Not sure what would be causing this. Thoughts?

technema

  • Zen Apprentice
  • *
  • Posts: 19
  • Karma: +0/-0
    • View Profile
Re: AD sync only transfers some users
« Reply #17 on: February 12, 2010, 12:34:39 am »
Ok, I fixed the initial error by editing /usr/share/perl5/EBox/UsersAndGroups.pm and set MAXGROUPLENGTH to be 40. However, now it is giving another one:

Quote
2010/02/11 14:45:12 DEBUG> ebox-ad-sync:296 main::getPrincipalName - [ad-sync] can't get userPrincipalName for...

And it says that about a number of users. Still now change otherwise, I still am only getting the same few users imported as before. Not sure what would be causing this. Thoughts?

Exactly the same issue ...

oinadmin

  • Zen Apprentice
  • *
  • Posts: 7
  • Karma: +0/-0
    • View Profile
Re: AD sync only transfers some users
« Reply #18 on: February 18, 2010, 01:02:48 pm »
I have the same error, help please!
« Last Edit: February 18, 2010, 01:10:21 pm by oinadmin »

Saturn2888

  • Zen Hero
  • *****
  • Posts: 707
  • Karma: +1/-0
    • View Profile
Re: AD sync only transfers some users
« Reply #19 on: February 18, 2010, 05:50:20 pm »
You might have to change another value which is also a fixed-char variable.

per

  • Zen Apprentice
  • *
  • Posts: 1
  • Karma: +0/-0
    • View Profile
Re: AD sync only transfers some users
« Reply #20 on: February 22, 2010, 08:15:00 pm »
Hi.
I had the problem with groups lenght. changed UsersAndGroups.pm now i have the error:
Invalid value for group name: Grupo de acceso de autorización de windows.
I think the problem is the "ó".
The group cannot be changed o deleted in AD.

Hope someone can help me.

technema

  • Zen Apprentice
  • *
  • Posts: 19
  • Karma: +0/-0
    • View Profile
Re: AD sync only transfers some users
« Reply #21 on: February 23, 2010, 06:16:35 pm »
Ok, I fixed the initial error by editing /usr/share/perl5/EBox/UsersAndGroups.pm and set MAXGROUPLENGTH to be 40. However, now it is giving another one:

Quote
2010/02/11 14:45:12 DEBUG> ebox-ad-sync:296 main::getPrincipalName - [ad-sync] can't get userPrincipalName for...

And it says that about a number of users. Still now change otherwise, I still am only getting the same few users imported as before. Not sure what would be causing this. Thoughts?

Exactly the same issue ...

I have found this on the trac : http://trac.ebox-platform.com/changeset/14955

Issue is here, in the function getPrincipalName() ...

jacalvo, please help !!!

Thx

J. A. Calvo

  • Zentyal Staff
  • Zen Hero
  • *****
  • Posts: 1986
  • Karma: +67/-3
    • View Profile
    • http://blogs.zentyal.org/jacalvo
Re: AD sync only transfers some users
« Reply #22 on: February 24, 2010, 12:39:35 am »
It is already fixed on the svn, and a new package will be released very soon.

In the meanwhile, you can download the fixed file from:

http://trac.ebox-platform.com/export/16907/trunk/client/usersandgroups/tools/ebox-ad-sync

And copy it to /usr/share/ebox-usersandgroups/

Hope this helps!
Zentyal Server Lead Developer

technema

  • Zen Apprentice
  • *
  • Posts: 19
  • Karma: +0/-0
    • View Profile
Re: AD sync only transfers some users
« Reply #23 on: February 24, 2010, 09:51:25 am »
It is already fixed on the svn, and a new package will be released very soon.

In the meanwhile, you can download the fixed file from:

http://trac.ebox-platform.com/export/16907/trunk/client/usersandgroups/tools/ebox-ad-sync

And copy it to /usr/share/ebox-usersandgroups/

Hope this helps!

Thx a lot, it seems to work. I have always some errors in the logs but my users are now in the groups  8)

For the issue with accented characters in UsersAndGroups.pm, i think the problem is in the regexp in the function sub _checkName. i have to change it :
Quote
$name =~ /^.*$/

J. A. Calvo

  • Zentyal Staff
  • Zen Hero
  • *****
  • Posts: 1986
  • Karma: +67/-3
    • View Profile
    • http://blogs.zentyal.org/jacalvo
Re: AD sync only transfers some users
« Reply #24 on: February 24, 2010, 12:01:48 pm »
For the issue with accented characters in UsersAndGroups.pm, i think the problem is in the regexp in the function sub _checkName. i have to change it :
Quote
$name =~ /^.*$/

I'm not sure if this is correct, the usernames shouldn't be accented in UNIX, have a look at this:

Code: [Select]
# adduser fóòô
adduser: To avoid problems, the username should consist only of
letters, digits, underscores, periods, at signs and dashes, and not start with
a dash (as defined by IEEE Std 1003.1-2001).
Zentyal Server Lead Developer

technema

  • Zen Apprentice
  • *
  • Posts: 19
  • Karma: +0/-0
    • View Profile
Re: AD sync only transfers some users
« Reply #25 on: February 24, 2010, 12:35:05 pm »
For the issue with accented characters in UsersAndGroups.pm, i think the problem is in the regexp in the function sub _checkName. i have to change it :
Quote
$name =~ /^.*$/

I'm not sure if this is correct, the usernames shouldn't be accented in UNIX, have a look at this:

Code: [Select]
# adduser fóòô
adduser: To avoid problems, the username should consist only of
letters, digits, underscores, periods, at signs and dashes, and not start with
a dash (as defined by IEEE Std 1003.1-2001).

Ok but some groups on Windows Server are accented and created by Windows itself ... so i don't want to remove them.

J. A. Calvo

  • Zentyal Staff
  • Zen Hero
  • *****
  • Posts: 1986
  • Karma: +67/-3
    • View Profile
    • http://blogs.zentyal.org/jacalvo
Re: AD sync only transfers some users
« Reply #26 on: February 24, 2010, 01:03:40 pm »
Ok but some groups on Windows Server are accented and created by Windows itself ... so i don't want to remove them.

Yes, I understand that. But with the current version (the ebox-ad-sync file from the svn repository), the only problem is that a warning appear in the log, isn't it? I mean, the synchronization of the rest of the users and groups works perfect I suppose...
Zentyal Server Lead Developer

technema

  • Zen Apprentice
  • *
  • Posts: 19
  • Karma: +0/-0
    • View Profile
Re: AD sync only transfers some users
« Reply #27 on: February 24, 2010, 02:26:04 pm »
Ok but some groups on Windows Server are accented and created by Windows itself ... so i don't want to remove them.

Yes, I understand that. But with the current version (the ebox-ad-sync file from the svn repository), the only problem is that a warning appear in the log, isn't it? I mean, the synchronization of the rest of the users and groups works perfect I suppose...

Yes, with the new ebox-ad-sync, It syncs with AD, users are in groups etc ... but the passwords don't synchronise. I don't see anything about the passwords in the logs.

J. A. Calvo

  • Zentyal Staff
  • Zen Hero
  • *****
  • Posts: 1986
  • Karma: +67/-3
    • View Profile
    • http://blogs.zentyal.org/jacalvo
Re: AD sync only transfers some users
« Reply #28 on: February 24, 2010, 04:28:12 pm »
Have you reset the passwords you want to synchronize?

As it says in the guide (http://trac.ebox-platform.com/wiki/Document/Documentation/EBoxActiveDirectorySync):
Quote
The passwords for the already existing users will need to be reset in order to synchronize them.
Zentyal Server Lead Developer

technema

  • Zen Apprentice
  • *
  • Posts: 19
  • Karma: +0/-0
    • View Profile
Re: AD sync only transfers some users
« Reply #29 on: February 24, 2010, 04:29:57 pm »
Have you reset the passwords you want to synchronize?

As it says in the guide (http://trac.ebox-platform.com/wiki/Document/Documentation/EBoxActiveDirectorySync):
Quote
The passwords for the already existing users will need to be reset in order to synchronize them.

yes
I can see passwords with the command slapcat but they are encrypted