Solved

Printing form linux --> Win95 with samba

Posted on 1997-03-03
1
278 Views
Last Modified: 2010-03-18
Hello,
I have one computer (thor.duijnhoven) with linux and I want to print on a
W95 computer (wodan.duijnhoven).
So I used samba.
I can ping this computer, and I can even print when I use
smbclient on the command line.
But when I use lp and I look use lpc to see what the status
is it says. Waiting for wodan.duijnhoven to come up.
My printcap file:
epson|peter|netwerk|Epson Stylus:\
:lp=:rm=WODAN.DUIJNHOVEN:\
      :rp=EPSON PEER:\
      :sd=/usr/spool/lpd/epsonstylus:\
      :lf=/usr/spool/lpd/epsonstylus/errs:\
      :if=/usr/local/samba/bin/smbprint:\
        :df=/var/spool/lp1/filter.ps:\
        :tf=/var/spool/lp1/filter.ps:\
        :af=/var/spool/lp1/lp-acct:\

0
Comment
Question by:marcd022697
1 Comment
 
LVL 2

Accepted Solution

by:
dux earned 50 total points
ID: 1584000
Put the following line in /etc/printcap:

lp:lp=/dev/null:sd=/usr/spool/lp1:sh:if=/usr/local/samba/smbprint

smbprint is a script used for printing with samba:


#!/bin/sh -x

# ...

eval acct_file=\$$#
spool_dir=`dirname $acct_file`
# Should read the following variables set in the config file:
#   server
#   service
#   password
eval `cat $config_file`echo "server $server, service $service" >> $logfile

(
# NOTE You may wish to add the line `echo translate' if you want automatic
# CR/LF translation when printing.
#       echo translate
        echo "print -"
        cat
) | /usr/local/samba/bin/smbclient "\\\\dana\\ibm" -N -P >> $logfile



config_file=$spool_dir/.config


0

Featured Post

Efficient way to get backups off site to Azure

This user guide provides instructions on how to deploy and configure both a StoneFly Scale Out NAS Enterprise Cloud Drive virtual machine and Veeam Cloud Connect in the Microsoft Azure Cloud.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Title # Comments Views Activity
Samba Security Improvement for Writable Directories 8 75
Guacamole and browser performance 1 105
Monitor Aliased network interface bandwitch CentOS 4 98
ifconfig 4 69
I have seen several blogs and forum entries elsewhere state that because NTFS volumes do not support linux ownership or permissions, they cannot be used for anonymous ftp upload through the vsftpd program.   IT can be done and here's how to get i…
Note: for this to work properly you need to use a Cross-Over network cable. 1. Connect both servers S1 and S2 on the second network slots respectively. Note that you can use the 1st slots but usually these would be occupied by the Service Provide…
This video shows how to use Hyena, from SystemTools Software, to bulk import 100 user accounts from an external text file. View in 1080p for best video quality.

838 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question