LinuxQuestions.org
Review your favorite Linux distribution.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Networking
User Name
Password
Linux - Networking This forum is for any issue related to networks or networking.
Routing, network cards, OSI, etc. Anything is fair game.

Notices


Reply
  Search this Thread
Old 05-07-2007, 08:44 PM   #1
gruelius
Member
 
Registered: Mar 2005
Distribution: Gentoo
Posts: 30

Rep: Reputation: 15
Samba + Cups Network Printing issues


Hi everyone,
Ive posted this on another forum and the samba mailing list with no responses so i might drop it here aswell :P.

Recently i setup my Gentoo server to do the following
Share files
Host website
and Share a printer.

Samba file sharing works perfectly but i have a few questions (more on that later!) but my main problem is with the printer.

I can print all the test pages i want however when i try to connect to it from a networked PC i get this message

"Access Denied"
http://img.photobucket.com/albums/v4.../problemmo.jpg

I believe it is to do with samba because in the samba error logs i see
Code:
[2007/05/07 07:36:35, 1] rpc_client/cli_pipe.c:cli_rpc_pipe_open(2222) 
  cli_rpc_pipe_open: cli_nt_create failed on pipe \spoolss to machine Julius-PC.  Error was NT_STATUS_ACCESS_DENIED 
[2007/05/07 07:36:37, 1] rpc_client/cli_pipe.c:cli_rpc_pipe_open(2222) 
  cli_rpc_pipe_open: cli_nt_create failed on pipe \spoolss to machine Julius-PC.  Error was NT_STATUS_ACCESS_DENIED
I have samba set up properly to allow access to the printer, and the user does have printer permissions

Code:
[global] 
   workgroup = ROSCH 
   server string = Samba Server %v 

   printcap name = cups 
   printing = cups 
   load printers = yes 

   log file = /var/log/samba/log.%m 
   max log size = 100 

   socket options = TCP_NODELAY SO_RCVBUF=8192 SO_SNDBUF=8192 

   interfeaces = lo eth1 

   hosts allow = 127.0.0.1 192.168.0.* 

   vfs object = vsan-clamav 
   vscan-clamav:config-file = /etc/samba/vscan-oav.conf 
    
   security = user 
   force user = julius 
   guest ok = Yes 
    
   hosts allow = 127.0.0.1, 192.168.0., 192.168.1., 192.168.0. 
   hosts deny = 0.0.0.0/0 
   vfs objects = vscan-clamav 

[print$] 
   comment = Printer Drivers 
   path = /etc/samba/printer 
   browseable = yes 
   guest ok = yes 
   read only = yes 

[printers] 
   comment = All Printers 
   path = /var/spool/samba 
   printable = Yes 
   browseable = No 
   public = yes 
   guest ok = yes
Here is my cups.conf
Code:
LogLevel info 
SystemGroup lpadmin 
# Allow remote access 
Port 631 
Listen /var/run/cups/cups.sock 
# Share local printers on the local network. 
Browsing On 
BrowseOrder allow,deny 
BrowseAddress @LOCAL 
DefaultAuthType Basic 
<Location /> 
  # Allow shared printing and remote administration... 
  Order allow,deny 
  Allow @LOCAL 
</Location> 
<Location /admin> 
  Encryption Required 
  # Allow remote administration... 
  Order allow,deny 
  Allow @LOCAL 
</Location> 
<Location /admin/conf> 
  AuthType Basic 
  Require user @SYSTEM 
  # Allow remote access to the configuration files... 
  Order allow,deny 
  Allow @LOCAL 
</Location> 
<Policy default> 
  <Limit Send-Document Send-URI Hold-Job Release-Job Restart-Job Purge-Jobs Set-Job-Attributes Create-Job-Subscription Renew-Subscription Cancel-Subscription Get-Notifications Reprocess-Job Cancel-Current-Job Suspend-Current-Job Resume-Job CUPS-Move-Job> 
    Require user @OWNER @SYSTEM 
    Order deny,allow 
  </Limit> 
  <Limit Pause-Printer Resume-Printer Set-Printer-Attributes Enable-Printer Disable-Printer Pause-Printer-After-Current-Job Hold-New-Jobs Release-Held-New-Jobs Deactivate-Printer Activate-Printer Restart-Printer Shutdown-Printer Startup-Printer Promote-Job Schedule-Job-After CUPS-Add-Printer CUPS-Delete-Printer CUPS-Add-Class CUPS-Delete-Class CUPS-Accept-Jobs CUPS-Reject-Jobs CUPS-Set-Default> 
    AuthType Basic 
    Require user @SYSTEM 
    Order deny,allow 
  </Limit> 
  <Limit CUPS-Authenticate-Job> 
    Require user @OWNER @SYSTEM 
    Order deny,allow 
  </Limit> 
  <Limit All> 
    Order deny,allow 
  </Limit> 
</Policy>

Ive been scratching my head as to whats going on with that.

Now for my other question, on my home network i want the majority of the pc's to just connect to the tv dir as read only however i want to be able to edit them myself. The thing is i dont want a user + password prompt to come up every single time. To avoid this can i do smbpasswd -a *windows box user name*
and set the password as the windows password? Or do i have to have existing unix users?

Or can i have it so that one IP has write access, or one IP gets logged into a seperate admin account.

After i get all this working ill have to think about upgrading to the next gentoo release heh but ill ask bout that later :P


Thanks for reading
Julius
 
Old 05-08-2007, 07:50 AM   #2
soylentgreen
Member
 
Registered: Sep 2004
Location: old village
Distribution: android, BSD, CentOS, Ubuntu
Posts: 221

Rep: Reputation: 30
even tho it says 'access denied' have you tried to print? i was having that same problem with the error, but i could print.

in order to clear the 'access denied' message you need to have

Code:
use client driver = yes
that will make sure you're using your windows driver instead of trying to make it use the *nix driver.

if you **can't** print.. then you are probably going to have to add your LAN ip in your cups config file.

for example, if your lan address for the client is 192.168.0.25, then add the line in bold
Quote:
<Location />
# Allow shared printing and remote administration...
Order allow,deny
Allow @LOCAL
Allow 192.168.0.*
</Location>
 
Old 05-08-2007, 11:24 PM   #3
gruelius
Member
 
Registered: Mar 2005
Distribution: Gentoo
Posts: 30

Original Poster
Rep: Reputation: 15
Quote:
Originally Posted by soylentgreen
even tho it says 'access denied' have you tried to print? i was having that same problem with the error, but i could print.

in order to clear the 'access denied' message you need to have

Code:
use client driver = yes
that will make sure you're using your windows driver instead of trying to make it use the *nix driver.

if you **can't** print.. then you are probably going to have to add your LAN ip in your cups config file.

for example, if your lan address for the client is 192.168.0.25, then add the line in bold
I redid the config file, not following guides and it works perfectly now
 
  


Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
Whats the difference between CUPS printing and Samba shared printing? depam Linux - Software 1 03-17-2006 01:56 PM
Windows Apps freeze when printing to network samba + cups printer urzumph Debian 1 02-17-2005 06:38 PM
samba + cups + network printing -> problem... tisam Linux - Software 2 12-28-2004 09:48 PM
samba + cups + network printing ->problem tisam Linux - Hardware 0 12-28-2004 06:03 AM
Printing issues with cups/samba MDK9.2 mortalic Linux - Networking 0 10-16-2003 06:19 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Networking

All times are GMT -5. The time now is 08:27 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration