[Samba] samba-tool classicupgrade (from v3 to v4) aborts with "Unable to get id for sid"

Jon Detert jdetert at infinityhealthcare.com
Tue Apr 2 15:22:15 MDT 2013


> > > From: "Andrew Bartlett" <abartlet at samba.org>
> > > To: "Max Olivas" <molivas at northglenn.org>
> > > Cc: "Jon Detert" <jdetert at infinityhealthcare.com>,
> > > samba at lists.samba.org
> > > Sent: Friday, March 22, 2013 7:01:34 AM
> > > Subject: Re: [Samba] samba-tool classicupgrade (from v3 to v4)
> > > aborts with "Unable to get id for sid"
> > > 
> > > On Thu, 2013-03-21 at 10:15 -0600, Max Olivas wrote:
> > > > >>> On 3/19/2013 at 8:28 AM, in message
> > > > >>> <2119021439.23770729.1363703293922.JavaMail.root at infinityhealthcare.com>,
> > > > >>> Jon Detert <jdetert at infinityhealthcare.com> wrote:
> > > > 
> > > > I'm trying to upgrade from samba3 -> 4.  I ran this command:
> > > > 
> > > > WORKDIR=/usr/local/mobius
> > > > /usr/local/samba/bin/samba-tool domain classicupgrade
> > > > --dbdir=$WORKDIR/var --use-xattrs=yes
> > > > --realm=infinityhealthcare.com $WORKDIR/smb.conf
> > > > 
> > > > but it failed with the error given in this email's subject.
> > > >  What
> > > > does it mean, and how do I fix it?
> > 
> > -- snip --
> > 
> > > The big issue here is that passdb has never had a 'fsck', and
> > > Samba
> > > operates quite well as a 'classic' DC with an almost totally
> > > invalid
> > > database!
> 
> --snip --
> 
> > > As to what has happened in your particular instance, could you
> > > please
> > > post me the output of ldbdump private/idmap.ldb?

-- snip --

> # /home/jdetert/samba4-master/bin/ldbdump
> /usr/local/samba/private/idmap.ldb
> dn: CN=CONFIG
> cn: CONFIG
> upperBound: 4000000
> lowerBound: None
> xidNumber: None
> 
> dn: CN=S-1-5-7
> cn: S-1-5-7
> objectClass: sidMap
> objectSid: S-1-5-7
> type: ID_TYPE_UID
> xidNumber: 65534
> 
> dn: CN=S-1-5-21-4219228698-1431711829-1578001372-500
> cn: S-1-5-21-4219228698-1431711829-1578001372-500
> objectClass: sidMap
> objectSid: S-1-5-21-4219228698-1431711829-1578001372-500
> type: ID_TYPE_UID
> xidNumber: 0
> 
> dn: CN=S-1-5-21-4219228698-1431711829-1578001372-513
> cn: S-1-5-21-4219228698-1431711829-1578001372-513
> objectClass: sidMap
> objectSid: S-1-5-21-4219228698-1431711829-1578001372-513
> type: ID_TYPE_GID
> xidNumber: 100
> 
> dn: @INDEXLIST
> @IDXATTR: xidNumber
> @IDXATTR: objectSid
> 
> #


Still stuck on the same error (shown below).  If I could determine which SIS can't be mapped to an ID, is there something I could do to make the map possible?  E.g. by creating a posix user or group named similarly?

The actual error :
ERROR(<class 'passdb.error'>): uncaught exception - Unable to get id for sid
  File "/usr/local/samba/lib/python2.7/site-packages/samba/netcmd/__init__.py", line 175, in _run
    return self.run(*args, **kwargs)
  File "/usr/local/samba/lib/python2.7/site-packages/samba/netcmd/domain.py", line 1318, in run
    useeadb=eadb, dns_backend=dns_backend, use_ntvfs=use_ntvfs)
  File "/usr/local/samba/lib/python2.7/site-packages/samba/upgrade.py", line 938, in upgrade_from_samba3
    result.names.domaindn, result.lp, use_ntvfs)
  File "/usr/local/samba/lib/python2.7/site-packages/samba/provision/__init__.py", line 1581, in setsysvolacl
    set_gpos_acl(sysvol, dnsdomain, domainsid, domaindn, samdb, lp, use_ntvfs, passdb=s4_passdb)
  File "/usr/local/samba/lib/python2.7/site-packages/samba/provision/__init__.py", line 1511, in set_gpos_acl
    passdb=passdb)
  File "/usr/local/samba/lib/python2.7/site-packages/samba/provision/__init__.py", line 1474, in set_dir_acl
    setntacl(lp, path, acl, domsid, use_ntvfs=use_ntvfs, skip_invalid_chown=True, passdb=passdb, service=service)
  File "/usr/local/samba/lib/python2.7/site-packages/samba/ntacls.py", line 104, in setntacl
    (owner_id, owner_type) = passdb.sid_to_id(sd.owner_sid)



More information about the samba mailing list