Access Denied error when Adding printers using the APW... AND MORE!!!

Paul Huff phuff at et.byu.edu
Mon Jun 11 17:22:08 GMT 2001


Okay, after pouring over the source for the last week or so, I've figured
out what my problem was....  (I had to add a gazillion DEBUG's to find it
though... :)...)
It's actually a problem with my add printer command...  I didn't know that
you had to output to STDIN the name of the share you're trying to
add... (That's not documented anywhere that I saw...)  Otherwise the code
that's in add_print_hook (line 4166 approximately [I can't remember where
I added all the DEBUG's...) Doesn't hup the daemons and run
add_all_printers()...  I suggest adding some documentation on the add
printer command script in general...  :)

A seemingly unrelated problem is that I can't get any of the shares that
I add in win 2k to be useful in NT 4.0...  They all show up as having 
an invalid printer name...  I've tried adding DEBUG's to everywhere
that ERROR_INVALID_PRINTER_NAME is returned but to no avail.  I was
wondering if anybody knew of another error that show's up as an Invalid
Printername error box in WIN NT 4.0...  I figure it could be a
configuration issue but I'd like to understand exactly what's going wrong
as well...

One more problem I'm having is that no Printers share shows up on my
samba server in NT 4.0, and so I can't add printers using NT... only win
2k...  However, this is probably some kind of configuration issue with
how I've set things up as well...  

> > > Are you connected as root (or a 'printer admin'?)  Do
you have > > > permissions to copy the driver files to [print$]?
> > >
> > Yes... And yes... Even stranger is the fact that once I hit ok on the
> > "Access denied" box it sends me back to the Add Printer Wizard, and I
> > click "finish" again and it goes right through...  No error at all... I've
> > written my "addprinter command" script to be smart enough to check for a
> > share as already being there... so I know it's not adding it a second
> > time...  It almost seems as if it has to do with not reading the config
> > file fast enough... I tried sending a HUP to the daemons from within the
> > script, too, just to make sure they re-read them correctly, but that
> > didn't seem to work either...
> > -Paul
> 






More information about the samba-technical mailing list