General
cancel
Showing results for 
Search instead for 
Did you mean: 

Configure a Non HP Printer in Unix Box

Suriya Prakash
Regular Advisor

Configure a Non HP Printer in Unix Box

Hi,
I have a canon Imageclass mf4370dn network printer. i configured this printer on my unix server (HP-UX 11.31) as a remote printer. I done all the basic settings on windows machine also. i using the printing coammand as
"ux2dos /etc/hosts | lp -duatcanon". after giving this command no pending jobs in unix as well as windows. but i didnt get the printout.

On windows pc i configured the
1. SimulatePassThrough in regedit
2. Add the printer services for unix in add/remove windows components.
3. start the tcp/ip print services in services.msc.

I configured one of my hp printer as remote printer in same machine. i can get the print from that printer.

Pls help me to get print from the canon printer.

I think we cant configure the canon printer as n/w printer because of jetdirect network protocal not supported on this printer.

Is there is any option to configure this printer as n/w printer.

Thanks,
Suriya.
25 REPLIES
Shibin_2
Honored Contributor

Re: Configure a Non HP Printer in Unix Box

>> I think we cant configure the canon printer as n/w printer because of jetdirect network protocal not supported on this printer.


Now-a-days most non-HP printers access the services through port 9100 ( which is normally for Jetdirect in HP printers ).

You can try to reinstall the printer as network printer in UNIX. If you have hppi software installed, use hppi to configure it.


Btw, did you connect this printer to network / via PC ? ( asked this, because of your statement "On windows pc i configured " ).
Regards
Shibin
Suriya Prakash
Regular Advisor

Re: Configure a Non HP Printer in Unix Box

HI, I connected this printer on my windows pc as n/w printer and i configured in unix machine as remote printer.
Shibin_2
Honored Contributor

Re: Configure a Non HP Printer in Unix Box

I think, you didn't get my question.

How this printer connected to network? via LPT port through a PC or via network cable ?

If the printer connected to network via LPT cable through a PC, at PC side, UNIX printing services need to be enabled and disable the internal firewall for the PC to printer and PC to UNIX machine. Then configure the printer in your UNIX machine as remote printer using the IP of your windows PC ( where the printer connected ).

If the printer connected to network using network cable, you can try to add the printer in UNIX server as network.
Regards
Shibin
Suriya Prakash
Regular Advisor

Re: Configure a Non HP Printer in Unix Box

Hi,

My printer is a n/w printer and i configured as a n/w printer in windows pc. but its a canon printer. so i cant configure as a network printer in unix. so i configured as a remote printer in unix but i'm not getting the print.

Read my question clearly...

Thanks,
Suriya
Steven Schweda
Honored Contributor

Re: Configure a Non HP Printer in Unix Box

I know nothing, but, ...

> I have a canon Imageclass mf4370dn network
> printer. [...]

What do you know about this printer?

1a. What is it expecting you to send it?
Does it know what to do with plain ASCII
text, or is it expecting PostScript, or PCL,
or some kind of Canon Printer Control
Language (which only Canon's Windows printer
drivers know how to speak), or what?

1b. What are you sending it?

2a. How is it expecting you to send this
stuff? LPR? Direct to port 9100? Other?

2b. How are you trying to send it?
Arvin E.
Frequent Advisor

Re: Configure a Non HP Printer in Unix Box

As your canon printer stated "dn" in the end of its name , I suppose your canon printer is a d=duplex and n=network printer,

so I think it must listen on port 9100 for receive request,

so you can configure IP for your printer in its settings, and telnet to it from your hp-ux box, if it was OK,

then you can install it as n/w printer just like what you do with your hp printer...

hope this help,

-Arvin-
Suriya Prakash
Regular Advisor

Re: Configure a Non HP Printer in Unix Box

As your canon printer stated "dn" in the end of its name , I suppose your canon printer is a d=duplex and n=network printer,

so I think it must listen on port 9100 for receive request,

so you can configure IP for your printer in its settings, and telnet to it from your hp-ux box, if it was OK,

