Samba + XP Home = Access Denied, unable to connect


Page 1 of 2 12 LastLast
Results 1 to 15 of 18

Thread: Samba + XP Home = Access Denied, unable to connect

  1. #1
    Join Date
    May 2002
    Posts
    1,449

    Samba + XP Home = Access Denied, unable to connect

    I am trying to get my networked computers to share a printer that is hooked up to a debian 3.0r0 printserver running samba and cups. See attached network diagram for more information on my lan's structure. I set the printer up in Windows XP using the wizard and it found the printserver and the attached printer (\\printserv\epson). When I try to print with XP I get the error: "epson on printserv: Access denied, unable to connect". My samba logs show this:

    Code:
    [2003/06/21 03:23:19, 0] printing/printing.c:print_job_start(952)
      print_job_start: insufficient permissions to open spool file /var/spool/cups/s
    mbprn.000234.2tbqId.
    printserv:/var/log/samba# ls -l /var/spool/cups |grep 000234.2tbqId
    printserv:/var/log/samba# ls -l /var/spool |grep cups
    drwx------    3 lp       sys          1024 Jun 21 02:48 cups
    printserv:/var/log/samba#
    From people with a similar samba configuration I learned that the permissions are correctly set /var/spool/cups. Doing a chmod 777 on /var/spool/cups and restarting cups, smbd and nmbd have no effect.

    My /etc/samba/smb.conf is as follows:

    Code:
    [global]
            workgroup = homelan
            security = share
            encrypt passwords = yes
            printing = cups
            printcap name = cups
            load printers = yes
            log file = /var/log/samba/samba-log.%m
            lock directory = /var/log/samba
    
    [printers]
            comment = All Printers
            security = share
            path = /var/spool/cups
            browseable = no
            printable = yes
            read only = yes
            public = yes
            writable = yes
            guest ok = yes
            create mode = 0700
    All machines in question can ping each other. Printing works locally from the printserver and over the lan from the windows 98 machine. People on irc.freenode.net suggest it is most likely a local windows XP spooling issue. All network machines have user accounts and samba accounts on the printserver. Tried adding the following to XP's registery to force a login prompt but no luck there either.

    Code:
    REGEDIT4
    
     [HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Servi
    ces\netlogon\parameters]
    "RequireSignOrSeal"=dword:00000000
    If anyone has any advice on how to fix this or learn more about what is causing the problem please post. This seems to not be a common samba problem and I have found very little information on what to troubleshoot or how to find out more about the fix. If someone could tell me what I did wrong in configuration I would be very thankful.

    EDIT:Spelling and no smilies
    Attached Images Attached Images
    Last edited by Loki3; 07-27-2003 at 07:28 PM.

  2. #2
    Join Date
    Sep 2000
    Location
    Darwin, NT, Australia
    Posts
    156
    Gday,

    We had the same issue here at work with our XP machines ... get an "Unable to connect: Access Denied" error.

    Managed to find post to the Samba lists through a Google search that related to this issue. It invovles setting the "use client driver = yes" option. As described below:

    From smb.conf manual:
    "use client driver (S)

    This parameter applies only to Windows NT/2000 clients. It has no affect on Windows 95/98/ME clients. When serving a printer to Windows NT/2000 clients without first installing a valid printer driver on the Samba host, the client will be required to install a local printer driver. From this point on, the client will treat the print as a local printer and not a network printer connection. This is much the same behavior that will occur when disable spoolss = yes.

    The differentiating factor is that under normal circumstances, the NT/2000 client will attempt to open the network printer using MS-RPC. The problem is that because the client considers the printer to be local, it will attempt to issue the OpenPrinterEx() call requesting access rights associated with the logged on user. If the user possesses local administator rights but not root privilegde on the Samba host (often the case), the OpenPrinterEx() call will fail. The result is that the client will now display an "Access Denied; Unable to connect" message in the printer queue window (even though jobs may successfully be printed).

    If this parameter is enabled for a printer, then any attempt to open the printer with the PRINTER_ACCESS_ADMINISTER right is mapped to PRINTER_ACCESS_USE instead. Thus allowing the OpenPrinterEx() call to succeed. This parameter MUST not be able enabled on a print share which has valid print driver installed on the Samba server.

    See also disable spoolss

    Default: use client driver = no"

    Further reading:

    http://au1.samba.org/samba/docs/man/...SECLIENTDRIVER

    Hope that helps.

    Cya round
    Jinx
    "... and the truth shall set you free"

    ========================
    Two fish are in a tank.
    One says to the other "I'll man the cannon, you drive."

  3. #3
    Join Date
    May 2002
    Posts
    1,449
    Well whatever I did, I am in a much worse position now. Here's what I did to best of my memory:

    1)Added use client driver = yes to /etc/samba/smb.conf
    2)Yah! XP lists printer as "ready"
    3)XP still does not print
    4)Remembers that I'll probably need to run XP's print wizard again
    5)Tries to delete old printer configuration for epson
    6)Nothing happens, tries to add new printer, nothing happens.
    7)Reboot printserver and set bios clock to correct time
    8)In XP:Nothing happens
    9)Try everything to reconfigure XP's printer driver... nothing happens
    10)Check to see if windows 98 still prints... it doesn't
    11)4 hours later XP still lists printer as "deleting"
    12)98 informs me of "There was an error writing to \\printserver\epson... network name cannot be found"
    Code:
    [2003/07/27 15:48:18, 0] smbd/service.c:make_connection(589)
    (192.168.1.102) Can't change directory to 
    /var/spool/cups (Permission denied)
    13)Copy my old semi-working smb.conf from above post into printserver
    14)XP still 'deleting' despite 4.5 hours and twice as many reboots and 98 gives same error message as above

    Can still print from printserver locally and ping all computers on network.

    Currently laying in a fetal position underneath of the desk crying. I'll sort through the mess tomorrow. Any ideas until then are quite welcome. Thanks in advance.
    Last edited by Loki3; 07-28-2003 at 03:52 AM.

  4. #4
    Join Date
    Jul 2003
    Location
    North Port, Fl
    Posts
    115

    How did you add the printer in XP?

    Did you browse the network to add the printer?
    If you did then it won't work.
    What I've noticed since W2K on is that you add the network printer as a a local port i.e; \\fileserver\theprintername
    That has always worked for me. To make you life easier while connecting XP is to disable its firewall until all is working, then re-enable it.

  5. #5
    Join Date
    May 2002
    Posts
    1,449
    XP's firewall is disabled. I did browse the network when I set up XP but I cannot deleted that printer entry, (right click, delete and it just says deleting for 4 hours), if I could delete it I would try again. At this point I'm considering uninstall cups and samba and starting over again because I cannot tell what I did wrong.

  6. #6
    Join Date
    Jul 2003
    Location
    North Port, Fl
    Posts
    115

    Setup the printer again on XP

    Add the printer in XP again, give it a different name, such as pleaseworklaser
    You'll have to load the drivers for it locally.
    When asked whether it is local or net, chose local, add port, type in path \\server\printer\
    or add the printer as if it was plugged into lpt1 and later change the port to \\server\printer, both ways will work.
    This is a Windows problem and I've seen it on non-Linux print servers.
    If cups still works for '98 systems, you don't need to remove and reload.
    To get rid of the ^%^%#@^% printer I think you may have to disconnect from the network, via the control panel, can't remember since I haven't run into this in a while.

    Good Luck!
    Last edited by swiftnet; 07-28-2003 at 04:20 PM.

  7. #7
    Join Date
    May 2002
    Posts
    1,449
    Yah! I got XP to delete the old printer driver by your method! Thank you very much. Tried adding the printer again using both technques but using the location \\printserv\epson resulted in a network path could not be found. I tried to add the printer to XP by setting it up as a network printer and then browsing the network to find the printer's location which apparently was printserv\\printserv\epson. I tried the local printer/switch port method using the new path and it replied with a "path does not exist". Windows 98 still does not work and gives me this error: "There was an error printing to \\printserv\epson... network name not found" Now i am really confused on why 98 no longer prints smb.conf and all cups config files are exatcly the same as when 98 worked. Assuming once again both these problems are problems with the windows machines. Any other ideas? Thanks in advance.

  8. #8
    Join Date
    Jul 2003
    Location
    North Port, Fl
    Posts
    115

    What are the actual names?

    Try this on the Linux box:
    Log in with the account name of the Windows box user
    type in:
    smbclient -L samba_svr_name
    This should list your shares, including the printer.
    What is the share name of the printer via samba?

    I've run into names where they acted as if they were too long for windows, an example was this printer:
    The Linux share was
    //fileserver/hpofficejetG85cxi
    Windows would see it as
    \\fileserver\hpofficejetG
    I had to type in the full path (\\fileserver\hpofficejetG85cxi) even though the share name was truncated when browsing to the server via Windows.

    Please get me the share name info.

    Thanx
    Last edited by swiftnet; 07-29-2003 at 03:23 AM.

  9. #9
    Join Date
    May 2002
    Posts
    1,449
    Code:
    dad@printserv:/home/admin$ smbclient -L \\printserv
    added interface ip=192.168.1.103 bcast=192.168.1.255 nmask=255.255.255.0
    Got a positive name query response from 192.168.1.103 ( 192.168.1.103 )
    Password:
    Domain=[HOMELAN] OS=[Unix] Server=[Samba 2.2.3a-6 for Debian]
    
            Sharename      Type      Comment
            ---------              ----      -------
            IPC$                  IPC       IPC Service (Samba 2.2.3a-6 for Debian)
            ADMIN$             Disk      IPC Service (Samba 2.2.3a-6 for Debian)
            epson              Printer   Local Raw Printer
    
            Server               Comment
            ---------            -------
            PRINTSERV            Samba 2.2.3a-6 for Debian
    
            Workgroup            Master
            ---------            -------
            HOMELAN              PRINTSERV
            MSHOME               DRAGONMISTRESS
    dad@printserv:/home/admin$
    It seems to me that the computer DRAGONMISTRESS (192.168.1.101) is on a different workgroup and that the windows 98 machine isn't even listed. Would a netbios name = *** fix that issue? I have no idea how to get the 98 machine reconized by samba. Many thanks for help.

  10. #10
    Join Date
    Jul 2003
    Location
    North Port, Fl
    Posts
    115

    OK - here are some things to try

    Definitely change the MSHOMW WKGRP to HOMELAN, it'll make browsing easier, of course you'll have to reboot that pc when you change names.

    From Win98: start, run, type in:

    \\printserv

    if it fails to find the shares on printserv, try from a command prompt:

    net view \\printserv

    if it fails, do the same as above, but use the ip:

    \\192.168.1.103

    Does it come up and show the printer on printserv?

    Yes is good, no is not_so_good

    If the shares showed on any of these than samba is sharing, at least to a point.
    If the ip address worked but the name didn't:

    Create a hosts file (hosts is in the Windows directory on '98)
    192.168.0.103 printserv


    If no then samba doesn't seem to be sharing...
    at the samba machine (as root) type:
    service smb status
    it should show smbd and nmbd pid's .. running
    If not restart 'em and check the status.
    If the smbd and nmbd are running, but the shares aren't working, then it is in the smb.conf
    If the services are failing, then it is going to take a bit longer : (

    The printserv doesn't need to "see" the '98 system, but you could if you want (as root) add it to the hosts file (/etc/hosts)
    192.168.0.win98machine-number win98machine-name

    Can the Windows machines see each other? Are the gateways all set correctly?

    Try these commands - any errors?

    nmblookup -T machine-name
    testparm
    testprns printer-name

    I know alot of questions, but it is hard without laying hand and eyes on a system.

    Please keep me updated on these things - I'll be posting again tomorrow evening

  11. #11
    Join Date
    May 2002
    Posts
    1,449
    Well I've run out of time. Windows wins again. Anyway, I really want to thank you for your excellent help in this matter. I'm very sorry that your guys effort on my part is a waste but I had a week to configure it and get it to work and a weeks up. Thanks again, and I'm sorry.

  12. #12
    Join Date
    Jul 2003
    Location
    North Port, Fl
    Posts
    115

    Unhappy Sorry I couldn't help more

    I know everybody says this distro is better than that distro, etc. For the less experienced, yet wanna be a power user group, I'd recommend Mandrake. I Iearned on it, tried several other distro's from the easy, but somewhat lacking (Lycoris, Xandros, Lindows), to the Linux mainstays ( Suse, Yoper, RedHat, and Debian). I came back to Mandrake because I like it's swiss army knife approach. If you ever want to try setting up printers, samba servers, email servers, Mandrake makes it pretty damn easy, without losing the power of Lunux and opensource.

  13. #13
    Join Date
    May 2002
    Posts
    1,449
    I've been using linux for about a year now and debian was a real big jump for me from redhat 7.3, this was pretty much the first time I've ever tried to do any networking/printing/samba work in linux. I needed to press print on computer B and have it print on computer A in a week and I didn't get it done in time. However, there's no way in hell I'm giving up my personal debian system! Once again, you provided very excellent help.

  14. #14
    Join Date
    Aug 2002
    Posts
    157
    heh, we must have chosen the same week to do the same thing, I'm not having much luck either, although with 2 deb machines on my network I have manged to get linux to linux network printing working.
    running Debian

    must remember to change this sig regularly

  15. #15
    Join Date
    May 2002
    Posts
    1,449
    Well I'm trying again. From the Windows 98 machine, a \\jeeves (I renamed the printserver) and net view \\jeeves all came back as "You need to be logged in to perform that action". From the XP home machine it said, no network path. nmblookup -T jeeves said this:

    querying jeeves on 192.168.1.255
    192.168.1.103 jeeves<00>

    testparm epson:

    Load smb config files from epson
    params.c:OpenConfFile() - Unable to open configuration file "epson":
    No such file or directory
    Error loading services

    testparm with no agruements passed.

    Right now the printer is not hooked up to the printserver (jeeves) so I assume that's why testparm epson failed.
    "I know where you're from but where do you belong?"

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •