Yes! Thanks very much. Sorry. I didn't know about lpstat, I was trying to get that info out of lpoptions.<br><br>Cheers!<br><br>John<br><br><div><span class="gmail_quote">On 1/28/07, <b class="gmail_sendername">Jim McQuillan
</b> <<a href="mailto:jam@mcquil.com">jam@mcquil.com</a>> wrote:</span><blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;"><br><br>john wrote:
<br>> Thanks Jim. I feel honored when I get a response from you in person,<br>> pretty darn cool.<br><br>careful... my head is already rather large :)<br>><br>> I am using Ubuntu, but I am using LTSP 4.2 not MUkow. I am also using
<br>> cups (via the (gnome-cups-manager) to manage printers. The printer is<br>> shared via smb://  Using your example below would I just do something<br>> similar to:<br>><br>> case `echo $DISPLAY | sed s/:.*$//` in
<br>>   ws004)   lpoptions -d smb://pathtoprinter;;<br>>   ws005)   lpoptions -d smb://pathtootherprinter;<br>> esac<br><br>Well, doesn't cups assign a simple name to your printers, that you can<br>use from the command line?
<br><br>Try:<br><br>     lpstat -l -a<br><br>to get a list of printers that cups knows about.  The name that shows as<br>the first word of each line is the name you want to use in the lpoptions<br>command.<br><br>Jim.<br>
<br><br>><br>> Thanks again for your help.<br>> John<br>><br>> On 1/28/07, *Jim McQuillan* <<a href="mailto:jam@mcquil.com">jam@mcquil.com</a> <mailto:<a href="mailto:jam@mcquil.com">jam@mcquil.com</a>
>><br>> wrote:<br>><br>>     John,<br>><br>>     what you are trying to do, really isn't LTSP related at all.<br>><br>>     It just so happens that your users are connection with LTSP terminals,
<br>>     and the printers are attached to LTSP terminals.  Other than that,<br>>     it's<br>>     really a printer management issue on the server.<br>><br>>     You want one users default printer to be printerA, and another users
<br>>     default printer to be printerB.<br>><br>>     Assuming that you've got your printers all configured in CUPS on the<br>>     server, you can use the 'lpoptions' command to set a default for
<br>>     each user.<br>><br>>     Because a user may log into ws004 in the morning, and then log into<br>>     ws005 in the afternoon, you'll need to call lpoptions each time<br>>     the user<br>>     logs in.  the /etc/profile script might be a good place to put this.
<br>><br>>     The magic scripting you'll need to add is something like this:<br>><br>>     case `echo $DISPLAY | sed s/:.*$//` in<br>>       ws004)   lpoptions -d printerA;;<br>>       ws005)   lpoptions -d printerB;;
<br>>     esac<br>><br>>     That way, each time a user logs in, it checks the current terminal<br>>     that<br>>     they are logging in with, and it sets their default printer<br>>     accordingly.<br>
><br>>     If you are using Ubuntu's LTSP, you can't use the $DISPLAY, you'll<br>>     have<br>>     to use another env variable, like $SSH_CLIENT, which has a different<br>>     format.  do:  echo $SSH_CLIENT to see what the value looks like.
<br>><br>>     Hope that helps,<br>>     Jim McQuillan<br>>     <a href="mailto:jam@Ltsp.org">jam@Ltsp.org</a> <mailto:<a href="mailto:jam@Ltsp.org">jam@Ltsp.org</a>><br>><br>><br>>     john wrote:
<br>>     > Hi all,<br>>     ><br>>     > I want to use networked printing on my thin clients and specify<br>>     it per<br>>     > station ( e.g tell ws004 to print to networked printer A and<br>
>     ws005 to<br>>     > print to networked printer B).<br>>     ><br>>     > My reading of lts.conf it appears to say that one can only do this<br>>     > with local printers. Can anyone help me figure out if what I want to
<br>>     > do is possible?<br>>     ><br>>     > TIA!<br>>     ><br>>     > John<br>><br>><br>> ------------------------------------------------------------------------<br>><br>> _______________________________________________
<br>> K12OSN mailing list<br>> <a href="mailto:K12OSN@redhat.com">K12OSN@redhat.com</a><br>> <a href="https://www.redhat.com/mailman/listinfo/k12osn">https://www.redhat.com/mailman/listinfo/k12osn</a><br>> For more info see <
<a href="http://www.k12os.org">http://www.k12os.org</a>><br><br>_______________________________________________<br>K12OSN mailing list<br><a href="mailto:K12OSN@redhat.com">K12OSN@redhat.com</a><br><a href="https://www.redhat.com/mailman/listinfo/k12osn">
https://www.redhat.com/mailman/listinfo/k12osn</a><br>For more info see <<a href="http://www.k12os.org">http://www.k12os.org</a>><br></blockquote></div><br>