then you can install it as n/w printer just like what you do with your hp printer...

hope this help,

-Arvin-

Hi Arvin,

I add the ip in host entry.

I'm able to ping from my unix server.

but telnet is not connecting.

If i configure as a network printer,

which driver i should choose.

Thanks,
Suriya
Steven Schweda
Honored Contributor

Re: Configure a Non HP Printer in Unix Box

> but telnet is not connecting.

As usual, showing actual commands with their
actual output can be more useful than vague
descriptions or interpretations.

> so I think it must listen on port 9100 for
> receive request,

He probably expected you to try a command
like:

telnet name_or_addr 9100

Sadly, we non-psychics have no idea what you
actually did, or what actually happened when
you did it.
Suriya Prakash
Regular Advisor

Re: Configure a Non HP Printer in Unix Box

Hi,

I can able to connect when i telnet ip 9100.

Pls see the below result

# telnet 172.23.0.105 9100
Trying...
Connected to 172.23.0.105.
Escape character is '^]'.

But without 9100 i cant, pls check below

# telnet 172.23.0.105
Trying...
telnet: Unable to connect to remote host: Connection refused

What should i do to configure as n/w printer.

Thanks,
Suriya.
Shibin_2
Honored Contributor

Re: Configure a Non HP Printer in Unix Box

Now configure the printer as network printer in your UNIX box.

You can use hppi ( if you have ) or via sam.

Choose "Laserjet printer not in this list" or generic printer driver.
Regards
Shibin
rmueller58
Valued Contributor

Re: Configure a Non HP Printer in Unix Box

suri,

the Canon MF Devices are fairly simple,

as someone mention using hppi -s

****************************************************************
*****] ****
**** ] **** JetDirect Printer Installer for UNIX
**** ]]]]] ]]]]] **** Version E.10.34
**** ] ] ] ] ****
**** ] ] ]]]]] **** Spooler Administration
***** ] ****
****** ] **** User: (root) OS: (HP-UX B.11.11)
I N V E N T
****************************************************************

Spooler:
1) Add printer to local spooler
2) Delete printer from local spooler
3) Modify existing spooler queue(s)
4) Install New Model Script
5) Remove Model Script

?) Help q) Quit

Select 1)
Enter the network printer name or IP address (q - quit):

Enter the defined IP address of the printer:

Canon is a recognized "engine" in most cases by HP/UX and will be installable at a 5SI Compatible,

in order to printer from the command line,

You should not have to filter through ux2dos

just:

lp -d /etc/hosts

you can send along the command line args,
such as -oc -oduplex -olandscape before the jobname and after the destination

lp -dqname -oc /etc/hosts
will send compressed printing

the others are obvious

if you have line break issues you will need to use the ovsi#.## options

for 8x11 landscape I send the following

lp -dqname -olandscape -ovsi5.45 jobname

Again, do not bother with the Ux2Dos command, it is unnessary.
Suriya Prakash
Regular Advisor

Re: Configure a Non HP Printer in Unix Box

Hi,

I try to configure as a network printer,

While add printer to the local spooler

I'm getting the below error.

Please enter selection: 1

Enter the network printer name or IP address (q - quit): 172.23.0.105

!! No response from 172.23.0.105 !!
... (trying to ping 172.23.0.105)


The HP JetDirect Printer Installer for Unix can ping the device.
The problem may be:
* incorrect GET community name!
* it is not a network printer!
* other.

Do you want to continue (y/n/q, default - n)?

Thanks,
Suriya
Shibin_2
Honored Contributor

Re: Configure a Non HP Printer in Unix Box

Yes, please go ahead. Below piece of screen shot will help you to configure.

==========


The HP JetDirect Printer Installer for Unix can ping the device.
The problem may be:
* incorrect GET community name!
* it is not a network printer!
* other.

Do you want to continue (y/n/q, default - n)? y

There are three choices:
1. Supply the correct community name (if this is the problem).
2. Ignore it and continue the process.
3. Supply another IP name (default) .

Please select a number (q - to config menu): 2

