Operating System - HP-UX
1823959 Members
3913 Online
109667 Solutions
New Discussion юеВ

A Printer for a group of users?

 
SOLVED
Go to solution

A Printer for a group of users?

Hello,

As I can configure to a group of users so that they prime for a single predetermined printer?.... and that they cannot see the rest of the printers defined in the operating system one.

Thank you,
Orlando Oliveira
6 REPLIES 6
Pete Randall
Outstanding Contributor

Re: A Printer for a group of users?

In their profile, you could set the LPDEST variable and that would become their default printer destination unless overridden with the -d option of the lp command.


Pete

Pete

Re: A Printer for a group of users?

Hello,

Thank you for your quick answer, but you could specify me better the steps to continue.

Thank you again,
Orlando Oliveira
Pete Randall
Outstanding Contributor
Solution

Re: A Printer for a group of users?

This type of solution depends on how your users are printing. If they use the lp command, then the LPDEST variable will set a default destination for them as long as they do not override it with lp -d. Once you've set LPDEST for each of the users in this group by putting "export LPDEST=this_group's_printer, an lp command (without and -d override) will print to the printer you've set LPDEST to.

Does that make sense?


Pete

Pete

Re: A Printer for a group of users?

Thank you Pete,

The explanation was quite clear.
Orlando Oliveira
Pete Randall
Outstanding Contributor

Re: A Printer for a group of users?

Orlando,

I just re-read my answer and it wasn't very clear to me. Please, no points for this, I just wanted to straighten out what I meant to say:



This type of solution depends on how your users are printing. If they use the lp command, then the LPDEST variable will set a default destination for them as long as they do not override it with lp -d. Once you've set LPDEST for each of the users in this group by putting "export LPDEST=this_group's_printer" in their .profile, an lp command (without the -d override) will print to the printer you've set LPDEST to.


Pete

Pete
Jose Antonio Orozco
Frequent Advisor

Re: A Printer for a group of users?

you can use a process to
1) ask to every user in your system to choose a printer (at logon, if not configured)
2) put that information in their home (i'm using .lpdest)
3) modify the logon profile script in order to set LPDEST
4) use a script to limit sending to their printer selected.
You must ensure the user is not able to change their selection ...
My scripts has spanish dialogs, but it could help you

I have the following lines in my /etc/profile
# selects a printer, if it isn't so
/usr/local/bin/PRINTER_SEL.SH
# set LPDEST
LPDEST=`cat $HOME/.lpdest | head -1`
export LPDEST

my best regards

J.A. OROZCO
What is not backed up, it not exists