Usenet comp.os.linux.announce (1993-2013)
 help / color / mirror / Atom feed
* Linux Frequently Asked Questions: TABLE OF CONTENTS [monthly posted]
@ 1993-07-21  9:52 corsini
  1993-07-21  9:52 ` Linux Frequently Asked Questions 1/6 " corsini
  0 siblings, 1 reply; 8+ messages in thread
From: corsini @ 1993-07-21  9:52 UTC (permalink / raw)


Archive-name: linux-faq/TOC
Last-Modified: 93/07/11
Version: 1.20

*********************************************************
*							*
*   TOC of the Frequently Asked Questions about Linux   *
*							*
*********************************************************

This post contains the TOC of the Linux FAQ (6 parts)
and a short introduction.


Hi Linuxers!

The original FAQ 1st version was posted on Dec. 19, 1991 by Robert Blum.
Since Feb. 1992, I'm the maintainer of this FAQ.

Most credits to Linus, Robert and Ted for the departure point of this
work. I haven't systematically copyrighted all the contributions, so
thanks to every one who participated even indirectly to this FAQ.


Since September 1992, the FAQ is co-written by:

WHO 			(WHAT) 		E-MAIL
=============================================================================
Michael K. Johnson  	(META-FAQ) 	johnsonm@stolaf.edu
Matt Welsh		(GENERAL INFO)	mdw@tc.cornell.edu
Zane Healy		(BBS INFO)	healyzh@holonet.net
Matt Welsh		(INSTALLATION)	mdw@tc.cornell.edu
Peter MacDonald		(SLS INFO)	pmacdona@sanjuan.uvic.ca
Mark Komarinski 	(DOS) 	 	komarimf@craft.camp.clarkson.edu
Drew Eckhardt		(SCSI)		drew@cs.colorado.edu 
Rick Miller		(DEVICE INFO)	rick@ee.uwm.edu
Hongjiu Lu		(GCC)		hlu@{eecs.wsu.edu,nynexst.com}
Krishna Balasubramanian (X11)		balasub@cis.ohio-state.edu 
Rick Sladkey		(EMACS)		jrs@world.std.com
Philip Copeland		(NET INFO)	p_copela@csd.bristol-poly.ac.uk
Brian McCauley		(LPD)		B.A.McCauley@bham.ac.uk
Vince Skahan		(UUCP/NEWS..)	vince@victrola.sea.wa.us
Dirk Hohndel		(PROOF READER)	hohndel@informatik.uni-wuerzburg.dbp.de
Marc-Michel Corsini	(FAQ collector)	corsini@labri.u-bordeaux.fr
=============================================================================

If anyone is interested in participating with this FAQ, just send me a
note with: your name/e-mail and the section you want to maintain.  

Many of the questions could be avoided, if people had read the FAQ of
the following newsgroups: news.announce.newusers, comp.lang.c,
gnu.emacs.help,  comp.unix.questions, comp.windows.x.i386unix.  
 
This article contains a listing of the sections *AND* queries answered
in the Linux FAQ. 

This FAQ is supposed to reduce the noise level ;-) in the comp.os.linux
newsgroup, and spare the time of many activists. I will cross-post it each 
month to news.answers. The Linux FAQ is NOT an introduction to UNIX, there
are many books for unix, and there is *also* a FAQ for unix (it's the
one of comp.unix.questions which contains things such as "How do I
remove a file named -". I DO NOT WANT TO ADD SUCH THINGS IN THIS FAQ
DEVOTED TO LINUX.

This FAQ is available at the main Linux sites in the doc directory,
the addresses are given in section II. of this FAQ. There is also an
archive of (all) FAQs at rtfm.mit.edu [18.70.0.224]. Have a look in
the anonymous ftp directory: /pub/usenet/news.answers/linux-faq.
If you do not have anonymous ftp access, you can access the archive by
mail server. Send mail to mail-server@rtfm.mit.edu with the words
"help" and "index" in the body on separate lines for more information.

The information in this multi-parts FAQ is likely to change relatively
quickly. If this is more than two months old (it was released on
July 1993) then you should obtain a new copy. See the paragraph
above for details of where to find a more recent version.

Please suggest any change, rephrasing, deletions, new questions,
answers ...  
Please include "FAQ" in the subject of messages sent to me about FAQ.  
Please send them to linux@labri.u-bordeaux.fr whatever will be the
From part of this message. Finally discussion about the FAQ can be
done on the DOC Channel (see section II). 

Regards,
				Marc-Michel

Thanks to Martin Schulze (Martin.Schulze@Informatik.Uni-Oldenburg.de),
the FAQ can be found in LaTeX version --- the first attempt was done
by Pepe de flores ---  at tsx-11.mit.edu in pub/linux/docs.

Future Plan:

	This document is under re-organization. Send suggestions to
	linux@labri.u-bordeaux.fr with a meaningful subject line.


================================8<=====8<==============================
CONTENTS
	0.	WARNINGS				(part1)
	I.	LINUX GENERAL INFORMATION		(part1)
	II.	LINUX USEFUL ADDRESSES			(part1)
	III.	INSTALLATION and COMMON PROBLEMS	(part2)
	IV.	SOME CLASSICAL PROBLEMS			(part2)
	V.	LINUX and DOS				(part2)
	VI.	MISCELLANEOUS HINTS			(part3)
	VII.	MORE HINTS				(part3)
	VIII.	FEATURES				(part4)
	IX.	GCC MISC INFORMATION			(part4)
	X.	SCSI SPECIAL				(part4)
	XI.	EMACS for LINUX				(part5)
	XII.	X11, THE MINIMUM and MORE		(part5)
	XIII.	NETWORKING and LINUX			(part5)
	XIV.	EVERYTHING FOR PRINTING			(part6)
	XV.	UUCP/NEWS/MAIL for LINUX		(part6)
================================8<=====8<==============================



0. WARNINGS
===========

I. LINUX GENERAL INFORMATION 
=============================
   I.01)  What is linux?
   I.02)   Does Linux support GCC, TCP/IP, X-Windows, MGR, etc.?
   I.03)   What is the current state of Linux?
   I.04)  Linux sounds great, but where do I get it and how do I 
     install it? 
   I.05)  Sounds good, but all of these docs are very confusing. Is
     Linux really difficult to install and use?
   I.06)  What's the best advice you can give to a Linux newbie?
   I.07)  Does it run on my computer?
   I.08)   How much space will Linux take up on my hard drive?
   I.09)   Will Linux run on a PC or 286-AT? If not, why?
   I.10)   Will Linux run on a 386 Laptop?
   I.11)   Why the suggested 4Meg, for Linux?
   I.12)   How would this operate in an OS/2 environment?
   I.13)  How long has Linux been publicly available?
   I.14)  How reliable is Linux, anyway?
   I.15)   What is the proper pronounciation for "Linux"?
   I.16)   What's about the copyright of linux?
   I.17)  Should I be a UNIX and/or a DOS wizard to install/use Linux?
   I.18)  Does Linux use TSS segments to provide multitasking?
   I.19)  If my PC runs under Linux, is it possible to ftp, rlogin,
     rsh etc.. to other Unix boxes?
   I.20)   Does linux do paging? Can I have virtual memory on my small
     machine?
   I.21)   Can I have tasks spanning the full 4GB of addressable 386
     memory? No more 64kB limits like in coherent or standard minix?
   I.22)   Does the bigger program sizes mean I can run X?
   I.23)   What are the differences, pros and cons compared to Minix ?
   I.24)   What are the pros and cons compared to 386BSD ?
   I.25)   Can't we split comp.os.linux ?

II. LINUX USEFUL ADDRESSES 
=========================

II.A. LINUX ON THE NET: ftp, mailing-list
II.B. OBTAINING LINUX FROM BBS'S: everything about bbs

II.A. LINUX ON THE NET
~~~~~~~~~~~~~~~~~~~~~~
  II.01)  Where can I get linux?
  II.02)  I do not have FTP access, what can I do to get linux?
  II.03)  Is there a newsgroup or mailing-list about linux? 
  II.04)  Where can I get my questions answered? How about bug-reports?
     What do I put into a post to comp.os.linux?
  II.05)  Could you be more explicit about the multi-channel list?
  II.06)  How can I join the channel XXX on the linux-activists
     mailing list?
  II.07)  How can I leave the channel XXX on the linux-activists
     mailing list?
  II.08)  I'm not an hacker, what are the channels I could be interested
     in? 
  II.09)  Does there exist a place where the traffic of the newsgroup
     is kept?

II.B OBTAINING LINUX FROM BBS'S
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
  II.10)   I don't have access to FTP, how can I obtain Linux?
  II.11)   I got this FAQ from a local BBS, or a friend, and I see there
     is a newsgroup called comp.os.linux .  I don't have access to USENET or
     mail, so how can I get the messages?
  II.12)   Do BBS's offer anything that the Internet does not?
  II.13)   What is a BBS?
  II.14)   How can I get a (Near) complete list of BBS's that carry Linux?

III. INSTALLATION, SETUP, and COMMON PROBLEMS
=============================================

III.A. WHERE TO START: What are the reliable sources of information
III.B. LINUX PACKAGES: Where and how install a complete Linux package

III.C. SOME COMMON PROBLEMS: Simple problems and simple solutions


III.A. WHERE TO START
~~~~~~~~~~~~~~~~~~~~~
 III.01)  I want to install Linux on my machine. Where do I start?
 III.02)  Is there some kind of limit on how large my Linux partitions
     and/or filesystems can be?

III.B. LINUX PACKAGES
~~~~~~~~~~~~~~~~~~~~~
 III.03)  Is there an easy way to get all of the Linux stuff?
 III.04)  Where can I get these releases of Linux?
 III.05)  What files do I need to get for the SLS release?
 III.06)  Now that I have the files, how do I install SLS?
 III.07)  Any other information about SLS?
 III.08)  How do I get and install H.J. Lu's "bootable rootdisk" release?

III.C. SOME COMMON PROBLEMS
~~~~~~~~~~~~~~~~~~~~~~~~~~~
 III.09)  What filetype is the extension ".z"? What about ".taz", 
     ".tpz", and ".tgz"? I see these files on the archives but I don't
     know how to unpack them.
 III.10)  How do I make partitions and/or filesystems for Linux?
 III.11)  Why does fdisk say "Linux cannot currently use XXXX sectors of
     this partition"? 
 III.12)  What does the message "MINIX-fs: Magic match failed" on bootup 
     mean?
 III.13)  Linux mkfs doesn't accept the size I give the device,
     although I double-checked with fdisk, and it's correct.
 III.14)   How can I get mkfs/mkefs to check for bad blocks?
 III.15)  How can I boot Linux off of my hard drive? 
 III.16)  How can I remove LILO from my hard drive?
 III.17)  When installing SLS, I get the error "You may have inserted
     the wrong disk" when putting in the next disk in a series. What's
     going on?
 III.18)   When installing SLS, the installation script creates a "boot
     floppy" for me to boot Linux with. How can I make these myself (or fix
     problems with them?)
 III.19)  How can I set the default video mode used by Linux? Do I have
     to recompile the kernel to do this? 
 III.20)   How else can I use rdev?
 III.21)   When I login as non-root, I get tons of errors about
     "shell-init: permission denied". Also, some things work as root but
     not as a normal user. What's the deal?
 III.22)  I have the previous version of the Linux kernel, how can 
     I upgrade it?
 III.23)  Where is /usr/include/linux and /usr/include/asm, or,
     Why won't the kernel compile correctly?
 III.24)   How can I upgrade to the newest version of GCC and/or
     libraries? 
 III.25)  What's the deal with these things called "jump tables"? 
 III.26)  How to upgrade jump tables? (Without hanging my system)
 III.27)  How can I be sure I won't be writing over anything important
     when installing Linux?  I have to use DOS on my machine, and I don't
     want to lose any files.
 III.28)  I just rebooted my machine, and now Linux dies with a
     "panic: trying to free unused inode". What's going on?
 III.29)  Can I use both OS/2 and Linux on my machine??
 III.30)   I use OS/2's Boot Manager on my hard drive. How can I get it
     to recognize Linux?
 III.31)   When I run Linux's fdisk it says "OPUS" for OS/2's Boot
     Manager partition. Is this right? What's OPUS?

IV. SOME CLASSICAL PROBLEMS 
===========================
  IV.01)  While running du I get "Kernel panic: free_inode: bit
     already cleared".  Also, du produces a ENOENT error for all the files
     in certain of my directories.  What's going on?
  IV.02)  How can I partition my hard-drive to use Linux?
  IV.03)  What must I do to mkfs a floppy?
  IV.04)  I can do this as root but not as non-root, is it a bug?
  IV.05)  Sometimes, I get "mount can't open lock file"; what does this
     means? 
  IV.06)  When I try "mount /dev/hd?? /user", I get error 2.
  IV.07)  Since I have upgrade my Linux kernel, ps won't work anymore,
     why? 
  IV.08)  Since Linux 0.96b I have a lot of core file all over
     my disk. How can I sweep them away ?
  IV.09)  I can only log-in as "root", is it normal ?
  IV.10)  Sometimes my Linux virtual console get messed up when I cat
     a binary file. The characters shown are above ascii 127, any clue ?

V. LINUX and DOS 
=================
   V.01)  Is is possible to access DOS from Linux?
   V.02)  Why use mtools if you can just mount a drive?
   V.03)  How do I get the mtools package set up correctly?
   V.04)  What is the format of the file /etc/mtools?
   V.05)  Where can I find out more about mtools?
   V.06)  How do I use the DOS file system?
   V.07)   When I mount an MS-DOS disk, I get two lines of what seem to
     be error messages and the message: No bmap support.  Is my disk bad?
   V.08)  I want to use the DOS file system with either conv=binary or
     conv=auto, but I want to convert text files from DOS to UNIX format,
     or from UNIX to DOS format.
   V.09)  Where can I find out more about the DOS file system?
   V.10)  This sounds me like a chicken and eggs problem, how can I
     install the mtools package at the very beginning.
   V.11)  Could someone explain how to use rawrite?
   V.12)  What is as86.tar.Z ?
   V.13)  Turbo (Microsoft) Assembler won't compile the Linux boot
     code.  In fact, some of the opcodes in these files look completely
     unfamiliar.  Why?
   V.14)  What about the dos emulator (dosemu)?
   V.15)   I have a Stacker volume on my hard drive.  Can I access that?
   V.16)   How about OS/2 HPFS partitions, or MacIntosh/Amiga floppies?
     Can I mount any of them?

VI. MISCELLANEOUS HINTS 
=======================

VI.A Misc Information
VI.B Minor/Major Information

VI.A. Misc information
~~~~~~~~~~~~~~~~~~~~~~
  VI.01)  It seems that $#@! ported on linux don't run correctly, what
     do I do about reporting bugs?
  VI.02)  Has $#@! been ported to Linux?
  VI.03)  I've ported $#@! to Linux, what should i do to add it in the 
     standard distribution?
  VI.04)  I want to port $#@! to Linux, what are the flags?

VI.B.Major/Minor device number
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
  VI.05)  What are the device minor/major numbers?
  VI.06)  (Chuck Boyer) Could some one clear up the devices meaning?

VII. MORE HINTS 
=============== 
 VII.01)  Where is 'which' ?
 VII.02)  How to use setterm: for the novice?
 VII.03)  I've tried clear/reset which exist on most of unix but it
     doesn't work, have I missed something? 
 VII.04)  I know there are VC, but where is the setterm stuff?
 VII.05)  I know there are shared libraries; does there exist an easy
     way to check an executable for sharing ? 
 VII.06)  What is the rdev program provided in the images?
 VII.07)  How to start Linux from drive B?
 VII.08)  The program boot_b works fine /but/ once the first disk is
     read the system go back to the first drive, any hints?
 VII.09)  How can I get Linux to boot directly from the harddisk?
 VII.10)  Sometimes, when I want to remove a directory, I get an error
     message, is it a (known) bug?
 VII.11)  I'm looking for init, getty, login, passwd stuff, where 
     can I find them? 
 VII.12)  How can I setup a user account other than root ?
 VII.13)  I've been trying to get Linux to run on my [3/4]86 box. It
     can't even boot. Any suggestions?
 VII.14)  Does there exist games, languages (other than C), and
     anything which make the system more friendly?
 VII.15)  I have an SVGA, but Linux detect an EGAc/EGAm; is it normal?
 VII.16)  How can I change the keyboard repeat rate?
 VII.17)  I compiled fdformat.c and ran it on 1.44Mb and 1.2Mb, the
     results are unreadable, any clue? 
 VII.18)  Is it possible to disable the 3-fingers salute (ctrl-alt-del) ?
 VII.19)  Could some one explain the information provided at boot-time?
 VII.20)  I have upgraded the kernel from XX to YY (XX > YY), however the
     login screen still says YY.
 VII.21)  What is doshell good for ?
 VII.22)  I don't have the kernel sources, how can I change the keyboard
     language?
 VII.23)  Does there exist a possibility to track down the source of
     kernel pannic messages ?

VIII. FEATURES 
==============
VIII.01)  I've read that linux has virtual consoles, what must I do to
     get them?
VIII.02)  When Linux boots, I get the following message "8 virtual
     consoles"; how can I acess to the 5-8 vc's ?
VIII.03)  What kind of shell is /bin/sh ?
VIII.04)  Does there exist a man page for **** ?
VIII.05)  Is there a simple man package (groff is too big):
VIII.06)  What are the editors available in linux?
VIII.07)  Does there exist a printer package for Linux?
VIII.08)  Are uucp, mail, and/or USENET news available for Linux?
VIII.09)  How do I make swapping work?
VIII.10)  When I boot I get one of the following messages:
     "Unable to find swap signature" or "Bad swap-space bitmap"
VIII.11)  How do I know if it is swapping?
VIII.12)  How is it possible to remove a swap file?
VIII.13)  How is it possible to remove a swap device?
VIII.14)  How much swap space do I need ?
VIII.15)  Could someone explain the swap process on Linux?, is it
     swapping or paging ?
VIII.16)  Is there any way to tell how much swap space you are using
     or have left? 
VIII.17)  I have a 2Megs box, but "free" reports only 1Meg why?
VIII.18)  What tape drives work with Linux ?
VIII.19)  Is there a driver for my Colorado Jumbo tape drive ?
VIII.20)  Does there exist shared libs ?
VIII.21)  Does Linux work for SCSI drives?
VIII.22)  Linux is supposed to work with ESDI drive. However I have
     trouble with my Magtron MT-4115E (Joincom controler), any clue?
VIII.23)  How does one go about applying a patch to Linux ?
VIII.24)  I got the patches on some ftp sites, and applied them to the
     kernel and tried to compile. It didn't !!. Are the patches buggy?
VIII.25)  What is VFS?
VIII.26)  What's about Bus Mice ?
VIII.27)  What's about TeX ?
VIII.28)  What's about MGR ?
VIII.29)  What's about X11 ?

IX. GCC MISC INFORMATION
========================
  IX.01)  What C compiler should I use for Linux ?
  IX.02)  Where can I found information about the C compiler ?
  IX.03)  I seem to be unable to compile anything with gcc. Why?
  IX.04)  How to compile programs which may be debugged with gdb?
  IX.05)  When compiling some code, cc1 complains about some insn
     code, what's that? 
  IX.06)  How can I write codes suitable for building shared library ?

X. SCSI SPECIAL
===============
   X.01)  What hardware is supported?
   X.02)  What hardware is not supported?
   X.03)  How do I get SCSI information?
   X.04)  Where is the latest version maintained?
   X.05)  I've found one of the following bugs :
   X.06)  What do I do if I find a bug that still looks like a 
     bug after I've read the FAQ?
   X.07)  What SCSI disks are supported? 
   X.08)  What about CD ROMS?
   X.09)  What about SCSI tapes ? 
   X.10)  How do I partition the disk?
   X.11)  The linux partitioning programs don't work.
   X.12)  My partitioning program can't figure out the disk geoemetry
   X.13)  What are the major / minor numbers for SCSI drives?
   X.14)  My tape drive or other removeable media device isn't recognized
     at boot time.
   X.15)  How do I reduce kernel bloat and eliminate the drivers I
     don't want?
   X.16)  I get SCSI timeouts.
   X.17)  My Seagate / Future Domain TMC-88x board is not detected.
   X.18)  The Seagate / Future Domain TMC-88x driver doesn't work.
   X.19)  The Adaptec driver doesn't work.
   X.20)  The WD-7000FASST driver doesn't work
   X.21)  My Ultrastor 14F or 34F isn't detected 
   X.22)  When using a Seagate / Future Domain TMC-88x, why does my system 
     hang when syncing to disk?
   X.23)  My system is dog slow (ie, 60k/sec)

XI. EMACS for LINUX
=====================

XI.A. GENERAL INFORMATION 
XI.B. GNU EMACS for LINUX

XI.A. GENERAL INFORMATION
~~~~~~~~~~~~~~~~~~~~~~~~~~~

XI.B. GNU EMACS for LINUX
~~~~~~~~~~~~~~~~~~~~~~~~~~~
  XI.01)  What versions of GNU Emacs are available for Linux?
  XI.02)  Which files do I need?
  XI.03)  What if I want to compile Emacs myself?
  XI.04)  How do I get Emacs to recognize my cursor keys?
  XI.05)  What packages are particularly useful under Linux?
  XI.06)  Why does Emacs from the SLS dump core?

XII. X11 THE MAXIMUM and MORE
=============================

XII.A. X386 GENERAL INFORMATION
XII.B. HARDWARE REQUIREMENTS: Supported Video cards, mice.

XII.C. LINUX DISTRIBUTION: Files required, Current version.
XII.D. LEARNING/USING X: Pointers to X documentation.

XII.E. DEBUGGING STARTUP PROBLEMS: Checklist, Screen restoration, Hanging.
XII.F. XCONFIG: Video mode settings and common errors in Xconfig.

XII.G. X-APPLICATIONS: Compiling X programs.
XII.H. ATI: SVGA server for ATI boards.

XII.I. BUGS


XII.A. X386 GENERAL INFORMATION
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
 XII.01)  What is the X11 release supported by Linux?
 XII.02)  What is X386/XFree86?
 XII.03)  Where can I get X386 1.2 (X11R5)?
 XII.04)  Any tips on compiling X11R5?

XII.B  HARDWARE REQUIREMENTS:
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
 XII.05)  What VGA boards are supported?
 XII.06)  What Mouses are supported?

XII.C. LINUX DISTRIBUTION
~~~~~~~~~~~~~~~~~~~~~~~~~
 XII.07)  What is the current version?
 XII.08)  What Files do I need to download?
 XII.09)  Where do the X11 files go? What are they?

XII.D.  LEARNING/USING X
~~~~~~~~~~~~~~~~~~~~~~~~
 XII.10)  Where can I find the basic help for learning/using X ?
 XII.11)  What docs are available besides man pages?
 XII.12)  How do I start up X?
 XII.13)  How can I start X directly with xdm after booting ?
 XII.14)  How do I configure X .. colors, menu, keyboard?
 XII.15)  [suggested by Thomas Koenig]
     	How do I support national keyboards in X11 ?

XII.E. DEBUGGING STARTUP PROBLEMS:
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
 XII.16)  What do I use in my Xconfig file to use the bus mouse?
     Logitech doesn't work with my Logitech busmouse.
 XII.17)  My busmouse works fine with windows but ...
 XII.18)  Does anyone have a working PS/2 mouse? Has anyone gotten the 
     "Mini-DIN" mouse on an HP Vectra 486/33T to work? The slight info I've 
     been able to find says it's PS/2 compatible. Does anyone have a
     working MouseMan on a PS/2 port ?
 XII.19)  I have trouble with my logitech Pilot mouse and X under
     Linux, any clue ? 
 XII.20)  I cannot type in my xterm 
 XII.21)  What are some of the common omissions and errors?
 XII.22)  Why is the server unable to find some of the fonts?
 XII.23)  My server "hangs" Why?
 XII.24)  When I started X11 I got "Cannot connect to
     server" or "process does not exist", any clue ?
 XII.25)  Why cant I run more than 4 xterms?
     	  How can I have more than 4 pty's ?
 XII.26)  How does X11 start up?
 XII.27)  What devices does X depend on:

XII.F. Xconfig: Xconfig and Video mode settings.
~~~~~~~~~~~~~~~
 XII.28)  What do the mode names in Xconfig mean?
 XII.29)  How do I compute the numbers for the video modes?
 XII.30)  How can I determine the clocks on the video chip?
     	Where can I find clock.exe or clock.pas ?
 XII.31)  What are the settings used with a trident-8900C?
 XII.32)  Oh what, Oh what, Oh what can I do with a trident 8900b?
 XII.33)  What are common problems with Xconfig?
 XII.34)  Where can I get Xconfig-files for various hardware?

XII.G X-APPLICATIONS: Compiling X Programs.
~~~~~~~~~~~~~~~~~~~~~
 XII.35)  Does anyone know where I can find the libobz.a library ?
 XII.36)  I get _setjmp undefined when linking xv from .a files.
 XII.37)  How do I compile an X application that has an Imakefile?
 XII.38)  How do I compile a program that has no Imakefile?
 XII.39)  gcc complains the X libraries are not found or links static.
 XII.40)  When using Makefiles generated by xmkmf why do I get many error 
     	messages?
 XII.41)  (Ton van Rosmalen wrote):
     I recently compiled XFree86 1.2A for Linux and it compiled fine with
     gcc-2.3.3 and libc-4.3.3 iff I skipped the make depend.
 XII.42)  What are the  development tools available for X under Linux?

XII.H ATI: SVGA server for ATI boards.
~~~~~~~~~
 XII.43)  What's new?
 XII.44)  What is the ATI SVGA driver?
 XII.45)  What is the ATI SVGA driver *NOT*?
 XII.46)  What cards will the driver work with?
 XII.47)  What should I put in my Xconfig file?
 XII.48)  What is the history of the driver?
 XII.49)  What is the future of the driver?

XII.I BUGS:
~~~~~~~~~~~

XIII.	NETWORKING and LINUX
============================
XIII.01)  Where can I find useful information about networking for
     Linux ?

XIV.  EVERYTHING FOR PRINTING
=============================
 XIV.01)  What _is_ the Linux lpr/lpd package?
 XIV.02)  What is _the_ Linux lpr/lpd package?
 XIV.03)  How do I get lpr to work properly other than for root? Where
     do the files go and what should their permissions be?
 XIV.04)  What are all these diretrories for? (/etc, /usr/etc,
     /etc/inet,
     /usr/spool, /var/spool)
 XIV.05)  Why do I get ``jobs queued, but cannot start daemon'' or
     ``lpc: connect: No such file or directory'' ?
 XIV.06)  Where do I get a printcap for a xxxxx?
 XIV.07)  What is the content of /etc/printcap?
 XIV.08)  What is the format of a /etc/printcap?
 XIV.09)  My /etc/printcap looks identical to someone else's but it
     doesn't work - why?
 XIV.10)  What's the minimum /etc/printcap?
 XIV.11)  How do I prevent the `staircase effect'?
 XIV.12)  How do I get my printer to go back to the default font after
     each printout?
 XIV.13)  How do I prevent a formfeed at the end of every printout?
 XIV.14)  How do I print to a serial port?
 XIV.15)  What serial settings do I have to put in my printcap? How do
     I know how to set them?
 XIV.16)  I can cat to the serial port, but lpd won't print anything
     (1).
 XIV.17)  I can cat to the serial port, but lpd won't print anything
     (2).
 XIV.18)  How do I use a printer that's doesn't present a normal
     device interface?
 XIV.19)  How do I get burst/banner pages?
 XIV.20)  How do I print text on a PS printer?
 XIV.21)  Why do files with a lot of graphics get truncated?
 XIV.22)  Why doesn't `lpr -i' work?
 XIV.23)  Why doesn't `lpr -p' work?
 XIV.24)  Why does lprm say `too many users'?
 XIV.25)  Why does lpc complain that it hasn't stopped a daemon?
 XIV.26)  Why does
 XIV.27)  How do I print over a Network?
 XIV.28)  Which /dev/{tty,cua,lp}*  is my printer?
 XIV.29)  When the kernel boots it says `using polling driver,' is
     there an interrupt driven driver?
 XIV.30)  What's the difference between the polling driver and an the
     interrupt driven one?
 XIV.31)  How do I write filters?
 XIV.32)  I've written a filter in shell script which works OK when I
     use it from the shell prompt but fails when I tell lpd to use it?
 XIV.33)  When should I define an `of' filter?
 XIV.34)  Where do I get filters for given printers?
 XIV.35)  How do I get a program that won't read from STDIN to act as
     a filter?
 XIV.36)  The set of filters supported by lpd seem strange - why
     aren't there filters for Postscript, GIF, TIFF and so on?
 XIV.37)  What are magic filters?

XV. UUCP/NEWS/MAIL for LINUX
============================

XV.A. General Information
XV.B. UUCP

XV.C. News
XV.D. Mail

XV.A. General Information
~~~~~~~~~~~~~~~~~~~~~~~~~
  XV.01)  What uucp, news, and mail software works under Linux ?
  XV.02)  So where are the sources ?
  XV.03)  Do I really need the sources ?
  XV.04)  How do I get my system a news/mail/uucp feed ?

XV.B. UUCP
~~~~~~~~~~
  XV.05)  Why do I get 'timeout' on connections when I upgraded to
     uucp-1.04 ? 
  XV.06)  Why doesn't anonymous uucp seem to work ?

XV.C News
~~~~~~~~~
  XV.07)   What newsreader is best ?
  XV.08)  with trn - why do I get the message 'dbinit failed' ? 
  XV.09)  why is my 'nn' database getting continuously corrupted ?
  XV.10)  why can't I post to moderated groups ?
  XV.11)  Why do I have problems that appear to be permission-related ?
  XV.12)  Why doesn't SLS have the 'Performance Release' of C-news?
     	  INN ? NNTP ? 
  XV.13)  Why does doexpire say "severe space shortage" when there's
     	lots of room ? 
  XV.14)  How do I set up NNTP?

XV.D. Mail
~~~~~~~~~~
  XV.15)  Why is my hostname.domainname not in my headers and
     something funky's there ? 
  XV.16)  Why can't elm write to my mailbox ?
  XV.17)  is sendmail+IDA available for Linux instead of smail ?
-- 
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
#	LaBRI 			 |					    #
#  351 cours de la Liberation    |  e-mail:  corsini@geocub.greco-prog.fr   #
#  33405 Talence Cedex		 |  e-mail:  corsini@labri.u-bordeaux.fr    #
#  				 |					    #
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
-- 
	 There will be a sig when our local net is reliable.
	       For now, I would rather stay anonymous.


^ permalink raw reply	[flat|nested] 8+ messages in thread
* Linux Frequently Asked Questions 6/6 [monthly posted]
@ 1993-06-11 10:06 corsini
  0 siblings, 0 replies; 8+ messages in thread
From: corsini @ 1993-06-11 10:06 UTC (permalink / raw)


Archive-name: linux-faq/part6

Last-Modified: 93/06/11
Version: 1.19

*********************************************************
*							*
*   Answers to Frequently asked questions about Linux   *
*							*
*********************************************************

This post contains Part 6 of the Linux FAQ (6 parts).
It must be read *after* the 5 first parts. 

===================================8<====>8============================
CONTENTS (of this part)

	XIV.	EVERYTHING FOR PRINTING		(part5)
	XV.	UUCP/NEWS/MAIL for LINUX	(part6)

===================================8<====>8============================



XIV.  EVERYTHING FOR PRINTING
=============================
**** This is the lpd FAQ version 1.3 (last update 8th june), this
**** section is maintained by Brian McCauley. Please send any
**** suggestion to: B.A.McCauley@bham.ac.uk

 XIV.01)  What _is_ the Linux lpr/lpd package?

ANSWER: To quote the net-FAQ:

Lpr is a utility that is used to print files out to local and remote
printers. As with all networking, there are configuration files which
have to be tailored to your needs. These files are concerned with
access control, accounting and page setup of your printer(s).  Now all
control of the printer is performed by a process called lpd

Lpd is a laser printer daemon (yes I know an epson isn't a laser
printer but thats besides the point). The program lpd is normally
started in /etc/rc.local in either the forground or the background.
What happens is that lpd will sink back as a daemon, only ever being
invoked when a printer request is generated. lpd itself has some
options which are of possible intrest to some people chiefly that of
the '-l' flag which causes lpd to log requests recieved from the
network (useful for debugging). The other option is for what port lpd
should listen for data on and is generally not used.

[ Note: lp really stands for line printer but as technology has
advanced laser printer makes more sense. Note also that lpr can be
used for queuing requests to use any specialised resource on a network
not just hardcopy output devices. ]


 XIV.02)  What is _the_ Linux lpr/lpd package?

ANSWER: Up until 28th May 1993, as far as there is a definitive Linux
version of anything _the_ Linux lpr/lpd is <bir7@leland.stanford.edu>
Ross Biro's port of the BSD sources dated 20th November 1992 (so if
you're used to AT&T's you'll find some differences).  Ross's binaries
and the diffse wer found in:

tsx-11.mit.edu:pub/linux/binaries/usr.bin/lpr.tar.Z
sunsite.unc.edu:pub/Linux/system/Daemons/lpr.tar.Z

The SLS file lpr.tgz on disk b2 contained the same stuff.

In addition to the standard BSD lpr capabilities Ross Biro's port
should have had better support for serial printers (but it didn't work
in the old binaries).

Ross's port was not based on the latest BSD sources (by about 3 years,
'88 vs '91). His new release will also be based on these sources which
can be found are at:

gatekeeper.dec.com and /afs/ir.stanford.edu/src/...

However this changed as of about 28th May 1993 so from now on this
version will be called the "old" binaries. On or about that date two
different new releases of lpd appeared. One of these was a version of
Ross's with bug fixes in:

sunsite.unc.edu:pub/Linux/system/Daemons/lpr.tar.z
tsx-11.mit.edu:pub/linux/binaries/usr.bin/lpr.tar.z

The other is a port of the '91 BSD sources by
<waltje@uWalt.NL.Mugnet.ORG> Fred van Kempen port and is availble as
source:

tsx-11.mit.edu:pub/linux/packages/net/net-2/sources/lpd/ 

or as part of the net-2 binary release in:

tsx-11.mit.edu:pub/linux/packages/net/net-2/binaries/net-std.tar.z 

Original '91 BSD sources are all over the place.

ftp.uu.net:systems/unix/bsd-sources/usr.sbin/lpr/
src.doc.ic.ac.uk:unix/bsd-sources/usr.sbin/lpr/

to name but two. The BSD sources have unGNU things in their Makefiles
so they don't compile ``out of the box''.

Ross agrees that Fred's version should be thought of as _the_ Linux
lpd package. I <B.A.McCauley@bham.ac.uk> have not had a chance to look
at the differences in detail yet, but most of this FAQ refers to the
BSD lpd package or Linux in general so this is probably not too
important.

There are some other versions of lpd stuff about but I have to draw
the line somewhere. If anyone whants to maintain FAQ sections on these
they are welcome to do so. The other versions include plp and the ka9q lp
facility. There are also rumours of SysV spoolers being ported.


 XIV.03)  How do I get lpr to work properly other than for root? Where
do the files go and what should their permissions be?

ANSWER: There is quite a bit of variation between the various releases
but I'll try where possible to offer solutions that are universally
applicable. Put /etc/lpd& in your /etc/rc or /etc/rc.local (usually in
/etc/rc.local after you start syslogd (if you use syslogd)).

Set the group fields of the file permissons/ownership as follows:

-rwxr-s---   1 root     daemon      37892 Nov 19 23:32 /etc/lpd
-rwx--s--x   1 root     daemon      21508 Nov 19 23:32 /usr/bin/lpc
-rws--s--x   1 root     daemon      17412 Nov 19 23:32 /usr/bin/lpq
-rwx--s--x   1 root     daemon      17412 Nov 19 23:32 /usr/bin/lpr
-rwx--s--x   1 root     daemon      17412 Nov 19 23:32 /usr/bin/lprm
-r-xr-xr-x   1 root     daemon       2816 May 10 13:37 /usr/bin/lptest
srwxrwxrwx   1 root     daemon          0 Feb  4 20:54 /dev/printer

...and for each of the spool directories listed in the sd fields of
/etc/printcap... 

/usr/spool/lpd:
total 5
drwxrwxr-x   2 root     daemon       1024 May 18 23:00 .
drwxr-xr-x  11 root     root         1024 Feb 19 20:56 ..
-rw-rw-r--   1 root     daemon          4 May 18 23:00 .seq
-rw-rw-r--   1 root     daemon         18 May 18 23:00 lock
-rw-rw-r--   1 root     daemon         25 May 18 23:00 status

Note these 3 files are created by lpr and lpd so if you've never
run these they could be missing so touch them into being.

In Fred's port the group is ``lp'' not ``daemon''. You don't need the
socket /dev/printer for Fred's port as it keeps it's socket in
/tmp/.printer and creates/deletes it as needed.

Some of these permissions may be overkill so don't be surprised if
your system works with different permissions. The fact that lpq needs
to be suid root is inelegant and may change in the future. People tell
me that lpr must be setuid(root) but I've not seen evidence that this
is really the case as long as the file permissions on the spool queues
are right. Still as far as I know lpr is designed to be secure when
installed setuid(root).

Alternative approach: just make lpc, lpr and lprm setuid(root) then
you can almost forget the file permissions on the spool queues!

You're free to choose different directories for the executables on
your system (notably lpc is usually in /etc even though it has
commands that are useful to non-root).

There location of master lpd lock file is fixed at compile time. It is
either in /usr/spool/lpd.lock or /var/spool/lpd/lpd.lock depending on
which version of lpd you get.

My advise is keep your primary spool queue in /usr/spool/lpd and make
/var a symlink to usr or keep it in /var/spool/lpd and make /usr/spool
a symlink to ../var/spool. This gives the greatest compatibility with
the pathnames that are compiled into the various distributed binaries.

The main configuration file is /etc/printcap although the old binaries
look for it in /usr/etc/.  The old binaries' README says hosts.equiv
and hosts.lpd files are looked for in /etc/inet but again the more
accepted convention is to locate them in /etc.

Since, IMHO, working out in which particular etc directory each file
should reside is tedious, I would advise having only one:

mv -i /usr/etc/inet/* /etc/inet/* /usr/etc/* /etc/
rmdir /usr/etc/inet /etc/inet /usr/etc
ln -s ../etc /usr/etc
ln -s . /etc/inet

[But make sure the files in /usr/etc and /etc/inet are not already
symlinks into /etc or you'll be in deep water.]

This makes your /etc huge but I think it's safe as I'm not aware of
any packages that require different files or the same name in /etc and
/usr/etc. [Health warning: this is IMHO - other people have different
ideas.]


 XIV.04)  What are all these diretrories for? (/etc, /usr/etc, /etc/inet,
/usr/spool, /var/spool)

ANSWER: This is one to which I can't find a staight answer.

For various reasons including the difficulties of fsck'ing / some
people like to put all things that aren't needed during bootstrap in
/usr so that / is as small as possible. They therefore move
unessential big files (usually the binaries) from /etc/ to /usr/etc/.

Unless you know what you are doing I'd advise keeping it all in /etc
with /usr/etc and /etc/inet being symlinks back to /etc. (In fact
these links are probably soon to be redundant as most recent binaires
now look in /etc/.)

The alternative approach is to have a real /usr/etc directory
containing all the non-essential stuff and make symlinks to each file
therein from its namesake in /etc.

Also a few people like all their internet stuff in /etc/inet but as
recent binaries excpect to find this stuff in /etc they must create
links for each file from /etc into /etc/inet.

If you want to spread out your configuration files for the sake of
tidiness then a better solution is to have a directory tree called
/conf and make the files in /etc symlinks into this tree.

To avoid the problem of your /usr filesystem filling up as a result of
stuff in spool queues some poeple perfer to keep their spool queues
and such like in a separate filesystem called /var. If you don't have
a /var file system then you should make /var a symlink to usr. If you
_do_ have a /var filesystem to may want to make /usr/spool a symlink
to ../var/spool so that any programs expecting to find /usr/spool will
not be dissapointed.


 XIV.05)  Why do I get ``jobs queued, but cannot start daemon'' or
``lpc: connect: No such file or directory'' ?

ANSWER: Firstly this "start" in the context of this error really means
"wake". If ``ps ax'' does not reveal a lpd then you daemon has died
(or was never started).

If you so have an lpd then you are having trouble with the socket
connection to lpd.  I don't really understand this but the problem was
common in early days with the old binaries but developments in the
TCP/IP code in the kernel fixed it for most people. Using the new lpd
from the net-2 package without the net-2 kernel stuff sometimes gives
this problem.

When I get it I find that kill and restarting lpd a few times will
eventually get rid of the problem. There has also been a suggestion
that recompiling your kernel without TCP/IP at all can help. If
linux-0.99pl10 with it's all new TCP/IP stuff doesn't fix this then
further reserch is probably called for.


 XIV.06)  Where do I get a printcap for a xxxxx?

ANSWER: This question is essentially meaningless - see next question.


 XIV.07)  What is the content of /etc/printcap?

ANSWER: Given the similarity in appearence and name between
/etc/termcap and /etc/printcap one could be forgiven for assuming that
they contain analogous infomation. This is not the case. Whereas
termcap contains informations about terminal *types* - (mostly escape
seqences) printcap contains information about *specific* printers
(like the directory that holds the spool queue and the device name of
the printer). The information about a printer model's escape sequences
and so on are held in the various filters which are _programs_ called
by lpd to drive the printer. /etc/printcap simply gives the locations
of these filters.  For details RTFM(printcap). [Alternatively the
net-FAQ has a summary of some of the more important fileds.]

One last point you should always specify ``suppress header'' ``:sh:''
unless you have *text* (_not_ postscript) printer and want banners. On
a text printer they are usually a waste of time and paper. On a
postscript printer they usually stop your printer working.  (See the
banners question for further expanation).


 XIV.08)  What is the format of a /etc/printcap?

ANSWER: Ideally RTFM(termcap) (yes, I said *termcap*) but since most
people don't have TFM(termcap) here are the essentials.

Lines starting # are comments (as you might have guessed).

For each printer usable from the lpr command on your system there is
one logical line in the file. For the sake of readability each logical
line may be spread over several physical lines by making the last
character on all but the last physical line a backslash.

Each logical line has the following format:

name1|name2|name3:string_capability=string:\
       :numeric_capability#number:boolean_capability:

The leading spaces and colon on the second line are for readability
only.

A printer can have as many names as you like but conventionally the
final name is used as a longhand description of the printer. (Still
people are free to say `lpr -P "Fred's grotty teletype"' if that's
the description you've given.)