The following are supported printer types:
59) HP LaserJet Printer not given in this list
60) HP Plotter not given in this list

Please indicate 10.242.10.204's printer type (q - quit): 58

** Here, please select the number in your screen. It will be different depends on number of drivers in your system.

Is this printer connected to:
1) An HP XStation
2) An HP JetDirect EX (single parallel port)
3) An HP JetDirect EX Plus3 (multiple parallel ports)
4) Other

Please select a number (default-4, q - quit): 4


The following is a list of suggested parameter values for this queue. You
may change any settings by selecting the corresponding non-zero numbers.
The values will be used to configure this queue when '0' is selected.
To abort the operation, press 'q'.

Configurable Parameters: Current Settings
------------------------ ----------------

1) Lp destination (queue) name: [10_1]
2) Status Log [(No Log)]
3) Queue Class [(Not assigned)]
4) Default Queue [NO]
5) Additional printer configuration...

Select an item for change, or '0' to configure (q - quit): 1

*** Hope you know the remaining steps.


Regards
Shibin
Suriya Prakash
Regular Advisor

Re: Configure a Non HP Printer in Unix Box

Thanks sibin,

I done all the steps you have mentioned (thank you very much for the screenshot).

but i'm not getting the print.

no queue also in the print queue.

pls check the below screenshot.

# lp -dlasercanon /etc/hosts
request id is lasercanon-19 (1 file)
# lpstat
no entries

Thanks,
Suriya.
Shibin_2
Honored Contributor

Re: Configure a Non HP Printer in Unix Box

If lpstat command shows no jobs, that means it has gone out from the system and at printer side.

I hope your printer have web interface and there will be some logs, which will show, whether the job reached to printer or not.
Regards
Shibin
Suriya Prakash
Regular Advisor

Re: Configure a Non HP Printer in Unix Box

Hi Shibin,

I checked the printer log in web panel of the prinetr. nothing is there.

Thanks,
Suriya
Shibin_2
Honored Contributor

Re: Configure a Non HP Printer in Unix Box

First, you may check the status of your printer from hpnpadmin command.

hpnpadmin -Ss lasercanon


If that returns something, send a print request


lp -dlasercanon /etc/hosts; lpstat -olasercanon; hpnpadmin -Ss lasercanon; hpnpadmin -Ss lasercanon

Above commands should be in one line. So that you can see, if there is something happening at your printer side or not.
Regards
Shibin
Steven Schweda
Honored Contributor

Re: Configure a Non HP Printer in Unix Box

Not to waste time going over old ground, but
did you ever find any information anywhere
which suggests that this printer accepts
PostScript, or PCL, or anything in
particular? Or any evidence that it might
work in any environment other than Windows or
Mac OS X, that is, in any environment where
Canon does not supply driver software?

Just a thought.
Bill Hassell
Honored Contributor

Re: Configure a Non HP Printer in Unix Box

It's very important to understand that hppi (network printer tool for HP-UX) was designed for HP's proprietary JetDirect print servers (ie, LAN interfaces). There are VERY FEW non-HP printers that support port 9100 (JetDirect) printing. Canon has HUNDREDS of models, dozens that have a network connection and just a handful that support the JetDirect protocol, usually very large (expensive) models such as ImageRunner series. Only Canon will have a list that shows HP JetDirect compatibility.

Now since telnet 9100 did produce a response (the connection was not refused), this printer may support JetDirect protocol. So use hpnpadmin to see if you can interrogate the printer:

hpnpadmin -v

You should get a couple of pages of network information. If that is true, you should be able to add the printer with addqueue like this:

addqueue -q hpuxprn -h 1.2.3.4 -i 9998 -b off -r off -t off

If not, this printer does not support JetDirect protocol and you'll have to delete the existing printer and add it back as a "remote printer" since virtually all printers with a LAN connection support the lpr/lpd protocol. You add the printer using sam, cleverly renamed smh, but when you select "p" printers (not "l"), you'll see good old SAM.

