I was not able to connect in any way form a windows XP box to a SMB (samba) share hosted on a 10.7 Server. /private/var/log/krb5kdc/kdc.log   showed the following:

2011-10-10T16:57:56 digest-request: init request

2011-10-10T16:57:56 digest-request: init return domain: BUILTIN server: IMGQA-DB

2011-10-10T16:57:56 digest-request: uid=0

2011-10-10T16:57:56 digest-request: user=IMGQA-DB\\qtqa

2011-10-10T16:57:56 NTLM domain not configured

2011-10-10T16:57:56 digest-request: kdc failed with 36150275 proto=unknown

2011-10-10T16:57:56 digest-request: guest failed with 22 proto=ntlmv1-with-v2-session

Here is the fix to this known bug:

sudo serveradmin stop smb

wait a few seconds

sudo serveradmin start smb

If you wish to scrip this you can do the following:

 

sudo su -

cd /System/Library/LaunchDaemons

cat > com.smb.restart_smb.plist <<@@EOF

http://www.apple.com/DTDs/PropertyList-1.0.dtd">

    Label

    com.smb.restart_smb

    ProgramArguments

        /bin/bash

        -c

        sleep 60;serveradmin stop smb;sleep 5;serveradmin start smb

    RunAtLoad   

@@EOF

launchctl load com.smb.restart_smb.plist