Operating System - HP-UX
1820275 Members
3211 Online
109622 Solutions
New Discussion юеВ

Re: Change network printer 'location'/IP/hostname

 
SOLVED
Go to solution
lbdwag
Frequent Advisor

Change network printer 'location'/IP/hostname

Hi:

I could not find anything on how to change the 'location'/IP/hostname of a current network/remote printer on HP-UX 11.31.

I would rather not delete and re-add it, since all I really need to do is change this 1 piece of information.

--
Don
-- Don
15 REPLIES 15
Tim Nelson
Honored Contributor

Re: Change network printer 'location'/IP/hostname

Which is it.. A network based printer or a remote printer. They are different.

lbdwag
Frequent Advisor

Re: Change network printer 'location'/IP/hostname

It is a printer that has a Jetdirect card installed and sits directly on the network.
-- Don
Tim Nelson
Honored Contributor

Re: Change network printer 'location'/IP/hostname

Ahh.. network printer.

review /etc/lp/interface/PRINTER_NAME

grep for PERIPH=

if using a hostname then edit /etc/hosts

if using IP address then edit the interface file for the new IP address ( would recommmend creating a hostname and then next time you only have to edit the host file ).

Nothing more to do...

lbdwag
Frequent Advisor

Re: Change network printer 'location'/IP/hostname

That does not exists in my file(s).....
-- Don
Tim Nelson
Honored Contributor

Re: Change network printer 'location'/IP/hostname

You have no file under /etc/lp/interfaces/ with a name of your printer ??
lbdwag
Frequent Advisor

Re: Change network printer 'location'/IP/hostname

there are files there: lp0 lp1 lp2, etc... but when I ran: cat lp0 | grep PERIPH= it did not return anything.
-- Don
Dennis Handly
Acclaimed Contributor

Re: Change network printer 'location'/IP/hostname

>there are files there: lp0 lp1 lp2

You can search all of them with:
grep PERIPH= /etc/lp/interfaces/*
Heiner E. Lennackers
Respected Contributor

Re: Change network printer 'location'/IP/hostname

Even the printer has a jetdirect interface it does not necessary means that jetadmin is been used.
The name of the printer and the output of "lpstat -s" can be useful to identify how the printer is connected.
if this makes any sense to you, you have a BIG problem
Sandeep_Chaudhary
Trusted Contributor

Re: Change network printer 'location'/IP/hostname

u can do it with SAM
Bill Hassell
Honored Contributor
Solution

Re: Change network printer 'location'/IP/hostname

Your JetDirect printer(s) were added incorrectly. It would be as very good idea to delete each JetDirect printer and add it back using the addqueue command. You'll get all sorts of new printer options and a much more robust connection.

addqueue -h 12.34.56.78 -q myprinter -t off -b off -r off


Bill Hassell, sysadmin
lbdwag
Frequent Advisor

Re: Change network printer 'location'/IP/hostname

#grep PERIPH= /etc/lp/interface/*

does not find anything.
-- Don
lbdwag
Frequent Advisor

Re: Change network printer 'location'/IP/hostname

#lpstat -s

gives me:

device for lp4: /dev/null
remote to: text on hostname.domain.com
-- Don
lbdwag
Frequent Advisor

Re: Change network printer 'location'/IP/hostname

all of the printers were migrated from Tru64 using the Tru64 UNIX remote printer queue migration tool
-- Don
Tim Nelson
Honored Contributor

Re: Change network printer 'location'/IP/hostname

>>#lpstat -s

>>gives me:

>>device for lp4: /dev/null
>>remote to: text on hostname.domain.com

Indicates that your printer lp4 is a "remote spooled" printer. Only way to change the IP is to delete it and re-add it.

If this printer truely has a jetdirect interface I would second Bill's recommendation to delete it and re-add it using the "network" type of config. Makes life so much easier.

Another quick option would be to simply change the IP address related to hostname.domain.com either in the /etc/hosts or on your DNS server.

lbdwag
Frequent Advisor

Re: Change network printer 'location'/IP/hostname

I removed the printer and then re-added it via SMH... all seems to be working now.

Thanks for all of your help.
-- Don