[SOLVED]LMDE Sharing a printer (home network)

Archived topics about LMDE 1 and LMDE 2
Locked
toomuchcoffee

[SOLVED]LMDE Sharing a printer (home network)

Post by toomuchcoffee »

Alright...

I have a desktop and a laptop both running W7 and LMDE (dual boot).
The printer is connected to the desktop with usb. How can I share the printer with my laptop?
From what I could dig up so far I need to setup samba and cups to achieve this, problem is I don't really know where to begin..

Could anyone point me in the right direction? Thanks in advance :) .
Last edited by LockBot on Wed Dec 28, 2022 7:16 am, edited 2 times in total.
Reason: Topic automatically closed 6 months after creation. New replies are no longer allowed.
toomuchcoffee

Re: LMDE Sharing a printer (home network)

Post by toomuchcoffee »

I'll keep talking to myself and see where that gets me... and I'll go editing this post along the way.
For starters I tried using the 2 comps running LMDE.

I've found this old topic >> http://forums.linuxmint.com/viewtopic.php?f=42&t=28397

Changing settings in CUPS interface (localhost:631) gives me an error FORBIDDEN..
Found how to fix this here
try adding your user account to the 'lpadmin' group.

see /etc/cups/cupsd_conf . the SystemGroup is usually 'lpadmin'.

lpadmin s/b in /etc/group .

to add a user named joe to lpadmin, from command line:

adduser joe lpadmin .
altair4
Level 20
Level 20
Posts: 11427
Joined: Tue Feb 03, 2009 10:27 am

Re: LMDE Sharing a printer (home network)

Post by altair4 »

In Debian Mint ( at least the XFCE version ) Samba is pretty much broken by default so you should have done this first:

Code: Select all

sudo apt-get install libsmbclient
sudo apt-get install smbclient
sudo apt-get install python-smbc
Then edit smb.conf as root:

Code: Select all

gksu gedit /etc/samba/smb.conf
Add the following line to the [global] section:

Code: Select all

map to guest = Bad user
Then look for the [printers] share and change the "guest ok" line from no to yes:
[printers]
comment = All Printers
browseable = No
path = /var/spool/samba
printable = yes
guest ok = yes
read only = yes
create mask = 0700
Then restart samba:

Code: Select all

    sudo service samba restart
On the CUPS end:

** Make sure you can print locally to the printer.
** Then run:

Code: Select all

system-config-printer
And do all this stuff:
Server > Settings > Check "Publish Shared Printers connected to this system"
Right Click the attached printer > Properties > Policies > Check Enabled, Accepting Jobs, and Shared
Please add a [SOLVED] at the end of your original subject header if your question has been answered and solved.
ddalley
Level 4
Level 4
Posts: 303
Joined: Sun Mar 15, 2009 4:25 am
Location: Toronto, Canada

Re: LMDE Sharing a printer (home network)

Post by ddalley »

altair4 wrote:In Debian Mint ( at least the XFCE version ) Samba is pretty much broken by default so you should have done this first:

Code: Select all

sudo apt-get install libsmbclient
sudo apt-get install smbclient
sudo apt-get install python-smbc
Our neverending SAMBA journey continues.

The libsmbclient is installed here, however the other two files are not.
altair4 wrote:Then edit smb.conf as root:

Code: Select all

gksu gedit /etc/samba/smb.conf
Add the following line to the [global] section:

Code: Select all

map to guest = Bad user
I also edited this file to unremark the name resolving line and reorder it, as usual with host last, to actually set up the networking printer driver.

For some reason the icon won't let me rename it, though.
altair4 wrote:Then look for the [printers] share and change the "guest ok" line from no to yes:
[printers]
comment = All Printers
browseable = No
path = /var/spool/samba
printable = yes
guest ok = yes
read only = yes
create mask = 0700
Would you remind me again what this does, please?
altair4
Level 20
Level 20
Posts: 11427
Joined: Tue Feb 03, 2009 10:27 am

Re: LMDE Sharing a printer (home network)

Post by altair4 »

If you're talking about the [printers] share, it's set up to require credentials from the client before printing is allowed. Setting "guests ok" to yes allows anyone to print to that printer.

BTW, the [printers] share really isn't a share like a folder share in Samba. It creates a sharable printer for every printer that CUPS passes to it. That's why the [printers] share itself is not browseable.
Please add a [SOLVED] at the end of your original subject header if your question has been answered and solved.
ddalley
Level 4
Level 4
Posts: 303
Joined: Sun Mar 15, 2009 4:25 am
Location: Toronto, Canada

Re: LMDE Sharing a printer (home network)

Post by ddalley »

Um, so that means it is for sharing through the computer to which the printer is attached?

