Samba

Check Samba Server

Check its running with:

     >ps -few | grep mbd
     root       262     1  0 Jun21 ?        00:00:01 /usr/sbin/nmbd -D
     root       264   262  0 Jun21 ?        00:00:00 /usr/sbin/nmbd -D
     root       265     1  0 Jun21 ?        00:00:00 /usr/sbin/smbd -D
   

Check Samba Client

To check you can see your samba server, under XP use the command: net view

Install

See the "Unofficial Samba How-To"

Samba as a domain controller

To add a machine under XP you will need to enable the root user under samba. Give it a different smb password: smbpasswd -a root
(Note, under XP you get login failure if you don't enable the root user in samba)

Under XP you will also need to set the following attributes:
HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services\Netlogon\Parameters
"requiresignorseal"=dword:00000000 (from dword:00000001)
"signsecurechannel"=dword:00000000 (from dword:00000001)
using the command: regedit

Add a Computer

Create a unix account for the compuater called machineName. vipw
     machineName$:x:uid:gid:Machine Description:/nonexistent:/bin/false
    
gid = common samba workstation group (smbhost)
don't forget to add a line to shadow (vipw -s)
smbpasswd -m -a machineName
When adding the computer from windows you will br prompted for a user in the domain, you have to use 'root', which must have been added to samba

Add User

Add the user to the unix system (adduser)
Do a man on smbpasswd
To add a user:
     smbpasswd -a new-user-name
   

Samba printer config

Install the cupsys-bsd package.
Check you can print to your printer using: lpr -P'your-printer-name' 'file-name'
Setup printers in your smb.conf, e.g.:
       [hp-raw]
           comment = HP 970Cxi printer on Linux (PPA input)
           path = /tmp
           printer name = hp
           writable = yes  
           public = yes
           printable = yes 
           print command = lpr -l -r -h -P %p %s
       
       [hp-ps]
           comment = HP 970Cxi printer on Linux (Postscript input)
           path = /tmp
           printer name = hp
           writable = yes
           public = yes
           printable = yes
           print command = lpr -r -h -P %p %s 
    
Add the printer as an administrator (I prefer the raw printer as you can then use the windows driver)