The list of capabilities can be as long as needed and the order is not
significant. Each ``capability'' is denoted by a two character code.
(The name ``capability'' comes form the file format's termcap heritage
- parameter or attribute would be a more sensible terms.) [Note from
Ross Biro: capabilities with 3 character names don't work properly
which is why the serial port stuff in the old binaries failed.]
Capabilities having string value and have a = delimiter between the
capability name and the value while those having a numeric value use a
# (actually they can use either a # or an =). Boolean ``capablilties''
are true if they appear in the list and false if they do not.

Special characters in a string value can be expressed using `\'-escape
sequences as in C; in addition, `\E' stands for ESC.  `^' is also a
kind of escape character; `^' followed by CHAR stands for the
control-equivalent of CHAR.  Thus, `^a' stands for the character
control-a, just like `\001'. `\' and `^' themselves can be represented
as `\\' and `\^' respectively. `\:' for `:' seems to work but the
source code contains a comment to the effect that it is unsafe and
`\072' is a better idea.

Example:

lp|bam|BAM's Epson FX-80:lp=/dev/lp1:sd=/usr/spool/lp1:sh:mx#0:\
	:df=/usr/local/lib/magic-filter/lp.df:\
	:if=/usr/local/lib/magic-filter/lp.if:

Name is lp (this is the printer that lpr uses by default). It's also
known as bam or "BAM's Epson FX-80".