So you'll need 3 pieces of information, two of which are easy, one may be quite tricky to discover. So when SAM shows the Printer and Plotters menu, press tab to highlight File, then use the right arrow key to move to Actions and press Enter. Now select Add Remote Printer and press Enter.

Printer Name: the HP-UX local printer name
Remote System Name: IPaddr of the Canon printer
Remote Printer Name: (this is the tricky part)

And be sure the check [x] Remote Printer ... BSD system

So the tricky part is finding out what Canon used for a remote printer. Good luck with Canon support -- they know PCs really well but most will ask HP-what? The name that you need is the print server internal name. Sometimes the name is prn or lp or text. Years ago, I discovered a list of internal printer names by manufacturer (attached) so here are some possibilities:

print PRINT pt1 lpt1 XJDIRECT

I would try lpt1 as a guess.

That should get the printer working. In case you're wondering, HP is the largest printer manufacturer in the world so there is very little interest in providing support for non-HP printers.

About remote printers:
===================
Unlike serial or parallel (or HP JetDirect) printers, there almost no useful options for printing. So things like landscape or duplex or two-up print options do not exist. To get these features, you'll need the tech reference manual for the Canon printer and some scripting skills to write a filter, similar to HP-UX model scripts (/usr/lib/lp/model)


Bill Hassell, sysadmin
Suriya Prakash
Regular Advisor

Re: Configure a Non HP Printer in Unix Box

Dear All,

Thanks for the replies

pls check the below screenshots for all your commands.

# hpnpadmin -Ss lasercanon
*** Receive NO snmp response!
*** (printer down, cable off, or wrong Get community name?)
#


# lp -dlasercanon /etc/hosts; lpstat -olasercanon; hpnpadmin -Ss lasercanon;
request id is lasercanon-22 (1 file)
lasercanon-22 root priority 0 Dec 15 21:19
hosts 803 bytes
*** Receive NO snmp response!
*** (printer down, cable off, or wrong Get community name?)
#


# hpnpadmin -v 172.23.0.105
*** Receive NO snmp response!
*** (printer down, cable off, or wrong Get community name?)
#


# addqueue -q hpuxprn -h 1.2.3.4 -i 9998 -boff -r off -t off
hpuxprn added to spooler.
#

Whats the next step to do.

Thanks,
Suriya.
Bill Hassell
Honored Contributor

Re: Configure a Non HP Printer in Unix Box

> hpnpadmin -Ss ...

This indicates that this printer may not support HP's special protocol.

> # addqueue -q hpuxprn -h 1.2.3.4 -i 9998 -boff -r off -t off
> hpuxprn added to spooler.
> #

Sorry, I assumed that you would look at the man page for a new command like addqueue. -q is the HP-UX queue name. You choose this name for your printer on HP-UX. hpuxprn was just an example. -h is the hostname or IP address of the printer. 1.2.3.4 was just an example of an IP address.

> Whats the next step to do.

Delete the printer and add it back with the correct values for -q and -h. Use:

deletequeue -q hpuxprn


Bill Hassell, sysadmin
Suriya Prakash
Regular Advisor

Re: Configure a Non HP Printer in Unix Box

Hi Bill

Sorry for misunderstanding

pls check the below result.

# deletequeue -q hpuxprn
sh: deletequeue: not found.


# addqueue -q lasercanon -h 172.23.0.105 -i 9998 -b off -r off -t off
lasercanon already exists

Thanks,
Suriya
Suriya Prakash
Regular Advisor

Re: Configure a Non HP Printer in Unix Box

Hi,

Sorry for the mistake

pls check the below result.

# lp -dlasercanon /etc/hosts
request id is lasercanon-24 (1 file)
# addqueue -q lasercanon-24 -h 172.23.0.105 -i 9998 -b off -r off -t off
Could not create the queue
#

Thanks,
Suriya
Dennis Handly
Acclaimed Contributor

Re: Configure a Non HP Printer in Unix Box

># deletequeue -q hpuxprn
>sh: deletequeue: not found.

You won't be able to add the correct queue until you delete the bad one or pick a new name.