?? rhl59.htm
字號:
<BLOCKQUOTE>
<BLOCKQUOTE>
<HR ALIGN=CENTER>
<BR>
<NOTE>If your modem is configured to communicate to the host at a fixed baud rate, use the -s option with faxaddmodem. See the faxaddmodem manual page for details.</NOTE>
<BR>
<HR ALIGN=CENTER>
</BLOCKQUOTE></BLOCKQUOTE>
<P>A sample configuration session for my machine is shown in Listing 59.2. Note that I ran as root while I did this. I pressed the Enter key after each [yes] command to accept the default responses. If you do not like what you see, type n and then press
Enter.
<BR>
<P>
<FONT COLOR="#000080"><B>Listing 59.2. Sample configuration for HylaFAX.</B></FONT>
<BR>
<PRE>
<FONT COLOR="#000080"># faxaddmodem
Verifying your system is set up properly for fax service...
There is no entry for the fax user in the password file.
The fax software needs a name to work properly; add it [yes]?
Added user "fax" to /etc/passwd.
Added fax user to "/etc/passwd.sgi".
There does not appear to be an entry for the fax service in
either the yellow pages database or the /etc/services file;
should an entry be added to /etc/services [yes]?
There is no entry for the fax service in "/usr/etc/inetd.conf";
should one be added [yes]?
Poking inetd so that it rereads the configuration file.
There does not appear to be an entry for the FaxMaster in
either the yellow pages database or the /usr/lib/aliases file;
should an entry be added to /usr/lib/aliases [yes]?
Users to receive fax-related mail [root]?
Rebuilding /usr/lib/aliases database.
41 aliases, longest 81 bytes, 823 bytes total
Done verifying system setup.
Serial port that modem is connected to []? cua1
Ok, time to set up a configuration file for the modem. The manual
page config(4F) may be useful during this process. Also be aware
that at any time you can safely interrupt this procedure.
No existing configuration. Let's do this from scratch.
Phone number of fax modem []? +1.713.265.1539
This is the phone number associated with the modem being configured.
It is passed as an "identity" to peer fax machines and it may
also appear on tag lines created by the fax server.
The phone number should be a complete international dialing specification
in the form +&ltcountry code&gt; &ltarea code&gt; &ltlocal part&gt;.
Any other characters included for readability are automatically
removed if they might cause problems.
Area code []? 713
Country code [1]?
Long distance dialing prefix [1]?
International dialing prefix [011]?
Tracing during normal server operation [1]?
Tracing during send and receive sessions [11]?
Protection mode for received fax [0600]?
Rings to wait before answering [1]?
Modem speaker volume [off]?
The server configuration parameters are
FAXNumber: +1.713.265.1539
AreaCode 713
CountryCode 1
LongDistancePrefix: 1
InternationalPrefix: 011
ServerTracing: 1
SessionTracing: 11
RecvFileMode: 0600
RingsBeforeAnswer: 1
SpeakerVolume: off
Are these ok [yes]? n
Phone number of fax modem [+1.713.265.1539]?
Area code [713]?
Country code [1]?
Long distance dialing prefix [1]?
International dialing prefix [011]?
Tracing during normal server operation [1]?
Tracing during send and receive sessions [11]?
Protection mode for received fax [0600]?
Rings to wait before answering [1]?
Modem speaker volume [off]? low
The server configuration parameters are
FAXNumber: +1.713.265.1539
AreaCode 713
CountryCode 1
LongDistancePrefix: 1
InternationalPrefix: 011
ServerTracing: 1
SessionTracing: 11
RecvFileMode: 0600
RingsBeforeAnswer: 1
SpeakerVolume: low
Are these ok [yes]?
Now we are going to probe the tty port to figure out the type
of modem that is attached. This takes a few seconds, so be patient.
Note that if you do not have the modem cabled to the port, or the
modem is turned off, this may hang (just go and cable up the modem
or turn it on, or whatever).
Hmm, this looks like a Class 1 modem.
Product code is "1444".
Modem manufacturer is "USRobotics".
Modem model is "Courier".
Using prototype configuration file config.usr-courier...
The modem configuration parameters are:
ModemRate: 19200
ModemFlowControl: xonxoff
ModemFlowControlCmd: &H2
ModemSetupDTRCmd: S13=1&D2
ModemSetupDCDCmd: &C1
ModemDialCmd: DT%s@
ModemResultCodesCmd X4
Are these ok [yes]?
Startup a fax server for this modem [yes]
/usr/etc/faxd -m /dev/cua1
#</FONT></PRE>
<P>HylaFAX requires that a fax user exist in the password file on the server machine. This user should have the same user ID as uucp so that lock files can be easily shared.
<BR>
<P>Client applications communicate with the server machine via the faxd.recv program. This program is designed to be started by the inetd program. If the appropriate entry is not present in inetd's configuration file, confirming this prompt causes it to be
added. Note that there must also be a fax service already set up for this step to succeed (see above).
<BR>
<P>A fax server entry must exist so that the inetd program can set up the fax job submission server, faxd.recv, on the appropriate port. If the server machine is running NIS (formerly known as Yellow Pages), it may be necessary to create the entry in the
appropriate map. Otherwise the entry is installed in the /etc/services file.
<BR>
<P>The fax server sends mail notices to a well-known user called the FaxMaster when certain events occur. Some examples are when faxes are received or when modems appear to be on the blink. This step sets up a mail alias for this the FaxMaster. The alias
lists those system administrators that handle HylaFAX-specific problems. I chose root because I have a small system and I usually wind up doing all my administrative stuff as root anyway. If you have a large user base, perhaps a specific user could handle
all the fax-related problems.
<BR>
<P>This completes the collection of server-related parameters. The remaining steps identify and configure the modem. Note that if you do not specify a fixed rate for modem communications, faxaddmodem will probe for a good speed. The faxaddmodem command is
good at finding what type of modem you have and configuring it. Unless you have a compelling reason to change the responses to settings other than the defaults, leave them.
<BR>
<P>The fax daemon is now started for you. This is done with /usr/etc/faxd -m /dev/cua1. You may want to put this command in your /etc/rc.d file for subsequent boots so that you don't have to remember to start it yourself.
<BR>
<BR>
<A NAME="E68E455"></A>
<H3 ALIGN=CENTER>
<CENTER>
<FONT SIZE=5 COLOR="#FF0000"><B>Troubleshooting</B></FONT></CENTER></H3>
<BR>
<P>You are bound to run into difficulties while installing HylaFAX. Despite my assertions in the last section about two simple steps to complete the installation, you still have the potential of running into problems. Here is a brief list of problems and
their solutions. The list is by no means complete, nor is it guaranteed the examples will apply to you, but at least it will give you an idea of what could be wrong.
<BR>
<UL>
<LI>You need the afm-tar.Z file for the Adobe Font Metric (AFM) fonts required by the sendfax program. You can get this file via FTP from sgi.com. Some HylaFAX distributions do not include these Metric files. A subset of these fonts is available via FTP
from sgi.com in the file /sgi/fax/afm-tar.Z. If you do not install the AFM files, you get error messages about fonts not found.
<BR>
<BR>
<LI>Add a user called fax to the same group as uucp. The faxaddmodem call may not work and bomb with errors about too many arguments. If this happens, make sure your modem works. If you cannot use cu on your modem, fix that problem first. Check the cables,
initialization strings, and so on. For external modems, check to see whether the cable has the relevant signals for doing hardware flow control if necessary and that it passes the DCD and DTR signals appropriately.
<BR>
<BR>
<LI>If you have a Class 1 modem, you cannot use hardware flow control. Class 2 modems do support hardware control. Ensure that you have the correct cables for the type of external modem you plan to connect to.
<BR>
<BR>
</UL>
<BR>
<A NAME="E68E456"></A>
<H3 ALIGN=CENTER>
<CENTER>
<FONT SIZE=5 COLOR="#FF0000"><B>Setting Up a Send and Receive Daemon</B></FONT></CENTER></H3>
<BR>
<P>The faxd daemon is the main processing agent of the HylaFAX package. You need one faxd process and FIFO for each fax modem on your system. faxd listens to its own FIFO for all its command directives. When you start faxd, you can use the following
options:
<BR>
<UL>
<LI>-m to specify the terminal device the fax modem is attached to. For example, /dev/cua1 is a mandatory argument to faxd.
<BR>
<BR>
<LI>-q to specify a spooling area in which to operate other than /var/spool/HylaFAX.
<BR>
<BR>
<LI>-i to specify the interval in seconds that a job should be held between transmission attempts. By default, this interval is 900 seconds.
<BR>
<BR>
<LI>-g option can be used to indicate that faxd should act like the getty program if it receives a call from a data modem. See the getty man page for details. If this option is not specified and the server is not configured to support incoming data
connections, incoming data connections will be rejected.
<BR>
<BR>
<LI>-d stops faxd from detaching itself from the terminal. This is useful for debugging.
<BR>
<BR>
<LI>-1 option causes faxd to generate only 1D-encoded fax when sending.
<BR>
<BR>
</UL>
<BLOCKQUOTE>
<BLOCKQUOTE>
<HR ALIGN=CENTER>
<BR>
<NOTE>There is no way to abort an incoming fax. Just sit back and wait until it's over.</NOTE>
<BR>
<HR ALIGN=CENTER>
</BLOCKQUOTE></BLOCKQUOTE>
<P>The faxd.recv daemon is the program that implements the server side of the fax job submission protocol. It also implements extensions to this protocol to support job removal and the return of status information. faxd.recv is normally invoked by inetd
with a line in the following form:
<BR>
<BR>
<PRE>
<FONT COLOR="#000080">fax stream tcp nowait fax /usr/libexec/faxd.recv faxd.recv</FONT></PRE>
<P>The faxd.recv daemon accepts requests for transmitting faxes and creates the appropriate queue and document files in the HylaFAX spooling area. If a job is received properly, a request to process the job is then sent to a fax server by writing to a FIFO
special file named FIFO in the spooling directory. The faxd.recv daemon then returns a message to the sender indicating the Job ID (an integer number associated with the job). This Job ID can be used later to remove the job from the queue and to query the
job's status.
<BR>
<P>Diagnostics generated by faxd.recv are logged with the syslog facility. The user is always informed of any problem that affects the status of the queued job. Check the man pages for a list of these error messages.
<BR>
<BR>
<A NAME="E68E457"></A>
<H3 ALIGN=CENTER>
<CENTER>
<FONT SIZE=5 COLOR="#FF0000"><B>Sending a Fax</B></FONT></CENTER></H3>
<BR>
<P>To send a fax, you will use the sendfax program. The syntax for this command from the man page is
<BR>
<PRE>
<FONT COLOR="#000080">sendfax [ -a transmit-time ]
[ -c comments ]
[ -r regarding ]
[ -x to-company ]
[ -y to-location ]
[ -d destination ]
[ -f from ]
[ -h host[:modem] ]
[ -i identifier ]
[ -k kill-time ]
[ -lm ]
[ -n ]
[ -p ]
?? 快捷鍵說明
復制代碼
Ctrl + C
搜索代碼
Ctrl + F
全屏模式
F11
切換主題
Ctrl + Shift + D
顯示快捷鍵
?
增大字號
Ctrl + =
減小字號
Ctrl + -