The printer is on /dev/lp1 (aka AT-bus LPT1:). I don't want a burst
page. I don't want a file length limit. Files queued by `lpr -d' are
passed through /usr/local/lib/magic-filter/lp.df and those queued by
`lpr' through /usr/local/lib/magic-filter/lp.lf.

See also the next question.


 XIV.09)  My /etc/printcap looks identical to someone else's but it
doesn't work - why?

ANSWER: See if lpc stat reports a printer called ` :'. The last
character on a continued line must be a \. If there are whitespace
characters after the \ then it doesn't register the next line as a
continuation.
 

 XIV.10)  What's the minimum /etc/printcap?

ANSWER: This is a silly question but it _is_ frequently asked. The
answer is ``lp:sh'' (that's 6 bytes including the required linefeed
character on the end). To use this /etc/printcap you must make /dev/lp
a symlink to your printer and create your spool queue directory as
/usr/spool/lpd.  (You might think that if you wanted banner pages you
could loose the ``:sh'' but the termcap syntax requires at least one
capability per entry).


 XIV.11)  How do I prevent the `staircase effect'?

ANSWER: Unix terminates each line of a file with a linefeed but not a
carriage return so taken literally a Unix text file printed on an
ASCII device will start each line below the end of the previous line.
Some printers can be set to treat "linefeed" as "carriage return,
linefeed", others can't. If yours can then do simply do that. If the
printer cannot be fixed create a shell script filter that reads:

#!/bin/sh
if [ $1 = -c ]; then
  cat
else
  sed -e s/$/^M/
fi
echo -ne \\f

where ^M is a carriage return character not a ^ followed by a M.  To
type ^M in emacs use the sequence C-q C-m and in vi use C-v C-m.
Conventionally this script is called /usr/lib/lpf. The test of $1
allows the isertion of carriage returns to be switched off by the `-l'
switch on lpr.