My printer is on a NAS box's USB port, so it isn't attached to a PC directly and I've never had to make a guest edit before for it to work.
toomuchcoffee

Re: LMDE Sharing a printer (home network)

Post by toomuchcoffee »

altair4 wrote:In Debian Mint ( at least the XFCE version ) Samba is pretty much broken by default so you should have done this first:

Code: Select all

sudo apt-get install libsmbclient
sudo apt-get install smbclient
sudo apt-get install python-smbc
Then edit smb.conf as root:

Code: Select all

gksu gedit /etc/samba/smb.conf
Add the following line to the [global] section:

Code: Select all

map to guest = Bad user
Then look for the [printers] share and change the "guest ok" line from no to yes:
[printers]
comment = All Printers
browseable = No
path = /var/spool/samba
printable = yes
guest ok = yes
read only = yes
create mask = 0700
Then restart samba:

Code: Select all

    sudo service samba restart
On the CUPS end:

** Make sure you can print locally to the printer.
** Then run:

Code: Select all

system-config-printer
And do all this stuff:
Server > Settings > Check "Publish Shared Printers connected to this system"
Right Click the attached printer > Properties > Policies > Check Enabled, Accepting Jobs, and Shared
Had done all that up to running

Code: Select all

system-config-printer
It launches but I got this on the terminal:

Code: Select all

coffee@coffee ~ $ system-config-printer
ERROR:dbus.proxies:Introspect error on :1.86:/: dbus.exceptions.DBusException: org.freedesktop.DBus.Error.AccessDenied: Rejected send message, 1 matched rules; type="method_call", sender=":1.85" (uid=1000 pid=3810 comm="/usr/bin/python /usr/bin/system-config-printer ") interface="org.freedesktop.DBus.Introspectable" member="Introspect" error name="(unset)" requested_reply="0" destination=":1.86" (uid=0 pid=3815 comm="/usr/lib/cups-pk-helper/cups-pk-helper-mechanism ")
And the window seems to freeze after some time..

Right clicking the printer gives me an error:

Code: Select all

Option 'printer-resolution' has value '(unknown IPP tag)' and cannot be edited.
but everything is setup the way you instructed :? .


The printer is connected to the box through USB, box is connected to router, laptop is on wireless... when I try to print from the laptop I get a "printer is not responding"..

I already switched from coffee to beer by now :o .

edit:
I ran your how/to on sharing folders between both machines yesterday and it worked perfectly..
altair4
Level 20
Level 20
Posts: 11427
Joined: Tue Feb 03, 2009 10:27 am

Re: LMDE Sharing a printer (home network)

Post by altair4 »

coffee@coffee ~ $ system-config-printer
ERROR:dbus.proxies:Introspect error on :1.86:/: dbus.exceptions.DBusException: org.freedesktop.DBus.Error.AccessDenied: Rejected send message, 1 matched rules; type="method_call", sender=":1.85" (uid=1000 pid=3810 comm="/usr/bin/python /usr/bin/system-config-printer ") interface="org.freedesktop.DBus.Introspectable" member="Introspect" error name="(unset)" requested_reply="0" destination=":1.86" (uid=0 pid=3815 comm="/usr/lib/cups-pk-helper/cups-pk-helper-mechanism ")
Cheese and crackers ! I have no idea what that's all about. I try to stay away from Debian based Mint for reasons like this. Was this an update to an earlier LMDE or was this a new install of the latest respin? I try to do some searches on that message but it looks like multiple failures to me.
Please add a [SOLVED] at the end of your original subject header if your question has been answered and solved.
altair4
Level 20
Level 20
Posts: 11427
Joined: Tue Feb 03, 2009 10:27 am

Re: LMDE Sharing a printer (home network)

Post by altair4 »

I did a search on the second error message:
Option 'printer-resolution' has value '(unknown IPP tag)' and cannot be edited.
And it sent me back to this forum: http://forums.linuxmint.com/viewtopic.php?f=198&t=99361
It appears to be a known bug.
Please add a [SOLVED] at the end of your original subject header if your question has been answered and solved.
toomuchcoffee

Re: LMDE Sharing a printer (home network)

Post by toomuchcoffee »

Its a fresh UP4 final install... the laptop is the RC but everything is updated, the error probably has something to do with the UI... but like I said all the options are ticked, everything matches.
toomuchcoffee

Re: [SOLVED]LMDE Sharing a printer (home network)

Post by toomuchcoffee »

Three letters, the first is a u, the second a f... can you guess the third one? :oops:
Oh man I went through folders and conf's and.. grrr.

Thank you very much for your help altair :D .

Actually I'm not even sure if it was the firewall....
Locked

Return to “LMDE Archive”