1<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"> 2 3<html> 4 <head> 5 <meta name="generator" content="HTML Tidy, see www.w3.org"> 6 <title>Force Connection to Localhost</title> 7 <meta name="GENERATOR" content= 8 "Modular DocBook HTML Stylesheet Version 1.7"> 9 <link rel="HOME" title=" LPRng Reference Manual" href= 10 "index.htm"> 11 <link rel="UP" title= 12 "LPRng Clients - lpr, lprm, lpq, lpc, lpstat " href= 13 "lprngclients.htm"> 14 <link rel="PREVIOUS" title="Default Printer and Server Host" 15 href="defaultrmrp.htm"> 16 <link rel="NEXT" title="User Identification " href= 17 "allowusersetting.htm"> 18 </head> 19 20 <body class="SECT1" bgcolor="#FFFFFF" text="#000000" link= 21 "#0000FF" vlink="#840084" alink="#0000FF"> 22 <div class="NAVHEADER"> 23 <table summary="Header navigation table" width="100%" border= 24 "0" cellpadding="0" cellspacing="0"> 25 <tr> 26 <th colspan="3" align="center">LPRng Reference Manual: 5 27 Sep 2003 (For LPRng-3.8.22)</th> 28 </tr> 29 30 <tr> 31 <td width="10%" align="left" valign="bottom"><a href= 32 "defaultrmrp.htm" accesskey="P">Prev</a></td> 33 34 <td width="80%" align="center" valign="bottom">Chapter 5. 35 <b class="APPLICATION">LPRng</b> Clients - lpr, lprm, 36 lpq, lpc, lpstat</td> 37 38 <td width="10%" align="right" valign="bottom"><a href= 39 "allowusersetting.htm" accesskey="N">Next</a></td> 40 </tr> 41 </table> 42 <hr align="LEFT" width="100%"> 43 </div> 44 45 <div class="SECT1"> 46 <h1 class="SECT1"><a name="FORCELOCALHOST">5.8. Force 47 Connection to Localhost</a></h1> 48 49 <p>Options used:</p> 50 51 <ul> 52 <li> 53 <p><var class="LITERAL">force_localhost</var> FLAG <span 54 class="emphasis"><i class="EMPHASIS">force localhost to 55 be remote host</i></span></p> 56 </li> 57 </ul> 58 <br> 59 <br> 60 61 <p>The legacy BSD print spooler required an <b class= 62 "APPLICATION">lpd</b> print server to be running on each 63 host. During the initial stages of development and 64 deployment, the default <b class="APPLICATION">LPRng</b> 65 configuration and deployment was to always allow <span class= 66 "emphasis"><i class="EMPHASIS">lightweight</i></span> 67 operation, that is, clients would always connect to the 68 remote host specified in the printcap.</p> 69 70 <p>While this default was appropriate for experienced system 71 administrators, novice administrators or those who had 72 already configured print spooling systems and simply wanted 73 to upgrade found themselves confused by this change. This 74 problem resulted in over 700 postings to the <b class= 75 "APPLICATION">LPRng</b> mailing list in a five year 76 period.</p> 77 78 <p>This problem was solved by providing a <var class= 79 "LITERAL">force_localhost</var> option in the configuration, 80 and setting the default value to <var class="LITERAL">1</var> 81 or <acronym class="ACRONYM">TRUE</acronym>. When this option 82 is <acronym class="ACRONYM">TRUE</acronym>, then all <b 83 class="APPLICATION">LPRng</b> clients will connect to the 84 server on the localhost, <span class="emphasis"><i class= 85 "EMPHASIS">unless</i></span> they use the <tt class= 86 "COMMAND">lpr -Pserver@host</tt> command line form. If 87 lightweight operation is wanted, the administrator can either 88 compile the <b class="APPLICATION">LPRng</b> software with 89 the appropriate value or can explicitly set the <var class= 90 "LITERAL">force_localhost@</var> flag.</p> 91 92 <div class="INFORMALEXAMPLE"> 93 <a name="AEN4196"></a> 94<pre class="SCREEN"> 95 # default: 96 lp:lp=lp@10.0.0.1:... 97 lpr -Plp -> 98 lp:lp=lp@localhost:... 99 lpr -Plp@10.0.0.1 -> 100 lp:lp=lp@10.0.0.1 (no other options) 101 102 lp:lp=lp@10.0.0.1:force_localhost@:... 103 lpr -Plp -> 104 lp:lp=lp@10.0.0.1:... 105 106 To disable at compile time: 107 configure --disable-force_localhost 108</pre> 109 </div> 110 <br> 111 <br> 112 </div> 113 114 <div class="NAVFOOTER"> 115 <hr align="LEFT" width="100%"> 116 117 <table summary="Footer navigation table" width="100%" border= 118 "0" cellpadding="0" cellspacing="0"> 119 <tr> 120 <td width="33%" align="left" valign="top"><a href= 121 "defaultrmrp.htm" accesskey="P">Prev</a></td> 122 123 <td width="34%" align="center" valign="top"><a href= 124 "index.htm" accesskey="H">Home</a></td> 125 126 <td width="33%" align="right" valign="top"><a href= 127 "allowusersetting.htm" accesskey="N">Next</a></td> 128 </tr> 129 130 <tr> 131 <td width="33%" align="left" valign="top">Default Printer 132 and Server Host</td> 133 134 <td width="34%" align="center" valign="top"><a href= 135 "lprngclients.htm" accesskey="U">Up</a></td> 136 137 <td width="33%" align="right" valign="top">User 138 Identification</td> 139 </tr> 140 </table> 141 </div> 142 </body> 143</html> 144 145