Alternatively your printer may have an escape sequence that will set
the way it handles linefeed characters. A simple filter that uses an 
`echo -ne' command to send this sequence may be appropriate.

#!/bin/sh
# Filter for HP printers to treat LF as CRLF  
echo -ne \\033\&k2G
cat
echo -ne \\f

[Ross Biro's new release includes a slightly more complex filter
stript called /usr/lib/hpof that does this and a few other things to
make an HP printer behave sensibly even if it was in the wrong
language when you started.]


 XIV.12)  How do I get my printer to go back to the default font after
each printout?

ANSWER: Either make your filters do it or define the `tr'
``capability'' in /etc/printcap to be your printer's font reset
command. For details of the format of this string see the question on
the format of printcap. This may not work if a printout crashes in the
middle of an escape sequence - putting a lot of ^@ on the front may
help but this probably won't be enough it you were printing raster
graphics when the filter died.


 XIV.13)  How do I prevent a formfeed at the end of every printout?

ANSWER: If you don't have an `if' specified in /etc/printcap then lpd
will automatically put a formfeed at the end of each file. If you're
using a filter then it's up to the filter to decide if it wants to put
a formfeed. To disable formfeed completely if you don't have an `if'
put :ff=: in your /etc/printcap.  But please note this suppresses the
formfeed that would usually be printed if a filter dies. If you want
formfeeds after text printouts but not on printouts printed with `lpr
-l' then create the following `if' filter:

