The following errors were found while installing Samba-3.0.20b from scratch in a
CentOS 4.1 system (RHEL based).
1 - After compiling successfuly all the samba stuff (--with-expsam=mysql), I go
to /path/to/samba-3.0.20b/examples/pdb/mysql/ and I try to run the specified
mysql.dump to my MySQL server. I've previously set up a user 'samba', owning the
mysql -p -B samba < mysql.dump
This would return me an error about SQL syntax, and after looking at how MySQL
Administrator created this syntax, the way I know MySQL syntax, and the syntax
present in the file, I realized it was all different.
2 - After solving the 1st issue, when creating a user using "pdbedit -a", it
would return me an error about a non-existant field "logon_hours", which happens
not to be in the samba "mysql.dump", so all I had to do was creat it.
3 - smb.conf is not right. there's this ambiguous parameter "passdb backend =
plugin:/usr/local/samba/lib/pdb_mysql.so:mysql", which should be replaced for
"passdb backend = mysql:mysql"
My script and my smb.conf follow in attachment.
Created attachment 1526 [details]
this is the script u ran into my database
Created attachment 1527 [details]
this is a functional smb script for RH based distros
this is a functional smb script for RH based distros, and should be bundled in
the scripts folder for users like me that like to maintain their PDC from
source in RH based systems.
Look at https://bugzilla.samba.org/show_bug.cgi?id=3188, I have a mysql.dump
there that works for me.
@samba-pdbsql: We should get a fixed mysql.dump included into newer Samba releases.
See bug 3375. If someone wants to maintain these modules outside
the Samba source tree, that is fine. But the source has been removed
from the upcoming 3.0.22 release.