[Samba] Creating users with non-ascii chars fails (solved)

Roel van Meer roel at 1afa.com
Thu Sep 4 01:43:14 MDT 2014


Marc Muehlfeld writes:

> Am 02.09.2014 14:52, schrieb Roel van Meer:
> > I'm trying to create a user with non-ascii characters in the name, but this
> > fails:
> >
> > root at test-samba4:~# samba-tool user create foa --given-name='foaä'
> > New Password:
> > Retype Password:
> > ldb_handler_fold: unable to casefold string [foaä]
> > ldb_handler_fold: unable to casefold string [foaä]
> > ldb_handler_fold: unable to casefold string [foaä]
> > ldb_handler_fold: unable to casefold string [foaä]
> > Conversion error: Illegal multibyte sequence(ä)
> > ERROR(ldb): Failed to add user 'foa':  - objectclass_attrs: attribute
> > 'displayName' on entry 'CN=foaä,CN=Users,DC=s4,DC=local' contains at
> > least one invalid value!

All right, I figured it out.

The problem here was that I was accessing my s4 server through ssh in an  
xterm, and *that xterm* did not run with an UTF-8 locale setting.

By setting the locale to en_US.UTF-8, starting a new xterm and ssh-ing to  
the s4 server in that xterm, creating a user with non-ascii characters in  
the name works.

Lesson learned: the locale setting of your client matters to the server you  
are connecting to.

Thanks!

Roel


More information about the samba mailing list