#!/bin/sh
cat
if [ "$1" != -c ]; then
  echo -ne \\f
fi

If you want a formfeed after `lpr -l' to be optional you can misuse the
`-i' switch to suppress the formfeed with the following trick (after
all `lpr -i -l' would usually not be implemented).

#!/bin/sh
cat
# use lpr -i -l to print raw without trailing formfeed
if [ "$1" != -c -o "$4" = -i0 ]; then 
  echo -ne \\f
fi 


 XIV.14)  How do I use a printer that's doesn't present a normal
device interface?

ANSWER: [Firstly I'll explain the question.] The most common example
is a printer that is connected via a network in some strange way.  For
example consider a printer conneccted to a host running some esoteric
OS with which you can only communicate via E-mail. To use this printer
without going through lpr you would say something like:

  | uuencode tmp | mail printer-request@eosteric

in place of: 

  > /dev/lp

To use such a printer through lpr the ``lp'' capability of the print
queue can be directed to /dev/null and _each_ filter must must
explicitly uuencode and mail its output. In more complex cases if you
already have an ``if'' or ``of'' filter for a strangely connected
printer then other filters can pass their output to/through this
filter to avoid duplication of effort.  In this case the ``if'' filter
should usually be called with the ``-c'' switch to minimise the
further manipulations if performs.


 XIV.15)  How do I get burst/banner pages?

ANSWER: For a simple text printer (in particular not postscript) and a
simple text banner simply take :sh: out of the printcap record. If you
want to prevent the banner comming out in whatever font was last used
on the printer then define the `tr' ``capability'' to be your
printer's font reset command.

If you want a fancy cusomised banner (or have a postscript printer)
leave :sh: in the printcap and make each of your filters print the
banner. All the information to put on the banner is included in the
filter's positional parameters.  RTFM(printcap) for details. [ If
you're using <B.A.McCauley@bham.ac.uk>'s magic-filter package then
call the code to print the banners from the config script. ]


 XIV.16)  How do I print text on a PS printer?

ANSWER: You need a filter based on a program that converts ascii to
postscript. The most well known of these is ``enscript'' but it's also
the hardest to find. Others include ``a2ps'' and ``mpage'' (for
details of these see the periodic c.o.l.a posting "How to print under
Linux" by <gtaylor@god.hounix.org> Grant Taylor)

The nearest thing to enscript that an archie search revealed was a
package called ``nenscript-1.13++.tar.Z'' deep in the guts of
gatekeeper.dec.com which appears to do the job but it's prone to
trimming off the tops of your pages.  (It didn't compile ``out of the
box'' with the GNU libs but all it needed was one #undef.)

[I've not looked into these in detail as I don't have a PS printer. I
would like someone to send me an exaple of a filter that they use
using one of these.]


 XIV.17)  Why do files with a lot of graphics get truncated?

ANSWER: Usually because you've got a limit set on the maximum size
file that can sit in the spool queue. Put `mx#0' in your printcap.


 XIV.18)  Why doesn't `lpr -i' work?

ANSWER: To get lpr -i to work you need a filter istalled as `if' that
implements it.  The -i switch is simply passed on by lpd to the filter.
There is such a filter usually called /usr/lib/lpf that can be obtained from
bsd source archives in the directory bsd-source/lpr/filters.  It's also part
of Fred's port but he put it in /usr/bin/.  If you whant to use this program
but still want your filter to do some printer specific initialisation then
write script thus:

#!/bin/sh
# My initialisation stuff goes here
exec /usr/lib/lpf $*


 XIV.19)  Why doesn't `lpr -p' work?

ANSWER: Because it's broken. lpd always thinks that the printer is 0
characters wide regardless of what printcap says. This is still broken
in Ross's new release and Fred's port of the '91 sources. Looking at the
sources the fix for Fred's port appears to be:

-------------------------------Cut Here-------------------------------------
*** printjob.c.old	Sat Feb 27 14:07:01 1993
--- printjob.c	Sun Jun  6 11:02:36 1993
***************
*** 265,271 ****
  	 */
  	for (i = 0; i < 4; i++)
  		strcpy(fonts[i], ifonts[i]);
! 	strcpy(width+2, "0");
  	strcpy(indent+2, "0");
  
  	/*
--- 265,271 ----
  	 */
  	for (i = 0; i < 4; i++)
  		strcpy(fonts[i], ifonts[i]);
! 	sprintf(&width[2], "%d", PW);
  	strcpy(indent+2, "0");
  
  	/*
***************
*** 1081,1087 ****
  		FF = DEFFF;
  	if ((PW = pgetnum("pw")) < 0)
  		PW = DEFWIDTH;
- 	sprintf(&width[2], "%d", PW);
  	if ((PL = pgetnum("pl")) < 0)
  		PL = DEFLENGTH;
  	sprintf(&length[2], "%d", PL);
--- 1081,1086 ----
----------------------------------Cut Here------------------------------

This patch is untested as I don't have a complete set of net-2 include
files on my machine yet.

One other thing: lpd calls pr by full pathname so if you keep pr
somewhere different from where lpd looks you will need a symlink.
Where lpd expects to find pr varies from version to version but I
think /usr/bin/pr is the usual place.


 XIV.20)  Why does lprm say `too many users'?

ANSWER: This was a bug in the C library in the scandir() function
which failed when an unsorted directory list was requested. This has
been fixed now so just get a new libc.so. Alternatively there is a
lprm with a workround (by toy@soho.crd.ge.com) in:

sunsite.unc.edu:/pub/Linux/system/Daemons/lprm-fix.tar.z


 XIV.21)  Why does lpc complain that it hasn't stopped a daemon?

ANSWER: There's one lpd process that runs all the time and it spawns
off children to handle each printer as needed. These children leave
lock files lying about so lpc thinks that they are still running and
tries to kill them. Was a bug but it was not serious and is fixed in
the latest releases.


 XIV.22)  Why does 


 XIV.23)  How do I print over a Network?

ANSWER: To print on the printer "foo" connected to the machine
"bar.baz.net" from the machine "mine.baz.net" you put an entry like
this in your /etc/printcap (on mine.baz.net):

foo:lp=:rm=bar.baz.net:rp=foo:sd=/usr/lpd/spool/foo:

and, of course, create the spool directory /usr/lpd/spool/foo.

There's no point specitying filters and the like in
mine.baz.net:/etc/printcap as it's the one in
bar.baz.net:/etc/printcap that will get used.

On the machine bar.baz.foo, you need to put "mine.baz.net" on a line
by itself in either /etc/hosts.equiv or /etc/hosts.lpd; note that
putting it in /etc/hosts.equiv will allow for unauthenticated logins as
well as printing.  /etc/hosts.lpd is printing only.

[ Editors note: I realise there are more questions about net printing
but I don't know them. If you find any let me know (with answers if
possible). See also the net FAQ ]


 XIV.24)  Which /dev/lp* is my printer?

ANSWER: On an XT bus system LPT1: becomes /dev/lp0 (major=6, minor=0),
on an AT LPT1: becomes /dev/lp1 (major=6, minor=1). To be more
precise:

Name Major Minor I/O address
 lp0   6     0       0x3bc
 lp1   6     1       0x378
 lp2   6     2       0x278


 XIV.25)  When the kernel boots it says `using polling driver,' is
there an interrupt driven driver?

ANSWER: Yes the latest kernels support parrallel port IRQs but to
enable them you must ether: edit the IRQ number into lp_table[] in
lp.c in the kernel source, or use `lpcntl'. The interrupt driver uses
less processor time and gives a faster throughput but sometimes one
may choose sacrifice this to free up an IRQ line. If your printer is
/dev/lp1 using IRQ 7 put:

/etc/lpcntl /dev/lp1 7

in your /etc/rc.

If you don't have lpcntl get it from:

tsx-11.mit.edu:/pub/Linux/BETA/lp/lpirq.4.tar.Z


 XIV.26)  What's the difference between the polling driver and an the
interrupt driven one?

ANSWER: A polling sits in a loop repeatedly reading the port hardware
to see if it is ready for another character and then gives it one. An
interrupt driver goes to sleep and is woken by the port hardware
(using a hardware interrupt) when it wants another character. Polling
drivers are easier to write but in multitasking environments they are
a bad thing.) I have seen some OSs for PC/AT machines where the
polling printer drivers are more reliable than the interrupt ones but
I doubt this is the case in Linux :-).
 

 XIV.27)  How do I write filters?

ANSWER: In normal Unix terminology, filters are just programs (so they
must have execute permission) that read a stream from their standard
input and write to their standard output.

lpd filters are filters in the sense that thay read from their STDIN
and write to their STDOUT but are not necessarily true filters in that
they may assume that their standard input is a file and perform
lseek() operations on it. I'm not sure that such filters are strictly
conforming but they seem to work OK.

All lpd filters must conform to a particular command line syntax (or
more often simply ignore command line parameters). For details of the
command line parameters RTFM(printcap).

It's easier to debug filters if you test them in an immediate shell
before you install them. (If your filter make use of its command line
arguments you'll have to specify them too).

my-new-filter <file >/dev/lp1

If you want to write a shell script filter it must have a #!/bin/sh
header.  Here for example is my Epson FX-80 dvi filter:

#!/bin/sh
/usr/TeX/bin/dvips -f | \
/usr/bin/gs -q -sDEVICE=eps9high -r120x216 -dNOPAUSE -sOutputFile=- -

More good specific examples can be found in the peroidic c.o.l.a
posting "How to print under Linux" by <gtaylor@god.hounix.org> Grant
Taylor. The document also explains to print out the types of file you
wouldn't normally have a filter for eg. texinfo. (Not that you can't
have a texinfo filter - I have one but it does leaver the printer
idling for a long time while tex runs.)


 XIV.28)  I've written a filter in shell script which works OK when I
use it from the shell prompt but fails when I tell lpd to use it?

ANSWER: You may need a #!/bin/sh header. You may also need to set PATH
within the script since the daemon's PATH may not have everything you
need.


 XIV.29)  When should I define an `of' filter?

ANSWER: Never. (Well strictly speaking there are circumstances but
you're unlikey to meet them until you're so familar with lpd that you
won't need this FAQ.)


 XIV.30)  Where do I get filters for given printers?

ANSWER: From BSD source archives (I think). [Editors note: I need a
better answer here ].

If you already have a program to print say DVI on your printer by some
mechanism then making it into a filter is usually a matter of writting
trivial shell script - see this FAQ. If the program you are using
insists on reading a names file as input see the next question. Text
mode filters are trivial too (see this FAQ) unless you want lpr to
have a choice of fonts in which case they are slightly harder than
trivial.  You will probably want to insert and `echo -ne' command at
the beginning and end of your filter to set up the font etc to your
liking.


 XIV.31)  How do I get a program that won't read from STDIN to act as
a filter?

ANSWER: For example dvilj2p insists on a named file as its input (and
what's more expects one with a .dvi suffix). To make a dvi filter for
a laserjet you'll have to capture the STDIN into a temporary file.

#!/bin/sh
cat >/tmp/$$.dvi
dvilj2p /tmp/$$
rm /tmp/$$.dvi

The problem with this kludge is that is may have a very high disk
overhead. (In the long term dvilj2p should be fixed).

If you have procfs you can use the following trick:

#!/bin/sh
ln -s /proc/self/fd/0 /tmp/$$.dvi
dvilj2p /tmp/$$
rm /tmp/$$.dvi

Note: If it wasn't for the fact that dvilj2p adds a .dvi suffix you
wouldn't need the temporary symlink and could just specify
/proc/self/fd/0 directly. People who use this trick often usually keep
permanent symlinks to /proc/self/fd/* in /dev.


 XIV.32)  The set of filters supported by lpd seem strange - why
aren't there filters for Postscript, GIF, TIFF and so on?

ANSWER: History. You can, in fact, use any of the filters (with the
possible exception of the default filter) for any reason. If you're
never going to use Benson Varian raster files you could use the -v
switch for GIF files. Remember that if you create a filter for a file
format that takes a long time to process then your printer may sit
idle between print jobs even when there are things in the queue.

If you are on a network remember that the filter setups go on the
print server so you will need to consider other people's needs too.
One way to avoid running out of filter options is to define several
logical printers in /etc/printcap that all point to the same physical
one. One small problem with this is that you have no control over the
order in which files from separate queues are printed. Another way to
avoid running out of possible types is to use magic filters.


 XIV.33)  What are magic filters?

ANSWER: Magic filters deduce their input files' types from `magic
numbers' (distictive byte patterns at particular offsets).  Magic
filters are usually perl scripts, shell scripts or C programs that
simply identify the file type then call the appropriate non-magic
filter. Blatent plug :-) I <B.A.McCauley@bham.ac.uk> have a generic
magic filter bash script that selects the right filter to use based on
the output of the `file' command. With my magic ``dvi'' filter (and
3 associated non-magic filters) I can do things like:

lpr -d file1.dvi file2.div.Z file3.ps file4.texinfo.z

(BTW confguring lpr to handle texinfo files getting a bit silly - see
previous question).

This is now at:

tsx-11.mit.edu:pub/linux/sources/usr.bin/magic-filter-0.3.tar.gz

(Although the release number will doubtless change in future).

Other examples of magic filters (a simpler shell one and one in C)
can be found in the periodic c.o.l.a posting "How to print under
Linux" by <gtaylor@god.hounix.org> Grant Taylor.

Magic filters should never specified as `of' as the output filter only
gets called once if a number of files are printed without a gap.

IMHO magic filters as `if' can also cause problems as they may prevent
you, say, _listing_ a PostScript or nroff file. (Other people disagree
as, if you are making your printer available on a network, it can be a
pain having people accidently listing ps files.)



XV. UUCP/NEWS/MAIL for LINUX
============================
*** This section is an expert of the UUCP-NEWS-MAIL-FAQ, posted twice
*** monthly in c.o.l.a. This section and the complete FAQ about UUCP
*** and others is written by Vince Skahan (vince@victoria.sea.wa.us),
*** mail him for any corrections and information.
***
*** Last update 93/06/11


XV.A. General Information
XV.B. UUCP

XV.C. News
XV.D. Mail


XV.A. General Information
~~~~~~~~~~~~~~~~~~~~~~~~~

  XV.01)  What uucp, news, and mail software works under Linux ?

ANSWER:
Just about everything, most with no (or minimal) patching required...

The following is a quick but not all-inclusive list of software known to work
under Linux:

	UUCP 		- Taylor UUCP 1.04
	News transport	- Cnews 12/22/91 patchdate (no 'optional' speedups)
                          Cnews 'performance release' (needs patching)
                          INN 1.4 (needs patching)
                          dynafeed
                          nntp 1.5.11 'reference' release, slurp 1.05
	News readers	- tin-1.2-p0
                          trn-2.5 (probably also 3.0)
                          nn-6.4.18
                          tass
                          rn4.4
                          waffle 1.65
	Mail transport  - smail2.5
                          smail3.1.28
                          sendmail5.65c+IDA
	Mail program	- elm2.4.21 (probably also 2.4.22)
                          pine
                          procmail
                          deliver

  XV.02)  So where are the sources ?

ANSWER:
At your friendly neighborhood archive site where you find sources normally.
Consult archie for a list.

Config files for the portions of UUCP/News/Mail currently in the SLS
distribution of Linux can be found on sunsite.unc.edu in the file
sunsite.unc.edu:/pub/Linux/system/Mail/newspak-1.4.tar

  XV.03)  Do I really need the sources ?

ANSWER:
Yes, if you want to *really* understand how the pieces are configured and
how they fit together.  If you already know how...probably not unless you
want to change the paths used or do custom patching for some reason.

There is considerable documentation in the sources that doesn't get
"installed" that helps fill in the blanks between what you need to know, and
what you can figure out.

  XV.04)  How do I get my system a news/mail/uucp feed ?

ANSWER:
	Please see the "how to become a USENET site" periodic posting
	in news.answers


XV.B. UUCP
~~~~~~~~~~

  XV.05)  Why do I get 'timeout' on connections when I upgraded to
uucp-1.04 ? 

ANSWER:
	If you use a 'Direct' device in the Devices file, there's now a
	10 second timeout compiled in.  Make the name of the Device anything
	other than 'Direct'.

  XV.06)  Why doesn't anonymous uucp seem to work ?

ANSWER:
	The SLS anonymous uucp only works in Taylor mode because it's
	compiled with HAVE_TAYLOR_CONFIG.  If you want to do anon uucp in HDB
	mode, you'll have to recompile the sources with just HDB defined.

	HDB mode also seems rather particular about things like blank spaces
	and blank lines in your Permissions file.  If you get log file entries
	that indicate 'no permission' for anon uucp, a good place to start is
	to make sure that there are no blank lines (comment 'em out).


XV.C News
~~~~~~~~~

  XV.07)   What newsreader is best ?

ANSWER:
	No way I'll open that can of worms other than to say that you
	definitely want something with "kill files" and probably want
	something with 'threads'.  

	For what little it's worth, I use 'nn'.
	
  XV.08)  with trn - why do I get the message 'dbinit failed' ? 

ANSWER:
	Because you didn't run mthreads from cron to keep the threads database
	up-to-date.

  XV.09)  why is my 'nn' database getting continuously corrupted ?

ANSWER:
	If you built it from sources and you asked for the 'words' method of
	building the database,  it will definitely get corrupted if your
	filesystem doesn't handle long filenames (ie...comp.os.linux.announce
	is more than 14-characters).  Build it with the 'by-number' way of
	creating the database and you'll be fine.

  XV.10)  why can't I post to moderated groups ?

ANSWER:
	Probably because the newsreader is trying to call /bin/mail to send
	the mail and it doesn't like it.  Replace the /bin/mail in SLS with
	the port of mailx-5.3a.tar.z from the pub/Linux/system/Mail dir on
	sunsite.unc.edu and make it mode 2755 and group mail (like 'elm') and
	you'll be all set.

	Another possibility is that you have a moderated newsgroup set up on
	your local system as not-moderated and somebody upstream is quietly
	deleting the article (some system's software, not a person).  Make
	sure you run a 'checkgroups' every now and then when the checkgroups
	article rolls by in news.admin every few weeks.

  XV.11)  Why do I have problems that appear to be permission-related ?

ANSWER:
	All the stuff in /usr/local/lib/news should be news.news except
	/usr/local/lib/news/setnewsids which should be setuid root.

	Past versions of SLS had no 'news' group or user by default, which
	caused lots of problems for people if they installed the news 
	software *before* they added the 'news' group and user.

  XV.12)  Why doesn't SLS have the 'Performance Release' of C-news?
	  INN ? NNTP ? 

ANSWER:
	Because SLS can't have *everything*.  It has the pre-performance C-news
	because it's a very fast and stable implementation for non-nntp sites
	that fits the needs of a normal uucp-only site.  If you're that into
	having the most current of everything, you should probably be building
	it from the sources.

  XV.13)  Why does doexpire say "severe space shortage" when there's
	lots of room ? 

ANSWER:
	Because it can't read /etc/mtab.  Make it mode 644.  This happens
	when you unmount a mounted filesystem by root with a umask that
	doesn't permit world-read of files owned by root.

  XV.14)  How do I set up NNTP?

ANSWER:
	Please see the extended description from Matt Welsh in the
	UUCP-NEWS-MAIL-FAQ that appears routinely in c.o.l.a.


XV.D. Mail
~~~~~~~~~~

  XV.15)  Why is my hostname.domainname not in my headers and
something funky's there ? 

ANSWER:
	Because you didn't edit one or more of the following files like the
	README.linux files in the lib directories told you to:

		/usr/local/lib/smail/paths
		/usr/local/lib/smail/config
		/usr/local/lib/elm/elm.rc 

  XV.16)  Why can't elm write to my mailbox ?

ANSWER:
	You need elm and filter to be mode 2755 and group mail
	and also have /usr/spool/mail mode 775 and group mail.


  XV.17)  is sendmail+IDA available for Linux instead of smail ?

ANSWER:
   Yes !!! I've recently switched from smail to sendmail+IDA from the binary
   distribution on sunsite.unc.edu and it works great...and I'm a uucp-only
   site.  Look in pub/Linux/system/Mail for it...

 

	   ===================8<==========>8================


-- 
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
#	LaBRI 			 |					    #
#  351 cours de la Liberation    |  e-mail:  corsini@geocub.greco-prog.fr   #
#  33405 Talence Cedex		 |  e-mail:  corsini@labri.u-bordeaux.fr    #
#  				 |					    #
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
-- 
	 There will be a sig when our local net is reliable.
	       For now, I would rather stay anonymous.


^ permalink raw reply	[flat|nested] 8+ messages in thread

end of thread, other threads:[~1993-07-21  9:52 UTC | newest]

Thread overview: 8+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
1993-07-21  9:52 Linux Frequently Asked Questions: TABLE OF CONTENTS [monthly posted] corsini
1993-07-21  9:52 ` Linux Frequently Asked Questions 1/6 " corsini
1993-07-21  9:52   ` Linux Frequently Asked Questions 2/6 " corsini
1993-07-21  9:52     ` Linux Frequently Asked Questions 3/6 " corsini
1993-07-21  9:52       ` Linux Frequently Asked Questions 4/6 " corsini
1993-07-21  9:52         ` Linux Frequently Asked Questions 5/6 " corsini
1993-07-21  9:52           ` Linux Frequently Asked Questions 6/6 " corsini
  -- strict thread matches above, loose matches on Subject: below --
1993-06-11 10:06 corsini

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox