\documentclass[letterpaper]{article}
\nonstopmode
\akai
\usepackage{linuxdoc-sgml}
\usepackage{qwertz}
\usepackage{url}
\usepackage[latin1]{inputenc}
\usepackage{t1enc}
\usepackage[english]{babel}
\usepackage{epsfig}
\usepackage{null}
\def\addbibtoc{
\addcontentsline{toc}{section}{\numberline{\mbox{}}\relax\bibname}
}%end-preamble
\setcounter{page}{1}
\title{PPP HOWTO ¤¤Ä¶ª©}
\author{§@ªÌ: Robert Hart {\ttfamily \onlynameurl{hartr@interweft.com.au}}\\ 
Ä¶ªÌ: \onlynameurl{Asd L. Chen}
\& \onlynameurl{C.W.Huang}}
\date{v3.0, 31 March 1997.
Â½Ä¶¤é´Á: 25 August - 9 October 1997}
\abstract{³o¥÷¤å¥ó®i¥Ü¦p¦ó§â§Aªº Linux PC ³s±µ¨ì¤@¥x PPP ¦øªA¾¹¤W¡A¦p¦ó¨Ï¥Î PPP §â°Ï°ìºô¸ô³sµ²¦b¤@°_¨Ã¥B´£¨Ñ¤@ºØ§â§Aªº Linux ¹q¸£³]©w¬° PPP ¦øªA¾¹ªº¤èªk¡D¥»¤å¦P®É´£¨ÑÀ°§U°»¿ùµLªk¥¿±`¹B§@ªº PPP ³sµ²¡D}


\begin{document}
\maketitle
\tableofcontents
{\bfseries ª©ÅvÁn©ú}



¥»¤å¥óªº´²¥¬¥²¶·¨Ì¾Ú GPL (GNU Public License)¡D



{\bfseries ´²¥¬}



¤@¥¹³o¥÷¤å¥ó¦³·sªºª©¥»²£¥Í´N·|¶K¨ì comp.os.linux.answer °Q½×¸s¡D
¤]¥i¥H¦b¦¹¨ú±o HTML ®æ¦¡ªº¤å¥ó:

\begin{itemize}
\item \nameurl{http://sunsite.unc.edu/LDP/HOWTO/}{Linux Howto Index}
\item \nameurl{http://www.interweft.com.au/other/ppp-howto/ppp-howto.html}{PPP-HOWTO}
\end{itemize}




¨ä¥¦®æ¦¡(SGML, ASCII, postscript, DVI)ªº¤å¥ó¥i¥H±q³o¸Ì¨ú±o:
\nameurl{ftp://sunsite.unc.edu/pub/Linux/docs/HOWTO/other-formats}{Howtos - other formats}.

¦]¬° sunsite.unc.edu  ªº­t¸ü«D±`¦a­«¡A½Ð¨Ï¥Î³Ì¾aªñ§Aªº¾A·í¬M®g(mirror)¸`ÂI¡D



{\bfseries ·PÁÂ}



¤£Â_¦a¦³³\¦h¤H´£¨Ñ§Ú¼g§@¦¹¤å¥óªº¨ó§U¡D
¯S§O·PÁÂ Al Longyear ¹ï PPP ¥»¨­ªº«ü¾É(¦pªG³o¸Ì¦³¥ô¦ó¿ù»~¡A¨º¬O§Úªº¦Ó¤£¬O¥Lªº)¡A
Greg Hankins(Linux HOWTOs ªººûÅ@¤H)¥H¤Î Debi Tackett (MaximumAccess.com) 
³\¦h¦b§Î¦¡¡A¤º®e¶¶§Ç¡AÅÞ¿è»P¸ÑÄÀ²M´·«×ªº¦³¥Î«ØÄ³¡D 



³Ì«á¡A¹ï©ó³\¦h¥H¹q¤l¶l¥ó´£¨Ñ§Ú·N¨£ªº¤H¡A·PÁÂ±z¡D
´N¹³©Ò¦³ HOWTO ªº§@ªÌ¤@¼Ë¡AÀ°§U¥L¤H©ÒÀò±oªºº¡¨¬·P´N¬O§Ú­Ì©Ò¦¬¨ìªº³ø¹S¡A¦Ó³o¤w¨¬°÷¡D
¸g¥Ñ¼g§@³o¥÷ HOWTO ¤å¥ó§ÚÀvÁÙ¤@¤p³¡¥÷¤H±¡¶Å¡A³o¬O§Ú¡A¥H¤Î©Ò¦³¨ä¾l Linux ªº¨Ï¥ÎªÌ¡A
©Ò¿n¤íµ¹¬°§Ú­Ì¼¶¼g»PºûÅ@³o­Ó§@·~¨t²Îªº¤Hªº¡D




\section{Â²¤¶}

PPP ¡]ÂI¹ïÂI¨ó©w¡^¬O¦b¦ê¦C³sµ²¤W¶] IP ¡]ºô»Úºô¸ô¨ó©w¡^¥H¤Î¨ä¥¦ºô¸ô¨ó©wªº¤@ºØ¾÷¨î¡A
¦ê¦C³sµ²¥i¥H¬Oª½±µªº¦ê¦C³s±µ¡]¨Ï¥Î null-modem Æl½u¡^©Î¬O¨Ï¥Î¼Æ¾Ú¾÷¥H¤Î¹q¸Ü½u¸ô©Ò³y¥Xªº³sµ²
(·íµM¤]¥]¬A¦p ISDN ªº¼Æ¦ì½u¸ô)¡D

¨Ï¥Î PPP, §A¥i¥H§â§Aªº Linux PC ³s±µ¨ì¤@¥x PPP  ¦øªA¾¹¤W¨Ã¦s¨ú¸Ó¦øªA¾¹©Ò³s±µªººô¸ô¸ê·½¡]´X¥G¡^´N¦p¦P§A¬Oª½±µ³s±µ¦b¸Óºô¸ô¤W¤@¯ë¡D

§A¤]¥i¥H§â§Aªº Linux PC ³]¬°¤@¥x PPP  ¦øªA¾¹¡A³o¼Ë¤@¨Ó¨ä¥¦¹q¸£´N¥i¥H¼·¤J§Aªº¹q¸£¨Ã¥B¦s¨ú¦b§A°Ï°ìºô¸ô¸Ìªº¸ê·½¡D

¦]¬° PPP  ¬O¤@ºØÂI¹ïÂI (peer-to-peer) ªº¨t²Î¡A¦]¦¹§A¤]¥i¥H¨Ï¥Î¨â¥x Linux PC ¤Wªº PPP  §âºô¸ô³sµ²¦b¤@°_¡]©Î¬O§â°Ï°ìºô¸ô³sµ²¨ìºô»Úºô¸ô¤W¡^¡D

³Ì¥D­nªº®t²§·íµM¬O³t«× ¡Ð ¼Ð·Çªº¤A¤Óºô¸ô³s½u¬O¥H 10 Mbps¡]¨C¬í¦Ê¸U¦ì¤¸¡^³o­Ó²z½×¤Wªº³Ì¤j³e³q¶q¦b°Ê§@¡A
¦Ó¦b¼Æ¾Ú¾÷³o¤è­±³Ì¤j¬O¥H 56 kbps¡]¨C¬í¤d¦ì¤¸¡^ªº³t«×¦b°Ê§@¡D

¦P®É¡A¨Ì¾Ú PPP  ³s½uªº«¬ºA¡A¬Y¨ÇÀ³¥Î¥H¤ÎªA°È¦b¨Ï¥Î¤W¥i¯à·|¦³¨Ç­­¨î¡D




\subsection{«È¤áºÝ¥H¤Î¦øªAºÝ}

PPP ¬O¤@ºØ§¹§¹¥þ¥þ¬O{\bfseries ÂI¹ïÂI}ªº¨ó©w¡F¼·±µªº¾÷¾¹¥H¤Î±µ¨ü¼·±µªº¾÷¾¹¤§¶¡¡]¦b§Þ³N¤W¡^¨Ã¨S¦³®t²§¡D
µM¦Ó¡A¬°¤F²M·¡©ú¥Õªº½t¬G¡A¥H{\bfseries ¦øªAºÝ}»P{\bfseries «È¤áºÝ}ªº¤è¦¡¨Ó«ä¦Ò¬O«Ü¦³¥Îªº¡D

·í§A¼·¤J¤@­Ó¸`ÂI­n«Ø¥ß PPP  ³s½u®É¡A§A¬O{\bfseries «È¤áºÝ}¡D§A©Ò³s½uªº¨º¥x¾÷¾¹¬O{\bfseries ¦øªAºÝ}¡D

·í§A¦b³]©w¤@¥x Linux ¾÷¾¹¨Ï¨ä±µ¦¬¨Ã³B²z¼·¤Jªº PPP ³s½u®É¡A§A¥¿¦b³]¥ß¤@¥x PPP {\bfseries ¦øªAºÝ}¡D

¥ô¦ó Linux PC ³£¥i¥H¬O PPP  ¦øªAºÝ¥H¤Î«È¤áºÝ ¡Ð ¬Æ¦Ü©ó¦pªG§A¦³¤@­Ó¥H¤Wªº¦ê¦C°ð¡]¥H¤Î¼Æ¾Ú¾÷¡A¦pªG¦³¥²­n¡^ªº¸ÜÁÙ¥i¥H¦P®É§êºt³o¨âºØ¨¤¦â¡D
¦p¦P«e­±©Ò»¡ªº¡A´N PPP ¦Ó¨¥¡A¤@¥¹³s½u«Ø¥ß¨º»ò«È¤áºÝ»P¦øªAºÝ¤§¶¡¨Ã¤£¯uªº¦³¤°»ò®t²§¡D

¬°¤F²M·¡©ú¥ÕªºÃö«Y¡A³o¥÷¤å¥ó§â±Ò©l©I¥s¡]§Y "¼·¤J"¡^ªº¨º¥x¾÷¾¹ºÙ§@{\bfseries «È¤áºÝ}¡A
¦Ó§â¦^À³¹q¸Ü¡A®Ö¹ï¼·¤J½Ð¨D¤§Åç»{¡]§Q¥Î¨Ï¥ÎªÌ¥N¸¹¡A±K½X¥H¤Î¨ä¥¦¥i¯àªº¾÷¨î¡^ªº¨º¥x¾÷¾¹ºÙ§@{\bfseries ¦øªAºÝ}¡D

¨Ï¥Î PPP  °µ¬°«È¤áºÝ§â¬Y­Ó¦a¤èªº¤@¥x©Î¦h¥x¾÷¾¹³sµ²¨ìºô»Úºô¸ô¤W¥i¯à¬O¤j³¡¥÷¤H³£·P¿³½ìªº¤@ÂI
- ³o¬O±N¥L­Ìªº Linux ¾÷¾¹§@¬°¤@«È¤áºÝ¡D

¦b³o¥÷¤å¥ó¤¤©Ò´y­zªºµ{§Ç±N·|Åý§A¯à°÷«Ø¥ß¨Ã¦Û°Ê¤Æ§Aªººô»Úºô¸ô³s½u¡D

³o¥÷¤å¥ó¤]±N¦b§â§Aªº Linux PC ³]¬° PPP {\bfseries ¦øªA¾¹}¥H¤Î¨Ï¥Î PPP ¨Ó³sµ²¨â­Ó°Ï°ìºô¸ô¡]¦³§¹¾ãªº»¼°e³]©w¡^³o¨Ç¤è­±µ¹§A«ü¤Þ¡]³o±`±`³QºÙ§@«Ø¥ß¼s°ìºô¸ô³sµ²¡^¡D




\subsection{¤£¦P Linux ®M¥ó¶¡ªº®t²§}

¦³³o¦h¤£¦Pªº Linux ®M¥ó¡A¥L­Ì¦³¦Û¤vªº¯S½è»P¦æ¬°¼Ò¦¡¡D

¯S§O¦a¡ALinux (¥H¤Î Unix)¹q¸£¦³¨âºØ¤£¦Pªº°_©l¤è¦¡¡A¬É­±³]©wµ¥µ¥¡D

³o¨âºØ¤À§O¬O {\bfseries BSD system initialisation} »P {\bfseries System V system initialisation}¡D
¦pªG§A¶i¤J¬Y¨Ç Unix ªº·s»D°Q½×¸s¡A§A·|µo²{¸g±`¦³Âù¤è¤ä«ùªÌªº¾Ôª§¡D
¦pªG§AÄ±±o¦³½ì¡A´N¥[¤J³o­Ó®ö¶Oºô¸ôÀW¼eªº¦æ¦C!

³Ì´¶¹M¨Ï¥Îªº®M¥ó¥i¯à¬O

\begin{itemize}
\item Slackware\\ 
¨Ï¥Î BSD §Î¦¡ªº¨t²Î°_©l
\item Red Hat (and its former associate Caldera)\\ 
¨Ï¥Î SysV ¨t²Î°_©l(¦³¨Ç³\ªº­×§ï)
\item Debian\\ 
¨Ï¥Î SysV ¨t²Î°_©l
\end{itemize}




BSD §Î¦¡ªº¨t²Î°_©l³q±`±N¥¦ªº±Ò°ÊÀÉ®×©ñ¦b {\ttfamily /etc/...}¡A³o¨ÇÀÉ®×¬O:
\par
\addvspace{\medskipamount}
\nopagebreak\hrule
\begin{verbatim}
        /etc/rc
        /etc/rc.local
        /etc/rc.serial
                (¤]¥i¯à¦³¨ä¥¦ÀÉ®×)
\end{verbatim} 
\nopagebreak\hrule 
\addvspace{\medskipamount}




³Ìªñ¡A¤@¨Ç BSD ¨t²Îªº°_©l¼Ò¦¡±N¨Ï¥Î {\ttfamily /etc/rc.d...} °µ¬°±Ò°ÊÀÉ®×ªº¦s©ñ¥Ø¿ý¡A¦Ó¤£¬O±N©Ò¦³ªºªF¦è³£¥á¨ì {\ttfamily /etc} ¤U¡D

System V °_©l¼Ò¦¡±N±Ò°ÊÀÉ®×¦s©ñ¦b {\ttfamily /etc/...} ©Î {\ttfamily /etc/rc.d/...} ¤Î¨ä¤Uªº¤@°ï¤l¥Ø¿ý¤¤:

\par
\addvspace{\medskipamount}
\nopagebreak\hrule
\begin{verbatim}
drwxr-xr-x   2 root     root         1024 Jul  6 15:12 init.d
-rwxr-xr-x   1 root     root         1776 Feb  9 05:01 rc
-rwxr-xr-x   1 root     root          820 Jan  2  1996 rc.local
-rwxr-xr-x   1 root     root         2567 Jul  5 20:30 rc.sysinit
drwxr-xr-x   2 root     root         1024 Jul  6 15:12 rc0.d
drwxr-xr-x   2 root     root         1024 Jul  6 15:12 rc1.d
drwxr-xr-x   2 root     root         1024 Jul  6 15:12 rc2.d
drwxr-xr-x   2 root     root         1024 Jul 18 18:07 rc3.d
drwxr-xr-x   2 root     root         1024 May 27  1995 rc4.d
drwxr-xr-x   2 root     root         1024 Jul  6 15:12 rc5.d
drwxr-xr-x   2 root     root         1024 Jul  6 15:12 rc6.d
\end{verbatim} 
\nopagebreak\hrule 
\addvspace{\medskipamount}




¦pªG§A¹Á¸Õ´M§ä§Aªº¤A¤Óºô¸ô¥d¤Îºô¸ô»¼°e³]©w¯u¥¿ªº°t¸m¦a¤è¡A§A»Ý­n°lÂÜ¨ì³o¨ÇÀÉ®×¸Ì§ä¥X°t¸m«ü¥Oªº©Ò¦b¡D




\subsection{®M¥ó¬ÛÃöªº PPP °t¸m¤u¨ã}

¦b¬Y¨Ç¦w¸Ë®M¥ó(¦p Red Hat »P Caldera)¡A¦³¤@­Ó¥H X window ³]©wªº PPP ¼·±µ¨t²Î¡D
³o¥÷ HOWTO ¨Ã¥¼¥]§t³oºØ»P³Ì¥ó¬ÛÃöªº¤u¨ã¡D¦pªG§A¦b¨Ï¥Î¤W¦³°ÝÃD¡Aª½±µ©M®M¥óªºµo¦æ¤H¸ß°Ý¡D

¹ï©ó Red Hat 4.x ªº¨Ï¥ÎªÌ¡A¥i¥H¦b Linux ªº¸ê·½°Ï§ä¨ì \nameurl{http://www.interweft.com.au}{Red Hat PPP-TIP}¡A
¤]¥i¦b¤ä´©°Ï§ä¨ì \nameurl{http://www.Red Hat.com}{Red Hat Software}¡D




\section{IP ¸¹½X}

¨C¤@­Ó³s¤Wºô»Úºô¸ôªº³]³Æ³£¥²¶·¾Ö¦³¥¦­Ì¦Û¤vªº¡A°ß¤@ªº IP ¸¹½X¡D³o¨Ç¬O¥Ñ¨C­Ó°ê®aªº¦³Ãö³æ¦ì¶°¤¤«ü©wªº¡D

¦pªG§A­n§â°Ï°ìºô¸ô³s¤Wºô»Úºô¸ô¡A¦b§Aªº°Ï°ìºô¸ô¸Ì§A©Ò¾Ö¦³ªº©Ò¦³¹q¸£¤Î³]³Æ³£{\bfseries ¥²¶·}¨Ï¥Î±q«ü©wµ¹§Aªººô¸ô½d³ò¸Ì¤À°tªº IP ¸¹½X¡D
§Y¨Ï³s±µ¥t¤@­Ó°Ï°ìºô¸ô¡]¦bºô»Úºô¸ô¤§¥~¡^§A¤]{\bfseries µ´¤£¯à}¾ÌªÅ¨ú¥Î IP ¸¹½X¡D
¦pªG§A'°½¨Ó'ªº IP ¸¹½X¶}©l¤zÂZ¨ä¥¦¤w¸g¨Ï¥Î³o­Ó IP ªº¹q¸£ªº¸Ü¡A³ÌÁV®É¤£¶È¤£·|°Ê¡AÁÙ±N·|¤Þ°_¥þÅé©Êªº¤j¯}Ãa¡D

½Ðª`·N¦b³o¾ã¥÷¤å¥ó¸Ì©Ò¨Ï¥Îªº IP ¸¹½X¡]¦³¤@¨Ç­Ó¨Ò¥~¡^³£¬O±q«O¯dµ¹¨S¦³¡]¤£´¿¡^³s¤Wºô»Úºô¸ôªººô¸ô©Ò¨Ï¥Îªº¡¥¥¼³s½uºô¸ô¸¹½X¡¦¨t¦C¨Óªº¡D

¦³¤@¨Ç¯S§O¯dµ¹¤£³s±µºô»Úºô¸ôªººô¸ô¨Ï¥Îªº IP ¸¹½X¡D³o¨Ç IP ¸¹½X¨Ì§Ç¬O:

\begin{itemize}
\item 1 ­Ó A-µ¥¯Å ªº¦ì§}\\ 
10.0.0.0 (netmask 255.0.0.0)
\item 16 ­Ó B-µ¥¯Å ªº¦ì§}\\ 
172.16.0.0 - 172.31.0.0 (netmask 255.255.0.0)
\item 256 ­Ó C-µ¥¯Å ªº¦ì§}\\ 
192.168.0.0 - 192.168.255.0 (netmask 255.255.255.0)
\end{itemize}




¦pªG§Aªººô¸ô{\bfseries ÁÙ¨S}±q§A°ê®aªºÅv³d³æ¦ì¤À°t¨ì IP ¸¹½X¡A¨º»ò§Aªº¾÷¾¹À³¸Ó¨Ï¥Î«e­±©Ò¦C³o¨Çºô¸ô¸¹½X¤¤ªº¤@­Ó¡D

³o¨Ç¸¹½X{\bfseries ¥Ã»·¤£¸Ó}¨Ï¥Î¦bºô»Úºô¸ô¤W¡D

µM¦Ó¡A¥¦­Ì¤´¥i¨Ï¥Î¦b¤@³¡³s±µ¦bºô»Úºô¸ôªº¾÷¾¹¤Wªº¤º³¡¤A¤Óºô¸ô¥d¤W¡D
¦]¬° IP ¸¹½X¬O¤À°tµ¹ºô¸ô¬É­±¡A¦Ó¤£¬O¹q¸£¥»¨­ªº¡D
¦]¦¹ÁöµM§Aªº¤A¤Óºô¸ô¬É­±¨Ï¥Î 10.0.0.1 (¨Ò¦p)¡A·í§A¥H PPP ³s¤Wºô»Úºô¸ô®É¡A§Aªº PPP ¬É­±±N¥Ñ¦øªA¾¹¤À°tµ¹¥t¤@­Ó(¦Xªkªº) IP ¸¹½X¡D
§Aªº PC ±N¦³ºô»Úºô¸ôªº³s±µ¯à¤O¡A¦ý¨ä¥¦°Ï°ìºô¸ô¤ºªº¹q¸£«h¨S¦³¡D

¤£¹L¡A¨Ï¥Î Linux  ¥H¤Î ipfwadm  ³nÅéªº IP °°¸Ë¯à¤O(¤]¥s°µ NAT - Network address Translation ºô¸ô¦ì¸mÂà´«)¡A
§A´N¥i¥H§â§Aªº°Ï°ìºô¸ô¤W¤£¨ã¦Xªk IP ¸¹½Xªº¾÷¾¹³s¤Wºô»Úºô¸ô¡]´£¨ÑªºªA°È·|¦³¨Ç­­¨î¡^¡D

·Q±o¨ì§ó¦h¸ê°T½Ð°Ñ¦Ò 
\nameurl{http://sunsite.unc.edu/mdw/HOWTO/mini/IP-Masquerade}{Linux IP Masquerade mini HOWTO}¡D

¹ï©ó¤j³¡¤Àªº¨Ï¥ÎªÌ¡A¸g¥Ñ PPP  ³s±µ³æ¤@¾÷¾¹¨ìºô»Úºô¸ôªA°È´£¨ÑªÌ(Internet Service Providers: ISP)¡A
¨ú±o¤@­Ó IP ¸¹½X¡]©Î§ó¥¿½Tªº»¡¡A¤@­Óºô¸ô¸¹½X¡^¬O¨S¦³¥²­nªº¡D

¦pªG§A§Æ±æ³s±µ¤@­Ó¤p«¬ªº°Ï°ìºô¸ô¨ìºô»Úºô¸ô¤W¡A³\¦hºô»Úºô¸ôªA°È´£¨ÑªÌ¥i¥H±q¥L­Ì¤w¦³ªº IP ¦ì§}ªÅ¶¡¤¤´£¨Ñµ¹§A¤@­Ó¦¸ºô¸ô¡]¯S©wªº¤@¬q IP ¸¹½X¡^¡D
©ÎªÌ¡A¨Ï¥Î IP °°¸Ë¯à¤O¡D¡@

¹ï©ó¸g¥Ñ ISP  ³s±µ³æ¤@ PC ¨ìºô»Úºô¸ô¤Wªº¨Ï¥ÎªÌ¡A¤j³¡¤Àªº´£¨ÑªÌ¨Ï¥Î°ÊºAªº IP «ü©w¡D
³o¬O»¡¡A³s½uµ{§Çªº¤@³¡¥÷¤¤¡A§A©ÒÁpÃ´ªº PPP ªA°È±N·|§i¶D§Aªº¾÷¾¹³o¦¸³s½uªº´Á¶¡¸Ì¸Ó PPP ¬É­±À³¸Ó¨Ï¥Î¤°»ò IP ¸¹½X¡D
¨C¦¸§A³s¤W ISP ©Ò±o¨ìªº¸¹½X¤£·|¤@¼Ë¡D

¨Ï¥Î°ÊºAªº IP ¸¹½X¡A§A¨C¦¸ªº³s½u{\bfseries ¤£·|}³£¨ú±o¬Û¦Pªº IP ¸¹½X¡D
³o¹ï¦b§A Linux  ¾÷¾¹¤Wªº¦øªA«¬ºAÀ³¥Îµ{¦¡¹³¬O sendmail, ftpd, httpd ¥H¤Î½Ñ¦p¦¹Ãþªº³nÅé¦Ó¨¥·|²£¥Í°ÝÃD¡D
³o¨ÇªA°È®Ú°ò©ó³o³¡´£¨ÑªA°Èªº¹q¸£¯à¥H¦P¼Ëªº IP ¸¹½X¨ú¥Î¡D

¥Ñ©ó°ÊºAªº IP ¸¹½X«ü©w¦Ó¦³©Ò­­¨îªºªA°È¡]¥H¤Î¸Ñ¨Mªº¤èªk¡A¥i¯àªº¸Ü¡^µy«á·|¦b³o¥÷¤å¥ó¤¤°Q½×¡D




\section{³o¥÷¤å¥óªº¥Øªº}


\subsection{³]¥ß PPP «È¤áºÝ}

³o¥÷¤å¥ó´£¨Ñ·Q­n¨Ï¥Î Linux ¥H¤Î PPP ¼·±µ¨ì¬Y¤@¥x PPP ¦øªA¾¹¨Ã¥B¨Ï¥Î PPP ³]¥ß IP ³s½uªº¤H­Ì¤@¨Ç«ü¤Þ¡D
¤å¥ó¤¤°²³] PPP  ¤w¸g½sÄ¶¦n¨Ã¥B¦w¸Ë¦b§Aªº Linux  ¾÷¾¹¤W(¦ýÂ²µu¦a²[»\­«·s°t¸m¡þ­«·s½sÄ¶§Aªº®Ö¤ß¥H«K¥]§t PPP  ¤ä´©ªº³¡¥÷)¡D

ÁöµM DIP¡]«Ø¥ß SLIP ³s½uªº¼Ð·Ç¤è¦¡¡^¥i¥H¥Î¨Ó³Ð³y PPP  ³s½u¡A¦ý DIP «ü¥O½Z¤@¯ë³£¬Û·í¦a½ÆÂø¡D
¦]¬°³o­Ó½t¬G¡A³o¥÷¤å¥ó¨Ã¤£²[»\¨Ï¥Î DIP ¨Ó«Ø¥ß PPP ³s½uªº³¡¥÷¡D

¨ú¦Ó¥N¤§ªº¬O¡A³o¥÷¤å¥ó´y­z¼Ð·Çªº Linux PPP  ³nÅé(chat/pppd)¡D




\subsection{¨Ï¥Î PPP  ³sµ²¨â­Ó°Ï°ìºô¸ô©Î³sµ²¤@­Ó°Ï°ìºô¸ô¨ìºô»Úºô¸ô¤W}

³o¥÷¤å¥ó´£¨ÑÃö©ó³sµ²¨â­Ó°Ï°ìºô¸ô©Î³sµ²¤@­Ó°Ï°ìºô¸ô¨ìºô»Úºô¸ô¤Wªº¡]°ò¥»¡^¸ê°T¡D




\subsection{³]¥ß PPP ¦øªA¾¹}

³o¥÷¤å¥ó´£¨Ñ¦p¦ó°t¸m§Aªº Linux PC °µ¬° PPP  ¦øªA¾¹ªº«ü¤Þ¡]¤¹³\¨ä¥L¤H¼·±µ¨ì§Aªº Linux PC ¨Ã¥B«Ø¥ß PPP  ³s½u¡^¡D

§AÀ³¸Óª`·Nªº¬O³]©w Linux  §@¬° PPP  ¦øªA¾¹ªº¤èªk¦³µL¼ÆºØ¡D³o¥÷¤å¥ó¡]¥Ø«e¡^µ¹§A¤@ºØ¤è¦¡ ¡Ð 
§@ªÌ¥Î¨Ó¥¦³]¥ß¤@¥x¤p«¬ PPP  ¦øªA¾¹¡]¦@¦³ 16 ¥x¼Æ¾Ú¾÷¡^¡D

³o­Ó¤è¦¡¤wª¾¹B§@¨}¦n¡D¤£¹L¡A¥¦¤£¤@©w¬O³Ì¦nªº¤è¦¡¡D




\subsection{¨Ï¥Î PPP ©óª½±µÆl½u(direct null modem)³sµ²}

¥»¤å¥ó´£¨Ñ¨Ï¥Î PPP ³sµ²©ó¨â³¡ Linux PCs ©ó null modem Æl½uªºÂ²µu´y­z¡D
¥H¦¹ªk³sµ²¨ä¥¦§@·~¨t²Î©ó Linux ¤]¬O¥i¯àªº¡D
¦pªG­n³o¼Ë°µ¡A§A¥²¶·°Ñ¦Ò§A­n³sµ²ªº§@·~¨t²Îªº¤å¥ó¡D




\subsection{³o¥÷¤å¥ó¥Ø«e©|¥¼²[»\ªº...}

\begin{itemize}
\item ½sÄ¶ PPP ³nÅé\\ 
°Ñ¨£ÀHªþ§A¨Ï¥Îªº pppd ª©¥»¦Ó¨Óªº¤å¥ó¡D
\item ³s±µ¥H¤Î°t¸m¼Æ¾Ú¾÷¨ì Linux ¤W(²Ó¸`)\\ 
½Ð°Ñ¾\ Serial-HOWTO¡A¥H¤Î¼Æ¾Ú¾÷¬ÛÃöªº°_©l³]©w¡A°Ñ¾\
\nameurl{http://www.in.net/info/modems/index.html}{Modem Setup Information}
¸Ìªº¸ê°T¥i¯à¹ï§A³]©w¼Æ¾Ú¾÷¦³©ÒÀ°§U¡D
        
\item ¨Ï¥Î DIP  ³Ð³y PPP  ³s½u\\ 
¨Ï¥Î chat ¨ú¥N...
\item ¨Ï¥Î socks  ©Î¬O IP Masquerade\\ 
¤w¸g¦³²[»\³o¨â­Ó®M¥óªºµ´¨Î¤å¥ó¡D
\item ¨Ï¥Î {\ttfamily diald} ¥H«Ø¥ß¦Û°Ê³s½u\\ 
½Ð°Ñ¾\ {\ttfamily diald} ¤å¥ó¸Ìªº¸ê°T¡D
\item ¨Ï¥Î EQL ±N¨â³¡¼Æ¾Ú¾÷¦X¦¨³æ¤@ PPP ³sµ²¡D
\item »P®M¥ó¬ÛÃöªº PPP ³s½u¤èªk(¨Ò¦p Red Hat 4.x ºô¸ô³]©w¤u¨ã)\\ 
½Ð°Ñ¾\¸Ó®M¥ó¤¤ªº¤å¥ó¡D
\item ¤£Â_¼W¥[ªº¦Û°Ê«Ø¥ß PPP ¤u¨ã\\ 
½Ð°Ñ¾\¾A·íªº¤å¥ó¡D
\end{itemize}





\section{²[»\ªº³nÅéª©¥»}

³o¥÷¨Ï¥Î»¡©ú°²³]§A¨Ï¥Î Linux 1.2.x  ®Ö¤ß°t¦X PPP 2.1.2 ³nÅé©Î Linux 1.3.X/2.0.x ¥H¤Î PPP 2.2  ª©¡D

¦b¥»¤å¥ó¼¶¼g¤§®É¡ALinux ªº PPP ³nÅé³Ì·s¥¿¦¡ª©¥»¬O ppp-2.2f¡D
³Ì·sªºª©¥»(ppp-2.3)ÁÙ¦b beta ¶¥¬q¡D

¨Ï¥Î PPP 2.2.0  °t¦X®Ö¤ß 1.2.13 ¬O¦³¥i¯àªº¡DµM¦Ó¡A­n³o¼Ë°µ»Ý­n®Ö¤ß­×¸É¡D
«ØÄ³®Ö¤ß 1.2.13 ª©¥»ªº¨Ï¥ÎªÌ¤É¯Å¨ì ppp-2.2 ¦]¬°¥¦¥]§t¤F³\¦h¿ù»~­×¥¿¤Î¥\¯à¥[±j¡D

{\bfseries ÁÙ¦³¡A§AÀ³¯S§Oª`·N¤£¯à±N PPP 2.1.2 »P Linux ®Ö¤ß 2.0.X ¦X¥Î¡D}



½Ðª`·N³o¥÷¤å¥ó{\bfseries ¤£}¥]¬A¨Ï¥Î Linux  ®Ö¤ß 2.0.x  ªº¥i¸ü¤J¼Ò²Õ©Ò¤Þ°_ªº°ÝÃD¡D
½Ð°Ñ¾\ kerneld mini-HOWTO ¥H¤Î®Ö¤ß¡þ¼Ò²Õ 2.0.x  ªº¤å¥ó¡]¦b Linux 2.0.x  ªº­ì©lµ{¦¡¥Ø¿ý {\ttfamily /usr/src/linux/Documentation/...} ¸Ì¡^¡D

{\bfseries ¦]¬°³o¥÷¤å¥ó¬O³]­p¨Ó¨ó§U·s¤âªº¡A±j¯P«ØÄ³§A¨Ï¥Î¤wª¾¯àÃ­©w¦a¦@¦P¹B§@ªº Linux ª©¥»¤Î¾A·íªº PPP ª©¥»¡D}




\section{¨ä¥¦¦³¥Îªº¡þ­«­nªº¤å¥ó}

¹ªÀy¨Ï¥ÎªÌ¾\Åª:-
\begin{itemize}
\item ÀHªþ©ó PPP ®M¥óªº¤å¥ó;
\item pppd ¥H¤Î chat ªº½u¤W¨Ï¥Î¤â¥U;\\ 
(¨Ï¥Î {\ttfamily man chat} ¥H¤Î {\ttfamily man pppd} ¨Ó¾\Åª)
\item Linux ºô¸ôºÞ²z«ü¤Þ (NAG);\\ 
°Ñ¾\ \nameurl{http://sunsite.unc.edu/mdw/LDP-books/nag-1.0/nag.html}{The Network Administrators' Guide}
\item Net-2/3 HOWTO;\\ 
°Ñ¾\ \nameurl{http://sunsite.unc.edu/mdw/HOWTO/NET-2-HOWTO.html}{Linux NET-2/3-HOWTO}
\item ¦b {\ttfamily /usr/src/linux/Documentation} ¸Ìªº Linux ®Ö¤ß¤å¥ó;
\item ¼Æ¾Ú¾÷³]©w¸ê°T - °Ñ¾\ \nameurl{http://www.in.net/info/modems/index.html}{Modem Setup Information}
\item ¥Ñ O'Reilly and Associates ¥Xª©ªº³Ì¨Î Unix/Linux ®ÑÄy¡]°Ñ¾\ \nameurl{ http://www.ora.com/}{O'Reilly and Associates On-Line Catalogue} ¸Ìªº¥Ø¿ý¡^¡D
¦pªG§A¬O Unix/Linux ªº·s¤â¡A¥ß¨è{\bfseries ¶]}¡]¤£­n¥Î¨«ªº¡^¨ìÂ÷§A³Ìªñªº¹q¸£®Ñ©±¥h§ë¸ê´X¼Ë³o¨Ç¸ê®Æ¡D
\item ¥Ñ Al Longyear ©ÒºûÅ@ªº PPP-FAQ¡A¥i¦b \nameurl{ftp://sunsite.unc.edu/pub/Linux/docs/faqs}{Linux PPP-FAQ} ¨ú±o¡D\\ 
¸Ì­±¥]¬A¤F¤j¶q¦³¥Îªº¸ê°T¥H°Ýµªªº§Î¦¡¥X²{¡A¦b¸Õ¹Ï§ä¥X¬°¦ó PPP ¤£¯à(¥¿±`)¤u§@®É¬Û·í¦³¥Î¡D
\item ¤£Â_·s¼W¥Ñ¤£¦P¥Xª©ªÀ»P§@ªÌ¥X«~ªº®ÑÄy;\\ 
¹ªÀy§A¥h¬d¾\³o¨Ç¬y³qªº®ÑÄy¡DLinux ªºµo®i»P®M¥óªººt¶i¬Û·í§Ö³t¡A¦Ó®ÑÄyªº§ïª©³t«×(¤@¯ë¨Ó»¡)¬Û·íªººC!
¶R¤@¥»¤w¸g¹L´Áªº¦n®Ñ(²{¦b¦³³\¦h)¥i¯à¨Ï±o·s¨Ï¥ÎªÌ·P¨ì§x´b»P¥¢±æ¡D
\end{itemize}




Linux ¤å¥óªº³Ì¨Î°_ÂI´N¬O \nameurl{http://sunsite.unc.edu/mdw/}{The Linux Documentation Project Home Page}. HOWTOs ¶É¦V©ó©w´Á¦a§ó·s¡D



ÁöµM§Y¨Ï¤£¥²¾\Åª³o¨Ç¸ê®Æ¤¤ªº¥ô¦ó¤@¥÷§A¤]¥i¥H¨Ï¥Î³o¥÷¤å¥ó¨Ó«Ø¥ß§Aªº PPP ³sµ²¡A
¦ý¬O¦pªG§A¥h¾\Åª³o¨Ç¤å¥ó¨º»ò§A¹ï©ó§A©Ò°µªº¨s³ºµo¥Í¤F¨Ç¤°»ò±N·|¤F¸Ñ§ó¦h!
§A±N¯à°÷ºë½Tªº´£¥X¦Û¤vªº°ÝÃD(©Î¦Ü¤Ö¦b comp.os.linux... ·s»D°Q½×¸s©Î Linux mailing lists ¤¤°Ý¥X¸û¦³²`«×ªº°ÝÃD)¡D



³o¨Ç¤å¥ó¡]»P¦UºØ¨ä¥¦¤å¥ó¡A¥]¬A¬ÛÃöªº RFCs µ¥¡^´£¨ÑÃB¥~ªº¥H¤Î¤ñ³o¥÷¨Ï¥Î»¡©ú©Ò¯à¥]§tªº§ó¦h²Ó¸`¸ÑÄÀ¡D

¦pªG§A­n¨Ï¥Î PPP ³s±µ°Ï°ìºô¸ô¨ìºô»Úºô¸ô¤W¡A¨º»ò§A±N±oª¾¹D¤@¨ÇÃö©ó TCP/IP ºô¸ô¹B§@ªºª¾ÃÑ¡D
¸É¥R¤@ÂI³o¥÷¤å¥ó«e­±´£¨ìªº¸ê®Æ¡A§A±N·|µo²{ O'Reilly ¥Xª©ªº "TCP/IP Network Administration"  ¥H¤Î "Building Internet Firewalls" «Ü¦³¦n³B!




\subsection{¦³¥Îªº Linux ¹q¤l¶l»¼¦Cªí}

¦³³\¦h¦b¤£¦P¨Ï¥ÎªÌµ¥¯Å¤§¶¡¬y³qªº¹q¤l¶l»¼¦Cªí(mailing lists)¡D
¿ï¾Ü§A¦³¿³½ì¥H¤Î¹ï§A±M·~ª¾ÃÑ¤ÎÆ[ÂI¦³©ÒÀ°§Uªº¦Cªí¨Ó­q¾\¡D



{\bfseries ¤@¨Ç©¾§i}: ¦³¨Ç¦Cªí¬Oµ¹¨º¨Ç"±M®a¯Å"¨Ï¥ÎªÌ©Î¬O¯S®í¥DÃDªº¡D
ÁöµM¨S¦³¤H·|©ê«è§A"¼ç¥ñ"(­q¾\¦ý¤£µoªí¤å³¹)¦b¸Ì­±¡A
¤£¹L¦pªG§A¦b¤£¾A¦Xªº¦Cªí¤¤´£¥X"·s¤â"ªº°ÝÃD§A¥i¯à·|¦¬¨ì¤@¨Ç¼««ãªº·N¨£¡D



³o¨Ã¤£¬O¦]¬°±M®a¯Åªº¨Ï¥ÎªÌ°Q¹½·s¶iªº¨Ï¥ÎªÌ¡A¦Ó¬O¦]¬°³o¨Ç¦Cªí¬O¥Î¨Ó³B²z¨ã¦³¤@©w§xÃø«×ªº¯S®í¥DÃDªº¡D



¥[¤J¨º¨Ç¥i¥H¤½¶}­q¾\ªº¦Cªí¡A¦ý½Ð§½­­§Aªº·N¨£©ó¦Cªíªº¬ÛÃö¥DÃD¤W­±¡D



Linux ¹q¤l¶l»¼¦Cªí¤@­Ó«Ü¦nªº°_ÂI¬O
\nameurl{http://summer.snu.ac.kr/~djshin/linux/mail-list/index.shtml}{Linux Mailing List Directory}¡D




\section{±N PPP ³]©w¬°«È¤áºÝªº¤u§@·§­n}

³o¥÷¤å¥ó¥]§t¤F³\¦h¸ê°T - ¦Ó¥B¨C¦¸§ïª©¤S¤£Â_¼W¥[!



¦]¦¹¡A¥»¸`ªº¥Øªº¦b©ó´£¨Ñ¤@Â²µuªº·§­n»¡©ú­n±N§Aªº Linux ¨t²Î§@¬°«È¤áºÝ³s±µ¨ì PPP ¦øªA¾¹©Ò»Ýªº¤u§@¡D




\subsection{¨ú±o/¦w¸Ë³nÅé}

¦pªG§Aªº Linux ®M¥ó¨Ã¥¼¥]§t PPP ³nÅé¡A§A¥i±q¦¹¨ú±o: \nameurl{ftp://sunsite.unc.edu/pub/Linux/system/network/serial/ppp/ppp-2.2.0g.tar.gz}{the Linux PPP daemon}.



³o¬O¥»¤å¥ó¼¶¼gªº®É­Ô³Ì·s¥¿¦¡ª©¥»¡DµM¦Ó¡A¾¨¶q±q¸Ó¯¸¨úªº³Ì·sªºª©¥»(¥»¤å¥ó¼¶¼g®É ppp-2.3 ©|¦b beta ¶¥¬q¦Ó¥BÀ³¸Ó«Ü§Ö·|µo¦æ)¡D



³o¥÷ PPP ®M¥ó¥]§t¤F¦p¦ó½sÄ¶¤Î¦w¸Ë©Ò»Ýªº«ü¤Þ¡A{\bfseries ¦]¦¹¥»¤å¨Ã¤£¥]§t¦¹³¡¥÷}!




\subsection{½sÄ¶®Ö¤ß¥[¤J PPP ¤ä´©}

Linux ªº PPP ¹B§@¥]§t¨â³¡¥÷
\begin{itemize}
\item ¤W­±´£¨ìªº PPP daemon
\item PPP ªº®Ö¤ß¤ä´©
\end{itemize}




³\¦h®M¥ó¦ü¥G¦b¥¦­Ì¹w³]ªº¦w¸Ë®Ö¤ß¤¤´£¨Ñ PPP ªº¤ä´©¡A¦ý¨ä¾l«h§_¡D



¦pªG¦b±Ò°Ê®É®Ö¤ß³ø§i³o¼Ëªº°T®§

\par
\addvspace{\medskipamount}
\nopagebreak\hrule
\begin{verbatim}
PPP Dynamic channel allocation code copyright 1995 Caldera, Inc.
PPP line discipline registered.
\end{verbatim} 
\nopagebreak\hrule 
\addvspace{\medskipamount}




§Aªº®Ö¤ß¤w½sÄ¶ PPP ¤ä´©¦b¤º¡D



¨º´N¬O»¡¡A¤£½×§A¨Ï¥Î¤°»ò®M¥ó§A¥i¯à§Æ±æ¦Û¦æ½sÄ¶®Ö¤ß¥H¦b§Aªº¯S©wµwÅé°t¸m¤§¤U±o¨ì³Ì¦³®Äªº¨t²Î¸ê·½§Q¥Î¡D
½Ð°O¦í®Ö¤ß¤£¯à³Q¸m´«¥X°O¾ÐÅé¦]¦¹¾¨¶qÅý®Ö¤ß«O«ù³Ì¤p¦b°O¾ÐÅé¦³­­ªº¾÷¾¹¤W¬Û·í¦³¥Î¡D



¥»¤å¥ó¦b \ref{Kernel configuration} {(°t¸m§Aªº Linux  ®Ö¤ß)} ¤@¸`´£¨Ñ¤F­«·s½sÄ¶®Ö¤ßªº³Ì¤Ö»¡©ú¡D



²Ó¸`³¡¥÷½Ð°Ñ¾\ \nameurl{Kernel-HOWTO.html}{The Linux Kernel HOWTO}¡D




\subsection{±q§Aªº ISP ¨ú±o¸ê°T}

´X¥G¦³µL¼ÆºØ³]©w PPP ¦øªA¾¹ªº¤èªk¡D
¬°¤F³s¤W§Aªº ISP, §A¥²¶·¨ú±o PPP ¦øªA¾¹¦p¦ó¹B§@ªº¸ê°T¡D



¦]¬°§A¥Îªº¬O Linux, ¦b¤@¨Ç¶Èª¾¹D MS Windows «È¤áºÝªº ISP ¿Ô¸ß³¡ªù¥i¯à·|¾D¹J§xÃø¡D



µM¦Ó¡A·U¨Ó·U¦hªº ISP ¨Ï¥Î Linux ´£¨ÑªA°È - ¦Ó¥B Linux ¤]º¯¤J¤½¥qÀô¹Ò¡A¦pªG§A¯uªº¹J¨ì°ÝÃD§A¤]¥i¯à·|«Ü©¯¹B¡D



\ref{Server info} {(¨ú±o§A©Ò»Ýªº PPP ¦øªA¾¹¸ê°T)} ¤@¸`§i¶D§A»Ý­nª¾¹D§A³s±µªº PPP ¦øªA¾¹ªº¤°»ò¸ê°T - ¥H¤Î¦p¦ó§ä¥X³o¨Ç¸ê°T¡D




\subsection{³]©w§Aªº¼Æ¾Ú¾÷¤Î¦ê¦C°ð}

¬°¤F³s¤W PPP ¦øªA¾¹¨Ã¨ú±o³Ì¨Îªº¸ê®Æ¶Ç¿é³t²v¡A§Aªº¼Æ¾Ú¾÷¥²¶·³]©w¥¿½T¡D



¦P¼Ë¦a¡A³s±µ¼Æ¾Ú¾÷¤Î¹q¸£ªº¦ê¦C°ð¤]¥²¶·¥¿½T¦a³]©w¡D



\ref{Modem} {(³]©w§Aªº¼Æ¾Ú¾÷¤Î¦ê¦C°ð)} ¤@¸`´£¨Ñ³o¤è­±ªº¸ê°T¡D




\subsection{«Ø¥ß¦WºÙ¨ì¦ì§}¸ÑªR(DNS)}

°£¤F°õ¦æ PPP ¤Î¦Û°ÊÃ±¤J PPP ¦øªA¾¹ªºÀÉ®×¤§¥~¡AÁÙ¦³¤@¨Ç¤å¦r°t¸mÀÉ®×¥²¶·³]©w¡A
¥H«KÅý§Aªº¹q¸£¯à±N¹³³o¼Ëªº¦WºÙ {\ttfamily www.interweft.com.au} ¸ÑªR¬° IP ¦ì§}¥H«K¯u¥¿»P¨º¥x¹q¸£³s½u¡D
³o¨ÇÀÉ®×¬O:-

\begin{itemize}
\item {\ttfamily /etc/resolv.conf}
\item {\ttfamily /etc/host.conf}
\end{itemize}




\ref{DNS} {(«Ø¥ß¦WºÙ¨ì¦ì§}¸ÑªR)} ¤@¸`´£¨Ñ³o¤è­±ªº³]©w²Ó¸`¡D



¯S§O¦a¡A§A¨Ã{\bfseries ¤£»Ý­n}¦b§Aªº Linux PC ¤W°õ¦æ¦WºÙ¦øªA¾¹¥H³s±µ¨ìºô»Úºô¸ô¤W(ÁöµM©Î³\§A·|·Q³o»ò°µ)¡D
§A©Ò»Ýªº¥u¬Oª¾¹D¦Ü¤Ö¤@³¡§A¯à¨Ï¥Îªº¦WºÙ¦øªA¾¹ IP ¦ì§}(³Ì¦n¬O§Aªº ISP ©Ò´£¨Ñªº)¡D




\subsection{PPP »P root Åv­­}

¦]¬°¦b§Aªº Linux ¹q¸£»P¥t¤@­Ó PPP ¦øªA¾¹«Ø¥ß³sµ²»Ý­n¾Þ§@ºô¸ô¬É­±(PPP ¬É­±¬O¤@­Óºô¸ô¬É­±)»P®Ö¤ßªº¸ô¥Ñªí¡Apppd »Ý­n¨Ï¥Î root ªºÅv­­¡D



²Ó¸`³¡¥÷¡A°Ñ¾\ \ref{root} {(¨Ï¥Î PPP »P root Åv­­)} ¤@¸`¡D




\subsection{ÀË¬d§Aªº PPP ®M¥óÀÉ®×¤Î³]©w PPP ¿ï¶µ}

¦³¦n´X­Ó°t¸m¤Î¼·¸¹ÀÉ®×»Ý­n«Ø¥ß¥H«KÅý PPP ¹B§@¡D¦b PPP ®M¥ó¤¤¦³¤@¨Ç½d¨Ò¡A¦Ó¥»¸`§i¶D§AÀ³¦³ªº³o¨ÇÀÉ®×¬O¤°»ò:-
\par
\addvspace{\medskipamount}
\nopagebreak\hrule
\begin{verbatim}
/etc/ppp/options
/etc/ppp/scripts/ppp-on
/etc/ppp/scripts/ppp-on-dialer
/etc/ppp/options.tpl
\end{verbatim} 
\nopagebreak\hrule 
\addvspace{\medskipamount}




¬Ý§A·Q¥Î PPP ¹F¨ìªº¥Ø¼Ð¬O¤°»ò§A¥i¯à»Ý­n¤@¨ÇÃB¥~ªºÀÉ®×:-
\par
\addvspace{\medskipamount}
\nopagebreak\hrule
\begin{verbatim}
/etc/ppp/options.ttyXX
/etc/ppp/ip-up
/etc/ppp/pap-secrets
/etc/ppp/chap-secrets
\end{verbatim} 
\nopagebreak\hrule 
\addvspace{\medskipamount}




°£¦¹¤§¥~¡APPP daemon ¦³¤j¶qªº½u¤W¿ï¶µ¡A¥¿½T¦a¨Ï¥Î¬O«Ü­«­nªº;
¦]¦¹¥»¸`±a§A¬Ý³o¨Ç¼Ð·Ç PPP ¿ï¶µ¨ÃÀ°§U§A¿ï¾Ü§AÀ³¨Ï¥Îªº¿ï¶µ¡D



²Ó¸`³¡¥÷¡A½Ð°Ñ¾\ \ref{options} {(³]©w PPP ³s±µÀÉ®×)} ¤@¸`¡D




\subsection{¦pªG§Aªº PPP ¦øªA¾¹¨Ï¥Î PAP »{ÃÒ(Password Authentication Protocol)}

³\¦h ISP ³]¥ß PPP ¦øªA¾¹¨Ï¥Î PAP »{ÃÒ¡D¦pªG§Aªº¦øªA¾¹{\bfseries ¨Ã¤£}¨Ï¥Î PAP
(¦pªG§A¥i¥H¥Î¤â°ÊÃ±¤J¨Ã¦¬¨ì¼Ð·Çªº¨Ï¥ÎªÌ¦WºÙ/±K½X´£¥Ü²Å¸¹¨º»ò¥¦¨Ã¥¼¨Ï¥Î PAP)¡A¨º»ò§A¥i¥H¸õ¹L¦¹¸`¡D



¨ú¥N¦b¶i¤J¦øªA¾¹®É¥X²{´£¥Ü²Å¸¹¿é¤J¨Ï¥ÎªÌ¦WºÙ¤Î±K½Xªº¬O¡A¨Ï¥Î PAP ªº PPP ¦øªA¾¹¨Ã¤£»Ý­n¤å¦r¼Ò¦¡ªºÃ±¤J¤è¦¡¡D



¨Ï¥ÎªÌ»{ÃÒ¬O³s±µ±±¨î¨ó©w(link control protocol, LCP)ªº¤@³¡¥÷¡A¦b«Ø¥ß PPP ³s½u¤§ªì´Á¥æ´«ªº¸ê°T¡D



\ref{pap} {(¦pªG§Aªº PPP ¦øªA¾¹¨Ï¥Î PAP »{ÃÒ(Password Authentication Protocol))} 
¤@¸`´£¨Ñ§A¨Ï¥Î PAP «Ø¥ß PPP ³sµ²©Ò»ÝÀÉ®×ªº¸ê°T¡D




\subsection{¥H¤â°Ê¤è¦¡³s±µ¦Ü PPP ¦øªA¾¹}

¤w¸g«Ø¥ß§¹°ò¥»ªºÀÉ®×¤§«á¡A³z¹L¤â°Ê(¨Ï¥Î minicom ©Î seyon)ªº¤è¦¡³s±µ¤Î±Ò°Ê§A Linux PC ªº pppd ¨Ó´ú¸Õ¬O­Ó¤£¿ùªº¥D·N¡D



°Ñ¨£ \ref{manual} {(¥H¤â°Ê¤è¦¡«Ø¥ß PPP ³sµ²)} »¡©ú³]©wªº²Ó¸`³¡¥÷¡D




\subsection{¨Ï§Aªº PPP ³sµ²¦Û°Ê¤Æ}

¤@¥¹§A¦¨¥\¦a¥Î¤â°Ê¤è¦¡Ã±¤J¡A§A¥i¥H¸ÕµÛ«Ø¥ß¤@«ü¥O½Z¥H¦Û°Ê«Ø¥ß¦¹³sµ²¡D



\ref{automate} {(¨Ï§Aªº³sµ²¦Û°Ê¤Æ - ³Ð³y³sµ²«ü¥O½Z)}
¤@¸`¥]§t¤F«Ø¥ß©Ò»Ýªº«ü¥O½Z¡A¥H¤Î¬Û·í¦hªºª`·N¤O¶°¤¤¦b {\ttfamily chat} ©R¥O©ó PPP ¦øªA¾¹ªºÃ±¤J¹Lµ{¡D  



³o¸`¤]°Q½×¤F¨Ï¥Î«ü¥O½Z©ó PAP/CHAP »{ÃÒªº¦øªA¾¹¤W¡D




\subsection{µ²§ô³sµ²}

¤@¥¹§Aªº³sµ²¯à°÷«Ø¥ß¨Ã¥¿±`¥¿§@¡A§A¥²»Ý¯à°÷µ²§ô³sµ²¡D



³o¦b \ref{off} {(µ²§ô PPP ³sµ²)} ¤@¸`»¡©ú¡D




\subsection{¦pªG§A¾D¹J°ÝÃD}

³\¦h¤HµLªkÅý PPP ¥¿±`¦a¤u§@¡DPPP ¦øªA¾¹ªººØÃþ¥H¤Î©M¥¦­Ì«Ø¥ß³s½uªº¤èªk¦³«D±`¦hºØ¡D
Ãþ¦ü¦a¡APPP ¦³³\¦hªº¿ï¶µ - ¦Ó¦³¨Ç¿ï¶µ¬O¤£¯à¤@°_¥Îªº¡D



°£¤FÃ±¤J¨Ã°_©l PPP ªA°Èªº°ÝÃD¤§¥~¡A¼Æ¾Ú¾÷¥»¨­¤Î¹q¸Ü½u¸ô¤]¥i¯à·|¦³°ÝÃD¡D



\ref{problems} {(¸Ñ¨M°ÝÃD)} ¤@¸`´£¨Ñ¤@¯ë¿ù»~ªº°ò¥»¸ê°T¡A¥H¤Î¦p¦ó¤ÀÂ÷¨Ã¸Ñ¨Mªº¤èªk¡D



³o¸Ì´£¨Ñªº{\bfseries ¤£¹L}¬O°ò¥»ªº¸ê°T¡DAl Longyear ©ÒºûÅ@ªº PPP-FAQ ¥]§t¤F§ó¦h³o¤@¤è­±ªº¸ê°T!




\subsection{«Ø¥ß³sµ²¤§«á}

¤@¥¹ PPP ³sµ²¥i¥H¹B§@¤F(¯S§O¦a¡A¤@¥¹ IP ¼h¥i¥H¹B§@)¡ALinux ªº PPP ¥i¥H¦Û°Ê°õ¦æ(¥H root ¨­¥÷)¤@«ü¥O½Z§¹¦¨{\bfseries ¥ô¦ó}§A·Q¹F¦¨ªº¥\¯à¡D



\ref{ip-up} {(«Ø¥ß³sµ²¤§«á)} ¤@¸`´£¨Ñ {\ttfamily /etc/ppp/ip-up} «ü¥O½Zªº¸ê°T¡A
¥¦¦p¦ó±µ¦¬ PPP ¶Ç¨Óªº°Ñ¼Æ¥H¤Î¦p¦ó§Q¥Î¥¦¨Ó°µ¤@¨Ç¹³¦Û ISP ¨ú¦^§Aªº¹q¤l¶l¥ó¡A
°e¥X¦b§A¾÷¾¹¦î¦C¤¤¦s©ñªº¶l¥óµ¥µ¥¤u§@¡D




\subsection{°ÊºA IP ³s±µ´£¨Ñ¼Ð·Ç IP ªA°Èªº°ÝÃD}

´N¹³¦bÂ²¤¶¤@¸`¸Ì«ü¥Xªº¡A°ÊºA IP ¸¹½X¼vÅT§Aªº Linux PC §@¬°ºô»Úºô¸ô¦øªA¾¹ªº¯à¤O¡D



\ref{dynamic-server} {(°ÊºA IP ³s±µ´£¨Ñ¼Ð·Ç IP ªA°Èªº°ÝÃD)}
¤@¸`´£¨Ñ(¥D­n)¨ü¼vÅTªºªA°È¥H¤Î§A©Ò¯à°µ(¦pªG¦³ªº¸Ü)ªº§JªA¿ìªk¡D




\section{°t¸m§Aªº Linux ®Ö¤ß\label{Kernel configuration}}

¬°¤F­n¯à°÷¨Ï¥Î PPP¡A§A½sÄ¶ªº Linux  ®Ö¤ß¥²¶·¥]§t PPP ªº¤ä´©¡D
¦pªG§AÁÙ¨S¦³ Linux  ªº­ì©lµ{¦¡½X½Ð¥ý¨ú±o ¡Ð ¦b Linux  ªºÀÉ®×¨t²Î¼Ð·Ç¤¤¥¦¬O©ñ¦b {\ttfamily /usr/src/linux} ¸Ì­±¡D



ÀË¬d³o­Ó¥Ø¿ý - ³\¦hªº Linux ®M¥ó·|¦b¦w¸Ë¹Lµ{¤¤¦w¸Ë¦¹­ì©lµ{¦¡½X(ÀÉ®×¤Î¦¸¥Ø¿ý)¡D



¦b±Ò°Ê®É¡A§Aªº Linux ®Ö¤ß·|¦L¥X¤j¶qªº°T®§¡D¦pªG®Ö¤ß¤ä´© PPP ªº¸Ü·|¥]§t¦¹¤@°T®§¡D
­nÆ[¬Ý³o¨Ç°T®§ªº¸Ü¡A¬Ý¬Ý§Aªº¨t²Î°O¿ýÀÉ©Î¥Î {\ttfamily dmesg $|$ less} «ü¥O±N³o¨Ç°T®§Åã¥Ü¦b¿Ã¹õ¤W¡D
¦pªG®Ö¤ß¤ä´© PPP ªº¸Ü§A±N·|¬Ý¨ì¹³³o¼Ëªº´X¦æ
\par
\addvspace{\medskipamount}
\nopagebreak\hrule
\begin{verbatim}
PPP Dynamic channel allocation code copyright 1995 Caldera, Inc.
PPP line discipline registered.
\end{verbatim} 
\nopagebreak\hrule 
\addvspace{\medskipamount}




(³o¬O Linux 2.0.x ¨t¦C®Ö¤ßªº°T®§)¡D



Linux ®Ö¤ßªº­ì©lµ{¦¡¥i¥H±q {\ttfamily sunsite.unc.edu} ©Î¨ä¬M®g¸`ÂI¨ú±o¡D




\subsection{¦w¸Ë Linux ®Ö¤ß­ì©lµ{¦¡½X}

¤U­±¬OÂ²µuªº¨ú±o¤Î¦w¸Ë Linux ®Ö¤ß­ì©lµ{¦¡½Xªº«ü¥Ü¡D¸Ô²Óªº¸ê°T¥i¥H¦b \nameurl{Kernel-HOWTO.html}{The Linux Kernel HOWTO} ¤¤§ä¨ì¡D





¬°¤F¦w¸Ë¤Î½sÄ¶®Ö¤ß¡A§A¥²¶·¥H root ªº¨­¥÷Ã±¤J¡D

\begin{enumerate}
\item ¤Á´«¨ì {\ttfamily /usr/src} ¥Ø¿ý¤U\\ 
{\ttfamily cd /usr/src}
\item ÀË¬d {\ttfamily /usr/src/linux} ¬Ý¬Ý§A¬O§_¤w¸g¦w¸Ë¤F­ì©lµ{¦¡½X¡D
\item ¦pªG¨S¦³ªº¸Ü¡A¥Ñ \nameurl{ftp://sunsite.unc.edu/pub/Linux/kernel/v2.0}{Linux kernel source directory}
©ÎÂ÷§A³Ìªñªº¬M®g¸`ÂI¨ú¦^¡D\\ 
¦pªG§A·Q§ä§óÂÂª©¥»ªº®Ö¤ß(¨Ò¦p 1.2.X)¡A¥i¨ì \nameurl{ftp://sunsite.unc.edu/pub/Linux/kernel/old}{Old Linux kernel source directory} §ä§ä¡D
\item ¿ï¾Ü¾A·íªº®Ö¤ß - ³q±`¬O³Ìªñªºª©¥»¡D¨ú¦^«á±N¦¹ 'tar' À£ÁYÀÉ©ñ¦b {\ttfamily /usr/src}¡D\\ 
{\bfseries ª`·N}: ¤@­Ó 'tar' ÀÉ®×¬O¤@ºØÀ£ÁYÀÉ - ¥i¯àÀ£¤F³\¦hÀÉ®×©M¥Ø¿ý¦b¸ÌÀY¡D¥¦¬Û·í©ó DOS ¤Uªº zip ÀÉ®×¡D
\item ¦pªG§A¤w¸g¦w¸Ë¤F­ì©lµ{¦¡¡A¦ý·Q­n¤É¯Å¨ì·sª©ªº®Ö¤ß¡A§A¥²¶·¥ý²¾°£ÂÂªºµ{¦¡½X¡D¥Î³o­Ó«ü¥O\\ 
{\ttfamily rm -rf /usr/src/linux}
\item ¥Î³o­Ó«ü¥O¸ÑÀ£ÁY\\ 
{\ttfamily tar xzf linux-2.0.XX.tar.gz}
\item µM«á¡A{\ttfamily cd /usr/src/linux} ¨Ã¬Ý¬Ý README ÀÉ¡D¸ÌÀY¥]§t¤F§¹¾ãªº¸ÑÄÀ¦p¦ó°t¸m¤Î½sÄ¶·s®Ö¤ß¡D
¥J²Ó¾\Åª³o­ÓÀÉ®×(±N¥¦¦L¥X¨Ó©ñ¦b¤âÃä¬O­Ó¦n¥D·N¡Aª½¨ì§A¤w°µ¤F¨¬°÷¦h¦¸ª¾¹D«ç»ò¿ì)¡D
\end{enumerate}





\subsection{¾é¸Ñ§AªºµwÅé}

¦pªG§A­n­«·s½sÄ¶§Aªº®Ö¤ß§A{\bfseries ¥²¶·}ª¾¹D¦b§A PC ¸Ì­±ªº¬É­±¥d¡þ³]³Æ!!
¹ï©ó¬Y¨Ç³]³Æ¡]¹³¬O­µ®Ä¥d¡^§A¤]±oª¾¹D¦UºØ³]©w¡]¹³¬OµwÅé¤¤Â_¸¹½X¡A¿é¥X¤J¦ì§}¥H¤Î½Ñ¦p¦¹Ãþªº¸ê°T¡^¡D




\subsection{½sÄ¶®Ö¤ß ¡Ð Linux 1.2.13 ®Ö¤ß}

­n¶}©l°t¸mµ{§Ç¡A­º¥ý¨Ì·Ó¦b¸Ñ»¡ÀÉ¸Ìªº»¡©ú¾A·í¦a¦w¸Ë­ì©lµ{¦¡½X¡DµM«á¥H¤U­±ªº«ü¥O¶}©l®Ö¤ßªº°t¸mµ{§Ç
\begin{tscreen}
\begin{verbatim}
make config
\end{verbatim}
\end{tscreen}




¬°¤F­n¯à°÷¨Ï¥Î PPP  ¡A§A¥²¶·°t¸m®Ö¤ß¥]§t PPP  ªº¤ä´©¡]¨Ï¥Î PPP »Ý­n pppd ¥H¤Î®Ö¤ßªº PPP ¤ä´©¨âªÌ¡^¡D
\par
\addvspace{\medskipamount}
\nopagebreak\hrule
\begin{verbatim}
  PPP (point-to-point) support (CONFIG_PPP) [n] y
\end{verbatim} 
\nopagebreak\hrule 
\addvspace{\medskipamount}




®Ú¾Ú¦b§A PC ¸Ì­±ªºµwÅé¥H¤Î§A·Q­nªº Linux  §@·~¨t²Î¯S¦â¦^µª¨ä¥¦ªº°t¸m°ÝÃD¡DµM«áÄ~Äò¨Ì·Ó¸Ó¸Ñ»¡ÀÉ¨Ó½sÄ¶¨Ã¦w¸Ë§Aªº·s®Ö¤ß¡D



®Ö¤ß 1.2.13 ¥u­n»s³y¥|­Ó PPP ¸Ë¸m¡D¹ï©ó¦h°ð¥d(multi-port serial cards)¨Ó»¡¡A§A¥²¶·­×§ï®Ö¤ß PPP ªº­ì©lµ{¦¡¥H«K±o¨ì§ó¦h°ðªº¤ä´©¡D
(°Ñ¨£ÀHªþ PPP-2.1.2 ®M¥ó¦Ó¨Óªº README.linux ÀÉ®×»¡©ú§A»Ý­n°µªº²Ó¸`³¡¥÷)¡D



ª`·N: ®Ö¤ß 1.2.13 ªº°t¸m¹ï¸Ü¤£¤¹³\§A¦^ÀY - ¦]¦¹¦pªG§A¦b {\ttfamily make config} ¹ï¸Ü¤¤µª¿ù°ÝÃD¡A¥Î {\ttfamily CTRL-C} ¸õ¥X¨Ó­«·s¶}©l¡D




\subsection{½sÄ¶®Ö¤ß  - Linux 1.3.x ¤Î 2.0.x ®Ö¤ß}

¹ï©ó Linux 2.0.x  ªº®Ö¤ß¡A§A¥i¥H¨Ï¥ÎÃþ¦ü Linux 1.2.13 ªºµ{§Ç¡D
¦A¤@¦¸¡A¨Ì·Ó¦b¸Ñ»¡ÀÉ¸Ìªº»¡©ú¾A·í¦a¦w¸Ë­ì©lµ{¦¡½X¡DµM«á¥H¤U­±ªº«ü¥O¶}©l®Ö¤ßªº°t¸mµ{§Ç
\begin{tscreen}
\begin{verbatim}
make config
\end{verbatim}
\end{tscreen}




µM¦Ó¡A§A¤]¦³¥t¥~ªº¿ï¾Ü
\begin{tscreen}
\begin{verbatim}
make menuconfig
\end{verbatim}
\end{tscreen}




³o´£¨Ñ¤@­Ó¥H¿ï³æ¬°°òÂ¦°t¦X½u¤W»²§Uªº°t¸m¨t²Î¡A¤¹³\§A¦b°t¸mµ{§Ç¤¤ÀH·N©Ò¤§¡D



¤]¦³¤@­Ó¥H X windows  ¬°°òÂ¦ªº°t¸m¬É­±
\begin{tscreen}
\begin{verbatim}
make xconfig
\end{verbatim}
\end{tscreen}




§A¥i¥Hª½±µ½sÄ¶ PPP  ªº¤ä´©¨ì®Ö¤ß¸Ì¥h©ÎªÌ¬O°µ¦¨¥i¸ü¤J¼Ò²Õ¡D

¦pªG§A¥u¦b§A Linux  ¾÷¾¹¹B§@ªº¤@³¡¥÷®É¶¡¸Ì¨Ï¥Î PPP  ªº¸Ü¡A¨º»ò«ØÄ³§A§â PPP  ªº¤ä´©½sÄ¶¬°¥i¸ü¤J¼Ò²Õ¡D
¨Ï¥Î 'kerneld'¡A§Aªº®Ö¤ß±N·|¦b§A¶}©l§Aªº PPP  ³sµ²µ{§Ç®É¦Û°Ê¸ü¤J´£¨Ñ PPP  ¤ä´©©Ò»Ýªº¼Ò²Õ¡D
³o¸`¬Ù¤FÄ_¶Qªº°O¾ÐÅéªÅ¶¡¡]¦]¬°®Ö¤ß¨S¦³¥ô¦ó¤@­Ó³¡¥÷¥i¥H³Q¸m´«¨ì°O¾ÐÅé¥~¡A¦ý¥i¸ü¤J¼Ò²Õ¦b¥¼¨Ï¥Î®É·|¦Û°Ê³Q²¾°£¡^¡D



­n³o¼Ë°µªº¸Ü¡A§A»Ý­n¥´¶}¥i¸ü¤J¼Ò²Õªº¤ä´©:
\par
\addvspace{\medskipamount}
\nopagebreak\hrule
\begin{verbatim}
        Enable loadable module support (CONFIG_MODULES) [Y/n/?] y
\end{verbatim} 
\nopagebreak\hrule 
\addvspace{\medskipamount}


­n¥[¤J PPP  ªº®Ö¤ß¤ä´©¡A¦^µª¤U¦C³o­Ó°ÝÃD:-
\par
\addvspace{\medskipamount}
\nopagebreak\hrule
\begin{verbatim}
        PPP (point-to-point) support (CONFIG_PPP) [M/n/y/?]  
\end{verbatim} 
\nopagebreak\hrule 
\addvspace{\medskipamount}




­n°µ¦¨¥i¸ü¤J¼Ò²Õªº¸Ü¡A¦^µª {\bfseries M} §Y¥i¡A§_«h´N½sÄ¶¦¨®Ö¤ßªº¤@³¡¥÷¡A¦^µª {\bfseries Y} ´N¬O¡D



»P 1.2.13 ªº®Ö¤ß¤£¦Pªº¬O¡A2.0.x ªº®Ö¤ßµø»Ý­n¦Û°Ê«Ø¥ß PPP  ³]³Æ¨Ã¥B¤@ÂI³£¤£»Ý­n¥h¬ã¨s­ì©lµ{¦¡½X¥H¼W¥[¥i¥Îªº PPP  ³]³Æ¡D




\subsection{PPP-2.2 »P {\ttfamily /proc/net/dev} ªºª`·N¨Æ¶µ}

¦pªG§A¦b¨Ï¥Î PPP-2.2¡A§A·|µo²{«Ø¥ß PPP ¸Ë¸mªº¤@­Ó°Æ§@¥Î´N¬O¦pªG§AÆ[¹î {\ttfamily /proc/net} ÀÉ®×¨t²Î¬Ý¤£¨ì PPP ªº¸Ë¸m¡A
ª½¨ì¶}©l¨Ï¥Î pppd ¸Ë¸m¤~·|³Q«Ø¥ß°_¨Ó:-
\par
\addvspace{\medskipamount}
\nopagebreak\hrule
\begin{verbatim}
[hartr@archenland hartr]$ cat /proc/net/dev
Inter-|   Receive                  |  Transmit
 face |packets errs drop fifo frame|packets errs drop fifo colls carrier
    lo:  92792    0    0    0    0    92792    0    0    0     0    0
  eth0: 621737   13   13    0   23   501621    0    0    0  1309    0
\end{verbatim} 
\nopagebreak\hrule 
\addvspace{\medskipamount}




¤@¥¹§A¦³¤@­Ó(©Î§ó¦h) PPP ªA°È±Ò°Ê«á¡A§A·|¬Ý¨ì¹³³o¼Ëªº¶µ¥Ø(±q¤@³¡ PPP ¦øªA¾¹¤W¨ú±o):-
\par
\addvspace{\medskipamount}
\nopagebreak\hrule
\begin{verbatim}
[root@kepler /root]# cat /proc/net/dev
Inter-|   Receive                  |  Transmit
 face |packets errs drop fifo frame|packets errs drop fifo colls carrier
    lo: 428021    0    0    0    0   428021    0    0    0     0    0
  eth0:4788257  648  648  319  650  1423836    0    0    0  4623    5
  ppp0:   2103    3    3    0    0     2017    0    0    0     0    0
  ppp1:  10008    0    0    0    0     8782    0    0    0     0    0
  ppp2:    305    0    0    0    0      297    0    0    0     0    0
  ppp3:   6720    7    7    0    0     7498    0    0    0     0    0
  ppp4: 118231  725  725    0    0   117791    0    0    0     0    0
  ppp5:  38915    5    5    0    0    28309    0    0    0     0    0
\end{verbatim} 
\nopagebreak\hrule 
\addvspace{\medskipamount}





\subsection{°t¸m®Ö¤ßªº¤@¯ë¦Ò¶q}

¦pªG§A­n§â§Aªº Linux PC ³]¬°¤@¥x PPP  ¦øªA¾¹ªº¸Ü¡A¨º»ò§A¥²¶·§â IP forwarding ªº¤ä´©½sÄ¶¶i¥h¡D
¦pªG§A·Q¨Ï¥Î Linux ³s±µ¨â­Ó°Ï°ìºô¸ô©Î±N°Ï°ìºô¸ô³s±µ¨ìºô»Úºô¸ô¤Wªº¸Ü³o­Ó¿ï¶µ¤]¬O»Ý­nªº¡D



¦pªG§A­n³s±µ¤@­Ó°Ï°ìºô¸ô¨ìºô»Úºô¸ô¤W¡]©ÎªÌ¬Æ¦Ü¥u¬O³s±µ¨â­Ó°Ï°ìºô¸ô¡^¡A§AÀ³¸Ó­nÃö¤ß¦w¥þ¤Wªº°ÝÃD¡D¦b®Ö¤ß¤¤¥[¤J IP firewalls ªº¤ä´©¥i¯à¬O¥²¶·ªº!



¦pªG§A·Q­n¥Î IP °°¸Ë³s±µ¨Ï¥Î«e­z¥ô¦ó¤@­Ó¡¥¥¼³s½u¡¦IP  ºô¸ô¸¹½Xªº°Ï°ìºô¸ô¨º»ò§A¤]»Ý­n³o­Ó°t¸m¡D



­n¨Ï¥Î IP °°¸Ë»P IP firewalling¡A§A{\bfseries ¥²¶·}¦b {\ttfamily make config} ¹Lµ{¤¤ªº²Ä¤@­Ó°ÝÃD¤W¦^µª yes:-
\par
\addvspace{\medskipamount}
\nopagebreak\hrule
\begin{verbatim}
Prompt for development and/or incomplete code/drivers (CONFIG_EXPERIMENTAL)?
\end{verbatim} 
\nopagebreak\hrule 
\addvspace{\medskipamount}




ÁöµM³oÅ¥°_¨Ó¹ï·s¨Ï¥ÎªÌ¦³¨Ç§xÃø¡A³\¦h¤H¤´´r§Ö¦a¨Ï¥Î Linux 2.0.X ®Ö¤ßªº IP °°¸Ë»P IP firewalling ¥\¯à¦Ó¨S¦³°ÝÃD¡D



¤@¥¹§A§¹¦¨·s®Ö¤ßªº¦w¸Ë¥H¤Î­«·s±Ò°Ê¤§«á¡A§A´N¥i¥H¶}©l°t¸m¨Ã´ú¸Õ§Aªº PPP ³sµ²¡D




\section{¨ú±o§A©Ò»Ýªº PPP ¦øªA¾¹¸ê°T\label{Server info}}

¦b§A¥i¥H«Ø¥ß¨ì¬Y¥x¦øªA¾¹ªº PPP  ³s½u¤§«e¡A§A»Ý­n¨ú±o¤U¦Cªº¸ê°T¡]±q PPP  ¦øªA¾¹ªº¨t²ÎºÞ²z¡þ¨Ï¥ÎªÌ¤ä´©¤H­û¨ú±o¡^:-
\begin{itemize}
\item ¼·±µªA°Èªº¹q¸Ü¸¹½X\\ 
¦pªG§A¬O¦b¨p¥Î¥æ´«¾÷(PABX)¨t²Î¤U¡A§AÁÙ»Ý­n¼·¥X¥~½u«H¸¹ªº¨p¥Î¥æ´«¾÷¸¹½X ¡Ð ³q±`¬O 0 ©Î 9¡D
\item ¦øªA¾¹¨Ï¥Î°ÊºA©ÎÀRºAªº IP ¸¹½X?\\ 
¦pªG¦øªA¾¹¨Ï¥ÎÀRºAªº IP ¸¹½X¡A¨º»ò§A»Ý­nª¾¹D¦b PPP  ³s½u¤¤§A³oºÝ­n¨Ï¥Î­þ­Ó IP ¸¹½X¡D
¦pªG§Aªº ISP ´£¨Ñ§A¤@¦Xªk IP ¸¹½Xªº¦¸ºô¸ô¡A§A»Ý­nª¾¹D§A¯à¨Ï¥Îªº IP ¸¹½X¤Îºô¸ô¾B¸n¡D\\ 

¤j³¡¤Àªººô»Úºô¸ôªA°È´£¨ÑªÌ³£¨Ï¥Î°ÊºAªº IP ¸¹½X¡D¦p«e­z¡A³o¹ï©ó§A¥i¥H¨Ï¥ÎªºªA°È·|¦³¨Ç­­¨î¡D\\ 

µM¦Ó¡A§Y¨Ï§A¨Ï¥ÎÀRºAªº IP ¸¹½X¡A¤j³¡¥÷ªº PPP ¦øªA¾¹¤]¤£¤¹³\(¬°¤F¦w¥þ²z¥Ñ)«È¤áºÝ¦Û¦æ«ü©w IP ¸¹½X¡A¦]¬°³o¦³¦w¥þ­·ÀI¡D
§A¤´µM{\bfseries ¥²¶·}ª¾¹D³o¨Ç¸ê°T¡D
\item ISP ªº»â°ì¦WºÙ¦øªA¾¹ IP ¸¹½X¬O¤°»ò?\\ 
ÁöµM¥u»Ý­n¤@­Ó¦ý³Ì¤ÖÀ³¸Ó±o­n¦³¨â­Ó¡D\\ 

³o¸Ì¥i¯à·|¦³¤@­Ó°ÝÃD¡D·L³nªº Windows 95 PPP ³]©w¤¹³\Åý DNS ªº¦a§}¦b³s½u¹Lµ{¤¤¶Ç¨ì«È¤áºÝ¡D
¦]¦¹§Aªº ISP (©Î¤½¥qªº¿Ô¸ß«Ç)¥i¯à·|§i¶D§A¤£»Ý­nª¾¹D DNS ¦øªA¾¹ªº IP ¦ì§}¡D\\ 

¹ï©ó Linux ¨Ó»¡¡A§A{\bfseries ¥²¶·}¦Ü¤Öª¾¹D¤@­Ó DNS ªº¦ì§}¡D
¥Ø«e Linux ªº PPP ¹ê§@¤¤¤£¤¹³\¦b³s¥ß³s½u¤§®É°ÊºA¦a«ü©w DNS ªº IP ¸¹½X - «Ü¥i¯à±N¨Ó¤]¤£·|¡D\\ 

{\bfseries ª`·N}: ÁöµM¡ALinux (§@¬° PPP ªº«È¤áºÝ)¤£¯à±q¦øªA¾¹¤¤±µ¨ü DNS ªº¦ì§}¡AµM¦Ó¡A§@¬° PPP ¦øªA¾¹®É¡A
¥¦¥i¥H¥Î pppd ªº¿ï¶µ {\ttfamily dns-addr} ¬°«È¤áºÝ«ü©w³o­Ó¸ê°T¡D
\item ¸Ó¦øªA¾¹¬O§_»Ý­n¨Ï¥Î PAP/CHAP?\\ 
¦pªG¬O³o¼Ë§A»Ý­nª¾¹D§A¥Î¨Ó³s½u "id" ¥H¤Î "secret" ¡D¡]³o¤j·§·|¬O§Aªº¦b³o­Ó ISP ªº¨Ï¥ÎªÌ¦WºÙ¥H¤Î±K½X¡^¡D
\item ¦øªA¾¹·|¦Û°Ê°_°Ê PPP  ©ÎªÌ¦b¤@¥¹§AÃ±¤J¤§«á»Ý­nµo¥X¥ô¦ó«ü¥O¨Ó°_°Ê¦øªAºÝªº PPP?\\ 
¦pªG§A¥²¶·¤U¬Y­Ó«ü¥O¨Ó°_°Ê PPP  ªº¸Ü¡A¥¦¬O¤°»ò?
\item ¦pªG¦øªA¾¹¬O·L³nªº Windows NT ¨t²Î¡A¥¦¬O§_¨Ï¥Î·L³nªº PAP/CHAP ¨t²Î?\\ 
³\¦h¤½¥qªº°Ï°ìºô¸ô¦ü¥G¬O¨Ï¥Î Windows NT ªº¨t²Î¥H¼W¥[¦w¥þ©Ê¡D
\end{itemize}




¥J²Ó¦aª`·N³o¨Ç¸ê°T ¡Ð §A°¨¤W­n¨Ï¥Î¥¦­Ì!




\section{³]©w§Aªº¼Æ¾Ú¾÷¤Î¦ê¦C°ð\label{Modem}}

§AÀ³¸Ó½T»{§Aªº¼Æ¾Ú¾÷³]©w¥¿½T¦Ó¥B§Aª¾¹D¥¦³s±µ¨ì­þ­Ó¦ê¦C°ð¡D



{\bfseries ÂÔ°O}:-
\begin{itemize}
\item DOS com1: = Linux /dev/cua0 (and /dev/ttyS0)
\item DOS com2: = Linux /dev/cua1 (and /dev/ttyS1)\\ 
µ¥µ¥
\end{itemize}




ÁÙ­n´£¿ô§A´N¬O¦pªG§A¦³¥|­Ó¦ê¦C°ð¡A¼Ð·Ç PC ¤WÅý com1 »P com3 ¦@¥Î IRQ4 ¥BÅý com2 »P com4 ¦@¥Î IRQ3¡D



¦pªG§A¦³¨ä¥¦¾÷¸Ë¸m©M¦ê¦C°ð¦@¥Î¤@­Ó IRQ ªº¸Ü¥i¯à·|¦³°ÝÃD¡D
§A¥²¶·½T©w§Aªº¼Æ¾Ú¾÷¦ê¦C°ð¾Ö¦³¥¦¦Û¤v¡A°ß¤@ªº¤@­Ó IRQ¡D³\¦h²{¦bªº¦ê¦C°ð¥d(»P«~½è¸û¨Îªº¥D¾÷ªO¤Wªº¦ê¦C°ð)¤¹³\§A±N¦ê¦C°ð¤Wªº IRQ ²¾¶}¡D



¦pªG§A¦b¥Î Linux 2.0.X ®Ö¤ß¡A§A¥i¥H¥Î {\ttfamily cat /proc/interrupts} ÀË¬d¨Ï¥Î¤¤ªº IRQ¡A§A·|¬Ý¨ì¹³³o¼Ëªº¿é¥Xµ²ªG
\par
\addvspace{\medskipamount}
\nopagebreak\hrule
\begin{verbatim}
 0:    6766283   timer
 1:      91545   keyboard
 2:          0   cascade
 4:     156944 + serial
 7:     101764   WD8013
10:     134365 + BusLogic BT-958
13:          1   math error
15:    3671702 + serial
\end{verbatim} 
\nopagebreak\hrule 
\addvspace{\medskipamount}




³o¸ÌÅã¥Ü¤F¤@­Ó¦ê¦C°ð¦b IRQ4 (¤@­Ó·Æ¹«)»P¤@­Ó¦ê¦C°ð¦b IRQ15¡D
(¤]¦³¤@¦ê¦C°ð¦b com2, IRQ3 »P com4 ¬O¦b IRQ14¡A¦ý¨Ã¥¼¨Ï¥Î¡A¨S¦³Åã¥Ü¥X¨Ó)¡D



½Ð¤p¤ß - ¦pªG§A­n½Õ§Aªº IRQ ªº¸Ü§A­n½T¹êª¾¹D§A¦b°µ¨Ç¤°»ò! §A¤£¥u»Ý­n¥´¶}§Aªº¹q¸£¥~´ß¡A±N¬É­±¥d©Þ¤U¨Ã½Õ¾ã jumper¡A§AÁÙ»Ý­nª¾¹D¨º­Ó¦û¥Î¤°»ò IRQ¡D
¥H§Úªº¨Ò¤l¨Ó»¡¡A³o§¹¥þ¬O¥H SCSI ¬°¥Dªº PC¡A¦]¦¹§Ú±N¥D¾÷ªO¤Wªº³q±`·|¦û¥Î IRQ14 »P 15 ªº IDE ¬É­±Ãö±¼¡D



§AÁÙ»Ý­nª`·N¦pªG§Aªº PC ÁÙ¶]¤F¨ä¥¦ªº§@·~¨t²Î¡A§ó°Ê IRQ ªº¦ì§}¥i¯à¨Ï¨º­Ó§@·~¨t²Î±Ò°Ê¤£¥¿±`¡A©Î®Ú¥»¶}¤£¤F¾÷!



¦pªG¯uªº±N¦ê¦C°ð²¾¨ì¤F«D¼Ð·Çªº IRQ¡A¨º»ò§A»Ý­n§i¶D Linux ¨C¤@­Ó°ð©Ò¥Îªº IRQ ¦ì§}¡D
³o¥i¥H¥Î {\ttfamily setserial} «ü¥O¹F¦¨¡A¦Ó¥B³Ì¦n±N¥¦©ñ¨ì {\ttfamily rc.local}¡A©Î¦b SysV ¨t²Î¤¤¥Ñ {\ttfamily rc.local} ©Ò©I¥sªº {\ttfamily rc.serial} ¸Ì­±¦¨¬°¶}¾÷¹Lµ{ªº¤@³¡¥÷¡D
¥H§Ú¤W­±©Ò¦Cªº¾÷¾¹¨Ó»¡¡A¥Î³o¼Ëªº«ü¥O
\par
\addvspace{\medskipamount}
\nopagebreak\hrule
\begin{verbatim}
/bin/setserial -b /dev/ttyS2 IRQ 11
/bin/setserial -b /dev/ttyS3 IRQ 15
\end{verbatim} 
\nopagebreak\hrule 
\addvspace{\medskipamount}




µM¦Ó¡A¦pªG§A¨Ï¥Î¥Ñ {\ttfamily kerneld} ¦æµ{©Ò­t³dªº°ÊºA¸ü¤J¦ê¦C¼Ò²Õ¡A§A¤£¯à¹³³o¼Ë¨C¦¸¶}¾÷®É³]©w¤@¦¸ IRQ «á´N§â¥¦§Ñ¤F¡D
³o¬O¦]¬°¦pªG¦ê¦C¼Ò²Õ³Q²¾°£¡ALinux ´N·|§Ñ¤F³o¨Ç¯S®íªº³]©w¡D



¦]¦¹¡A¦pªG§A¥H°ÊºA¤è¦¡¸ü¤J¦ê¦C¼Ò²Õ¡A§A¥²¶·­n¦b¨C¤J¸ü¤J¼Ò²Õ®É­«·s³]©w IRQ ¤~¦æ¡D




\subsection{¦ê¦C°ð»P³t«×¬Û®e©Êªºª`·N¨Æ¶µ}

¦pªG§A¨Ï¥Î°ª³t(¥~±µ¦¡)¼Æ¾Ú¾÷(14,400 baud ©Î§ó°ª)¡A§Aªº¦ê¦C°ð³t«×¥²¶·¯à°÷³B²z³oºØ¼Æ¾Ú¾÷©Ò²£¥Íªº¸ê®Æ¶q¡A¯S¦b¬O·í¼Æ¾Ú¾÷¦bÀ£ÁY¸ê®Æ®É¡D



§Aªº¦ê¦C°ð»Ý­n¤@ºØ·s«¬ªº UART (Universal Asynchronous Receiver Transmitter)¡A¹³¬O 16550(A)¡D
¦pªG§A¦b¨Ï¥Î¤@³¡ÂÂªº¾÷¾¹(©ÎÂÂªº¦ê¦C¥d)¡A«Ü¥i¯à¦ê¦C°ð¤W¥u¦³ÂÂªº 8250 UART¡A³o¦b§A¨Ï¥Î°ª³t¼Æ¾Ú¾÷®É¥i¯à·|µo¥Í°ÝÃD¡D



¨Ï¥Î³o­Ó«ü¥O
\begin{tscreen}
\begin{verbatim}
setserial -a /dev/ttySx
\end{verbatim}
\end{tscreen}




Åý Linux ¦^³ø§A¨Ï¥Îªº UART Ãþ«¬¡D¦pªG§A¨S¦³ 16550A «¬ªº UART¡A¥h¶R¤@¶ô·sªº¦ê¦C¥d(¤£¨ì \$50)¡D
·í§A¶R¤@¶ô·s¥d®É¡A½T©w§A¯à½Õ¾ã¤W­±ªº IRQ!



ª`·N: ³Ì¦­ª©¥»ªº 16550 UART ´¹¤ù¤W¦³·å²«¡D³oÂI«Ü§Ö´N³Qµo²{¤F¦Ó¥B¤]µo¦æ¤F·sª©ªº´¹¤ù - 16550A UART¡D
¦ý¤´¦³¤Ö³¡¥÷¦³·å²«ªº´¹¤ù¬y¤J¤F¥«­±¡DÁöµM¤£¤Ó¥i¯à­è¦n´NÅý§A¶R¨ì¡A¦ý§AÁÙ¬OÀ³¸Ó¬Ý¤@¤U´¹¤ùÃþ«¬¬O¤£¬O 16550A¡A¯S§O¬O¦b¤@¨Ç¸û¦­´Áªº¦ê¦C¥d¤W¡D




\subsection{¦ê¦C°ð¦WºÙ}

¥H«e¡ALinux ¥Î {\ttfamily cuaX} ªí¥Ü¼·¥Xªº¦ê¦C°ð¦W¦Ó {\ttfamily ttySx} ªí¥Ü¼·¤Jªº¦WºÙ¡D



¦Û®Ö¤ß 2.0.X ¤§«á³o¼Ëªº­n¨D¤w¸g§ïÅÜ¤F¡A©Ò¥H§AÀ³¸Ó¥i¥H¥Î {\ttfamily ttySx} ¦P®Éªí¥Ü¼·¤J¤Î¼·¥Xªº¦WºÙ¡D
¾Ú§Ú¤F¸Ñ {\ttfamily cuaX} ªº¸Ë¸m¦WºÙ¦b¥¼¨Óª©¥»ªº®Ö¤ß¤¤¥i¯à·|¨ú®ø¡D




\subsection{°t¸m§Aªº¼Æ¾Ú¾÷}

¬°¨Ï¥Î PPP §A±N±o¥¿½T¦a°t¸m§Aªº¼Æ¾Ú¾÷ ¡Ð ­n§¹¦¨³o¥ó¤u§@½Ð¾\Åª§Aªº¼Æ¾Ú¾÷¨Ï¥Î¤â¥U! 
¤j³¡¤Àªº¼Æ¾Ú¾÷³£¦³ PPP  ©Ò»Ý¨Dªºªº{\bfseries ¥X¼t¹w³]¿ï¶µ}¡D
³Ì°ò¥»ªº°t¸m¬O:-
\begin{itemize}
\item µwÅé¬y¶q±±¨î (RTS/CTS) (\&K3 ¦b³\¦h±Ä¥Î Hayes «ü¥O¶°ªº¼Æ¾Ú¾÷)
\end{itemize}


§AÀ³¸Ó­n¬ã¨sªº¨ä¥¦³]©w¡]¨Ï¥Î¼Ð·Ç Hayes «ü¥O¡^¬O:
\begin{itemize}
\item E1 ¶}±Ò«ü¥Oªº¥»¦a¦^À³ (chat ¹B§@©Ò»Ý)
\item Q0 ¦^³ø°õ¦æµ²ªG¥N½X (chat ¹B§@©Ò»Ý)
\item S0=0 Ãö³¬¦Û°Ê¦^À³ (°£«D§A·QÅý§Aªº¼Æ¾Ú¾÷±µÅ¥¹q¸Ü)
\item \&C1 ¥u¦b³s½u¤§«á°»´ú¸üªi
\item \&S0 Data Set Ready (DSR)¥Ã»·³]¬°¶}±Ò
\item (¬Ý±¡ªp)   Data Terminal Ready
\end{itemize}




¦³¤@­Ó¯¸¥x´£¨Ñ§A¤£Â_¼W¥[ªº¼Æ¾Ú¾÷´Ú¦¡ªº³]©w¡A¥i¯à·|¹ï§A¦³©ÒÀ°§U¡A¦b
\nameurl{http://www.in.net/info/modems/index.html}{Modem setup information}¡D



¦b§Aªº¹q¸£»P¼Æ¾Ú¾÷¤§¶¡ªº¼Æ¾Ú¾÷¦ê¦C­±¬É­±¦p¦ó¹B§@¤]­È±o¬ã¨s¤F¸Ñ¡D
¤j³¡¤À²{¥Nªº¼Æ¾Ú¾÷³£¤¹³\§A¥H©T©wªº³t«×¨Ï¥Î¦ê¦C¬É­±¡A§Y¨Ï¹q¸Ü½u¸ô¬É­±¤Á´«¨ì³Ì°ªªº³t«×¥¦¸ò»·ºÝ¼Æ¾Ú¾÷³£¯à°÷³B²z¡D



³oºÙ¬° split speed operation¡D¦pªG§Aªº¼Æ¾Ú¾÷¯à¤ä´©³o¶µ¥\¯à¡A§â¼Æ¾Ú¾÷ªº¦ê¦C¬É­±Âê©w¦b¥¦ªº³Ì°ª³t«×¡]³q±`¬O 115,200 baud ¡A¦ý¹ï 14,400 ¼Æ¾Ú¾÷¨Ó»¡¥i¯à¬O 38,400 baud¡^¡D



¨Ï¥Î§Aªº³q°T³nÅé¡]¨Ò¦p minicom¡^§ä¥XÃö©ó§A¼Æ¾Ú¾÷ªº°t¸m¸ê°T¨Ã¥B³]¬° PPP  ©Ò»Ýªº³]©w¡D
³\¦h¼Æ¾Ú¾÷·|¦b AT\&V «ü¥Oªº¦^À³¤¤¦^³ø¥¦­Ì¥Ø«eªº³]©wª¬ªp¡A¦ý¬O§AÀ³¸Ó¬d¬Ý¤@¤U§Aªº¼Æ¾Ú¾÷¨Ï¥Î¤â¥U¡D

¦pªG§A§â³]©w¥þ³£§Ë¶Ã¤F¡A¨º»ò§A¥i¥HÂÇ¥Ñµo¥X AT\&F «ü¥O¦^¨ìÃ­©wª¬ºA¡]³q±`¥i¥H¡^ ¡Ð ¦^¨ì¥X¼t³]©w¡D
¡]¦b§Ú¹J¹Lªº¤j³¡¤À²{¥N¼Æ¾Ú¾÷¤¤¡A¥X¼tªº³]©w¥]§t©Ò¦³¨Ï¥Î PPP ©Ò»Ýªº³]©w ¡Ð ¦ý¬O§AÀ³¸Ó°µ­ÓÀË¬d¡^¡D



¤@¥¹§A§ä¥X¤F¥²­nªº³]©w¦r¦ê´N§â¥¦¼g¤U¨Ó¡DµM«á§A¥²¶·°µ­Ó¨M©w: §A¥i¥H±N³o¨Ç³]©w­È¦s¦b¼Æ¾Ú¾÷¤Wªº«D´§µo©Ê°O¾ÐÅé¤¤³o¼Ë¥i¥H¥Î¾A·íªº AT «ü¥O´N¥i¥s¥X¡D
¥t¤@­Ó°µªk¬O±N³o¨Ç¥¿½Tªº³]©w¦b PPP ªº¼·¸¹¹Lµ{¤¤¶Ç¤J¡D

¦pªG§A¥u±q Linux ¤U¨Ï¥Î¼Æ¾Ú¾÷³s±µ¨ì ISP ¦øªA¾¹¡A³ÌÂ²³æªº°µªk´N¬O±N³o¨Ç³]©w­È¦s¤J¼Æ¾Ú¾÷¤Wªº«D´§µo©Ê°O¾ÐÅé(non-volatile RAM)¡D

¥t¤@¤è­±¡A¦pªG§A­nÁÙ¦b¨ä¥¦ªºÀ³¥Îµ{¦¡©Î§@·~¨t²Î¤W¨Ï¥Î¼Æ¾Ú¾÷¡A³Ì«OÀIªº°µªk¬O¦b¨C¦¸¼·¸¹®É¤~±N³o¨Ç¸ê°T¶Ç¤J¡A
¦p¦¹¥i¥H½T«O¦b¨C¦¸¼·¸¹®É¼Æ¾Ú¾÷Á`¬O¦b¥¿½Tªºª¬ºA¡D(°O¤U³o¨Ç³]©w¦r¦êÁÙ¦³­Ó¦n³B´N¬O¦b¼Æ¾Ú¾÷¿ò¥¢¤F°O¾ÐÅéªº¤º®e®É¡A³o½T¹ê¥i¯àµo¥Í)¡D




\subsection{¦ê¦C¬y¶q±±¨îª`·N¨Æ¶µ}

·í¸ê®Æ¦b¦ê¦C³q°T½u¸ô¤W¬y°Êªº®É­Ô¡A¥i¯à·|µo¥Í¸ê®Æ¨ì¹Fªº¤ñ¹q¸£¯à³B²zªºÁÙ­n§Ö³oºØ±¡ªp¡]¹q¸£¥i¯à¦£µÛ°µ¨ä¥¦ªº¨Æ ¡Ð °O±o¡ALinux ¬O¤@­Ó¦h¨Ï¥ÎªÌ¡A¦h¤uªº§@·~¨t²Î¡^¡D
¬°¤F½T«O¸ê®Æ¤£·|º|¥¢¡]¦b½w½Ä°Ï¤¤ªº¸ê®Æ¤£·|¶W¸ü¦Ó¦]¦¹º|¥¢±¼¡^¡A»Ý­n¬Y¨Ç±±¨î¸ê®Æ¬y¶qªº¤èªk¡D



¦³¨âºØ¤èªk¥i¥H¦b¦ê¦C½u¸ô¤W¹F¦¨³o­Ó¥Øªº:-
\begin{itemize}
\item ¨Ï¥ÎµwÅé«H¸¹(Clear To Send/Request to Send - CTS/RTS)
\item ¨Ï¥Î³nÅé«H¸¹(control S and control Q, also known as XON/XOFF).
\end{itemize}




ÁöµM«áªÌ¥Î¦b²×ºÝ¾÷¡]¤å¦r¡^³sµ²¤W¥i¯à«Ü¦n¡A¦ý¬O¦b PPP  ¤Wªº¸ê®Æ¨Ï¥Î¾ã­Ó 8 bits ½s½XªÅ¶¡ ¡Ð ¦Ó¥B¦b¸ê®Æ¤¤ªº¬Y­Ó¦a¤è¬Û·í¥i¯à¦s¦b·|³QÂà¦¨ control S  ¥H¤Î control Q  ªº¦ì¤¸²Õ¡D
©Ò¥H¡A¦pªG¼Æ¾Ú¾÷³]¦¨¨Ï¥Î³nÅé¬y¶q±±¨îªº¸Ü¡A¨º»ò¶Ç¿é«Ü®e©ö³QÂZ¶Ã!

¹ï©ó¨Ï¥Î PPP ªº°ª³t³sµ²¡]¨Ï¥Î 8 bits ¸ê®Æ½s½X¡^¨Ó»¡µwÅé¬y¶q±±¨î¬O«Ü­«­nªº¡A¦]¦¹§A¥²¶·¨Ï¥ÎµwÅé¬y¶q±±¨î¡D




\subsection{´ú¸Õ§Aªº¼Æ¾Ú¾÷ªº¼·¥X¥\¯à}

¦b§A§¹¦¨¤F¦ê¦C°ð»P¼Æ¾Ú¾÷ªº³]©w¤§®É¸ÕµÛ¼·¨ì§Aªº ISP ¤W¬Ý¬Ý¯à§_³s¤W¥H½T©w³]©w¬O§_¦³»~¡D



¨Ï¥Î§Aªº²×ºÝ¾÷³q°T³nÅé¡]¹³¬O minicom¡^¡A¼·¨ì§A·Q¨Ï¥Î PPP  ³s½uªº¨º¥x PPP  ¦øªA¾¹¡D



¡]ª`·N: ¦b³o­Ó¶¥¬q§Ú­Ì¨Ã¤£¹Á¸Õ«Ø¥ß PPP  ³s½u ¡Ð ¥u¬O­nÃÒ¹ê§Ú­Ì¾Ö¦³¥¿½Tªº¹q¸Ü¸¹½X¥H¤Î¬°¤FÃ±¤J¨Ã¥B°_°Ê PPP  ¦Ó{\bfseries ½T¹ê¦a}§ä¥X¦øªA¾¹¨s³º¶Ç°eµ¹§Ú­Ì¤°»ò°T®§¡^¡D



¦b³o­Ó¹Lµ{¤¤¡A¥i¥HºI¨ú¡]°O¿ý¨ì¤@­ÓÀÉ®×¸Ì¡^¾ã­ÓÃ±¤Jªº¹Lµ{©ÎªÌ¬O¤p¤ß¦a¡]«D±`¤p¤ß¦a¡^½T¹ê¼g¤U»·ºÝ¦øªA¾¹©Òµ¹§A´£¥Ü¿é¤J§Aªº¨Ï¥ÎªÌ¦WºÙ¥H¤Î±K½Xªº°T®§¡]¥H¤Î¥ô¦ó«Ø¥ß PPP  ³s½u»Ý­n¤U¹Fªº«ü¥O¡^¡D



¦pªG§Aªº¦øªA¾¹¨Ï¥Î PAP¡A§A¥i¯à¤£·|¬Ý¨£Ã±¤Jªº´£¥Ü²Å¸¹¡A¦Ó¬O(¥H¤å¦rªí¥Üªº)³sµ²³q°T¨ó©w(¬Ý°_¨Ó¹³¬O©U§£)¥X²{¦b§Aªº¿Ã¹õ¤W¡D



¤@¨ÇÄµ§i:-

\begin{itemize}
\item ¬Y¨Ç¦øªA¾¹¬Û·íÁo©ú: §A¥i¥H¥Î¤å¦r¼Ò¦¡ªº¨Ï¥ÎªÌ¦WºÙ/±K½X¤è¦¡©Î¨Ï¥Î PAP Ã±¤J¡D
¦]¦¹¦pªG§Aªº ISP ©Î¤½¥q¯¸¥x¨Ï¥Î PAP ¦ý§A¨S¦³¥ß¨è¦b¿Ã¹õ¤W¬Ý¨ì©U§£¡A¤]¨Ã¤£ªí¥Ü§A°µ¿ù¤F¡D
\item ¬Y¨Ç¯¸¥x­n¨D§A¥ý¿é¤J¤@¨Ç°_©lªº¤å¦r{\itshape µM«á\/}¤~±Ò°Ê¼Ð·Çªº PAP µ{§Ç¡D
\item ¬Y¨Ç PPP ¦øªA¾¹¬O³Q°Êªº - ¥¦­Ì´N§¤¦b¨º¸Ìµ¥«Ý¦Ó¤£°e¥X¥ô¦ó¸ê®Æ¡Aª½¨ì«È¤áºÝ¼·¤J¨Ã°e¥X¦Xªkªº³sµ²±±¨î¨ó©w¡D
¦pªG§A­n³s±µªº PPP ¦øªA¾¹¬O³Q°Ê¼Ò¦¡ªº¡A§A±N¤£·|¬Ý¨ì¥ô¦ó©U§£!
\item ¬Y¨Ç¦øªA¾¹¦b§A«ö¤U {\ttfamily ENTER} «e¤£·|±Ò°Ê PPP - ¦]¦¹¦pªG§A¥¿½TÃ±¤J¦ý¥¼¬Ý¨ì©U§£ªº¸Ü¥i¥H¸Õ¸Õ!
\end{itemize}




³o³Ì¤Ö­È±o¼·±µ¨â¦¸ ¡Ð ¬Y¨Ç¦øªA¾¹·|¦b¨C¦¸§AÃ±¤J®É§ïÅÜ´£¥Ü¡]¨Ò¦p¨Ì®É¶¡§ïÅÜ!¡^¡D
§Aªº Linux ¾÷¾¹¦b¨C¦¸§A¼·¤Jªº®É­Ô­n¯à°÷¿ë»{ªº¨â­Ó¥D­nªº´£¥Ü¬O:-
\begin{itemize}
\item ­n¨D§A¿é¤J¨Ï¥ÎªÌ¦WºÙªº´£¥Ü;
\item ­n¨D§A¿é¤J±K½Xªº´£¥Ü;
\end{itemize}




¦pªG§A¥²¶·µo¥X¬Y­Ó«ü¥O¨Ó°_°Ê¦øªAºÝªº PPP¡A¨º»ò§A¤]»Ý­n§ä¥X¤@¥¹§AÃ±¤J¤§«á¦øªA¾¹©Òµ¹§A¿é¤J«ü¥O¥H±Ò°Ê PPP ªº´£¥Ü¡D



¦pªG§Aªº¦øªA¾¹¦Û°Ê°_°Ê PPP  ªº¸Ü¡A¤@¥¹§AÃ±¤J§¹¦¨¡A§A±N¶}©l¨£¨ì¿Ã¹õ¤W¥X²{©U§£ ¡Ð ³o¬O PPP  ¦øªAºÝ¶Ç°eµ¹§Aªº¾÷¾¹¥H°_°Ê¨Ã¥B°t¸m PPP ³s½uªº¸ê°T¡D



³o¬Ý°_¨ÓÀ³¸Ó·|¬O¹³³o¼ËªºªF¦è:-
\par
\addvspace{\medskipamount}
\nopagebreak\hrule
\begin{verbatim}
~y}#.!}!}!} }8}!}$}%U}"}&} } } } }%}& ...}'}"}(}"} .~~y}
\end{verbatim} 
\nopagebreak\hrule 
\addvspace{\medskipamount}




(¦Ó¥B¥¦ÁÙ·|¤@ª½¶i¨Ó! )



¦b¬Y¨Ç¨t²Î¤¤ PPP  ¥²¶·¦b¦øªAºÝ¤W©ú½T¦a¥[¥H°_°Ê¡D³o³q±`¬O¦]¬°¸Ó¦øªA¾¹³Q³]©w¦¨¤¹³\¨Ï¥Î¬Û¦P¨Ï¥ÎªÌ¦WºÙ¡þ±K½X°t¹ï¨Ó°µ PPP  Ã±¤J¤Î¤@¯ë¨Ï¥Î¬É­±(shell) ªºÃ±¤J¡D
¦pªG¬O³o¼Ë¡A¤@¥¹§AÃ±¤J´Nµo¥X¸Ó«ü¥O¡D¦A¤@¦¸¡A§A±N·|¨£¨ì PPP  ³s½u¦øªAºÝ°_°Êªº©U§£¸ê°T ¡Ð ©Ò¥H²{¦b§A¥i¥H±¾Â_¤F¡D



¦pªG§A¨S¦³¦b³s¤W®É¥ß§Y¦b¿Ã¹õ¤W¬Ý¨ì³o¨Ç©U§£(¦pªG¥²­nªº¸Ü¥ýÃ±¤J¨Ã±Ò°Ê PPP ¦øªA¾¹)¡A
«ö¤U {\bfseries Enter} ¸Õ¸Õ¯à§_±Ò°Ê PPP ¦øªA¾¹...



³o­Ó®É­Ô¡A§A´N¥i¥H±¾Â_§Aªº¼Æ¾Ú¾÷¡]³q±`¬O¡A§Ö³t¦aÁä¤J {\ttfamily +++} ¤@¥¹§Aªº¼Æ¾Ú¾÷¦^À³ OK µM«á±µµÛ¤U ATHO «ü¥O¡^¡D



¦pªG§A¤£¯à¨Ï§Aªº¼Æ¾Ú¾÷¹B§@ªº¸Ü¡A¾\Åª§Aªº¼Æ¾Ú¾÷¨Ï¥Î¤â¥U¡A§A³q°T³nÅéªº½u¤W¨Ï¥Î¤â¥U¥H¤Î Serial HOWTO!  
¤@¥¹§A¸Ñ¨M¸Ó°ÝÃD¡AÄ~Äò¶i¦æ«e­±©Ò»¡ªº¡D




\section{«Ø¥ß¦WºÙ¨ì¦ì§}¸ÑªR(DNS)\label{DNS}}

ÁöµM§Ú­Ì¤HÃþ³ßÅwµ¹¨Æª«¨ú­Ó¦WºÙ¡A¹q¸£³ßÅw¼Æ¦r¡D
¦b TCP/IP ºô¸ô¤W¡]³o¤]´N¬Oºô»Úºô¸ô¡^¡A§Ú­ÌÂÇ¥Ñ¯S©wªº¦WºÙ©I¥s¬Y¥x¾÷¾¹¡A¦Ó¥B¨C¥x¾÷¾¹³£¦s¦b©ó¤@­Ó¯S©wªº»â°ì¼Ð°O¸Ì­±¡D
Á|¨Ò¦Ó¨¥¡A§Úªº Linux ¤u§@¯¸ºÙ¬° {\bfseries archenland} ¦Ó¥¦¬O¦s¦b©ó {\bfseries interweft.com.au} ³o­Ó»â°ì¸Ì¡D
©Ò¥H¥¦¦b¤H­Ì¤ß¥Ø¤¤ªº¦ì§}´N¬O {\bfseries archenland.hedland.edu.au}¡D
(ºÙ¬° FQDN - fully qualified domain name¡D)

µM¦Ó¡A¬°¤F¨Ïºô»Úºô¸ô¤Wªº¨ä¥¦¹q¸£§äªº¨ì³o¥x¾÷¾¹¡A¨Æ¹ê¤W¹q¸£¦bºô»Úºô¸ô¤W·¾³q®É¥¦¬OÂÇ¥Ñ¨ä IP ¸¹½X¨Ó»{ª¾ªº¡D

§â¾÷¾¹¡]¥H¤Î»â°ì¡^ªº¦WºÙÂàÄ¶¡]¸ÑªR¡^¦¨¬°¦bºô»Úºô¸ô¤W©Ò¹ê»Ú¨Ï¥Îªº IP ¸¹½X¬O´£¨Ñ»â°ì¦WºÙªA°È¤§¾÷¾¹ªº¤u§@¡D

¥¦¬O³o¼Ë¤l¹B§@ªº:-
\begin{itemize}
\item §Aªº¾÷¾¹»Ý­nª¾¹D¬Y³¡¯S©w¹q¸£ªº IP ¦ì§}¡D»Ý­n³o¶µ¸ê°TªºÀ³¥Îµ{¦¡¦V§Aªº Linux PC ¤Wªº'¦WºÙ¸ÑªR¾¹'¸ß°Ý¦¹¸ê°T;
\item ¦WºÙ¸ÑªR¾¹¬d¸ß¾÷¾¹¤º³¡ªº¥D¾÷¦WºÙÀÉ®×(¥i¯à¬O {\ttfamily /etc/hosts} ¥H¤Î/©Î¬Oª¾¹D³o¶µ¸ê°Tªº»â°ì¦WºÙ¦øªA¾¹¡A¦Ó¦WºÙ¸ÑªR¾¹¹ê»Úªº¦æ¬°¥Ñ {\ttfamily /etc/host.conf} ÀÉ®×¨M©w);
\item ¦pªGµª®×¦b¥D¾÷¦WºÙÀÉ®×¤¤¡A´N¥H¦¹µª®×¦^µª;
\item ¦pªG¬O¦b«ü©wªº»â°ì¦WºÙ¦øªA¾¹¤¤¡A§Aªº PC ´N¦V¸Ó¾÷¾¹¸ß°Ý;
\item ¦pªG³o³¡»â°ì¦WºÙ¦øªA¾¹¤w¸gª¾¹D³Q¸ß°Ý¦WºÙªº IP ¸¹½X¡A´N¥H¦¹¦^µª¡D§_«h¡A¥¦·|³z¹Lºô»Úºô¸ô¦V¨ä¥¦ªº¦WºÙ¦øªA¾¹§ä´M¸ê°T¡D
³Ì«á³o³¡¦WºÙ¦øªA¾¹·|±N¸ê°T¶Ç¦^µ¹­ì¨Ó¸ß°Ýªº¦WºÙ¸ÑªR¾¹¡AµM«á¶Çµ¹­n¨D¦¹¸ê°TªºÀ³¥Îµ{¦¡¡D
\end{itemize}




·í§A³Ð³y¥X PPP  ³s½u®É¡A§A»Ý­n§i¶D§Aªº Linux  ¾÷¾¹¥¦¥i¥H¦b­þ¸Ì§ä¨ì¥D¾÷¦WºÙ¹ï·Ó¨ì IP ¸¹½X¡]¦ì§}¸ÑªR¡^ªº¸ê°T¡A¦p¦¹{\bfseries §A}´N¥i¥H¨Ï¥Î¾÷¾¹ªº¦WºÙ¦Ó{\bfseries §Aªº¹q¸£}¥i¥H§â³o¨Ç¦WºÙÂàÄ¶¦¨¥¦¹B§@©Ò»Ýªº IP ¸¹½X¡D



¤@­Ó¤èªk¬O¿é¤J©Ò¦³§A·QÁpµ¸ªº¥D¾÷¨ì {\ttfamily /etc/hosts} ÀÉ®×¸Ì¡]¦pªG§A¬O³s¤Wºô»Úºô¸ôªº¸Ü³o¯uªº¬O§¹¥þ¤£¥i¯àªº¨Æ¡^¡F
¥t¤@­Ó¤èªk¬O¨Ï¥Î¬Û¹ï©ó¾÷¾¹¦WºÙªº IP ¸¹½X¡]­n°O±o¥þ³¡ªº IP ¦ì§}¬O¤£¥i¯àªº°£«D¦b³Ì¤pªº°Ï°ìºô¸ô¤W¡^¡D



³Ì¦nªº¤èªk¬O³]©w§Aªº Linux  ¨Ï¥¦ª¾¹D¸Ó¨ì­þ¨ú±o³o¶µ¦WºÙ¨ì¸¹½Xªº¸ê°T ¡Ð ¦Û°Ê¦a¡D
³o¶µªA°È¬O¥Ñ»â°ì¦WºÙ¦øªA¾¹¨t²Î©Ò´£¨Ñ¡D»Ý­n°µªº¥þ³¡¤u§@¬O§â IP ¸¹½X¿é¤J¨ì§Aªº {\ttfamily /etc/resov.conf} ÀÉ®×¸Ì¡D




\subsection{{\ttfamily /etc/resolv.conf} ÀÉ®×}

§Aªº PPP  ¦øªA¾¹¨t²ÎºÞ²z¡þ¨Ï¥ÎªÌ¤ä´©¤H­ûÀ³¸Ó­n´£¨Ñµ¹§A¨â­Ó DNS ªº IP ¸¹½X¡]¥u»Ý­n¤@­Ó ¡Ð ¦ý¬O¨â­Ó¦b¥X°ÝÃD®É¥i¥H¦h¨ÇÀ°§U¡^¡D

¦p«e©Ò­z¡ALinux ¤£¯à¥H¹³ MS Windows 95 ¤@¼Ëªº¤è¦¡¨Ó³]©w¥¦ªº¦WºÙ¦øªA¾¹ªº IP ¸¹½X¡D
©Ò¥H§A¥²¶·(¦³Â§»ª¦a){\bfseries °í«ù}§Aªº ISP ´£¨Ñ§A³o¶µ¸ê°T!

§Aªº {\ttfamily /etc/resolv.conf} ¬Ý°_¨ÓÀ³¸Ó·|¹³³o¼Ë:
\par
\addvspace{\medskipamount}
\nopagebreak\hrule
\begin{verbatim}
domain your.isp.domain.name
nameserver 10.25.0.1
nameserver 10.25.1.2
\end{verbatim} 
\nopagebreak\hrule 
\addvspace{\medskipamount}




½s¿è³o­ÓÀÉ®×¡]¦pªG¨S¦³ªº¸Ü´N«Ø¤@­Ó·sªº¡^¥H§e²{§Aªº ISP  ´£¨Ñªº¸ê°T¡D¥¦ªº¾Ö¦³ªÌ¥H¤ÎÅv­­À³¸Ó¹³¤U­±³o¼Ë:-
\begin{tscreen}
\begin{verbatim}
-rw-r--r--   1 root     root           73 Feb 19 01:46 /etc/resolv.conf
\end{verbatim}
\end{tscreen}




¦pªG§A¦]¬°¥»¨Ó´N¦b°Ï°ìºô¸ô¤W©Ò¥H¤w¸g³]¥ß {\ttfamily /etc/resolv.conf} ÀÉ®×ªº¸Ü¡A¥u­nÂ²³æªº§â PPP ³s½uªº DNS ¦øªA¾¹ IP ¸¹½X¥[¨ì§A¤w¦³ªºÀÉ®×¸Ì§Y¥i¡D




\subsection{{\ttfamily /etc/host.conf} ÀÉ®×}

§A¤]À³¸ÓÀË¬d§Aªº {\ttfamily /etc/host.conf} ÀÉ®×¬O§_³]©w¥¿½T¡D¥¦¬Ý°_¨ÓÀ³¸Ó¹³³o¼Ë
\par
\addvspace{\medskipamount}
\nopagebreak\hrule
\begin{verbatim}
order hosts,bind
multi on
\end{verbatim} 
\nopagebreak\hrule 
\addvspace{\medskipamount}




¥¦§i¶D§Aªº¦WºÙ¸ÑªR¾¹¦b¦V¦WºÙ¦øªA¾¹¸ß°Ý¤§«e¥ý¨Ï¥Î¥D¾÷¦WºÙÀÉ®×¤¤ªº¸ê°T¡D




\section{¨Ï¥Î PPP »P root Åv­­\label{root}}

¦]¬° PPP »Ý­n³]©wºô¸ô³]³Æ¡AÅÜ§ó®Ö¤ß»¼°eªí®æ¥H¤Î½Ñ¦p¦¹Ãþªº°Ê§@¡A©Ò¥H¥¦»Ý­n¥H root ªºÅv­­¨Ó°µ³o¨Ç¨Æ¡D



¦pªG root ¥H¥~ªº¨Ï¥ÎªÌ­n¯à«Ø¥ß PPP  ³s½u¡A¨º»ò pppd µ{¦¡À³¸Ó³]¬°¥H root ªº¨­¤À°õ¦æ(setuid):-
\begin{tscreen}
\begin{verbatim}
-rwsr-xr-x   1 root     root        95225 Jul 11 00:27 /usr/sbin/pppd
\end{verbatim}
\end{tscreen}




¦pªG {\ttfamily /usr/sbin/ppd} ¤£¬O³]©w¬°³o¼Ë¡A¨º»ò¥H {\bfseries root} ªº¨­¤À¤U³o­Ó«ü¥O:

\begin{tscreen}
\begin{verbatim}
chmod u+s /usr/sbin/pppd
\end{verbatim}
\end{tscreen}




³o¼Ë¬OÅý pppd ¥H root ªºÅv­­°õ¦æ¡A§Y¨Ï¬O¥Ñ¤@¯ë¨Ï¥ÎªÌ©Ò°õ¦æªº¡D
³o¯àÅý¤@¯ë¨Ï¥ÎªÌ°õ¦æªº pppd ¨ã¦³¥²­nªºÅv­­«Ø¥ßºô¸ô¬É­±¤Î®Ö¤ß»¼°eªí®æ¡D



¥H root ªº¨­¤À°õ¦æªºµ{¦¡¦b¦w¥þ¤W¬O¼ç¦bªºº|¬}¡A©Ò¥H§A¹ï©ó³]©w¬° 'setuid' ªºµ{¦¡¥²¶·«D±`¦a¤p¤ß¡D
³\¦h¦aµ{¦¡(¥]¬A pppd)¤w¸g³Q¤p¤ß¦a¼¶¼g¥H±N¥Î root ªº¨­¤À°õ¦æªº¦MÀI­°¨ì³Ì§C¡A©Ò¥H³o¼Ë°µÀ³¸Ó¬O¦w¥þ¦a(¤£¹L¤£«OÃÒ)¡D



®Ú¾Ú§A§Æ±æ§Aªº¨t²Î¦p¦ó¹B§@¦Ó©w¡A¯S§O¬O¦pªG§A§Æ±æ§A¨t²Î¸Ìªº¥ô¦ó¨Ï¥ÎªÌ³£¯à±Ò©l PPP ³sµ²¡A§AÀ³¸Ó§â§Aªº ppp-on/off «ü¥O½Z³]©w¬°¥þ³¡ªº¤H³£¥i¥HÅª¨ú¡þ°õ¦æ¡D¡]¦pªG§Aªº PC ¥u¥Ñ§A¨Ï¥Î¨º»ò³o¼Ë¤j·§¤£¿ù¡^¡D



µM¦Ó¡A¦pªG§A¤£§Æ±æ¥ô¦ó¤H³£¯à°_©l PPP  ³s½u¡]¨Ò¦p¡A§Aªº«Ä¤l¦b§Aªº Linux PC ¤W¦³±b¸¹¦Ó§A¤£§Æ±æ¥L­Ì¦b¨S¦³§AªººÊ·þ¤U³s¤Wºô»Úºô¸ô¡^¡A§A±N±o«Ø¥ß¤@­Ó PPP ¸s²Õ¡]½s¿è {\ttfamily /etc/group} ÀÉ®×¡^¨Ã¥B:
\begin{itemize}
\item ±N pppd ³]©w¬°¥H root ªºÅv­­°õ¦æ¡A¾Ö¦³ªÌ¬O root ¦Ó¸s²Õ¬O PPP¡A¦Ó¨ä¥¦ªºÅv­­³£Ãö³¬¡D¥¦¬Ý°_¨ÓÀ³¸Ó¹³³o¼Ë
\begin{tscreen}
\begin{verbatim}
-rwsr-x---   1 root     PPP        95225 Jul 11 00:27 /usr/sbin/pppd
\end{verbatim}
\end{tscreen}

 
\item ¨Ï ppp-on/off «ü¥O½Z¥Ñ¨Ï¥ÎªÌ root ¥H¤Î¸s²Õ PPP  ©Ò¾Ö¦³
\item ¨Ï ppp-of/off «ü¥O½Z¯à¥Ñ¸s²Õ PPP Åª¨ú¡þ°õ¦æ
\begin{tscreen}
\begin{verbatim}
  -rwxr-x---   1 root     PPP           587 Mar 14  1995 /usr/sbin/ppp-on
  -rwxr-x---   1 root     PPP           631 Mar 14  1995 /usr/sbin/ppp-off
\end{verbatim}
\end{tscreen}

\item Ãö³¬¨ä¥¦ªº¦s¨úÅv­­
\item §â¯à°÷°_°Ê PPP  ªº¨Ï¥ÎªÌ¥[¤J /etc/group ÀÉ®×ªº PPP ¸s²Õ¸Ì
\end{itemize}




§Y¨Ï¦p¦¹¡A¤@¯ë¨Ï¥ÎªÌ¤´µMµLªk¥H³nÅéªº¤è¦¡¤¤¤î³sµ²¡D
°õ¦æ {\ttfamily ppp-off} «ü¥O½Z»Ý­n root ªºÅv­­¡DµM¦ó¡A¥ô¦ó¨Ï¥ÎªÌ³£¥i¥HÃö±¼¼Æ¾Ú¾÷(©Î±N¹q¸Ü½u¥Ñ¤º±µ¦¡¼Æ¾Ú¾÷©Þ¤U)¡D



¥t¥~¤@ºØ(§ó¦nªº)¿ìªk¡A¤¹³\¨Ï¥ÎªÌ¨Ï¥Î {\ttfamily sudo} ¨Ó°_°Ê ppp ³sµ²¡D
³o¼Ë¥i¥H´£¨Ñ§ó¨Îªº¦w¥þ©Ê¨Ã¥B¥i¥HÅý§A³]©wÅý¥ô¦ó(¥i«H¥ôªº)¨Ï¥ÎªÌ¨Ï¥Î«ü¥O½Z¨Ó±Ò°Ê/µ²§ô³sµ²¡D
¨Ï¥Î {\ttfamily sudo} ¥i¥HÅý¤@¦ì¥i«H¥ôªº¨Ï¥ÎªÌ°®²b¦Ó¦w¥þ¦a±Ò°Ê/µ²§ô PPP ³sµ²¡D




\section{³]©w PPP ³s±µÀÉ®×\label{options}}

§A¥²¶·¥H {\bfseries root} ¨­¥÷Ã±¤J¨Ó«Ø¥ß³o¨Ç¥Ø¿ý¨Ã¥B½s¿è³o¨Ç³]¥ß PPP ³s½u©Ò»ÝªºÀÉ®×¡A§Y¨Ï§A·QÅý©Ò¦³ªº¨Ï¥ÎªÌ³£¯à¨Ï¥Î PPP¡D



PPP ¨Ï¥Î´X­ÓÀÉ®×¨Ó«Ø¥ß¨Ã³]©w PPP ³sµ²¡D³o¨ÇÀÉ®×¦b PPP 2.1.2 »P 2.2 ¤¤ªº¦WºÙ»P¦ì¸m³£¤£¦P¡D



¦b PPP 2.1.2 ¤¤³o¨ÇÀÉ®×¬O:-
\par
\addvspace{\medskipamount}
\nopagebreak\hrule
\begin{verbatim}
/usr/sbin/pppd               # PPP °õ¦æÀÉ
/usr/sbin/ppp-on             # ¼·¸¹/³s½u«ü¥O½Z
/usr/sbin/ppp-off            # Â_½u«ü¥O½Z
/etc/ppp/options             # ©Ò¦³³s½u©Ò¨Ï¥Îªº¿ï¶µ
/etc/ppp/options.ttyXX   # µ¹¬Y¤@¯S©w³q°T°ð¨Ï¥Îªº¿ï¶µ
\end{verbatim} 
\nopagebreak\hrule 
\addvspace{\medskipamount}




¦b PPP 2.2 ¤¤³o¨ÇÀÉ®×¬O:-
\par
\addvspace{\medskipamount}
\nopagebreak\hrule
\begin{verbatim}
/usr/sbin/pppd                  # PPP °õ¦æÀÉ
/etc/ppp/scripts/ppp-on         # ¼·¸¹/³s½u«ü¥O½Z
/etc/ppp/scripts/ppp-on-dialer  # ¼·¸¹ªº chat «ü¥O½Z³¡¥÷
/etc/ppp/scripts/ppp-off        # Â_½u«ü¥O½Z
/etc/ppp/options                # ©Ò¦³³s½u©Ò¨Ï¥Îªº¿ï¶µ
/etc/ppp/options.ttyXX          # µ¹¬Y¤@¯S©w³q°T°ð¨Ï¥Îªº¿ï¶µ
\end{verbatim} 
\nopagebreak\hrule 
\addvspace{\medskipamount}






Red Hat Linux ªº¨Ï¥ÎªÌÀ³ª`·N¼Ð·Çªº Red Hat 4.X ¦w¸Ë±N³o¨Ç«ü¥O½Z©ñ¦b {\ttfamily /usr/doc/ppp-2.2.0f-2/scripts}¡D



¦b§Aªº {\ttfamily /etc} ¥Ø¿ý¸ÌÀ³¸Ó­n¦³­Ó¥Ø¿ý:
\begin{tscreen}
\begin{verbatim}
drwxrwxr-x   2 root     root         1024 Oct  9 11:01 ppp
\end{verbatim}
\end{tscreen}




¦pªG¥¦¤£¦s¦bªº¸Ü ¡Ð ¥H³o¼ËªºÅv­­«Ø¥ß¥¦¡D



¦pªG³o­Ó¥Ø¿ý¤w¸g¦s¦b¡A¥¦À³¸Ó·|¥]§t¤@­ÓºÙ¬° {\bfseries options.tpl} ªº¿ï¶µÀÉ®×¼ËªO¡D³o­ÓÀÉ®×¥]¬A¦b¤U­±¡D



¦]¬°¥¦¥]§t©Ò¦³ PPP ¿ï¶µªº¸ÑÄÀ©Ò¥H½Ð§A§â¥¦¦L¥X¨Ó¡]°t¦X pppd ªº½u¤W¨Ï¥Î¤â¥U¨Ó¾\Åª±N·|¬O«Ü¦³¥Îªº¡^¡D
ÁöµM§A¥i¥H¨Ï¥Î³o­ÓÀÉ®×§@¬° {\ttfamily /etc/ppp/options} ÀÉ®×ªº°òÂ¦¡A¦ý¬O«Ø¥ß§A¦Û¤vªº¡A¨S¦³¥]§t©Ò¦³¦b³o­Ó¼ËªO¸Ìªº«ü¥Oªº¿ï¶µÀÉ®×¥i¯à·|§ó¦n ¡Ð ¥¦·|µu±o¦h¦Ó¥B¤ñ¸û®e©ö¾\Åª¡þºûÅ@¡D



¦pªG§A¦³¦h­Ó¦ê¦C½u¸ô¡þ¼Æ¾Ú¾÷¡]¨å«¬ªº¨Ò¤l¬O PPP ¦øªA¾¹¡^¡A¨º»ò«Ø¥ß¤@­Ó¤@¯ë¤Æªº {\ttfamily /etc/ppp/options} ÀÉ®×¡A¨ä¤¤¥]§t¨C­Ó§A´£¨Ñ¤ä´©¼·¤Jªº¦ê¦C°ð©Ò¨Ï¥Îªº¦@¦P¿ï¶µ¨Ã¥B¬°¨C¤@­Ó»Ý­n­Ó§O³]©w¥H«Ø¥ß PPP ³s½uªº¦ê¦C½u¸ô³]¥ß­Ó§Oªº¿ï¶µÀÉ®×¡D



³o¨ÇÀÉ®×¦W¬° {\ttfamily options.ttyx1}, {\ttfamily options.ttyx2} ¨Ì¦¹Ãþ±À¡]¨ä¤¤ {\ttfamily x} ¬O§A¦ê¦C°ðªº¾A·í¥N½X¡^¡D



µM¦Ó¡A¹ï©ó³æ¤@ PPP  ³s½u¡A§A¥i¥Hª½±µ¨Ï¥Î {\ttfamily /etc/ppp/options} ³o­ÓÀÉ®×¡D¥t¥~¤@ºØ¿ìªk¡A§A¥i¥H§â©Ò¦³ªº¿ï¶µ©ñ¶i pppd «ü¥O§@¬°°Ñ¼Æ¡D



¨Ï¥Î {\ttfamily /etc/ppp/options.ttySx} ÀÉ®×ªº³]©w¤è¦¡·|¤ñ¸û®e©ö¥[¥HºûÅ@¡D
¦pªG§A¨Ï¥Î PPP  ¨Ó³s½u¨ì¦n´X­Ó¤£¦Pªº¸`ÂI¥hªº¸Ü¡A¨º»ò§A´N¥i¥H¦b {\ttfamily /etc/ppp/options.site} ¸Ì­±¬°¨C­Ó¸`ÂI«Ø¥ß¿ï¶µÀÉ®×µM«á¦b§A³s½u®É«ü©w¿ï¶µÀÉ®×§@¬° PPP «ü¥Oªº°Ñ¼Æ¡D
(¨Ï¥Î {\ttfamily file option-file} °Ñ¼Æ©ó pppd ªº«ü¥O¦C)¡D




\subsection{´À¥Nªº options.tpl ÀÉ®×}

¬Y¨Ç­Ó PPP  ªºµo¦æ®M¥ó¦ü¥Gº|¥¢¤F options.tpl ³o­ÓÀÉ®×¡A©Ò¥H¦b³o¸Ì¦³­Ó§¹¾ãªºÀÉ®×¡D
§Ú«ØÄ³§A¤£­nª½±µ½s¿è³o­ÓÀÉ®×¨Ó«Ø¥ß§A¦Û¤vªº {\ttfamily /etc/ppp/options}¡D
§â¥¦«þ¨©¨ì¤@­Ó·sªºÀÉ®×µM«á½s¿è¸ÓÀÉ®×¤ñ¸û¦n¡D¦pªG§A§Ë¶Ã¤F§A½s¿èªºÀÉ®×¡A§A¥i¥H¦^ÀY±q­ì©lÀÉ®×¦A«×¶}©l¡D

\par
\addvspace{\medskipamount}
\nopagebreak\hrule
\begin{verbatim}
# /etc/ppp/options -*- sh -*- general options for pppd
# created 13-Jul-1995 jmk
# autodate: 01-Aug-1995
# autotime: 19:45

# Use the executable or shell command specified to set up the serial
# line.  This script would typically use the "chat" program to dial the
# modem and start the remote ppp session.
#connect "echo You need to install a connect command."

# Run the executable or shell command specified after pppd has
# terminated the link.  This script could, for example, issue commands
# to the modem to cause it to hang up if hardware modem control signals
# were not available.
#disconnect "chat -- \d+++\d\c OK ath0 OK"

# async character map -- 32-bit hex; each bit is a character
# that needs to be escaped for pppd to receive it.  0x00000001
# represents '\x01', and 0x80000000 represents '\x1f'.
#asyncmap 0

# Require the peer to authenticate itself before allowing network
# packets to be sent or received.
#auth

# Use hardware flow control (i.e. RTS/CTS) to control the flow of data
# on the serial port.
#crtscts

# Use software flow control (i.e. XON/XOFF) to control the flow of data
# on the serial port.
#xonxoff

# Add a default route to the system routing tables, using the peer as
# the gateway, when IPCP negotiation is successfully completed.  This
# entry is removed when the PPP connection is broken.
#defaultroute

# Specifies that certain characters should be escaped on transmission
# (regardless of whether the peer requests them to be escaped with its
# async control character map).  The characters to be escaped are
# specified as a list of hex numbers separated by commas.  Note that
# almost any character can be specified for the escape option, unlike
# the asyncmap option which only allows control characters to be
# specified.  The characters which may not be escaped are those with hex
# values 0x20 - 0x3f or 0x5e.
#escape 11,13,ff

# Don't use the modem control lines.
#local

# Specifies that pppd should use a UUCP-style lock on the serial device
# to ensure exclusive access to the device.
#lock

# Use the modem control lines.  On Ultrix, this option implies hardware
# flow control, as for the crtscts option.  (This option is not fully
# implemented.)
#modem

# Set the MRU [Maximum Receive Unit] value to <n> for negotiation.  pppd
# will ask the peer to send packets of no more than <n> bytes. The
# minimum MRU value is 128.  The default MRU value is 1500.  A value of
# 296 is recommended for slow links (40 bytes for TCP/IP header + 256
# bytes of data).
#mru 542

# Set the interface netmask to <n>, a 32 bit netmask in "decimal dot"
# notation (e.g. 255.255.255.0).
#netmask 255.255.255.0

# Disables the default behaviour when no local IP address is specified,
# which is to determine (if possible) the local IP address from the
# hostname. With this option, the peer will have to supply the local IP
# address during IPCP negotiation (unless it specified explicitly on the
# command line or in an options file).
#noipdefault

# Enables the "passive" option in the LCP.  With this option, pppd will
# attempt to initiate a connection; if no reply is received from the
# peer, pppd will then just wait passively for a valid LCP packet from
# the peer (instead of exiting, as it does without this option).
#passive

# With this option, pppd will not transmit LCP packets to initiate a
# connection until a valid LCP packet is received from the peer (as for
# the "passive" option with old versions of pppd).
#silent

# Don't request or allow negotiation of any options for LCP and IPCP
# (use default values).
#-all

# Disable Address/Control compression negotiation (use default, i.e.
# address/control field disabled).
#-ac

# Disable asyncmap negotiation (use the default asyncmap, i.e. escape
# all control characters).
#-am

# Don't fork to become a background process (otherwise pppd will do so
# if a serial device is specified).
#-detach

# Disable IP address negotiation (with this option, the remote IP
# address must be specified with an option on the command line or in an
# options file).
#-ip

# Disable magic number negotiation.  With this option, pppd cannot
# detect a looped-back line.
#-mn

# Disable MRU [Maximum Receive Unit] negotiation (use default, i.e.
# 1500).
#-mru

# Disable protocol field compression negotiation (use default, i.e.
# protocol field compression disabled).
#-pc

# Require the peer to authenticate itself using PAP.
# This requires TWO WAY authentication - do NOT use this for a standard
# PAP authenticated link to an ISP as this will require the ISP machine
# to authenticate itself to your machine (and it will not be able to).
#+pap

# Don't agree to authenticate using PAP.
#-pap

# Require the peer to authenticate itself using CHAP [Cryptographic
# Handshake Authentication Protocol] authentication.
# This requires TWO WAY authentication - do NOT use this for a standard
# CHAP authenticated link to an ISP as this will require the ISP machine
# to authenticate itself to your machine (and it will not be able to).
#+chap

# Don't agree to authenticate using CHAP.
#-chap

# Disable negotiation of Van Jacobson style IP header compression (use
# default, i.e. no compression).
#-vj

# Increase debugging level (same as -d).  If this option is given, pppd
# will log the contents of all control packets sent or received in a
# readable form.  The packets are logged through syslog with facility
# daemon and level debug. This information can be directed to a file by
# setting up /etc/syslog.conf appropriately (see syslog.conf(5)).  (If
# pppd is compiled with extra debugging enabled, it will log messages
# using facility local2 instead of daemon).
#debug

# Append the domain name <d> to the local host name for authentication
# purposes.  For example, if gethostname() returns the name porsche,
# but the fully qualified domain name is porsche.Quotron.COM, you would
# use the domain option to set the domain name to Quotron.COM.
#domain <d>

# Enable debugging code in the kernel-level PPP driver.  The argument n
# is a number which is the sum of the following values: 1 to enable
# general debug messages, 2 to request that the contents of received
# packets be printed, and 4 to request that the contents of transmitted
# packets be printed.
#kdebug n

# Set the MTU [Maximum Transmit Unit] value to <n>. Unless the peer
# requests a smaller value via MRU negotiation, pppd will request that
# the kernel networking code send data packets of no more than n bytes
# through the PPP network interface.
#mtu <n>

# Set the name of the local system for authentication purposes to <n>.
# This will probably have to be set to your ISP user name if you are
# using PAP/CHAP.
#name <n>

# Set the user name to use for authenticating this machine with the peer
# using PAP to <u>.
# Do NOT use this if you are using 'name' above!
#user <u>

# Enforce the use of the host name as the name of the local system for
# authentication purposes (overrides the name option).
#usehostname

# Set the assumed name of the remote system for authentication purposes
# to <n>.
#remotename <n>

# Add an entry to this system's ARP [Address Resolution Protocol]
# table with the IP address of the peer and the Ethernet address of this
# system.
#proxyarp

# Use the system password database for authenticating the peer using
# PAP.
#login

# If this option is given, pppd will send an LCP echo-request frame to
# the peer every n seconds. Under Linux, the echo-request is sent when
# no packets have been received from the peer for n seconds. Normally
# the peer should respond to the echo-request by sending an echo-reply.
# This option can be used with the lcp-echo-failure option to detect
# that the peer is no longer connected.
#lcp-echo-interval <n>

# If this option is given, pppd will presume the peer to be dead if n
# LCP echo-requests are sent without receiving a valid LCP echo-reply.
# If this happens, pppd will terminate the connection.  Use of this
# option requires a non-zero value for the lcp-echo-interval parameter.
# This option can be used to enable pppd to terminate after the physical
# connection has been broken (e.g., the modem has hung up) in
# situations where no hardware modem control lines are available.
#lcp-echo-failure <n>

# Set the LCP restart interval (retransmission timeout) to <n> seconds
# (default 3).
#lcp-restart <n>

# Set the maximum number of LCP terminate-request transmissions to <n>
# (default 3).
#lcp-max-terminate <n>

# Set the maximum number of LCP configure-request transmissions to <n>
# (default 10).
# Some PPP servers are slow to start up. You may need to increase this
# if you keep getting 'serial line looped back' errors and your are SURE
# that you have logged in correctly and PPP should be starting on the server.
#lcp-max-configure <n>

# Set the maximum number of LCP configure-NAKs returned before starting
# to send configure-Rejects instead to <n> (default 10).
#lcp-max-failure <n>

# Set the IPCP restart interval (retransmission timeout) to <n>
# seconds (default 3).
#ipcp-restart <n>

# Set the maximum number of IPCP terminate-request transmissions to <n>
# (default 3).
#ipcp-max-terminate <n>

# Set the maximum number of IPCP configure-request transmissions to <n>
# (default 10).
#ipcp-max-configure <n>

# Set the maximum number of IPCP configure-NAKs returned before starting
# to send configure-Rejects instead to <n> (default 10).
#ipcp-max-failure <n>

# Set the PAP restart interval (retransmission timeout) to <n> seconds
# (default 3).
#pap-restart <n>

# Set the maximum number of PAP authenticate-request transmissions to
# <n> (default 10).
#pap-max-authreq <n>

# Set the CHAP restart interval (retransmission timeout for
# challenges) to <n> seconds (default 3).
#chap-restart <n>

# Set the maximum number of CHAP challenge transmissions to <n>
# (default 10).
#chap-max-challenge

# If this option is given, pppd will re-challenge the peer every <n>
# seconds.
#chap-interval <n>

# With this option, pppd will accept the peer's idea of our local IP
# address, even if the local IP address was specified in an option.
#ipcp-accept-local

# With this option, pppd will accept the peer's idea of its (remote) IP
# address, even if the remote IP address was specified in an option.
#ipcp-accept-remote
\end{verbatim} 
\nopagebreak\hrule 
\addvspace{\medskipamount}







\subsection{§ÚÀ³¸Ó¨Ï¥Î¤°»ò¿ï¶µ? (µL PAP/CHAP)}

¶â¡A§¹¥þµø±¡ªp¦Ó©w¡]­ü¡^¡D³o¸Ì©Ò´£¨ÑªºÀ³¸Ó¾A¥Î©ó¤j³¡¥÷ªº¦øªA¾¹¡D



µM¦Ó¡A¦pªG¥¦µLªk¹B§@ªº¸Ü¡A¾\Åª¼ËªOÀÉ({\ttfamily /etc/ppp/options.tpl}) {\bfseries ¥H¤Î} pppd ªº½u¤W¨Ï¥Î¤â¥U{\bfseries ¨Ã¥B}§i¶D§A©Ò³s½u¤§¦øªA¾¹ªº¨t²ÎºÞ²z¡þ¨Ï¥ÎªÌ¤ä´©¤H­û¡D



§AÁÙÀ³¸Óª`·N³o¸Ì©Ò®i¥Üªº³sµ²«ü¥O½Z¤]¨Ï¥Î¤F¤@¨Çµ¹ pppd ªº©R¥O¦C¿ï¶µ¥H«KÅý¨Æ±¡®e©ö½Õ¾ã¨Ç¡D

\par
\addvspace{\medskipamount}
\nopagebreak\hrule
\begin{verbatim}
# /etc/ppp/options (NO PAP/CHAP)
#
# Á×§K pppd ¶i¤J­I´º°õ¦æ
-detach
#
# ¨Ï¥Î¼Æ¾Ú¾÷±±¨î½u
modem
# ¨Ï¥Î uucp §ÎºAªºÂê©wÀÉ¥HÁ×§K¥¦¤H¨ú¥Î¦ê¦C¸Ë¸m
lock
# ¨Ï¥ÎµwÅé¬y¶q±±¨î
crtscts
# ¦b»¼°eªí®æ¤¤±N¦¹³sµ²«Ø¥ß¬°¹w³]»¼°e¸Ë¸m
defaultroute
# ¤£¨Ï¥Î¥ô¦ó"¶h¥X"±±¨î§Ç¦C
asyncmap 0
# ³Ì¤j¶Ç°e«Ê¥]¤j¤p¬° 552 bytes
mtu 552
# ³Ì¤j±µ¦¬«Ê¥]¤j¤p¬° 552 bytes
mru 552
#
#-------END OF SAMPLE /etc/ppp/options (no PAP/CHAP)
\end{verbatim} 
\nopagebreak\hrule 
\addvspace{\medskipamount}





\section{¦pªG§Aªº PPP ¦øªA¾¹¨Ï¥Î PAP »{ÃÒ(Password Authentication Protocol)\label{pap}}

¦pªG§A³s±µªº¦øªA¾¹»Ý­n PAP ©Î CHAP »{ÃÒ¡A§A»Ý­n¦h¤@ÂIªº¤u§@¡D



¦b¤W­±ªº¿ï¶µÀÉ®×¤¤¡A¥[¤W¤U­±´X¦æ
\par
\addvspace{\medskipamount}
\nopagebreak\hrule
\begin{verbatim}
#
# §i¶D pppd ¨Ï¥Î§Aªº ISP ¦WºÙ°µ¬°»{ÃÒ¹Lµ{¤¤ªº"¥D¾÷¦WºÙ"
name <your ISP user name>       # §A»Ý­n§ïÅÜ³o¤@¦æ
#
# ¦pªG§A°õ¦æ PPP *¦øªA¾¹* ¨Ã¥B»Ý­n¨Ï¥Î PAP ©Î CHAP »{ÃÒ¡A¾A·í°£¥h¤U­±ªº
# µù¸Ñ¡D¤£­n¦b§A°µ¬°«È¤áºÝ³s¤W¦øªA¾¹®É¨Ï¥Î¦¹¿ï¶µ(§Y¨Ï¥¦¨Ï¥Î PAP ©Î CHAP)
# ¦]¬°³o¬O§i¶D¦øªA¾¹¥²¶·¬°¥¦¦Û¤v¦b§Aªº¾÷¾¹¤W´£¨Ñ»{ÃÒ(³o´X¥G¬O¤£¥i¯àªº¡A
# ©Ò¥H³sµ²·|¥¢±Ñ)¡D
#+chap
#+pap
#
# ¦pªG§A¨Ï¥Î¦b /etc/ppp/pap-secrets ÀÉ®×¤¤¸g½s½Xªº±K½X¡A°£¥h¤U­±¤@¦æªºµù¸Ñ¡D
# ª`·N: ³o©M Windows NT ¤Wªº»·ºÝ¦s¨úªA°È¸Ìªº·L³n½s½X±K½X¬O¤£¦Pªº¡D
#+papcrypt
\end{verbatim} 
\nopagebreak\hrule 
\addvspace{\medskipamount}





\subsection{¨Ï¥Î MSCHAP}

·L³nªº Windows NT »·ºÝ¦s¨úªA°È(RAS)¥i¥H³Q³]©w¬°¨Ï¥Î¤@ºØ CHAP(Challenge/Handshake Authentication Protocol) ªºÅÜºØ¡D
¦b§Aªº PPP ­ì©lµ{¦¡½X¤¤¡A§A¥i¥H§ä¨ì¤@­Ó¥s {\ttfamily README.MSCHAP80} ªºÀÉ®×°Q½×³o¥ó¨Æ¡D



§A¥i¥H¶}±Ò pppd ªº°»¿ù¥\¯à§PÂ_¦øªA¾¹¬O§_­n¨D¨Ï¥Î¦¹»{ÃÒ¨ó©w¡D
¦pªG¦øªA¾¹¨Ï¥Î MS CHAP »{ÃÒ¡A§A·|¬Ý¨ì³o¼Ëªº¤@¦æ
\par
\addvspace{\medskipamount}
\nopagebreak\hrule
\begin{verbatim}
rcvd [LCP ConfReq id=0x2 <asyncmap 0x0> <auth chap 80> <magic 0x46a3>]
\end{verbatim} 
\nopagebreak\hrule 
\addvspace{\medskipamount}




ÃöÁäªº°T®§¬O {\bfseries auth chap 80}¡D



¬°¤F¨Ï¥Î MS CHAP¡A§A¥²¶·­«·s½sÄ¶ pppd ¥H¤ä´©¦¹¨ó©w¡D
½Ð°Ñ¨£ PPP ­ì©lµ{¦¡½X¤¤ªº {\ttfamily README.MSCHAP80} »¡©ú¦p¦ó½sÄ¶¥H¨Ï¥Î¦¹ÅÜºØ¨ó©w¡D



§AÁÙ­nª`·N³o¸Ìªºµ{¦¡½X¥u¬OÅý Linux PPP °µ¬°«È¤áºÝ³s±µ¤W MS Windows NT ¦øªA¾¹¥Îªº¡D
¥¦{\bfseries ¨Ã¤£}¤ä´©±N Linux ³]¥ß¬°Åý«È¤áºÝ¨Ï¥Î MSCHAP80 »{ÃÒ PPP ¦øªA¾¹¡D




\subsection{PAP/CHAP ±K½XÀÉ®×}

¦pªG§A¨Ï¥Î PAP ©Î CHAP »{ÃÒ¡A§A¥²¶·«Ø¥ß³o¨Ç±K½XÀÉ®×¡D¥¦­Ì¬O:
\par
\addvspace{\medskipamount}
\nopagebreak\hrule
\begin{verbatim}
/etc/ppp/pap-secrets
/etc/ppp/chap-secrets
\end{verbatim} 
\nopagebreak\hrule 
\addvspace{\medskipamount}




³o¨ÇÀÉ®×¾Ö¦³ªÌ¥²¶·¬° root¡A¸s²Õ¬° root¡A¦P®É¬°¤F¦w¥þÀÉ®×Åv­­À³¬° 740¡D



Ãö©ó PAP »P CHAP ²Ä¤@ÂI­n«ü¥Xªº¬O¥¦­Ì¬O³]­p¥Î¨Ó»{ÃÒ{\bfseries ¹q¸£¨t²Î}¦Ó¤£¬O{\bfseries ¨Ï¥ÎªÌ}ªº¡D



"¶â? ¦³¤°»ò¤£¦P©O?" §ÚÅ¥¨ì§A¦b°Ý¡D



®@¡A¤@¥¹§Aªº¹q¸£«Ø¥ß»P¦øªA¾¹«Ø¥ß PPP ³s½u¡A§A¨t²Î¤Wªº{\bfseries ¥ô¦ó}¨Ï¥ÎªÌ³£¥i¥H¨Ï¥Î¦¹³s½u - ¤£¥u¬O§A¦Ó¤w¡D
³o¤]¬O¬°¦ó§A¥i¥H¨Ï¥Î PPP ±N¨â­Ó°Ï°ìºô¸ô(LAN)³s±µ°_¨Ó«Ø¥ß¤@¼s°ìºô¸ô(WAN)ªº­ì¦]¡D



PAP (ÁÙ¦³ CHAP {\bfseries ¤]¬O})»Ý­n{\bfseries Âù¦V}»{ÃÒ - ¤]´N¬O¨C¤@¹q¸£»Ý­n¤@­Ó¦Xªkªº¦WºÙ»P±K½X¦b¥t¤@¹q¸£¤W¡D
µM¦Ó¡A³o{\bfseries ¨Ã¤£¬O}¤j³¡¥÷´£¨Ñ¼·±µ¦¡ PAP »{ÃÒ³s±µªº PPP ¦øªA¾¹¹B§@ªº¤è¦¡¡D



¤]´N¬O»¡¡A§Aªº ISP ¥i¯à·|µ¹§A¤@­Ó¨Ï¥ÎªÌ¦WºÙ»P±K½X¥H¤¹³\§A³s±µ¨ì¥L­Ìªº¨t²Î¶i¦Ó³s±µ¨ìºô»Úºô¸ô¤W¡D
§Aªº ISP ¹ï©ó§A¹q¸£ªº¦WºÙ¤@ÂI¤]¤£·P¿³½ì¡A¦]¦¹§A¥i¯à¥²¶·¨Ï¥Î§A¦b ISP ¤Wªº¨Ï¥ÎªÌ¦WºÙ°µ¬°§A¹q¸£ªº¦WºÙ¡D



³oÂI­n¨Ï¥Î pppd ¿ï¶µªº {\ttfamily name user name} ¨Ó¹F¦¨¡D
¦]¦¹¡A¦pªG§A¨Ï¥Î§A ISP µ¹§Aªº¨Ï¥ÎªÌ¦WºÙ¡A¥[¤W³o¤@¦æ
\par
\addvspace{\medskipamount}
\nopagebreak\hrule
\begin{verbatim}
name your_user name_at_your_ISP
\end{verbatim} 
\nopagebreak\hrule 
\addvspace{\medskipamount}


¨ì§Aªº {\ttfamily /etc/ppp/options} ÀÉ®×¤¤¡D



±q§Þ³N¤W¨Ó»¡¡APAP ¨ä¹êÀ³¸Ó­n¨Ï¥Î {\ttfamily user our\_user name\_at\_your\_ISP} ³o­Ó¿ï¶µ¡A¦ý¬O¦pªG¨Ï¥Î¨ì PAP ªº¸Ü¨º»ò pppd Áo©úªº¨¬¥H§â {\ttfamily name} ¸ÑÄ¶¬° {\ttfamily user}¡D
¨Ï¥Î {\ttfamily name} ³o­Ó¿ï¶µªº¦n³B¬O³o¹ï©ó CHAP ¤]¬O¦³®Äªº¡D



¦]¬° PAP/CHAP ¬O¥Î¨ÓÅç»{{\bfseries ¹q¸£}ªº¡A¦b§Þ³N¤W§A¤]»Ý­n«ü©w»·ºÝ¹q¸£ªº¦WºÙ¡D
µM¦Ó¡A¤j³¡¤Àªº¤H¥u±µ¤@®a ISP  ©Ò¥H§A¥i¥H¦b±K½XÀÉ¸Ìªº»·ºÝ¥D¾÷¦WºÙ¨Ï¥Î³q¥Î¦r¤¸(*) ¡D



³\¦h ISP ¦³¦h­Ó¼Æ¾Ú¾÷¼·±µ¤¤¤ß³s±µ¨ì¤£¦Pªº²×ºÝ¾÷¦øªA¾¹ ¡Ð ¨C­Ó²×ºÝ¾÷¦øªA¾¹³£¦³¤£¦Pªº¦WºÙ¡A¦ý³£±q³æ¤@ªº¡]¦Û°ÊÂà½u¡^¸¹½X¼·±µ¡D
¦b¬Y¨Ç±¡§Î¤U¥i¯à¦]¦¹¦Ó«Ü¤£®e©ö¹w¥ýª¾¹D»·ºÝ¹q¸£ªº¦WºÙ!




\subsection{PAP ±K½XÀÉ}

{\ttfamily /etc/ppp/pap-secrets} ³o­ÓÀÉ®×¬Ý°_¨Ó¹³
\par
\addvspace{\medskipamount}
\nopagebreak\hrule
\begin{verbatim}
# Secrets for authentication using PAP
# client        server       secret     acceptable_local_IP_addresses
\end{verbatim} 
\nopagebreak\hrule 
\addvspace{\medskipamount}




³o¥|­ÓÄæ¦ì¬O¥HªÅ¥Õ¤À¬É¦Ó¥B³Ì«á¤@¶µ¥i¥H¬OªÅ¥Õ(¦pªG§A¨Ï¥Î°ÊºA IP ©Î¥Ñ§Aªº ISP ©Ò´£¨ÑªºÀRºA IP)¡D



°²©w§Aªº ISP µ¹§Aªº¨Ï¥ÎªÌ¦WºÙ¬O {\ttfamily fred} ¦Ó±K½X¬O {\ttfamily flintstone} ªº¸Ü¨º»ò§AÀ³¸Ó¦b {\ttfamily /etc/ppp/options[.ttySx]} ¸Ì³]©w {\ttfamily name fred} ³o­Ó¿ï¶µ¨Ã¥B§â§Aªº {\ttfamily /etc/ppp/pap-secrets} ÀÉ®×³]¦¨¤U­±³o¼Ë

\par
\addvspace{\medskipamount}
\nopagebreak\hrule
\begin{verbatim}
# Secrets for authentication using PAP
# client        server  secret          acceptable local IP addresses
fred            *       flintstone
\end{verbatim} 
\nopagebreak\hrule 
\addvspace{\medskipamount}




³o¬O»¡¹ï©ó {\ttfamily fred} ³o­Ó¥»¦a¾÷¾¹¦WºÙ¡]§Ú­Ì¤w¸g§i¶D¹L pppd ¨Ï¥Î³o­Ó¦WºÙ¡A§Y¨Ï³o¤£¬O§Ú­Ì¥»¦a¾÷¾¹ªº¦WºÙ¤]¤@¼Ë¡^¥H¤Î{\bfseries ¥ô¦ó}ªº¦øªA¾¹¡A³£¨Ï¥Î {\ttfamily flintstone} ³o­Ó±K½X¡]·t½X¡^¡D



ª`·N¨ì§Ú­Ì¨Ã¤£»Ý­n«ü©w¥»¦aªº IP ¦ì§}¡A°£«D¦³­n¨D­n§Ú­Ì¨Ï¥Î¤@­Ó¯S©wªº¡A©T©wªº IP ¦ì§}¡D
§Y¨Ï§A¸ÕµÛ¥Î¤@©T©wªº IP¡A³o¤]¤£¤j¥i¯à¦æ±o³q¦]¬°¹ï©ó¤j³¡¥÷ªº PPP ¦øªA¾¹(¬°¤F¦w¥þªº²z¥Ñ)¤£¤¹³\»·ºÝ¨t²Î¦Û¦æ«ü©w IP ¸¹½X¡D




\subsection{CHAP ±K½XÀÉ}

¥Ø«eªº pppd ª©¥»­n¨D§A­n¦³¤¬¬ÛÅç»{ªº¤èªk ¡Ð ³o¬O»¡§A¥²¶·¯à°÷Åý±q§Aªº¾÷¾¹¨ì»·ºÝ¦øªA¾¹{\bfseries ¥H¤Î}±q»·ºÝ¦øªA¾¹¨ì§Aªº¾÷¾¹³o¨âºØÅç»{³£¯à¶i¦æ¡D



©Ò¥H¡A¦pªG§Aªº¾÷¾¹¬O {\ttfamily fred} ¦Ó»·ºÝ¬O {\ttfamily barney} ªº¸Ü¡A«h¦b¥¦­Ì­Ó§Oªº {\ttfamily /etc/ppp/options.ttySx} ¸Ì§Aªº³]¬° {\ttfamily name fred remotename barney} ¦Ó»·ºÝ¾÷¾¹À³³]¬° {\ttfamily name barney remotename fred}¡D



fred ³o¥x¾÷¾¹ªº {\ttfamily /etc/ppp/chap-secrets} ÀÉ®×¬Ý°_¨Ó·|¹³
\par
\addvspace{\medskipamount}
\nopagebreak\hrule
\begin{verbatim}
# Secrets for authentication using CHAP
# client        server  secret            acceptable local IP addresses
fred            barney  flintstone
barney          fred    wilma
\end{verbatim} 
\nopagebreak\hrule 
\addvspace{\medskipamount}




¦Ó barney ªº¬O

\par
\addvspace{\medskipamount}
\nopagebreak\hrule
\begin{verbatim}
# Secrets for authentication using CHAP
# client        server  secret            acceptable local IP addresses
barney          fred    flintstone
fred            barney  wilma
\end{verbatim} 
\nopagebreak\hrule 
\addvspace{\medskipamount}




¯S§O­nª`·Nªº¬OÂù¤è¾÷¾¹³£¥²¶·¨ã¦³Âù¦V»{ÃÒªº¶µ¥Ø¡D³o¤¹³\¥»¦aªº¾÷¾¹¦V»·ºÝ¾÷¾¹»{ÃÒ¥¦¦Û¤v{\bfseries ¨Ã¥B}Åý»·¦a¾÷¾¹¦V¥»¦a¾÷¾¹»{ÃÒ¥¦¦Û¤v¡D




\subsection{³B²z¦h­« PAP »{ÃÒ³s±µ}

¤@¨Ç¨Ï¥ÎªÌ¾Ö¦³¦h©ó¤@³¡¨Ï¥Î PAP ªº¦øªA¾¹¥i³s½u¡D
¦pªG§Aªº¨Ï¥ÎªÌ¦WºÙ¦b¨C³¡§A·Q³s±µªº¾÷¾¹¤W³£¤£¦P¡A³o¨Ã¤£¬O°ÝÃD¡D



µM¦Ó¡A³\¦h¨Ï¥ÎªÌ¦b¨â­Ó¨t²Î(©ÎªÌ¬Æ¦Ü¬O¥þ³¡)¤W¨ã¦³¬Û¦Pªº¨Ï¥ÎªÌ¦WºÙ¡D
³o¦b±q {\ttfamily /etc/ppp/pap-secrets} ¤¤¥¿½T¦a¿ï¾Ü¾A·í¤@¦æ®É·|¦³°ÝÃD¡D



¦p§A©Ò®Æ¦a¡APPP ´£¨Ñ¤@ºØ¾÷¨î¥H§JªA¦¹¦]Ãø¡D
PPP ¤¹³\§A¨Ï¥Î {\bfseries remotename} ¿ï¶µ¬°»·ºÝ¦øªA¾¹³]©w¤@­Ó"°²·Q¦WºÙ"¡D



°²³]§A³s±µ¨ì¨â³¡ PPP ¦øªA¾¹³£¨Ï¥Î¦WºÙ fred¡D§A¥H¦¹¤è¦¡«Ø¥ß {\ttfamily /etc/ppp/pap-secrets} ÀÉ®×
\par
\addvspace{\medskipamount}
\nopagebreak\hrule
\begin{verbatim}
fred    pppserver1      barney
fred    pppserver2      wilma
\end{verbatim} 
\nopagebreak\hrule 
\addvspace{\medskipamount}




¦p¦¹¡A¦b»P pppserver1 ³s½u®É§A¦b pppd ¿ï¶µ¤¤¨Ï¥Î {\ttfamily name fred remotename pppserver1} ¨Ã¦b³s½u pppserver2 ®É¨Ï¥Î {\ttfamily name fred remotename pppserver2}¡D



¦]¬°§A¥i¥H¨Ï¥Î¦b pppd ¨Ï¥Î {\ttfamily file filename} ¥H«ü©w ppp ¿ï¶µ¡A§A¥i¥H«Ø¥ß¤@«ü¥O½Z¥H³s±µ¨ì¨C³¡ PPP ¦øªA¾¹¡A¥¿½T¦a¨ú¥Î¿ï¶µÀÉ®×¨Ã¥B¿ï¾Ü¥¿½Tªº {\ttfamily remotename} ¿ï¶µ¡D




\section{¥H¤â°Ê¤è¦¡«Ø¥ß PPP ³sµ²\label{manual}}

²{¦b§A¤w¸g«Ø¥ß§Aªº {\ttfamily /etc/ppp/options} ¥H¤Î {\ttfamily /etc/resolv.conf} ÀÉ®×¡]¥H¤Î¡A¦pªG¦³»Ý­n¡AÁÙ¦³ {\ttfamily /etc/ppp/pap$|$chap-secrets} ÀÉ®×¡^¡A§A¥i¥HÂÇ¥Ñ¤â°Ê³]¥ß PPP ³s½u¨Ó´ú¸Õ³o¨Ç³]©w¡]¤@¥¹§Ú­Ì¨Ï¤â°Ê³s½u¯à¹B§@¡A§Ú­Ì±N·|¦Û°Ê¤Æ¸Ó¹Lµ{¡^¡D



­n°µ³o¥ó¨Æ¡A§Aªº³q°T³nÅé¥²¶·¯à¦b¤£­«¸m§Aªº¼Æ¾Ú¾÷ªº±¡ªp¤Uµ²§ô¡D
Minicom ¥i¥H°µ¨ì ¡Ð {\ttfamily ALT Q} ¡]©ÎªÌ¦b¤ñ¸ûÂÂªº minicom  ª©¥»¬O¨Ï¥Î {\ttfamily CTRL A Q}¡^¡D



½T©w§A¥H root Ã±¤J¡D



±Ò°Ê§Aªº³q°T³nÅé¡]¹³¬O minicom¡^¡A¼·±µ¨ì PPP ¦øªA¾¹¨Ã¥B¹³¥­±`¤@¼ËªºÃ±¤J¡D
¦pªG§A»Ý­nµo¥X¬Y­Ó«ü¥O¨Ó°_°Ê¦øªAºÝ¤Wªº PPP¡A¨º»ò´N°µ§a¡D§A±N·|¬Ý¨£§A¥H«e¬Ý¹Lªº©U§£¡D



¦pªG§A¨Ï¥Î PAP ©Î CHAP ªº¸Ü¡A¨º»ò¥u¬O³s½u¨ì»·ºÝ¨t²ÎÀ³¸Ó´N·|°_°Ê¦b»·ºÝ¤Wªº PPP ¦Ó¥B§A±N¦b¨S¦³Ã±¤Jªº±¡ªp¤U´N¨£¨ì³o¨Ç©U§£¡]ÁöµM³o¦b¬Y¨Ç¦øªA¾¹¤W¤£·|µo¥Í - ¸ÕµÛ«ö¤U {\bfseries Enter} ¬Ý¬Ý¯à§_¬Ý¨ì³o¨Ç©U§£¡^¡D



²{¦b¡A¦b¤£­n­«¸m¼Æ¾Ú¾÷ªº±¡ªp¤Uµ²§ô³q°T³nÅé(¦b minicom ¨Ï¥Î {\ttfamily ALT Q} ©Î {\ttfamily CTL A Q})¨Ã¥B¦b Linux ªº´£¥Ü²Å¸¹¤U¡]¥H root ªº¨­¤À¡^Áä¤J

\par
\addvspace{\medskipamount}
\nopagebreak\hrule
\begin{verbatim}
pppd -d -detach /dev/ttySx 38400 &
\end{verbatim} 
\nopagebreak\hrule 
\addvspace{\medskipamount}




{\ttfamily -d} ³o­Ó¿ï¶µ¶}±Ò°»¿ù¥\¯à ¡Ð ppp ³s½u°_°Ê®Éªº¡¨¥æ½Í¡¨±N·|°O¿ý¨ì§Aªº¨t²Î°O¿ý¸Ì¥h ¡Ð ¦pªG§A¹J¤W³Â·Ð³o·|«Ü¦³¥Îªº¡D



§A¼Æ¾Ú¾÷ªº¿O²{¦bÀ³¸Ó­n°{Ã{¡A¦]¬°­n«Ø¥ß PPP ³s½u¡DPPP ³s½uªº«Ø¥ß±N·|ªáÂI®É¶¡¡D



¦¹®É§A¥i¥HÆ[¹î PPP ¬É­±¡AÂÇ¥Ñµo¥X³o­Ó«ü¥O

\par
\addvspace{\medskipamount}
\nopagebreak\hrule
\begin{verbatim}
ifconfig
\end{verbatim} 
\nopagebreak\hrule 
\addvspace{\medskipamount}




¦b§A©Ò¾Ö¦³ªº¥ô¦ó¤A¤Óºô¸ô¥H¤Î¦^±Â³]³Æ¤§¥~¡A§AÀ³¸Ó·|¬Ý¨£¹³³o¼Ëªº¸ê°T:
\par
\addvspace{\medskipamount}
\nopagebreak\hrule
\begin{verbatim}
ppp0     Link encap:Point-Point Protocol
         inet addr:10.144.153.104  P-t-P:10.144.153.51 Mask:255.255.255.0
         UP POINTOPOINT RUNNING  MTU:552  Metric:1
         RX packets:0 errors:0 dropped:0 overruns:0
         TX packets:0 errors:0 dropped:0 overruns:0
\end{verbatim} 
\nopagebreak\hrule 
\addvspace{\medskipamount}




¨ä¤¤
\begin{itemize}
\item inet addr:10.144.153.10 ¬O¸Ó³sµ²¤¤§A³oºÝªº IP ¸¹½X¡D
\item P-t-P:10.144.153.5 ¬O¦øªAºÝªº IP ¸¹½X¡D
\end{itemize}


(¦ÛµM¡A ifconfig ¤£·|³ø§i³o¨Ç IP ¸¹½X¡A¦Ó¬O§Aªº PPP ¦øªA¾¹¤W¨Ï¥Îªº¡D)



ª`·N:  ifconfig ¤]§i¶D§A¸Ó³sµ²¤w¸g°_°Ê¨Ã¥B¥¿¦b°õ¦æ!



¦pªG¨S¦³ ppp ¸Ë¸m¦C¥X©Î±o¨ìªº¬O¹³³o¼Ëªº¸ê°T:

\par
\addvspace{\medskipamount}
\nopagebreak\hrule
\begin{verbatim}
ppp0     Link encap:Point-Point Protocol
         inet addr:0.0.0.0  P-t-P:0.0.0.0  Mask:0.0.0.0
         POINTOPOINT  MTU:1500  Metric:1
         RX packets:0 errors:0 dropped:0 overruns:0
         TX packets:0 errors:0 dropped:0 overruns:0
\end{verbatim} 
\nopagebreak\hrule 
\addvspace{\medskipamount}




§Aªº PPP ³s½u¨Ã¨S¦³«Ø¥ß... °Ñ¾\µy«á¦³Ãö¿ù»~±Æ°£ªº³¹¸`!



§AÁÙ¥i¥H¬Ý¨ì³o³¡»·ºÝ¾÷¾¹(¤Î¨ä«áªº)ªº»¼°e¸ô®|¡D­n°µ¨ì³oÂI¡A¤U³o­Ó«ü¥O

\par
\addvspace{\medskipamount}
\nopagebreak\hrule
\begin{verbatim}
route -n
\end{verbatim} 
\nopagebreak\hrule 
\addvspace{\medskipamount}




§AÀ³¸Ó¬Ý¨ì¹³³o¼Ëªº:-

\par
\addvspace{\medskipamount}
\nopagebreak\hrule
\begin{verbatim}
Kernel routing table
Destination     Gateway         Genmask         Flags MSS    Window Use Iface
10.144.153.3    *               255.255.255.255 UH    1500   0        1 ppp0
127.0.0.0       *               255.0.0.0       U     3584   0       11 lo
10.0.0.0        *               255.0.0.0       U     1500   0       35 eth0
default         10.144.153.3    *               UG    1500   0        5 ppp0
\end{verbatim} 
\nopagebreak\hrule 
\addvspace{\medskipamount}




¯S§Oª`·N³o¸Ì¡A§Ú­Ì¦³¨â­Ó¶µ¥Ø«ü¨ì§Ú­Ìªº ppp ¸Ë¸m¡D



²Ä¤@¶µ¬O¥D¾÷»¼°e(¥H H ºX¸¹ªí¥Ü)¨Ã¥B¤¹³\§Ú­Ì¬Ý¨ì³o³¡§Ú­Ì¥¿¦b³s±µªº¥D¾÷ - ¦ý¦A¨Ó´N¨S¦³¤F¡D



²Ä¤G¶µ¬O¹w³]»¼°e¸ô®|(¥Ñ pppd ªº {\ttfamily defaultroute} ¿ï¶µ©Ò«Ø¥ßªº)¡D
³o¥÷»¼°e¸ô®|§i¶D§Ú­Ìªº Linux PC ±N¥ô¦ó¤£¦b¤º³¡¤A¤Óºô¸ôªº«Ê¥]°e¨ì¨º¸Ì - ¨ì§Ú­Ì«ü©wªººô¸ô - ¤]´N¬O¨ì PPP ¦øªA¾¹¥»¨­¡D
¦Ó PPP ¦øªA¾¹¦³³d¥ô¬°§Ú­Ì±N«Ê¥]»¼°e¨ìºô»Úºô¸ô¨Ã±N¦^À³ªº«Ê¥]°e¦^µ¹§Ú­Ì¡D



¦pªG§A¦b»¼°eªí®æ¤¤¨S¬Ý¨ì¨â­Ó¶µ¥Ø¡A¦³¨Ç¨Æ¤£¹ï«l¡D
¯S§O¬O¦pªG§Aªº¨t²Î°O¿ý(syslog)Åã¥Ü¤@°T®§§i¶D§A pppd µLªk¨ú¥N¤w¦s¦bªº¹w³]»¼°e¸ô®|¡A¨º»ò§A¤w¦³¤@¹w³]»¼°e¸ô®|«ü¦V§Aªº¤A¤Óºô¸ô¬É­± - 
¦Ó³o{\bfseries ¥²¶·}¥Ñ«ü©wªººô¸ô»¼°e¨Ó¨ú¥N: {\bfseries §A¥u¯à¦³¤@­Ó¹w³]»¼°e¸ô®|!!!}



§A¥²¶·ÀË¬d¤@¤U§A¨t²Îªº°_©lÀÉ®×¥H§ä¥X¹w³]»¼°e¬O¦b¨º¸Ì«Ø¥ßªº(³o¬O¥Ñ {\ttfamily route add default...} «ü¥O«ü©wªº)¡D
±N¥¦§ï¦¨¹³³o¼Ëªº {\ttfamily route add net...}¡D



²{¦bÂÇ¥Ñ ifconfig ¤§¿é¥X©Ò¦^³øªº IP ¸¹½X¨Ó 'ping' ¤@¤U¸Ó¦øªA¾¹¥H´ú¸Õ³o­Ó³sµ²¡A¹³³o¼Ë

\par
\addvspace{\medskipamount}
\nopagebreak\hrule
\begin{verbatim}
ping 10.144.153.51
\end{verbatim} 
\nopagebreak\hrule 
\addvspace{\medskipamount}




§AÀ³¸Ó·|±µ¦¬¨ì¹³³o¼Ëªº¿é¥X

\par
\addvspace{\medskipamount}
\nopagebreak\hrule
\begin{verbatim}
PING 10.144.153.51 (10.144.153.51): 56 data bytes
64 bytes from 10.144.153.51: icmp_seq=0 ttl=255 time=328.3 ms
64 bytes from 10.144.153.51: icmp_seq=1 ttl=255 time=190.5 ms
64 bytes from 10.144.153.51: icmp_seq=2 ttl=255 time=187.5 ms
64 bytes from 10.144.153.51: icmp_seq=3 ttl=255 time=170.7 ms
\end{verbatim} 
\nopagebreak\hrule 
\addvspace{\medskipamount}




³o±N·|¤@ª½¦C¦L¤U¥h ¡Ð «ö¤U {\ttfamily CTRL C} ²×¤î¥¦¡A¨º®É§A±N·|±µ¦¬¨ì§ó¦h°T®§:

\par
\addvspace{\medskipamount}
\nopagebreak\hrule
\begin{verbatim}
--- 10.144.153.51 ping statistics ---
4 packets transmitted, 4 packets received, 0% packet loss
round-trip min/avg/max = 170.7/219.2/328.3 ms
\end{verbatim} 
\nopagebreak\hrule 
\addvspace{\medskipamount}




¨ì¥Ø«e³£«Ü¦n¡D



²{¦b¸ÕµÛÂÇ¥Ñ¦WºÙ ping ¬Y¥x¥D¾÷¡]¤£¬O PPP  ¦øªA¾¹¥¦¦Û¤vªº¦WºÙ¡A¦Ó¬O¦b¥t¤@­Ó¦a¤èªº¤@¥x§Aª¾¹D¥i¯à¤w¸g°_°Ê¦Ó¥B¥¿¦b¹B§@ªº¥D¾÷¡^¡D¨Ò¦p

\par
\addvspace{\medskipamount}
\nopagebreak\hrule
\begin{verbatim}
ping sunsite.unc.edu
\end{verbatim} 
\nopagebreak\hrule 
\addvspace{\medskipamount}




³o®É·|¦³¤@ÂI°±¹y¡A¦]¬° Linux  ±q§A¦b {\ttfamily /etc/resolv.conf} ¸Ì«ü©wªº DNS ¨ú±o§A­n 'ping' ªº§¹¾ã¥D¾÷¦WºÙ©Ò¹ïÀ³ªº IP ¦ì§} ¡Ð ©Ò¥H¤£­n¾á¤ß¡]¦ý¬O§A±N·|¬Ý¨£§Aªº¼Æ¾Ú¾÷¿O¸¹°{Ã{¡^¡D
¦bµu¼Èªº®É¶¡«á§A±N·|±µ¦¬¨ì¹³³o¼Ëªº¿é¥X

\par
\addvspace{\medskipamount}
\nopagebreak\hrule
\begin{verbatim}
 PING sunsite.unc.edu (152.2.254.81): 56 data bytes
64 bytes from 152.2.254.81: icmp_seq=0 ttl=254 time=190.1 ms
64 bytes from 152.2.254.81: icmp_seq=1 ttl=254 time=180.6 ms
64 bytes from 152.2.254.81: icmp_seq=2 ttl=254 time=169.8 ms
64 bytes from 152.2.254.81: icmp_seq=3 ttl=254 time=170.6 ms
64 bytes from 152.2.254.81: icmp_seq=4 ttl=254 time=170.6 ms
\end{verbatim} 
\nopagebreak\hrule 
\addvspace{\medskipamount}




¦A¤@¦¸¡AÂÇ¥Ñ«ö¤U {\ttfamily CTRL C} ²×¤î¿é¥X¨Ã¨ú±o²Î­p¸ê®Æ...

\par
\addvspace{\medskipamount}
\nopagebreak\hrule
\begin{verbatim}
--- sunsite.unc.edu ping statistics ---
5 packets transmitted, 5 packets received, 0% packet loss
round-trip min/avg/max = 169.8/176.3/190.1 ms
\end{verbatim} 
\nopagebreak\hrule 
\addvspace{\medskipamount}




¦pªG§A¨S¦³¦¬¨ì¥ô¦ó¦^À³¡A¸ÕµÛ ping ¤@¤U§Aªº ISP ´£¨Ñªº DNS ªº IP ¦ì§}¡D
¦pªG§A±q³o¸Ì±o¨ìªÖ©wªºµ²ªG¡A¨º»ò¬Ý°_¨Ó°ÝÃD¦b§Aªº {\ttfamily /etc/resolv.conf} ÀÉ®×¸Ì¡D



¦pªG³o¼Ë·|¨S¦³µ²ªG¡A°ÝÃD¥X¦bºô¸ô»¼°e¤W¡A©ÎªÌ¬O§Aªº ISP ¦b±N«Ê¥]»¼°e¦^µ¹§A®É¥X¤F°ÝÃD¡D
ÀË¬d¤W­±ªº»¼°eªí®æ¡A¦pªG¨S°ÝÃD¡A©M§Aªº ISP Ápµ¸¡D¤@­Ó´ú¸Õ ISP ªº¦n¤èªk¬O¥Î¥t¤@ºØ§@·~¨t²Î¨Ó³s±µ¡D
¦pªG³o¼Ë´N¥i¥H°Ê¡A¨º»ò°ÝÃD´N¦b§A³oÃä¡D



¦pªG¤@¤Á¥¿±`¡AÂÇ¥ÑÁä¤J³o­Ó«ü¥O²×¤î¸Ó³s½u

\par
\addvspace{\medskipamount}
\nopagebreak\hrule
\begin{verbatim}
ppp-off
\end{verbatim} 
\nopagebreak\hrule 
\addvspace{\medskipamount}




¤@¬qµu¼Èªº°±¹y¤§«á¡A¼Æ¾Ú¾÷À³¸Ó·|¦Û¤v±¾Â_¹q¸Ü



¦pªG³o­Ó«ü¥OµLªk°Ê§@ªº¸Ü¡A¨º»ò¤£¬OÃö±¼§Aªº¼Æ¾Ú¾÷´N¬O°_°Ê§Aªº³q°T³nÅé¨Ã¥B¥H {\ttfamily +++} ¤¤Â_¼Æ¾Ú¾÷µM«á·í§A±µ¦¬¨ì¼Æ¾Ú¾÷ªº OK ´£¥Ü®É¥H {\ttfamily ATH0} ±¾Â_¹q¸Ü¡D



§A¥i¯à¤]±o²M°£ pppd ©Ò«Ø¥ßªºÂê©wÀÉ
\par
\addvspace{\medskipamount}
\nopagebreak\hrule
\begin{verbatim}
rm -f /var/lock/LCK..ttySx
\end{verbatim} 
\nopagebreak\hrule 
\addvspace{\medskipamount}





\section{¨Ï§Aªº³sµ²¦Û°Ê¤Æ - ³Ð³y³sµ²«ü¥O½Z\label{automate}}

¤@¥¹§A¥i¥H¥Î¤W­zªº¤èªk¥Î¤â°Ê¤è¦¡Ã±¤J¡A§ó¦nªº°µªk¬O«Ø¥ß¤@¨Ç«ü¥O½Z¨Ó¦Û°Ê¬°§A¶i¦æ³o¨Ç¤u§@¡D

¤@¥÷ chat «ü¥O½Z¥i¥H¦Û°Ê¤ÆÃ±¤J¥H¤Î°_°Ê PPP  ªºµ{§Ç¡A¦]¦¹©Ò¦³§A±o°µªº¡]¥H root ©Î¬O ppp ¸s²Õ²Õ­ûªº¨­¤À¡^¥u¬Oµo¥X³æ¤@­Ó«ü¥O¨Ó°_°Ê§Aªº³s½u¡D






\subsection{¥H¨Ï¥ÎªÌ¦WºÙ¡þ±K½X»{ÃÒªº«ü¥O½Z}

¦pªG§Aªº ISP  ¨Ã¤£­n¨D¨Ï¥Î PAP/CHAP ªº¸Ü¡A³o¨Ç´N¬O¬°§A·Ç³Æªº!



¦pªG ppp ®M¥ó¦w¸Ë¥¿½T¡A§AÀ³¸Ó·|¦³¨â­Ó½d¨ÒÀÉ®×¡D
¦b PPP 2.1.2 ¤¤¬O¦b {\ttfamily /usr/sbin} ¦Ó¦b PPP 2.2 ¸Ì¬O¦b {\ttfamily /etc/ppp/scripts}¡D³o¨Ç¬O



¦b PPP-2.1.2

\begin{tscreen}
\begin{verbatim}
ppp-on
ppp-off
\end{verbatim}
\end{tscreen}




¦Ó¦b PPP-2.2

\begin{tscreen}
\begin{verbatim}
ppp-off
ppp-on
ppp-on-dialer
\end{verbatim}
\end{tscreen}




²{¦b¡A¦pªG§A¥¿¦b¨Ï¥Î PPP 2.1.2¡A§Ú±j¯P«ØÄ³§A§R°£³o¨Ç½d¨ÒÀÉ®×¡D
¥¦­Ì¦³¼ç¦bªº°ÝÃD - ¤£­n§i¶D§Ú¥¦­Ì¤u§@±o«Ü¦n - §Ú¤]¥Î¤F«Üªø¤@¬q®É¶¡(¦Ó¥BÁÙ¦b³o¥÷ HOWTO ªº²Ä¤@ª©¤¤±ÀÂË¥¦­Ì)!



¬°¤F ppp 2.1.2  ¨Ï¥ÎªÌªºÅv¯q¡A³o¸Ì¦³¤ñ¸û¦nªº¼ËªOÀÉ®×¡A³o¨Ç¬O±q ppp 2.2 µo¦æ®M¥ó¸Ì®³¨Óªº¡D
§Ú«ØÄ³§A«þ¨©¨Ã¨Ï¥Î³o¨Ç«ü¥O½Z{\bfseries ¦Ó¤£­n}¦A¥ÎÂÂªº PPP-2.1.2 «ü¥O½Z¡D




\subsection{{\ttfamily ppp-on} «ü¥O½Z}

³o¬O¹ê»Ú±Ò°Ê³s½uªº¤@¹ï«ü¥O½Z¤¤ªº²Ä¤@­Ó¡D

\par
\addvspace{\medskipamount}
\nopagebreak\hrule
\begin{verbatim}
#!/bin/sh
#
# Script to initiate a PPP connection. This is the first part of the
# pair of scripts. This is not a secure pair of scripts as the codes
# are visible with the 'ps' command.  However, it is simple.
#
# These are the parameters. Change as needed.
TELEPHONE=555-1212      # The telephone number for the connection
ACCOUNT=george          # The account name for logon (as in 'George Burns')
PASSWORD=gracie         # The password for this account (and 'Gracie Allen')
LOCAL_IP=0.0.0.0        # Local IP address if known. Dynamic = 0.0.0.0
REMOTE_IP=0.0.0.0       # Remote IP address if desired. Normally 0.0.0.0
NETMASK=255.255.255.0   # The proper netmask if needed
#
# Export them so that they will be available to 'ppp-on-dialer'
export TELEPHONE ACCOUNT PASSWORD
#
# This is the location of the script which dials the phone and logs
# in.  Please use the absolute file name as the $PATH variable is not
# used on the connect option.  (To do so on a 'root' account would be
# a security hole so don't ask.)
#
DIALER_SCRIPT=/etc/ppp/ppp-on-dialer
#
# Initiate the connection
#
#
exec /usr/sbin/pppd debug /dev/ttySx 38400 \
        $LOCAL_IP:$REMOTE_IP \
        connect $DIALER_SCRIPT
\end{verbatim} 
\nopagebreak\hrule 
\addvspace{\medskipamount}




¦Ó³o¬O {\ttfamily ppp-on-dialer} «ü¥O½Z:-

\par
\addvspace{\medskipamount}
\nopagebreak\hrule
\begin{verbatim}
#!/bin/sh
#
# This is part 2 of the ppp-on script. It will perform the connection
# protocol for the desired connection.
#
/usr/sbin/chat -v                                       \
        TIMEOUT         3                               \
        ABORT           '\nBUSY\r'                      \
        ABORT           '\nNO ANSWER\r'                 \
        ABORT           '\nRINGING\r\n\r\nRINGING\r'    \
        ''              \rAT                            \
        'OK-+++\c-OK'   ATH0                            \
        TIMEOUT         30                              \
        OK              ATDT$TELEPHONE                  \
        CONNECT         ''                              \
        ogin:--ogin:    $ACCOUNT                        \
        assword:        $PASSWORD
\end{verbatim} 
\nopagebreak\hrule 
\addvspace{\medskipamount}




¦b PPP-2.2 ¤¤¡A{\ttfamily ppp-off} «ü¥O½Z¬Ý°_¨Ó¹³:-

\par
\addvspace{\medskipamount}
\nopagebreak\hrule
\begin{verbatim}
#!/bin/sh
######################################################################
#
# Determine the device to be terminated.
#
if [ "$1" = "" ]; then
        DEVICE=ppp0
else
        DEVICE=$1
fi

######################################################################
#
# If the ppp0 pid file is present then the program is running. Stop it.
if [ -r /var/run/$DEVICE.pid ]; then
        kill -INT `cat /var/run/$DEVICE.pid`
#
# If the kill did not work then there is no process running for this
# pid. It may also mean that the lock file will be left. You may wish
# to delete the lock file at the same time.
        if [ ! "$?" = "0" ]; then
                rm -f /var/run/$DEVICE.pid
                echo "ERROR: Removed stale pid file"
                exit 1
        fi
#
# Success. Let pppd clean up its own junk.
        echo "PPP link to $DEVICE terminated."
        exit 0
fi
#
# The ppp process is not running for ppp0
echo "ERROR: PPP link is not active on $DEVICE"
exit 1
\end{verbatim} 
\nopagebreak\hrule 
\addvspace{\medskipamount}





\subsection{½s¿è³o¸Ì©Ò´£¨Ñªº°_©l«ü¥O½Z}

¦]¬°³o¥÷·sªº«ü¥O½Z¤À¦¨¨â³¡¥÷¡A§Ú­Ì¤À§O½s¿è¥¦­Ì¡D




\subsubsection{{\ttfamily ppp-on} «ü¥O½Z}

§A±N±o½s¿è³o­Ó«ü¥O½Z¥H¤Ï¬M§A¦b ISP ªº¨Ï¥ÎªÌ¦WºÙ¡A§A¦b ISP ªº±K½X¡A§A ISP ªº¹q¸Ü¸¹½X¡D



¨C¤@¦æ¹³¬O {\ttfamily TELEPHONE=} ¹ê»Ú¤W³]©w¤F³o­ÓÅÜ¼Æ¥]§t¦bµ¥¸¹¥kÃäªº¸ê°T (·íµM¤£¥]¬Aµù¸Ñ³¡¥÷)¡D
¦]¦¹½s¿è¨C¤@¦æ¨Ï¥¦¹ï§Aªº ISP »P³s½u¬O¥¿½Tªº¡D



¦Ó¥B¡A¦pªG§A(»Ý­n)¦b {\ttfamily /etc/ppp/options} ÀÉ®×¸Ì³]©w¤F IP ¸¹½X¡A§R°£³o¦æ

\par
\addvspace{\medskipamount}
\nopagebreak\hrule
\begin{verbatim}
$LOCAL_IP:$REMOTE_IP \
\end{verbatim} 
\nopagebreak\hrule 
\addvspace{\medskipamount}




ÁÙ¦³¡A½T©wÅÜ¼Æ {\ttfamily DIALER\_SCRIPT} «ü¦V§A±N­n¨Ï¥Îªº¼·¸¹«ü¥O½Zªº¥þ³¡¸ô®|¦WºÙ¡D
¦]¦¹¡A¦pªG§A²¾°Ê©Î§ïÅÜ³o­Ó«ü¥O½Zªº¦WºÙ¡A½T©w§A¥¿½T¦a§ïÅÜ {\ttfamily ppp-on} «ü¥O½Z¸Ìªº³o¤@¦æ¡D




\subsubsection{{\ttfamily ppp-on-dialer} «ü¥O½Z}

³o¬O²Ä¤G­Ó«ü¥O½Z¹ê»Ú«Ø¥ß°_§Ú­Ìªº PPP ³sµ²¡D



ª`·N: ¤@¥÷ chat «ü¥O½Z¤@¯ë¥þ³£©ñ¦b¦P¤@¦æ¸Ì¡D­Ë±×½u¬O¥Î¨ÓÅý¤@¦æ¥i¥H¸ó¹L¼Æ¦æªº¹êÅé¦æ¡]«K©ó¤H­Ì¾\Åª¡^¦Ó¨Ã¤£¬O«ü¥O½Z¥»¨­²Õ¦¨ªº¤@³¡¥÷¡D



µM¦Ó¡A¥J²Ó¦a¬Ý¬Ý¥¦ªº²Ó¸`³¡¥÷¥H«KÅý§Ú­Ì¤F¸Ñ¥¦¹ê»Ú(°²³]ªº)­n°µ¤°»ò¬O«D±`¦³¥Îªº!




\subsection{¤@¥÷ chat «ü¥O½Z¨ä¤¤ªº§t·N...}

¤@¥÷ chat «ü¥O½Z¬O¤@¨t¦C{\ttfamily {``}}´Á«Ý¦r¦ê{\ttfamily {''}} {\ttfamily {``}}°e¥X¦r¦ê{\ttfamily {''}}ªº°t¹ï¡D
¯S§O¬O¡Aª`·N¨ì§Ú­Ì{\bfseries Á`¬O}¦b°e¥X¬Y¨Ç°T®§¤§«e¥ý´Á«Ý{\bfseries ¬Y¨Ç°T®§}¥X²{¡D



¦pªG§Ú­Ì¦b{\bfseries ¨S¦³}¥ý±µ¦¬¨ì¥ô¦ó°T®§ªº±¡ªp¤U­n°e¥X¬Y¨Ç°T®§ªº¸Ü¡A§Ú­Ì¥²¶·¨Ï¥ÎªÅªº´Á«Ý¦r¦ê¡]ÂÇ¥Ñ {\ttfamily {``}}{\ttfamily {''}} «ü©ú¡^¦Ó¦b¨S¦³°e¥X¥ô¦ó°T®§ªº±¡ªp¤U­n´Á«Ý¬Y¨Ç°T®§§@ªk¤]Ãþ¦ü! 
¦Ó¥B¡A¦pªG¦r¦ê¥]§t¦n´X­Ó¦r¡]¨Ò¦p NO CARRIER¡^¡A§A¥²¶·§â¦r¦ê¥Î¤Þ¸¹¬A¦í¡A³o¼Ë chat ·|§â¦r¦ê·í§@¬O³æ¤@­Ó¶µ¥Ø¡D



¦b§Ú­Ì¼ËªO¸Ìªº chat «ü¥O¦æ¬O:

\par
\addvspace{\medskipamount}
\nopagebreak\hrule
\begin{verbatim}
exec /usr/sbin/chat -v
\end{verbatim} 
\nopagebreak\hrule 
\addvspace{\medskipamount}


°_°Ê chat ¡A{\ttfamily -v} §i¶D chat ±N¨ä©Ò¦³ªº¿é¥X¡þ¤J«þ¨©¨ì¨t²Î°O¿ý¸Ì¡]³q±`¬O /var/log/messages¡^¡D
¤@¥¹§AÄ±±o chat «ü¥O½Zªº¹B§@Ã­©w¦Ó¥i¾a¡A½s¿è³o¤@¦æ§â {\ttfamily -v} ²¾°£¥H«K´î¤Ö§A¨t²Î°O¿ýªº²VÂø¡D

\par
\addvspace{\medskipamount}
\nopagebreak\hrule
\begin{verbatim}
TIMEOUT         3
\end{verbatim} 
\nopagebreak\hrule 
\addvspace{\medskipamount}

³o³]©w±µ¦¬©Ò´Á«Ýªº¿é¤J¹O®É®É­­¬°¤T¬í¡D¦pªG§A¨Ï¥Î¯uªº¬O«ÜºCªº¼Æ¾Ú¾÷¨º»ò§A¥i¯à±o­n¼W¥[³o­Ó³]©w¨ì¤­¬í©Î¬O¤Q¬í!

\par
\addvspace{\medskipamount}
\nopagebreak\hrule
\begin{verbatim}
ABORT           '\nBUSY\r'
\end{verbatim} 
\nopagebreak\hrule 
\addvspace{\medskipamount}


¦pªG±µ¦¬¨ì BUSY ¦r¦ê¡A¤¤¤î°õ¦æ¡D

\par
\addvspace{\medskipamount}
\nopagebreak\hrule
\begin{verbatim}
ABORT           '\nNO ANSWER\r'
\end{verbatim} 
\nopagebreak\hrule 
\addvspace{\medskipamount}


¦pªG±µ¦¬¨ì NO ANSWER  ¦r¦ê¡A¤¤¤î°õ¦æ¡D

\par
\addvspace{\medskipamount}
\nopagebreak\hrule
\begin{verbatim}
ABORT           '\nRINGING\r\n\r\nRINGING\r'
\end{verbatim} 
\nopagebreak\hrule 
\addvspace{\medskipamount}


¦pªG±µ¦¬¨ì¡]­«½Æªº¡^RINGRING ¦r¦ê¡A¤¤¤î°õ¦æ¡D³o¬O¦]¬°¬Y¤H¥¿¥´¹q¸Üµ¹§A!

\par
\addvspace{\medskipamount}
\nopagebreak\hrule
\begin{verbatim}
"              \rAT
\end{verbatim} 
\nopagebreak\hrule 
\addvspace{\medskipamount}


¤£´Á«Ý¼Æ¾Ú¾÷¶Ç°e¥ô¦ó°T®§¨Ã¥B°e¥X AT ¦r¦ê¡D

\par
\addvspace{\medskipamount}
\nopagebreak\hrule
\begin{verbatim}
OK-+++\c-OK   ATH0
\end{verbatim} 
\nopagebreak\hrule 
\addvspace{\medskipamount}


³o¤@­Ó¤ñ¸û½ÆÂø¤@ÂI¡A¦]¬°¥¦¨Ï¥Î¤F¬Y¨Ç chat ªº¿ù»~¦^´_¥\¯à¡D

¥¦©Ò¥Nªíªº¬O...´Á«Ý OK ¡A¦pªG¨S¦³¦¬¨ì¡]¦]¬°¼Æ¾Ú¾÷¨Ã¤£¦b«ü¥O¼Ò¦¡¤U¡^¨º»ò°e¥X +++ ¡]¨Ï¼Æ¾Ú¾÷ªð¦^«ü¥O¼Ò¦¡ªº¼Ð·Ç Hayes ¬Û®e¼Æ¾Ú¾÷¦r¦ê¡^¨Ã¥B´Á«Ý OK¡F±µµÛ°e¥X ATH0 ¡]¼Æ¾Ú¾÷±¾Â_¦r¦ê¡^¡D
³oÅý§Aªº«ü¥O½Z¥i¥HÀ³¥I§Aªº¼Æ¾Ú¾÷ÂH¦b½u¤WµLªkÂ_½uªº±¡ªp¡D

\par
\addvspace{\medskipamount}
\nopagebreak\hrule
\begin{verbatim}
TIMEOUT         30
\end{verbatim} 
\nopagebreak\hrule 
\addvspace{\medskipamount}


³]©w«ü¥O½Z¨ä¾l³¡¥÷°õ¦æªº¹O®É®É­­¬° 30 ¬í¡D¦pªG§A´¿¸g¦]¬°¹O®É¦Ó¸gÅç¹L chat «ü¥O½Z³Q²×¤îªº°ÝÃD¡A§â¥¦¼W¥[¬° 45 ¬í©Î§ó¤[¡D

\par
\addvspace{\medskipamount}
\nopagebreak\hrule
\begin{verbatim}
OK              ATDT$TELEPHONE
\end{verbatim} 
\nopagebreak\hrule 
\addvspace{\medskipamount}


´Á«Ý OK ¡]¼Æ¾Ú¾÷¹ï ATH0 «ü¥Oªº¦^À³¡^¨Ã¥B¼·±µ¨ì§Ú­Ì·Q­n©I¥sªº¸¹½X¡D

\par
\addvspace{\medskipamount}
\nopagebreak\hrule
\begin{verbatim}
CONNECT         "
\end{verbatim} 
\nopagebreak\hrule 
\addvspace{\medskipamount}


´Á«Ý CONNECT ¦r¦ê¡]·í»·ºÝ¼Æ¾Ú¾÷¦³¦^À³®É§Ú­Ìªº¼Æ¾Ú¾÷°e¥Xªº¡^¨Ã¥B¤£°e¥X¥ô¦^ÂÐ°T®§¡D

\par
\addvspace{\medskipamount}
\nopagebreak\hrule
\begin{verbatim}
ogin:--ogin:    $ACCOUNT
\end{verbatim} 
\nopagebreak\hrule 
\addvspace{\medskipamount}


¦A¤@¦¸¡A³o¸Ì­±§Ú­Ì¦³¤@¨Ç¿ù»~¦^´_³]©w¡D´Á«ÝÃ±¤J´£¥Ü(...ogin:)¡A¦ý¬O¦pªG§Ú­Ì¦b¹O®É«e¨S¦³±µ¦¬¨ì¡A°e¥X¤@­Óªð¦^¦r¤¸(return)µM«á¦A¦¸§ä´MÃ±¤J´£¥Ü¡D
·í±µ¦¬¨ì´£¥Ü®É¡A°e¥X¨Ï¥ÎªÌ¦WºÙ¡]¦s©ñ¦b¨Ï¥ÎªÌ¬É­±ªº \$ACCOUNT Àô¹ÒÅÜ¼Æ¸Ì¡^¡D

\par
\addvspace{\medskipamount}
\nopagebreak\hrule
\begin{verbatim}
assword:        $PASSWORD
\end{verbatim} 
\nopagebreak\hrule 
\addvspace{\medskipamount}


´Á«Ý±K½X´£¥Ü¨Ã¥B°e¥X±K½X¡]¦A¤@¦¸¡A¦s©ñ¦b¨Ï¥ÎªÌ¬É­±ªº¤@­ÓÀô¹ÒÅÜ¼Æ¸Ì¡^¡D



³o­Ó chat «ü¥O½Z¦³¦X²zªº¿ù»~¦^´_¥\¯à¡D Chat ÁÙ¦³³\¦h­«­nªº¯S¦â¡A¤ñ³o¸Ì©Ò®i¥ÜÁÙ­n§ó¦h¡D
§ó¸Ô²Óªº¸ê°T½Ð°Ñ¾\ chat ªº½u¤W¨Ï¥Î¤â¥U({\ttfamily man 8 chat})¡D




\subsubsection{¦b¦øªA¾¹ºÝ±Ò°Ê PPP}

ÁöµM³o¥÷ {\ttfamily ppp-on-dialer} «ü¥O½Z¹ï©ó¦b§AÃ±¤J«á·|¦Û°Ê±Ò°Ê pppd ªº¦øªA¾¹¨Ó»¡«D±`ªº¦n¥Î¡AµM¦Ó¬Y¨Ç¦øªA¾¹»Ý­n§A©ú¥Õ¦a¦b¦øªA¾¹¤W±Ò°Ê PPP¡D



¦pªG§A»Ý­n¦b¦øªA¾¹¤W¤U«ü¥O¥H±Ò°Ê PPP¡A§A¥²¶·­n½s¿è {\ttfamily ppp-on-dialer} «ü¥O½Z¡D 



 
¦b³o«ü¥O½Zªº§ÀºÝ(¦b password ³o¦æ«á­±)¥[¤W {\bfseries ´Á«Ý °e¥X} ¦r¦ê¹ï - ³o¬O´M§ä§Aªº shell ´£¥Ü²Å¸¹
(¯S§O¤p¤ß¹ï Bourne shell ¦³¯S®í·N¸qªº¦r¤¸ - ¹³¬O \$ »P {[} ©Î ] ¥ª¥k¤è¬A¸¹µ¥)¡D



¤@¥¹ chat §ä¨ì¤F shell ´£¥Ü²Å¸¹¡Achat ¥²¶·¤U«ü¥O¥H±Ò°Ê§A ISP ªº PPP ¦øªA¾¹¡D



¥H§Úªº¨Ò¤l¦Ó¨¥¡A§Úªº PPP ¦øªA¾¹¨Ï¥Î¼Ð·Çªº Linux Bash ´£¥Ü²Å¸¹
\par
\addvspace{\medskipamount}
\nopagebreak\hrule
\begin{verbatim}
[hartr@kepler hartr]$
\end{verbatim} 
\nopagebreak\hrule 
\addvspace{\medskipamount}




¦Ó¥B»Ý­n§Ú¥´

\par
\addvspace{\medskipamount}
\nopagebreak\hrule
\begin{verbatim}
ppp
\end{verbatim} 
\nopagebreak\hrule 
\addvspace{\medskipamount}




¥H±Ò°Ê¦øªA¾¹¤Wªº PPP¡D



¦b¦¹¤¹³\¤@ÂI¿ù»~¦^´_¬O­Ó¦n¥D·N¡A©Ò¥H¦b§Úªº¨Ò¤l¤¤§Ú¥Î
\par
\addvspace{\medskipamount}
\nopagebreak\hrule
\begin{verbatim}
        hartr--hartr    ppp
\end{verbatim} 
\nopagebreak\hrule 
\addvspace{\medskipamount}




³o´N¬O»¡¡A¦pªG§Ú¦b¹O®É«e¨S¦¬¨ì´£¥Ü²Å¸¹¡A°e¥X return ¨Ã¥B¦A¦¸µ¥«Ý´£¥Ü²Å¸¹¡D



¤@¥¹¦¬¨ì´£¥Ü²Å¸¹¡A´N°e¥X {\ttfamily ppp} ¦r¦ê¡D



ª`·N: §O§Ñ¤F¦b«e¤@¦æµ²§ô«e¥[¤W $\backslash$ ¥H«KÅý chat »{¬°³o¾ã­Ó«ü¥O½Z¬O¦b¤@¦æ¸Ì!



¤£©¯ªº¬O¡A¬Y¨Ç¦øªA¾¹·|²£¥Í«D±`¦hÅÜªº´£¥Ü²Å¸¹!
§A¥i¯à¥²¶·¨Ï¥Î minicom ¦hÃ±¤J´X¦¸¥H«K¤F¸Ñ¤°»ò¥i¥H¥Î¨Ó°µ¬°½T©wªº{``}´Á«Ý{''}¦r¦ê¡D




\subsection{¨Ï¥Î©ó PAP/CHAP Åç»{³s½uªº chat «ü¥O½Z}

¦pªG§Aªº ISP  ¨Ï¥Î PAP/CHAP Åç»{¡A¨º»ò§Aªº chat «ü¥O½Z·|Â²³æ±o¦h¡D
§Aªº chat «ü¥O½Z©Ò­n°µªº¥þ³¡¥u¬O¼·±µ¹q¸Ü¡Aµ¥«Ý±µ¤W½u¡AµM«á´NÅý pppd ¥h³B²zÃ±¤J¨Æ©y!

\par
\addvspace{\medskipamount}
\nopagebreak\hrule
\begin{verbatim}
#!/bin/sh
#
# This is part 2 of the ppp-on script. It will perform the connection
# protocol for the desired connection.
#
exec /usr/sbin/chat -v                                  \
        TIMEOUT         3                               \
        ABORT           '\nBUSY\r'                      \
        ABORT           '\nNO ANSWER\r'                 \
        ABORT           '\nRINGING\r\n\r\nRINGING\r'    \
        ''              \rAT                            \
        'OK-+++\c-OK'   ATH0                            \
        TIMEOUT         30                              \
        OK              ATDT$TELEPHONE                  \
        CONNECT         ''                              \
\end{verbatim} 
\nopagebreak\hrule 
\addvspace{\medskipamount}





\subsection{pppd ªº {\ttfamily debug} »P {\ttfamily file option\_file} ¿ï¶µ}

´N¹³§Ú­Ì¤w¸g¬Ý¹Lªº¡A§A¥i¥H¹ï pppd ¨Ï¥Î {\ttfamily -d} ¿ï¶µ¥´¶}°»¿ù°T®§°O¿ý¡D
'{\ttfamily debug}' ¿ï¶µ©M³o­Ó¬O¤@¼Ëªº¡D



¦]¬°§Ú­Ì¥¿¦b¨Ï¥Î·sªº«ü¥O½Z«Ø¥ß·sªº³s½u¡A¥ý©ñµÛ¦¹¿ï¶µ¤£ºÞ¡D
(Äµ§i: ¦pªG§AªººÏºÐªÅ¶¡¤£¤j°÷¡A°O¿ý pppd ªº°T®§¥i¯à·|¤j¶q¼W¥[§Aªº¨t²Î°O¿ýÀÉ¤j¤p¨Ã¨Ï§A¹J¨ì³Â·Ð - ¤£¹L¦b¦¹§A¥²©w·|³s½u¥¢±Ñ¨Ã¹Á¸Õ³\¤[)¡D



¤@¥¹§A°ª¿³¦a»{¬°¤@¤Á¤u§@¥¿±`¡A§A¥i¥H°£¥h¦¹¿ï¶µ¡D



¦pªG§A¤£¬O±q {\ttfamily /etc/ppp/options} ©Î {\ttfamily /etc/ppp/options.ttySx} ÀÉ®×¤¤¥s¥X ppp ¿ï¶µ¡A
¥i¥H¦b pppd ¤W¥Î {\ttfamily file} ¿ï¶µ«ü©wÀÉ®×¦WºÙ - ¨Ò¦p

\par
\addvspace{\medskipamount}
\nopagebreak\hrule
\begin{verbatim}
exec /usr/sbin/pppd debug file options.myserver /dev/ttyS0 38400 \
\end{verbatim} 
\nopagebreak\hrule 
\addvspace{\medskipamount}





\section{´ú¸Õ§Aªº³s½u«ü¥O½Z}

¶}±Ò¤@­Ó·sªº Xterm¡]¦pªG§A¦b X  ©³¤U¡^©Î¶}±Ò¤@­Ó·sªºµêÀÀ¥D±±¥x¨Ã¥B¥H root Ã±¤J¡D



¦b³o­Ó·sªº¶¥¬q§@·~¤¤¡Aµo¥X³o­Ó«ü¥O

\begin{tscreen}
\begin{verbatim}
tail -f /var/log/messages
\end{verbatim}
\end{tscreen}




¡]©Î¬O§A¨t²Î°O¿ýÀÉ®×ªº¥ô¦ó¦WºÙ¡^¡D



¦b²Ä¤@­Óµøµ¡¡]©Î¬OµêÀÀ¥D±±¥x¤¤¡^µo¥X³o­Ó©R¥O

\begin{tscreen}
\begin{verbatim}
ppp-on &
\end{verbatim}
\end{tscreen}




¡]©Î¬O¥ô¦ó§A©Ò½s¿èªº {\ttfamily /usr/sbin/ppp-on} ª©¥»¤§¦WºÙ¡^¡D
¦pªG§A¨S¦³ÂÇ¥Ñ¦b³o­Ó«ü¥Oªº§ÀºÝ«ü©w \& ¨Ï±o«ü¥O½Z¶i¤J­I´º°õ¦æªº¸Ü¡A¨º»ò¦b ppp µ²§ô¡]·í³s½uµ²§ô®É¡^¤§«e§A³£¤£¯à¦^¨ì²×ºÝ¾÷´£¥Ü¤U



²{¦b¤Á´«¨ì°lÂÜ¨t²Î°O¿ýÀÉªºµøµ¡¡D



§A±N·|¨£¨ì¬Y¨Ç¹³¤U¦CªºªF¦è¡]°²©w§A¹ï chat «ü©w {\ttfamily -v} ¨Ã¥B¹ï pppd «ü©w {\ttfamily -d} ¿ï¶µ¡^....
³o¬Oºò¸ò¦b pppd °_°Ê¸ê°T¤§«á°O¿ý¨ì¨t²Î°O¿ýÀÉ®×¸Ìªº chat «ü¥O½Z¤Î¨ä¦^À³:

\par
\addvspace{\medskipamount}
\nopagebreak\hrule
\begin{verbatim}
Oct 21 16:09:58 hwin chat[19868]: abort on (NO CARRIER)
Oct 21 16:09:59 hwin chat[19868]: abort on (BUSY)
Oct 21 16:09:59 hwin chat[19868]: send (ATZ^M)
Oct 21 16:09:59 hwin chat[19868]: expect (OK)
Oct 21 16:10:00 hwin chat[19868]: ATZ^M^M
Oct 21 16:10:00 hwin chat[19868]: OK -- got it
Oct 21 16:10:00 hwin chat[19868]: send (ATDT722298^M)
Oct 21 16:10:00 hwin chat[19868]: expect (CONNECT)
Oct 21 16:10:00 hwin chat[19868]: ^M
Oct 21 16:10:22 hwin chat[19868]: ATDT722298^M^M
Oct 21 16:10:22 hwin chat[19868]: CONNECT -- got it
Oct 21 16:10:22 hwin chat[19868]: send (^M)
Oct 21 16:10:22 hwin chat[19868]: expect (ogin:)
Oct 21 16:10:23 hwin chat[19868]: kepler login: -- got it
Oct 21 16:10:23 hwin chat[19868]: send (hartr^M)
Oct 21 16:10:23 hwin chat[19868]: expect (ssword:)
Oct 21 16:10:23 hwin chat[19868]:  hartr^M
Oct 21 16:10:23 hwin chat[19868]: Password: -- got it
Oct 21 16:10:23 hwin chat[19868]: send (??????^M)
Oct 21 16:10:23 hwin chat[19868]: expect (hartr)
Oct 21 16:10:24 hwin chat[19868]: [hartr -- got it
Oct 21 16:10:24 hwin chat[19868]: send (ppp^M)
Oct 21 16:10:27 hwin pppd[19872]: pppd 2.1.2 started by root, uid 0
Oct 21 16:10:27 hwin pppd[19873]: Using interface ppp0
Oct 21 16:10:27 hwin pppd[19873]: Connect: ppp0 <--> /dev/cua1
Oct 21 16:10:27 hwin pppd[19873]: fsm_sdata(LCP): Sent code 1, id 1.
Oct 21 16:10:27 hwin pppd[19873]: LCP: sending Configure-Request, id 1
Oct 21 16:10:27 hwin pppd[19873]: fsm_rconfreq(LCP): Rcvd id 1.
Oct 21 16:10:27 hwin pppd[19873]: lcp_reqci: rcvd MRU
Oct 21 16:10:27 hwin pppd[19873]: (1500)
Oct 21 16:10:27 hwin pppd[19873]:  (ACK)
Oct 21 16:10:27 hwin pppd[19873]: lcp_reqci: rcvd ASYNCMAP
Oct 21 16:10:27 hwin pppd[19873]: (0)
Oct 21 16:10:27 hwin pppd[19873]:  (ACK)
Oct 21 16:10:27 hwin pppd[19873]: lcp_reqci: rcvd MAGICNUMBER
Oct 21 16:10:27 hwin pppd[19873]: (a098b898)
Oct 21 16:10:27 hwin pppd[19873]:  (ACK)
Oct 21 16:10:27 hwin pppd[19873]: lcp_reqci: rcvd PCOMPRESSION
Oct 21 16:10:27 hwin pppd[19873]:  (ACK)
Oct 21 16:10:27 hwin pppd[19873]: lcp_reqci: rcvd ACCOMPRESSION
Oct 21 16:10:27 hwin pppd[19873]:  (ACK)
Oct 21 16:10:27 hwin pppd[19873]: lcp_reqci: returning CONFACK.
Oct 21 16:10:27 hwin pppd[19873]: fsm_sdata(LCP): Sent code 2, id 1.
Oct 21 16:10:27 hwin pppd[19873]: fsm_rconfack(LCP): Rcvd id 1.
Oct 21 16:10:27 hwin pppd[19873]: fsm_sdata(IPCP): Sent code 1, id 1.
Oct 21 16:10:27 hwin pppd[19873]: IPCP: sending Configure-Request, id 1
Oct 21 16:10:27 hwin pppd[19873]: fsm_rconfreq(IPCP): Rcvd id 1.
Oct 21 16:10:27 hwin pppd[19873]: ipcp: received ADDR
Oct 21 16:10:27 hwin pppd[19873]: (10.144.153.51)
Oct 21 16:10:27 hwin pppd[19873]:  (ACK)
Oct 21 16:10:27 hwin pppd[19873]: ipcp: received COMPRESSTYPE
Oct 21 16:10:27 hwin pppd[19873]: (45)
Oct 21 16:10:27 hwin pppd[19873]:  (ACK)
Oct 21 16:10:27 hwin pppd[19873]: ipcp: returning Configure-ACK
Oct 21 16:10:28 hwin pppd[19873]: fsm_sdata(IPCP): Sent code 2, id 1.
Oct 21 16:10:30 hwin pppd[19873]: fsm_sdata(IPCP): Sent code 1, id 1.
Oct 21 16:10:30 hwin pppd[19873]: IPCP: sending Configure-Request, id 1
Oct 21 16:10:30 hwin pppd[19873]: fsm_rconfreq(IPCP): Rcvd id 255.
Oct 21 16:10:31 hwin pppd[19873]: ipcp: received ADDR
Oct 21 16:10:31 hwin pppd[19873]: (10.144.153.51)
Oct 21 16:10:31 hwin pppd[19873]:  (ACK)
Oct 21 16:10:31 hwin pppd[19873]: ipcp: received COMPRESSTYPE
Oct 21 16:10:31 hwin pppd[19873]: (45)
Oct 21 16:10:31 hwin pppd[19873]:  (ACK)
Oct 21 16:10:31 hwin pppd[19873]: ipcp: returning Configure-ACK
Oct 21 16:10:31 hwin pppd[19873]: fsm_sdata(IPCP): Sent code 2, id 255.
Oct 21 16:10:31 hwin pppd[19873]: fsm_rconfack(IPCP): Rcvd id 1.
Oct 21 16:10:31 hwin pppd[19873]: ipcp: up
Oct 21 16:10:31 hwin pppd[19873]: local  IP address 10.144.153.104
Oct 21 16:10:31 hwin pppd[19873]: remote IP address 10.144.153.51
\end{verbatim} 
\nopagebreak\hrule 
\addvspace{\medskipamount}




¡]ª`·N ¡Ð §Ú¨Ï¥ÎÀRºAªº IP ¸¹½X ¡Ð ¦]¦¹§Úªº¾÷¾¹°e³o¨ÇªF¦è¨ì PPP ¦øªA¾¹¥h ¡Ð ¦pªG§A¨Ï¥Î°ÊºAªº IP ¸¹½X¨º»ò§A±N¤£·|¬Ý¨£³o¨Ç¡D¡^
ÁÙ¦³¡A³o­Ó¦øªA¾¹»Ý­n«ü©wªº©R¥O¨Ó±Ò°Ê PPP¡D



³o¬Ý°_¨Ó¨S¤°»ò°ÝÃD ¡Ð ©Ò¥H¦p¦P«e­±ªº´ú¸Õ¯ë¡A ping ¤@¨Ç IP ¸¹½X¥H¤Î¥D¾÷¦WºÙ¡D

°_°Ê§Aªº¥þ²y¸ê°TÂsÄý¾¹©Î¬O¥ô¦ó¨ä¥¦ªFªF¨Ã¥B¶}©l³} ¡Ð §A¤W½u¤F!




\section{µ²§ô PPP ³sµ²\label{off}}

·í§A§¹¦¨ PPP  ³sµ²¤§«á¡A¥i¥H¨Ï¥Î¼Ð·Çªº {\ttfamily ppp-off} «ü¥O²×¤î¥¦¡]­n°O±o ¡Ð §A±o¬O root ©ÎªÌ¬O PPP  ¸s²Õªº²Õ­û! ¡^



§A±N·|¦b§Aªº¨t²Î°O¿ý¸Ì¬Ý¨£¤@¨Ç¹³³o¼ËªºªºªF¦è:

\par
\addvspace{\medskipamount}
\nopagebreak\hrule
\begin{verbatim}
Oct 21 16:10:45 hwin pppd[19873]: Interrupt received: terminating link
Oct 21 16:10:45 hwin pppd[19873]: ipcp: down
Oct 21 16:10:45 hwin pppd[19873]: default route ioctl(SIOCDELRT): Bad address
Oct 21 16:10:45 hwin pppd[19873]: fsm_sdata(LCP): Sent code 5, id 2.
Oct 21 16:10:46 hwin pppd[19873]: fsm_rtermack(LCP).
Oct 21 16:10:46 hwin pppd[19873]: Connection terminated.
Oct 21 16:10:46 hwin pppd[19873]: Exit.
\end{verbatim} 
\nopagebreak\hrule 
\addvspace{\medskipamount}




§O¾á¤ß¨º­Ó {\ttfamily SIOCDELRT} - ³o¤£¹L¬O pppd ªí¥Ü­nµ²§ô¤F¦Ó¨S¤°»ò¦n¾á¤ßªº¡D




\section{°»¿ù\label{problems}}

§Aªº³s½u¦³¦UºØ¥i¯àªº­ì¦]µLªk¹B§@ ¡Ð  chat µLªk¥¿½T¦a§¹¦¨¡A§Aªº½u¸ôÂø°T«Ü¤jµ¥µ¥¡D
©Ò¥H¡AÀË¬d§Aªº¨t²Î°O¿ý§ä´M½u¯Á¡D




\subsection{§Ú§â PPP ½sÄ¶¶i¥h¦ý¬O Linux »¡§Ú¨S¦³...}

¤@­Ó«D±`±`¨£ªº°ÝÃD¬O¤H­Ì¤w¸g±N PPP ½sÄ¶¨ì®Ö¤ß¤§¤¤¨Ã¥B¹Á¸Õ°õ¦æ pppd¡A¦ý®Ö¤ß¤´µM©ê«è»¡¥¦¤£¤ä´© PPP!
¦³³\¦h­ì¦]¥i¯à¾É­P¦¹¨Æµo¥Í¡D




\subsubsection{§A±Ò°Êªº¬O¥¿½Tªº®Ö¤ß¶Ü?}

ÁöµM§A{\bfseries ¤w¸g}­«·s½sÄ¶®Ö¤ß¥H¤ä´© PPP¡A§A«o¨S¦³±Ò°Ê·sªº®Ö¤ß¡D
³o¥i¯à¬O¦]¬°§A¨S¦³§ó·s {\ttfamily /etc/lilo.conf} ¨Ã­«¶] lilo¡D



ÀË¬dªº¤èªk¬O¤U³o­Ó«ü¥O {\ttfamily uname -a}¡A±N²£¥Í¹³³o¼Ëªºµ²ªG 

\par
\addvspace{\medskipamount}
\nopagebreak\hrule
\begin{verbatim}
Linux archenland 2.0.28 #2 Thu Feb 13 12:31:37 EST 1997 i586
\end{verbatim} 
\nopagebreak\hrule 
\addvspace{\medskipamount}




¥¦µ¹¥X¤F®Ö¤ßªºª©¥»¤Î®Ö¤ß½sÄ¶ªº¤é´Á - ³o¼Ë§A´Nª¾¹D¨ì©³µo¥Í¤F¤°»ò¨Æ¡D




\subsubsection{§A±N PPP ®Ö¤ß¤ä´©½sÄ¶¬°¼Ò²Õ¶Ü?}

¦pªG§A±N PPP ®Ö¤ß¤ä´©½sÄ¶¬°¼Ò²Õ¡A¦ý«o¨S¦³½sÄ¶¤Î¦w¸Ë¼Ò²Õ¡A§A´N·|±o¨ì³o­Ó¿ù»~¡D
¬Ý¤@¤U \onlynameurl{Kernel-HOWTO} ¥H¤Î¦b {\ttfamily /usr/src/linux} ¤Uªº {\ttfamily README} ÀÉ®×!



¥t¤@­Ó¼Ò²Õ³sµ²ªº¥i¯à°ÝÃD¬O§A´Á±æ»Ý­nªº¼Ò²Õ¦Û°Ê¦a³Q¸ü¤J¡A¦ý«o¨S¦³°õ¦æ {\ttfamily kerneld} (·|¦Û°Ê¸ü¤J¨Ã²¾°£¼Ò²Õªº¤u¨ã)¡D
¬Ý¤@¤U \onlynameurl{kerneld mini-HOWTO} ¸Ìªº¸ê°T»¡©ú¦p¦ó³]©w {\ttfamily kerneld}¡D




\subsubsection{§A¬O§_§A¥Î¥¿½Tªº PPP ª©¥»°t¦X§Aªº®Ö¤ß?}

§A{\bfseries ¥²¶·}¨Ï¥Î ppp-2.2 ¥H°t¦X®Ö¤ß 2.0.X¡D
§A¥i¥H¦b®Ö¤ß 1.2.X ¨Ï¥Î ppp-2.2 (¦pªG§A­×¸É¹L®Ö¤ß)§_«h§A¥²¶·¨Ï¥Î ppp-2.1.2¡D




\subsubsection{§A¬O§_¥H root ¨­¥÷°õ¦æ pppd?}

¦pªG§A¤£¬O¥H root ¨­¥÷°õ¦æ pppd (¨Ã¥B pppd ¨Ã¥¼³]©w¬°¥H root ¨­¥÷°õ¦æ)¡A§A´N·|¦¬¨ì¦¹°T®§¡D




\subsection{§Úªº¼Æ¾Ú¾÷³s¤W¤F¦ý PPP ¨Ã¥¼±Ò°Ê}

¦P¼Ë¤]¦³³\¤£ºÉªº­ì¦](°Ñ¦Ò¤@¤U comp.os.linux...)¡D



¤@­Ó{\bfseries ³Ì±`¨£}ªº¿ù»~¬O¦b§Aªº«ü¥O½Z¸Ì§A¤Ö¥´¤F¬Y¨ÇªF¦è¡D
³o¸Ì°ß¤@¥i°µªº¬O§A±N Linux PC »P¦øªA¾¹ªº¹ï¸Ü°O¨ì§Aªº¨t²Î°O¿ý¤¤({\ttfamily /var/log/messages})µM«á{\itshape ¤@¦æ¤@¦æ¦a\/}¬Ý­Ó¥J²Ó¡D
§A¥i¯àÁÙ»Ý­n¦A¦¸¥H¤â°Ê¤èªk¼·¤J¦øªA¾¹ÀË¬d¤@¹M¡D

§A±o­n±qÀY¨ì§À¤p¤ß¦aÀË¬d ¡Ð ¦Ó¥B¤ß¸Ì­n°O±o§Ú­Ì¤HÃþ¦³ºØ¶É¦V¡A¾\Åªªº¬O§Ú­Ì»{¬°§Ú­ÌÁä¤Jªº ¡Ð ¦Ó¤£¬O¯uªº¦b¨º¸Ìªº!




\subsection{¨t²Î°O¿ý»¡ {``}{\ttfamily serial line is not 8 bit clean}...{''}}

³o¤]¦³³\¦hªºÃþ¦ü±¡§Î - ¹³¬O {\ttfamily serial line looped back} µ¥µ¥¡A¾É­Pªº­ì¦]¥i¯à¬O³\¦h¨Æ±¡¤¤ªº¤@¥ó(©Î¤@¨t¦C)¡D



­nª¾¹D¨ì©³µo¥Í¤F¤°»ò¡A¥²¶·¹ï pppd ­I«á°µ¤F¨Ç¤°»ò¦³ÂI¤F¸Ñ¡D



·í pppd ±Ò°Ê«á¡A¥¦·|°e¥X³sµ²±±¨î¨ó©w(link control protocol)«Ê¥]¨ì»·ºÝ¾÷¾¹¡D
¦pªG¥¦¦¬¨ì¦Xªkªº¦^À³¤~·|¨«¨ì¤U¤@¶¥¬q(¨Ï¥Î IPCP - IP ±±¨î«Ê¥])¦Ó¥B¥u¦³¦b³o¨ó°Ó§¹¦¨¤§«á¹ê»Úªº IP ¼h¤~·|«Ø¥ß¦]¦¹§A¤~¯à¨Ï¥Î PPP ³sµ²¡D



¦pªG·í§Aªº PC °e¥X¨ó°Ó«Ê¥]®É¦b»·ºÝ¨S¦³ PPP ¦øªA¾¹¦b¹B§@¡A³o¨Ç«Ê¥]¦b»·ºÝÃ±¤J¹Lµ{¤¤±N³Q¼u¦^¨Ó¡D
¦]¬°³o¨Ç«Ê¥]¬O¨Ï¥Î 8 bits¡A¼u¦^¨Ó®É·|±N²Ä¤K­Ó¦ì¤¸ºI±¼(°O¥ô¡AASCII ¬O¤C¦ì¤¸ªº½X)¡D
PPP ¦]¦¹¦Ó©ê«è¦¹°T®§¡D



¦³³\¦h­ì¦]·|³y¦¨¨ó°Ó«Ê¥]³Q¼u¦^¡D




\subsubsection{§A¨S¦³¥¿½T¦aÃ±¤J¦øªA¾¹}

·í§Aªº chat «ü¥O½Z§¹¦¨«á¡A§Aªº PC ·|±Ò°Ê pppd¡DµM¦Ó¡A¦pªG§A¨Ã¥¼§¹¦¨¦b¦øªA¾¹ªºÃ±¤J¹Lµ{(¥]¬A°e¥X¥ô¦ó¥²­n¦b¦øªA¾¹¤W±Ò°Ê PPP ªº«ü¥O)¡APPP ´N¤£·|¶}©l¡D



¦]¦¹³sµ²±±¨î¨ó©w«Ê¥]³Q¼u¦^§A¤]¦]¦¹¦¬¨ì³o­Ó¿ù»~¡D



§A¥²¶·¤p¤ß¦aÀË¬d¨Ã­×¥¿(¥²­nªº¸Ü)§Aªº chat «ü¥O½Z(°Ñ¨£¤W­±»¡©ú)¡D




\subsubsection{§A¨Ã¥¼±Ò°Ê¦øªA¾¹¤Wªº PPP}

¬Y¨Ç PPP ¦øªA¾¹¦b§A§¹¦¨Ã±¤J¹Lµ{«á»Ý­n§A¿é¤J«ü¥O©Î«ö¤U {\ttfamily RETURN} ¤~·|¦b»·ºÝ±Ò°Ê PPP¡D



ÀË¬d§Aªº chat «ü¥O½Z(°Ñ¨£¤W­±»¡©ú)¡D



¦pªG§A¥H¤â°Ê¤è¦¡Ã±¤J®Éµo²{§A¥²¶·°e¥X {\ttfamily RETURN} ¤~·|¦b»·ºÝ±Ò°Ê PPP¡AÂ²³æ¦a¦b§Aªº chat «ü¥O½Z§ÀºÝ¥[¤WªÅ¥Õªº´Á«Ý/°e¥X¦r¦ê¹ï(ªÅªº°e¥X¦r¦ê¹ê»Ú¤W·|°e¥X {\ttfamily RETURN})¡D




\subsubsection{»·ºÝªº PPP ¹Lµ{±Ò°Ê«ÜºC}

³o¦³ÂI¨à§Þ¥©!



¹w³]ªº±¡ªp¤U§Aªº Linux pppd ³Q½sÄ¶¦¨³Ì¦h°e¥X¤Q­Ó³s½u±±¨î­n¨D«Ê¥]¡D
¦pªG¦øªA¾¹±Ò°Ê¦³ÂIºC¡A¤Q­Ó³s½u«Ê¥]¥i¯à¦b»·ºÝ PPP ·Ç³Æ¦n±µ¦¬«e´N¥þ³¡°e¥X¤F¡D



©ó¬O¦b§Aªº¾÷¾¹¤W¡Apppd ¬Ý¨ì¤Q­Ó«Ê¥]³Q¼u¦^(²Ä¤K¦ì¤¸³QºI¥h)¦Óµ²§ô¡D



¦³¨â­Ó¤èªk¥i¥H¸Ñ¨M¦¹¨Æ:-



¦b§Aªº PPP ¿ï¶µ¤¤¥[¤W {\ttfamily lcp-max-configure 30}¡D
³o¼W¥[ pppd ¦b©ñ±ó«e°e¥Xªº³s½u«Ê¥]ªº³Ì¤j¼Æ¥Ø¡D¹ï¤@­Ó¯uªº«ÜºCªº¦øªA¾¹¨Ó»¡¡A§A¥i¯àÁÙ»Ý­n§ó¦h¡D



©ÎªÌ¡A§A¥i¥H¦^¹L¨Ó¥Î¤@¨Ç§Þ¥©¡D§A©Î³\·|ª`·N¨ì·í§A¥H¤â°ÊÃ±¤J PPP ¦øªA¾¹¨ÃÅý PPP ±Ò°Ê®É¡A¦¬¨ìªº©U§£ªº{\bfseries ²Ä¤@­Ó}¦r§¹Á`¬O tilde(\~{}) ¦r¤¸¡D



§Q¥Î¦¹ÂI§Ú­Ì¥i¥H¦b chat «ü¥O½Z§ÀºÝ¥[¤W·sªº´Á«Ý/°e¥X¦r¦ê¹ï¡A´Á«Ý tilde ¦r¤¸¨Ã¤£°e¥X¥ô¦óªF¦è¡D
³o¬Ý°_¨Ó¹³³o¼Ë:-

\par
\addvspace{\medskipamount}
\nopagebreak\hrule
\begin{verbatim}
\~      ''
\end{verbatim} 
\nopagebreak\hrule 
\addvspace{\medskipamount}




ª`·N: ¦]¬° tilde ¦r¤¸¹ï shell ¨Ó»¡¦³¯S®í·N¸q¡A¥²¶·¥[¶h¥X²Å¸¹(´N¬O«e­±ªº­Ë±×½u)¡D




\subsection{¤£¯à³]¥ß¹w³]»¼°e¸ô®|}

¦pªG pppd ©Úµ´«Ø¥ß¹w³]»¼°e¸ô®|¡A³o¬O¦]¬°(À³¸Ó¨S¿ù)¥¦©Úµ´²¾°£©Î¨ú¥N¤w¦³ªº¹w³]»¼°e¸ô®|¡D



³q±`ªº­ì¦]¬O¦]¬°¬Y¨Ç®M¥ó±N§Aªº¤A¤Óºô¸ô¥d³]¬°¹w³]»¼°e¸ô®|¦Ó¤£¬O³]¬°«ü©wªººô¸ô»¼°e¡D



°Ñ¨£ Linux NAG »P Net2/3 HOWTOs ¸Ìªº¸ê°T¥H¥¿½T¦a³]©w§Aªº¤A¤Óºô¸ô¥d¤Î¬ÛÃöªº»¼°e¡D 



¥t¤@¥i¯à­ì¦]¬O§Aªº°Ï°ìºô¸ô¤w¨Ï¥Î¤F¹h¹D¾¹©Î¸ô¥Ñ¾¹¦Ó¥B§Aªº»¼°eªí®æ¤w³]©w¬°±N¹w³]»¼°e¸ô®|«ü¦V³o¸Ì¡D



­n­×¥¿³oºØ±¡ªp»Ý­n§ó¦hªººô¸ôª¾ÃÑ¦Ó¤w¸g¶W¥X¦¹¥÷ HOWTO ªº½d³ò¤F¡D
«ØÄ³§A¨ú±o¤@¨Ç±M®aªº·N¨£(¸g¥Ñ·s»D²Õ¸s©Î§A©P³ò¥i¥H°Ýªº¤H)¡D




\subsection{¨ä¥¦°ÝÃD}

ÁÙ¦³³\¦h­ì¦]¾É­P PPP µLªk³s±µ©Î¬OµLªk¥¿½T¹B§@¡D



²{¦b¥J²Ó¬Ý¬Ý PPP FAQ ¡]³o¯uªº¬O¤@¨t¦Cªº°ÝÃD»P¦^µª¡^¡D³o¬O¤@¥÷«D±`¸Ô¹êªº¤å¥ó¦Ó¥Bµª®×´N¦b¸Ì­±! 
¥H§Ú¦Û¤v¡]«ÜÄê¡^ªº¸gÅç¡A¦pªG§Aªº°ÝÃDµª®×¤£¦b¨ä¤¤¡A¨º»ò¸Ó°ÝÃD´N¤£¬O PPP ªº¿ù! 
¥H§Ú¬°¨Ò§Ú¨Ï¥Î ELF ®Ö¤ß¦Ó¥B¨S¦³¤É¯Å¾A·íªº®Ö¤ß¼Ò²Õ¡D¦bÀÆ¥ú¥X²{¤§«e§Ú¶È¶È®ö¶O¤F¤j·§¨â¤Ñ¡]¥H¤Î¤@­Ó±ß¤Wªº¤j³¡¤À®É¶¡¡^¶A©G¥h¨º­Ó¨Æ¹ê¤W¤w«D±`¨}¦nªº PPP ¦øªA¾¹¡D




\section{·í§¹¥þ³´©ó½¦µÛ®É¦p¦ó¨ú±oÀ°§U}

¦pªG§A¤£¯à¨Ï§Aªº PPP  ³sµ²¹B§@¡A¦^ÀY­«·s¾\Åª³o¥÷¤å¥ó¨ÃÀË¬d¨C¤@¥ó¨Æ ¡Ð ¦P®É°t¦X "chat -v..." ¥H¤Î "pppd -d"  ¦b§Aªº¨t²Î°O¿ý¸Ì«Ø¥ßªº¿é¥X§@¬°°Ñ¦Ò¡D



¤]­n°Ñ¦Ò PPP  ¥»¨­ªº¤å¥ó¥H¤Î FAQ  ¨Ã¥[¤W¦b¦¹´¿¸g´£¤Îªº¤å¥ó!



¦pªG§A¤´µM³´©ó½¦µÛª¬ºAªº¸Ü¡A¨º»ò¦³¨Ç¯à°÷¦b PPP  ³o¤è­±À°§Aªº¤H·|¦X²zªº¡B¦³³W«ßªº±½´y comp.os.linux.misc »P comp.os.linux.networking ·s»D°Q½×¸s¡A¥H¤Î comp.protocols.ppp¡D



§A¥i¥H¹Á¸Õ±H­Ó¤Hªº¹q¤l¶l¥óµ¹§Ú¡A¦ý§Ú¯uªº¦³¦Û¤vªº¤u§@¡]©M¥Í¬¡¡^¦Ó¥B§Ú¤£«OÃÒ·|«Ü§Ö¦a¦^ÂÐ¡]§Y¨Ï¤£§¹¥þ·|³o¼Ë¡^¦]¬°³o±oµø§Ú¥Ø«eªº¤u§@­t¾á¥H¤Î§Ú¨p¤Hªº¥Í¬¡ª¬ºA¦Ó©w!



¯S§O¬O ¡Ð {\bfseries ¤£­n±i¶K°Å¤U¨Óªº¿ù»~°»´ú¿é¥X¨ì·s»D°Q½×¸s¤W¤]¤£­nÂÇ¥Ñ¹q¤l¶l¥ó±Hµ¹§Ú} ¡Ð «eªÌ®ö¶O¤j¶qªººô¸ôÀW¼e¦Ó«áªÌ±NÂàµ¹ {\ttfamily /dev/null} (°£«D§Ú¯S§O­n¨D±N¥¦±Hµ¹§Ú!)




\section{³sµ²¹B§@¤§«áªº´¶¹M°ÝÃD}

¤@­Ó°ÝÃD¬O§A±N·|µo²{³\¦hªA°È´£¨ÑªÌ¥u¤ä´©¥L­Ìµ¹·s±b¸¹ªº®M¸Ë³s½u³nÅé¡D
³o¡]¨å«¬¡^¬Oµ¹·L³nµøµ¡Àô¹Òªº :-( ¡Ð ¦Ó¥B³\¦hªA°È´£¨ÑªÌªº¤ä´©³B¬Ý¨Ó¤@ÂI³£¤£¤F¸Ñ Unix (or Linux)¡D
©Ò¥H­n¦³·Ç³Æ¡A±q¥L­Ì¨º±o¤£¨ì¤Ó¦h¨ó§U!



§A·íµM¥i¥HÀ°¥L­Ì¤@­Ó¦£¨Ã¥B±Ð¨|¥L­ÌÃö©ó Linux ªºª¾ÃÑ¡]¥ô¦ó ISP ªº¨ó§U¤H­û¦bºô»Úºô¸ô¥Î»y¤¤³£À³¸Ó "ª¾¹D¥¦" ¦Ó³o·N¨ýµÛ¥L­Ì¦b®a¸ÌÀ³¸Ó­n¦³¥x Linux ¾÷¾¹ ¡Ð ·íµM¬O³o¼Ë¡^!




\subsection{§ÚµLªk¬Ý¨£§Ú³s½uªº PPP ¦øªA¾¹¥H¥~ªº¥@¬É}

¦nªº ¡Ð §Aªº PPP  ³s½u¤w«Ø¥ß¨Ã°õ¦æ¤¤¦Ó¥B§A¥i¥HÂÇ¥Ñ¸Ó PPP ¦øªA¾¹ªº IP ¸¹½X¡]ÂÇ¥Ñ {\ttfamily ifconfig ppp0} «ü¥O©ÒÅã¥Üªº²Ä¤G­Ó©Î  "»·ºÝ"  ªº IP ¸¹½X¡^ ping ¸Ó¦øªA¾¹¡A¦ý¬O§A¤£¯àÄ²¤Î¨ä«áªº¥ô¦ó¦a¤è¡D



­º¥ý¡A¹Á¸Õ ping §A¦b {\ttfamily /etc/resolv.conf} ¸Ì«ü©w§@¬°¦WºÙ¦øªA¾¹¨º¥x¾÷¾¹ªº IP ¸¹½X¡D
¦pªG¥i¥Hªº¸Ü¡A¨º»ò§A´N{\bfseries ¥i¥H}¨£¨ì¦b§A PPP  ¦øªA¾¹¤§¥~ªºªF¦è¡]°£«D³o­Ó IP ¸¹½X¸ò§A³s½uªº "»·ºÝ" IP ¸¹½X¬Û¦P¡^¡D
©Ò¥H²{¦b¨Ó¸Õ¸Õ ping §AªºªA°È´£¨ÑªÌªº§¹¾ãºô»Úºô¸ô¦WºÙ ¡Ð ¨Ò¦p

\begin{tscreen}
\begin{verbatim}
ping my.provider.net.au
\end{verbatim}
\end{tscreen}




¦pªG³o¼ËµLªk¦¨¥\¡A¨º»ò§A¦³­Ó¦WºÙ¸ÑªR¤Wªº°ÝÃD¡D³o¥i¯à¬O¦]¬°¦b§Aªº {\ttfamily /etc/resolv.conf} ÀÉ®×¸Ì¦³¥´¦r¿ù»~¡D
¥´¹q¸Üµ¹§AªºªA°È´£¨ÑªÌ¹ï·Ó©Ò±oªº¸ê°T¨Ã¥B¤p¤ß¦aÀË¬d³o­ÓÀÉ®×¡D¦pªG¬Ý°_¨Ó¥þ³£¨S°ÝÃD¡A¦A¥´¹q¸Üµ¹ªA°È´£¨ÑªÌ½T©w§A¼g¤U¥¿½Tªº IP ¸¹½X¡r



¦pªG¥¦¤´µMµLªk¹B§@¡]¦Ó¥B§AªºªA°È´£¨ÑªÌ½T»{¥Lªº¦WºÙ¦øªA¾¹¦³¶}¾÷¨Ã¥B¥¿¦b°õ¦æ¡^¡A¨º»ò§Aªº°ÝÃD¦b¨ä¥¦ªº¦a¤è ¡Ð ¦Ó¥B§Ú«ØÄ³§A¤p¤ß¦a±qÀY¨ì§ÀÀË¬d§A¦w¸Ëªº Linux¡]¯S§Oª`·NÀÉ®×Åv­­¡^¡D



¦pªG§A¤´µM¤£¯àÂÇ¥Ñ IP ¸¹½X ping §AªA°È´£¨ÑªÌªº¦WºÙ¦øªA¾¹¡A¨º»ò¤£¬O¥L­ÌÃö±¼¾÷¾¹¡]¥´­Ó¹q¸Üµ¹¥L­Ì½T©w¤@¤U¡^´N¬O¦³­Ó»¼°e°ÝÃDµo¥Í¦b§AªºªA°È´£¨ÑªÌ¨ºÃä¡D
¦A¤@¦¸¡A¥´¹q¸Üµ¹¥L­Ì¬d°Ý¬Ý¬Ý¡D



¦³­Ó¥i¯à¬O "»·ºÝ" ¬O¤@¥x Linux PPP ¦øªA¾¹¦Ó¦b¨ä®Ö¤ß¸Ì¨S¦³«ü©w IP forwarding ¿ï¶µ!



¤@­Ó¨}¦nªº´ú¸Õ¤èªk¬O¨Ï¥Î¤j¦h´£¨Ñµ¹¡]¤@¾ã®M¡^ Microsoft Windows ªº³nÅé¹Á¸Õ¶i¤J§AªºªA°È´£¨ÑªÌ¡D
¦pªG§¹¥þ¬Û¦Pªº±b¸¹¦b¥t¥~¤@®M§@·~¨t²Î¤U¤@¤Á¥¿±`¡A¨º»ò°ÝÃD¬O¦b§Aªº Linux  ¨t²Î¤W¦Ó¤£¬O¦b§AªºªA°È´£¨ÑªÌ¨ºÃä¡D




\subsection{§Ú¥i¥H±H°e¹q¤l¶l¥ó¡A¦ý¤£¯à±µ¦¬}

¦pªG§A¨Ï¥Î°ÊºAªº IP ¸¹½X¡A³o¬O«Ü¥¿±`ªº¡D°Ñ¾\¤U­±ªº "\ref{dynamic-server} {(³]¥ßªA°È)}" ¤@¸`¡D




\subsection{¬°¤°»ò¤H­Ì¤£¯à¨Ó§Úªº¾÷¾¹ finger, WWW, gopher, talk µ¥µ¥?}

¦P¼Ë¦a¡A¦pªG§A¨Ï¥Î°ÊºAªº IP ¸¹½X¡A³o¬O«D±`¥¿±`ªº¡D
°Ñ¾\¤U­±ªº "\ref{dynamic-server} {(³]¥ßªA°È)}"¸Ó¸`¡D




\section{¥H°ÊºA IP ´£¨Ñºô»Úºô¸ôªA°È\label{dynamic-server}}

¦pªG§A¨Ï¥Î°ÊºAªº IP ¸¹½X¡]³\¦hªA°È´£¨ÑªÌ¤]¥u´£¨Ñ°ÊºAªº IP ¸¹½X°£«D§A¬°§Aªº³s½u¥I¥X§ó¦h¥N»ù¡^¡A¨º»ò§A¥²¶·»{ÃÑ³oÁô§tªº­­¨î¡D



­º¥ý¡A¥~°eªA°È½Ð¨D±N¤£·|¦³°ÝÃD¡D³o¬O»¡§A¥i¥H¨Ï¥Î sendmail °e¥X¹q¤l¶l¥ó¡A±q»·ºÝ¸`ÂI¶Ç¿é(ftp)ÀÉ®×¡A ½Õ¬d(finger)¦b¨ä¥¦¾÷¾¹¤Wªº¨Ï¥ÎªÌ¡AÂsÄý¥þ²y¸ê°Tºôµ¥µ¥¡D



¯S§O¬O¡AÁöµM§A¤£¦b½u¤W¦ý§A¥i¥H¦^ÂÐ±a¦^§A¾÷¾¹¤Wªº¹q¤l¶l¥ó¡D¶l¥ó±N³æ¯Â¦a¥á¦b§Aªº¶l»¼¦î¦C¤¤ª½¨ì§A¼·¦^§Aªº ISP ¦A¦æ°e¥X¡D



µM¦Ó¡A§Aªº¾÷¾¹¨Ã«D¤@¤Ñ 24 ¤p®É³£³s±µ¦bºô»Úºô¸ô¤W¡A¥¦¨C¦¸³s½u¤]¤£·|¾Ö¦³¬Û¦Pªº IP ¸¹½X¡D
©Ò¥H§A¤£¥i¯à±µ±o¨ìª½±µ±H¨ì§A¾÷¾¹ªº¹q¤l¶l¥ó¡A¨Ã¥B«ÜÃø³]¥ß¤@¥x¥þ²y¸ê°T¦øªA¾¹©ÎÀÉ®×¶Ç¿é¦øªA¾¹! 
¦]¬°ºô»Úºô¸ô»P§Aªº¾÷¾¹¤£¦s¦b¤@ºØ°ß¤@ªº¡A¥Ã¤[¥i¥HÁpÃ´ªºÃö«Y¡A¦]¬°§Aªº¾÷¾¹¨Ã¨S¦³°ß¤@ªº IP ¸¹½X(°O¦í - ¨ä¥¦ªº¾÷¾¹¤]·|¨Ï¥Î³o¨Ç IP ¸¹½X¡A·í¥¦­Ì¼·¤W½u®É)¡D



¦pªG§A³]¥ß¤@¥x WWW¡]©Î¥ô¦ó¨ä¥¦¦øªA¾¹¡^¡A¦bºô»Úºô¸ô¤Wªº¥ô¦ó¤H³£§¹¥þ¤£·|ª¾¹D°£«D¥L­Ìª¾¹D§Aªº¾÷¾¹²{¦b¥¿¦b½u¤W¥H¤Î¥¦½T¹ê¡]¥Ø«e¡^ªº IP ¸¹½X¡D
¥L­Ì¦³³\¦hºÞ¹D¥i¥H±o¨ì³o¶µ¸ê°T¡A¥]¬A¥Ñ§A¥´¹q¸Üµ¹¥L­Ì¡A±Hµo¹q¤l¶l¥ó§i¶D¥L­Ì©ÎªÌ¬O¦b§AªA°È´£¨ÑªÌªº±b¸¹¤W¥©§®¦a¨Ï¥Î ".plan" ÀÉ®×¡]°²³]§Aªº´£¨ÑªÌ¤¹³\ shell ¤Î finger ¦s¨ú¡^¡D



²{¦b¡A¹ï¤j³¡¤Àªº¨Ï¥ÎªÌ¦Ó¨¥¡A³o¤£¬O­Ó°ÝÃD ¡Ð ¤j³¡¤À¤H­Ì©Ò·Q­n°µªº¥þ³¡¥u¬O±H°e»P±µ¦¬¹q¤l¶l¥ó¡]¨Ï¥Î¦b§AªA°È´£¨ÑªÌ¤Wªº±b¸¹¡^¥H¤Î³s½u¨ì¥þ²y¸ê°Tºô¡A¶Ç¿éÀÉ®×¥H¤Î¨ä¥¦ºô»Úºô¸ô¤WªºªA°È¡D
¦pªG§A¥²¶·¾Ö¦³¥Ñ¥~©¹¤ºªº³s½uªA°È¡A§A¯uªºÀ³¸Ó¨ú±oÀRºAªº IP ¸¹½X¡D¥t¥~¤@ºØ¤èªk¬O¬ã¨s«e­±´£¥Ü¹Lªº¤èªk...




\subsection{³]©w¹q¤l¶l¥ó}

§Y¨Ï¬O°ÊºAªº IP ¸¹½X¡A§Aªº½T¥i¥H°t¸m§A¾÷¾¹¤Wªº sendmail ¨Ó°e¥X§A¦b¥»¦aºÝ¼g¦nªº¥ô¦ó¹q¤l¶l¥ó¡D
¦³Ãö sendmail ªº°t¸m¥i¯à·|¬O«Ü§t½k¦Ó¥B«Ü§xÃøªº ¡Ð ©Ò¥H³o¥÷¤å¥ó¤£·|¸Õ¹Ï§i¶D§A¸Ó«ç»ò°µ¡D
µM¦Ó¡A§A¥i¯àÀ³¸Ó°t¸m§Aªº sendmail ¥H«K§Aªººô»Úºô¸ôªA°È´£¨ÑªÌ¯à±Â©R§A§@¬° "smart relay" ¥D¾÷¡]¦b {\ttfamily sendmail.cf} ªº {\bfseries DS} ¿ï¶µ¡^¡D¡]§ó¬°¸Ô²Óªº°t¸m¸ê°T½Ð°Ñ¾\ sendmail ªº¤å¥ó ¡Ð ¨Ã¸Ô¾\ÀHªþ©ó sendmail ªº m4 °t¸m¥¨¶°¡D´X¥G¥i¥H½T©w¸Ì­±¤@©w¦³¤@­Ó¯à²Å¦X§Aªº»Ý­n¡^¡D



¤]¦³¤@¥»«D±`¦nªº®Ñ¦bÁ¿ Sendmail(O'Reilly and Associates ºÙ¥¦¬° '¸t¸g')¡A¦ý¹ï¤j³¡¥÷ªº¨Ï¥ÎªÌ¨Ó»¡¹ê¦b¤Ó¹L§xÃø¤F!



¤@¥¹§A°t¸m¦n sendmail «á¡A§A¥i¯à·Q¦b PPP ³s½u­è¤@°_°Êªº®É­Ô´N­n sendmail »°§Ö°e¥X¥ô¦ó«Ý¦b¶l¥ó¦î¦C¸Ìªº°T®§¡D
­n³o»ò°µªº¸Ü¡A¥[¤J³o¦æ«ü¥O

\begin{tscreen}
\begin{verbatim}
sendmail -q &
\end{verbatim}
\end{tscreen}




¨ì§Aªº {\ttfamily /etc/ppp/ip-up} «ü¥O½Z¤¤(°Ñ¨£¤U­±»¡©ú)¡D



¥Ñ¥~©¹¤ºªº¹q¤l¶l¥ó¹ï°ÊºAªº IP ¸¹½X¦Ó¨¥¬O­Ó°ÝÃD¡D³B²z³o­Ó°ÝÃDªº¤èªk¬O:
\begin{itemize}
\item °t¸m§Aªº¨Ï¥ÎªÌ¶l»¼µ{¦¡Åý©Ò¦³°e¥X¥hªº¶l¥ó¦b "reply to" ªíÀY¤¤¦³­Ó¦b§Aªººô»Úºô¸ôªA°È´£¨ÑªÌ¤Wªº¹q¤l¶l»¼¦ì§}¡D\\ 
¦pªG¥i¥Hªº¸Ü¡A§A¤]À³¸Ó±N§Aªº FROM ¦a§}³]¬°§A ISP ´£¨Ñªº¹q¤l¶l»¼¦ì§}¡D
\item ¨Ï¥Î popclient µ{¦¡±q§AªºªA°È´£¨ÑªÌ¨ºÃäÂ^¨ú§Aªº¹q¤l¶l¥ó¡D©ÎªÌ¡A¦pªG§Aªº ISP ¨Ï¥Î IMAP¡A¨Ï¥Î¤ä´© IMAP ªº¨Ï¥ÎªÌ¶l»¼µ{¦¡(¨Ò¦p pine)¡D
\end{itemize}




§A¥i¥HÂÇ¥Ñ¦b {\ttfamily /etc/ppp/ip-up} «ü¥O½Z¤¤©ñ¤J¥²­nªº«ü¥O¥H«K¦b¼·±µ®É±N³o­Ó¹Lµ{¦Û°Ê¤Æ(°Ñ¨£¤U­±»¡©ú)¡D




\subsection{³]©w¥»¦aªº¦WºÙ¦øªA¾¹}

ÁöµM§A¤j¥i¨Ï¥Î¦b§A ISP  ¨º¸Ìªº»â°ì¦WºÙ¦øªA¾¹¡A§A¤]¥i¥H³]¥ß¤@¥x¥»¦aªº¼È¦s±M¥Î¡]¦¸­n¡^¦WºÙ¦øªA¾¹¡A¨ÃÂÇ¥Ñ {\ttfamily ip-up} «ü¥O½Z±Ò°Ê¡D
¶]¥»¦a¡]¼È¦s±M¥Î¡^¦WºÙ¦øªA¾¹ªº¦n³B¬O¦pªG§A¦b³s½u´Á¶¡±`±`ÁpÃ´¬Û¦Pªº¸`ÂI¨º»ò¥¦¥i¥H¸`¬Ù§Aªº®É¶¡¡]¥H¤ÎÀW¼e¡^¡D



¼È¦s±M¥Î¦WºÙ¦øªA¾¹¡]¦b {\ttfamily named.boot} ÀÉ®×¸Ì¨Ï¥Î¤@¦æ  'forwarders' «ü¦V§A ISPs ªº DNS¡^ªº¦WºÙ¦øªA¾¹°t¸m¤ñ¸ûÂ²³æ¡D 
O'Reilly book (DNS and Bind) ¸ÑÄÀ©Ò¦³§A»Ý­nª¾¹DªºªF¦è¡D



¤]¦³¤@¥÷ \onlynameurl{DNS-HOWTO} ¥i¥H¨ú±o¡D



¦pªG§A¦³¤@¤p«¬°Ï°ìºô¸ô¸g¥Ñ§Aªº Linux PC ¨ú¥Îºô»Úºô¸ô(¨Ò¦p¨Ï¥Î IP °°¸Ë)¡A
¦b¥»¦aºÝ°õ¦æ¦WºÙ¦øªA¾¹(¨Ï¥Î forwarders ¾É¦V)·|¬O­Ó¦n¥D·N¡A¦]¬°¥¦·|­°§C¥Ñ¦WºÙ¸ÑªR©Ò¦û¥Îªººô¸ôÀW¼e¤Î©µ¿ð®É¶¡¡D



ºô¸ô§@·~ªº¤@­Ó­nÂI: ·í§A­n¦b§A ISP ªº»â°ì¸Ì¶}©l±Ò¥Î¤@¥x¦¸­nªº¡A¼È¦s±M¥Îªº¦WºÙ¦øªA¾¹¤§«e¥ý¸ß°Ý§Aªº ISP ¬ÛÃöªºÅv­­¡D
¥¿½T°t¸m¥¦¡A§Aªº DNS ¤@ÂI³£¤£·|³y¦¨§A ISP  ªº§xÂZ¡A¦ý¬O¦pªG§A°µ¿ù¤F¨Ç¤°»ò¡A¥¦¥i¯à·|¤Þ°_³Â·Ð...




\section{¨Ï¥Î PPP ³sµ²¨â­Óºô¸ô\label{WAN}}

°ò¥»¤W³sµ²³æ¤@¥x Linux PC ¨ì PPP  ¦øªA¾¹¥H¤Î¨Ï¥Î PPP ³sµ²¨â­Ó°Ï°ìºô¸ô¨S¦³¤°»ò®t§O¡D°O±o¡APPP ¬O¤@ºØ{\bfseries ÂI¹ïÂI}ªº¨ó©w¡D



µM¦Ó¡A§A{\bfseries ªº½T}±oÁA¸ÑÃö©ó»¼°e¸ô®|¦p¦ó«Ø¥ßªº°ÝÃD¡D¾\Åª NET-2 howto ¥H¤Î Linux Network Administrator Guide (NAG)¡D
§A¤]±Nµo²{³o¥»®Ñ "TCP/IP Network Administration" (by O'Reilly and Assoc -  ISBN 0-937175-82-X)·|¦³·¥¨ÎªºÀ°§U¡D



¦pªG§A·Q¦b³sµ²ªº¬Y¤@Ãä¨Ï¥Î¤@­Óºô¸ô¸¹½Xªº¦¸ºô¸ô¤À³Î¡A§A·|µo²{ Linux (draft) sub networking mini-howto º¡¦³¥Îªº¡D
³o¥i¦b \nameurl{http://www.interweft.com.au/other/}{Linux Sub networking mini-HOWTO} §ä¨ì¡D



¬°¤F³sµ²¨â­Ó°Ï°ìºô¸ô¡A§A¨Ï¥Îªº{\bfseries ¥²¶·}¬O¤£¦Pªº IP ºô¸ô½s¸¹(©Î¬O¦P¼Ëºô¸ô½s¸¹ªº¦¸ºô¸ô)¦Ó¥B§A±N±o¨Ï¥ÎÀRºAªº IP ¸¹½X ¡Ð ©Î¨Ï¥Î IP °°¸Ë¡D
¦pªG§A·Q­n¨Ï¥Î IP °°¸Ëªº¸Ü¡A°Ñ¾\ IP masquerade mini-howto ¦³Ãö¥¦ªº³]©w¤¶²Ð¡D




\subsection{³]©w IP ¸¹½X}

»P¨ä¥¦°Ï°ìºô¸ôªººô¸ôºÞ²zªÌ¨ó°Ó¨âºÝªº PPP ¬É­±¨Ï¥Îªº IP ¸¹½X¡D
¦pªG§A¨Ï¥ÎÀRºAªº IP ¸¹½X¡A³o¥i¯à¤]·|­n¨D§A¼·±µ¯S©wªº¹q¸Ü¸¹½X¡D



²{¦b½s¿è¾A·íªº {\ttfamily /etc/ppp/options[.ttyXX]} ÀÉ®× ¡Ð ¹ï©ó¦¹³s½u¦b§A³o¤@ºÝ¨Ï¥Î¯S©wªº¼Æ¾Ú¾÷¤Î¦ê¦C°ð¬O­Ó¦n¥D·N¡D
§A¥i¯à¤]±o­n¥hÅÜ§ó§Aªº {\ttfamily /etc/ppp/options} ÀÉ®× ¡Ð ¨Ã¥B¤]­n¬°¥ô¦ó¨ä¥¦ªº³s½u«Ø¥ß¾A·íªº {\ttfamily options.ttyXX} ÀÉ®×!



¦b¾A·íªº¿ï¶µÀÉ®×¸Ì«ü©w PPP ³s±µ¤¤§A³oºÝªº IP ¸¹½X¡A³o»P«e­±©Ò®i¥Ü¨Ï¥ÎÀRºA IP ¸¹½X¼·±µªº¤è¦¡§¹¥þ¬Û¦P¡D




\subsection{³]©w»¼°e¸ô®|}

§A¥²¶·¦w±Æ§A°Ï°ìºô¸ô¤Wªº«Ê¥]¸g¹L PPP ³sµ²©Ò«Ø¥ßªº¬É­±»¼°e¥X¥h¡D³o¬O­Ó¨â¶¥¬qªº¹Lµ{¡D



­º¥ý¡A§A¥²¶·«Ø¥ß±q°õ¦æ PPP ³sµ²ªº¾÷¾¹¨ì³sµ²ªº»·¤èºô¸ô¥hªº»¼°e¸ô®|¡D
¦pªG¸Ó³sµ²³q©¹ºô»Úºô¸ô¡A¨º»ò³o¥i¥HÂÇ¥Ñ pppd ªº¿ï¶µ 'defaultroute' ¥Ñ¥¦¦Û¤v«Ø¥ßªº¹w³]»¼°e¸ô®|¨Ó³B²z¦Ó§A¤£¥²°µ¥ô¦ó¨Æ¡D



µM¦Ó¦pªG¸Ó³sµ²¥u¬O³sµ²¨â­Ó°Ï°ìºô¸ô¡A¨º»ò¥²¶·¥[¤J¤@­Ó«ü©wªººô¸ô»¼°e¸ô®|¡D
³o¬O¦b {\ttfamily /etc/ppp/ip-up} «ü¥O½Z¤¤¨Ï¥Î 'route' «ü¥O°õ¦æªº¡]°Ñ¾\³s½u°_°Ê¤§«á... ¸Ó¸`¸Ì¦³Ãö¦p¦ó°õ¦æªº¤¶²Ð¡^¡D



§A±o°µªº²Ä¤G¥ó¨Æ¬O§i¶D¦b§A°Ï°ìºô¸ô¤Wªº¨ä¥¦¹q¸£³o¥x Linux ¹q¸£¹ê»Ú¤W¬O¸Ó ppp ³sµ²¤¤³q©¹»·¤èºô¸ôªº'¹h¹D'¡D



·íµM¡A³o¨Ç¤u§@¸Ó³sµ²¥t¤@ºÝªººô¸ôºÞ²zªÌ¤]¥þ³£±o°µ!
µM¦Ó¡A¦]¬°¦o/¥L¥²¶·±N«Ê¥]»¼°e¨ì§Aªººô¸ô¡A¤@­Ó{\bfseries «ü©wªººô¸ô»¼°e¸ô®|}¬O¥²­nªº¡A¦Ó¤£¬O¹w³]»¼°e¸ô®|(°£«D»·ºÝªº°Ï°ìºô¸ô¬O³s¤W§A¥h¨ú¥Îºô»Úºô¸ôªº)¡D




\subsection{ºô¸ô¦w¥þ}

¦pªG§A¨Ï¥Î PPP ³sµ²§Aªº°Ï°ìºô¸ô¨ìºô»Úºô¸ô¤W¥h ¡Ð ©Î¬Æ¦Ü¥u¬O¨ì¤@­Ó{``}¥~­±ªº{''}°Ï°ìºô¸ô¤W¥h¡A§A³£¥²¶·¦Ò¼{¦w¥þ©Êªº°ÝÃD¡D
§Ú±j¯P¹ªÀy§A¦Ò¼{³]¥ß¤@¥x¨¾¤õÀð!



§AÁÙÀ³¸Ó¦b¥H¦¹¤è¦¡³s¨ì¥~­±ªº°Ï°ìºô¸ô©Îºô»Úºô¸ô{\bfseries ¤§«e}¥ý§i¶D§Aªº°Ï°ìºô¸ôºÞ²zªÌ¡D
¨S¦³³o¼Ë°µªº¸Ü¥i¯à¨Ï§A·S¤WÄY­«ªº³Â·Ð!




\section{«Ø¥ß³sµ²¤§«á - {\ttfamily /etc/ppp/ip-up} «ü¥O½Z\label{ip-up}}

¤@¥¹ PPP ³sµ²«Ø¥ß«á¡A pppd ·|§ä´M {\ttfamily /etc/ppp/ip-up} «ü¥O½Z¡D
¦pªG³o­Ó«ü¥O½Z¦s¦b¨Ã¥B¥i¥H°õ¦æªº¸Ü¡A¨º»ò PPP  ¦øªAµ{¦¡´N·|°õ¦æ³o­Ó«ü¥O½Z¡D
³o¤¹³\§A¦Û°Ê°õ¦æ¥ô¦ó¥i¯à¦³¥²­nªº¯S®í»¼°e¸ô®|«ü¥O¤Î¥ô¦ó§A·Q¦b¨C¦¸ PPP ³sµ²±Ò°Ê®É°õ¦æªº°Ê§@¡D



³o¤£¹L´N¬O¤@¯ë´¶³qªº shell «ü¥O½Z¡A¥i¥H°µ¥ô¦ó«ü¥O½Z¯à°µªº¨Æ(¤]´N¬O¡A¥ô¦ó§A·Q°µªº¨Æ)¡D



¨Ò¦p¡A§A¥i¯à·Q­n sendmail »°§Ö³B²z¦b¶l¥ó¦î¦C¤¤µ¥«Ý¥~°eªº°T®§¡D



Ãþ¦ü¦a¡A§A¥i¥H¦b {\ttfamily ip-up} ¸Ì´¡¤J¤@¨Ç«ü¥O¨ú±o¡]¨Ï¥Î POP¡^¦b§Aªº ISP ¨ºÃäµ¥µÛ§Aªº¥ô¦ó¹q¤l¶l¥ó¡D



¤£¹L¦b {\ttfamily /etc/ppp/ip-up} ¤]¦³¨Ç­­¨î:-

\begin{itemize}
\item ¥¦¥H§½­­ªºÀô¹ÒÅÜ¼Æ¥H¼W¥[¦w¥þ©Ê¡D³o¤]´N¬O»¡§A¥²¶·µ¹¥X°õ¦æÀÉªº¥þ³¡¸ô®|¦WºÙµ¥¡D
\item §Þ³N¤W¨Ó»¡¡A{\ttfamily /etc/ppp/ip-up} ¬O¤@­Ó{\itshape µ{¦¡\/}¦Ó«D«ü¥O½Z¡D
³o¬O»¡¥¦¥i¥H³Qª½±µ°õ¦æ - ¤]¦]¦¹¥¦¦b²Ä¤@¦æ¶}©l¥²¶·¨ã¦³¼Ð·Çªº file magic ({\ttfamily \#!/bin/bash}) ¨Ã¥B¯à³Q root Åª¨ú¤Î°õ¦æ¡D
\end{itemize}





\subsection{¯S®í»¼°e¸ô®|}

¦pªG§A³sµ²ªº¬O¨â­Ó°Ï°ìºô¸ô¡A§A±N±o³]¥ß¤@­Ó¨ì '¥~­±ªº' °Ï°ìºô¸ôªº«ü©w»¼°e¸ô®|¡D
³o¥i¥H«Ü®e©öªº¨Ï¥Î {\ttfamily /etc/ppp/ip-up} «ü¥O½Z¹F¦¨¡D°ß¤@ªº§xÃøµo¥Í¦b§Aªº¾÷¾¹¦³¦h­Ó PPP  ³sµ²®É¡D



³o¬O¦]¬° {\ttfamily /etc/ppp/ip-up} ³o­Ó«ü¥O½Z¬O¥Ñ¨C¤@­Ó°_°Êªº ppp ³s½u©Ò°õ¦æªº¡A©Ò¥H§A±o­n¤p¤ß¦a¬°¨C¤@­Ó°_°Êªº³sµ²°õ¦æ¥¿½Tªº»¼°e«ü¥O!




\subsection{³B²z¹q¤l¶l¥ó¦î¦C}

·í¨â­Ó°Ï°ìºô¸ôªº³sµ²«Ø¥ß¤§«á¡A§A¥i¯à·Q­n½T©w©ñ¦b¦î¦C¤¤ªº¹q¤l¶l¥ó³Q{\itshape ²M¥X\/} - °e¨ì¥¦ªº¥Øªº¦a¡D
³o¥i¥H¥Î¾A·íªº©I¥s {\ttfamily sendmail} ¨Ó¹F¦¨¡D 



¦b pppd ¶Ç»¼µ¹«ü¥O½Zªº¯S©w°Ñ¼Æ¤W¨Ï¥Î bash ªº `case' ±Ô­z¨Ó§¹¦¨³o­Ó¤u§@¡D
¨Ò¦p¡A³o¬O§Ú¥Î¨Ó³B²z§Ú­Ìªº¼s°ìºô¸ô³sµ²¤Î³q©¹§Ú®a¤A¤Óºô¸ôªº¡]¤]¬O¥Ñ¬Û¦Pªº PPP  ¦øªA¾¹³B²z¡^{\ttfamily /etc/ppp/ip-up} «ü¥O½Z¡D




\subsection{¤@­Ó {\ttfamily /etc/ppp/ip-up} «ü¥O½Zªº¨Ò¤l}

¤U­±ªº¨Ò¤l´£¨Ñ¤£¦Pªº¨Ï¥Î½d¨Ò¡D

\par
\addvspace{\medskipamount}
\nopagebreak\hrule
\begin{verbatim}
#!/bin/bash
#
# Script which handles the routing issues as necessary for pppd
# Only the link to Newman requires this handling.
#
# When the ppp link comes up, this script is called with the following
# parameters
#       $1      the interface name used by pppd (e.g. ppp3)
#       $2      the tty device name
#       $3      the tty device speed
#       $4      the local IP address for the interface
#       $5      the remote IP address
#       $6      the parameter specified by the 'ipparam' option to pppd
#
case "$5" in
# Handle the routing to the Newman Campus server
        202.12.126.1)
                /sbin/route add -net 202.12.126.0 gw 202.12.126.1
# and flush the mail queue to get their email there asap!
                /usr/sbin/sendmail -q &
                ;;
        139.130.177.2)
# Our Internet link
# When the link comes up, start the time server and synchronise to the world
# provided it is not already running
                if [ ! -f /var/lock/subsys/xntpd ]; then
                        /etc/rc.d/init.d/xntpd.init start &
                fi
# Start the news server (if not already running)
                if [ ! -f /var/lock/subsys/news ]; then
                        /etc/rc.d/init.d/news start &
                fi
                ;;
        203.18.8.104)
# Get the email down to my home machine as soon as the link comes up
# No routing is required as my home Ethernet is handled by IP
# masquerade and proxyarp routing.
                /usr/sbin/sendmail -q &
                ;;
        *)
esac
exit 0
\end{verbatim} 
\nopagebreak\hrule 
\addvspace{\medskipamount}




°_°Ê³q©¹§Ú­Ì Newman ®Õ¶éªº ppp ³sµ²¥H¤Î³o­Ó«ü¥O½Zªºµ²ªG¡A§Ú­Ì³Ì«á±o¨ì¤U­±³o­Ó»¼°eªí®æ°O¿ý¡]³o¥x¾÷¾¹¤]¬O§Ú­Ì³q±`¥Îªº PPP ¦øªA¾¹¨Ã¥B³B²z§Ú­Ìªººô»Úºô¸ô³sµ²¡^¡D
§Ú¤w¸g¦b³o­Ó¿é¥X¸Ì¥[¤J¤@¨Çµù¸Ñ¥H¸ÑÄÀ¨C­Ó¶µ¥Ø¬O¤°»ò:

\par
\addvspace{\medskipamount}
\nopagebreak\hrule
\begin{verbatim}
[root@kepler /root]# route -n
Kernel routing table
Destination     Gateway         Genmask         Flags MSS    Window Use Iface
# the HOST route to our remote internet gateway
139.130.177.2   *               255.255.255.255 UH    1500   0      134 ppp4
# the HOST route to our Newman campus server
202.12.126.1    *               255.255.255.255 UH    1500   0       82 ppp5
# the HOST route to my home ethernet
203.18.8.104    *               255.255.255.255 UH    1500   0       74 ppp3
# two of our general dial up PPP lines
203.18.8.64     *               255.255.255.255 UH    552    0        0 ppp2
203.18.8.62     *               255.255.255.255 UH    552    0        1 ppp1
# the specific network route to the Newman campus LAN
202.12.126.0    202.12.126.1    255.255.255.0   UG    1500   0        0 ppp5
# the route to our local Ethernet (super-netting two adjacent C classes)
203.18.8.0      *               255.255.254.0   U     1500   0     1683 eth0
# the route to the loop back device
127.0.0.0       *               255.0.0.0       U     3584   0      483 lo
# the default route to the Internet
default         139.130.177.2   *               UG    1500   0     3633 ppp4
\end{verbatim} 
\nopagebreak\hrule 
\addvspace{\medskipamount}





\subsection{³B²z¹q¤l¶l¥ó}

¤W¤@¸`´£¤Î¦p¦ó³B²z¥~°eªº¶l¥ó ¡Ð ¤@¥¹³s½u«Ø¥ß¤§«áÂ²³æ¦aÂÇ¥Ñ²M¥X¶l¥ó¦î¦C¹F¦¨¡D

¦pªG§A°õ¦æ³s©¹¼s°ìºô¸ôªº³sµ²¡A§A¥i¥H¸ò»·ºÝ°Ï°ìºô¸ôªººô¸ôºÞ²zªÌ¨ó½Õ½Ð¥¦­Ì°õ¦æ§¹¥þ¬Û¦Pªº°Ê§@¡D
¨Ò¦p¡A¦b§Ú­Ìªº¼s°ìºô¸ô³sµ²¤¤ Newman ®Õ¶é¨º¤@ºÝªº {\ttfamily /etc/ppp/ip-up} «ü¥O½Z¬Ý°_¨Ó¹³:

\par
\addvspace{\medskipamount}
\nopagebreak\hrule
\begin{verbatim}
#!/bin/bash
#
# Script which handles the routing issues as necessary for pppd
# Only the link to Hedland requires this handling.
#
# When the ppp link comes up, this script is called with the following
# parameters
#       $1      the interface name used by pppd (e.g. ppp3)
#       $2      the tty device name
#       $3      the tty device speed
#       $4      the local IP address for the interface
#       $5      the remote IP address
#       $6      the parameter specified by the 'ipparam' option to pppd
#
case "$5" in
        203.18.8.4)
                /usr/sbin/sendmail -q
                ;;
        *)
esac
exit 0
\end{verbatim} 
\nopagebreak\hrule 
\addvspace{\medskipamount}




µM¦Ó¦pªG§A¥u¯à¨Ï¥Î°ÊºA IP ¸¹½X¤è¦¡ªº PPP  ³s½u³s©¹§Aªº ISP¡A§A±o±q¦b§A ISP ¾÷¾¹¤Wªº±b¸¹¨ú±o§Aªº¹q¤l¶l¥ó¡D
³o³q±`¬O¨Ï¥Î POP(Post Office Protocol)¨ó©w¨Ó¹F¦¨ªº¡D¥i¥H¨Ï¥Î `popclient' µ{¦¡³B²z³o­Óµ{§Ç ¡Ð ¦Ó {\ttfamily ip-up} «ü¥O½Z¤]¥i¥H¬°§A¦Û°Ê¤Æ³o­Óµ{§Ç¡D



Â²³æ¦a«Ø¥ß¤@­Ó {\ttfamily /etc/ppp/ip-up} «ü¥O½Z¡A¨ä¤¤¥]§t¦³°_°Ê popclient µ{¦¡ªº¾A·í«ü¥O¡D
¦b§Ú°õ¦æ Red Hat Linux  ªº½¥¤W«¬¹q¸£¤W¡]¥ô¦ó®È¦æ®É§Ú³£±aµÛ¥¦¡^¬O³o¼Ëªº

\par
\addvspace{\medskipamount}
\nopagebreak\hrule
\begin{verbatim}
popclient -3 -c -u hartr -p <password> kepler.hedland.edu.au |formail -s procmail
\end{verbatim} 
\nopagebreak\hrule 
\addvspace{\medskipamount}




§A¥i¥H¨Ï¥Î slurp ©Î¨ä¥¦³nÅé¥H¬Û¦Pªº¤è¦¡¨ú±oºô¸ô·s»D¡A¥H¤Î½Ñ¦p¦¹ÃþªºªA°È¡D
°O±o¡Aip-up ³o­Ó«ü¥O½Z¥u¬O­Ó¼Ð·Çªº bash «ü¥O½Z¦]¦¹¥i¥H¥Î¨Ó¦Û°Ê¤Æ·í¨C¦¸¾A·íªº PPP ³sµ²«Ø¥ß®É»Ý­n§¹¦¨ªº¥ô¦ó¥\¯à¡D




\section{¨Ï¥Î {\ttfamily /etc/ppp/ip-down}}

§A¥i¥H«Ø¥ß¤@«ü¥O½Z¦b³s±µ¤@¥¹µ²§ô¤§«á°õ¦æ¡D³o¦s©ñ¦b {\ttfamily /etc/ppp/ip-down} ¸Ì¡D
³o¥i¥H¥Î¨ÓÁÙ­ì¥ô¦ó¹ïÀ³§A¦b {\ttfamily /etc/ppp/ip-up} «ü¥O½Z¤¤°µªº¯S®í°Ê§@¡D




\section{°Ï°ìºô¸ô¤Wªº»¼°e°ÝÃD}

¦pªG§A¤w¸g³s±µ¦b¬Y­Ó°Ï°ìºô¸ô¤W¦ý¬O¤´µM·Q­n¨Ï¥Î¦b§A­Ó¤Hªº Linux ¾÷¾¹¤Wªº pppd ªº¸Ü¡A§A±o­nÀ³¥I¬Y¨Ç»¼°e«Ê¥]ªº°ÝÃD¡A±q§Aªº¾÷¾¹¨ì§Aªº°Ï°ìºô¸ô¡]¸g¹L§Aªº¤A¤Óºô¸ô¬É­±¡^¥H¤Î¨ì»·ºÝªº PPP ¦øªA¾¹©M§ó¥~­±ªº¥@¬É¡D



³o¤@¸`¨Ã¤£¹Á¸Õ±Ð§A¦³Ãö«Ê¥]»¼°eªº¾÷¨î ¡Ð ¥¦¥u³B²z¤@­ÓÂ²³æªº¡A¯S©wªº»¼°e±¡ªp¡]ÀRºAªº¡^!



¦pªG§A¤£¼ô±x»¼°e¾÷¨îªº¸Ü¡A¨º»ò§Ú±j¯P¦a¹ªÀy§A¾\Åª Linux Network Administrator Guide (NAG)¡D
¦P®É O'Reilly ªº®Ñ "TCP/IP Network Administration" ¤]¥H«D±`®e©ö¤F¸Ñªº¤è¦¡²[»\¤F³o­Ó¥DÃD¡D



ÀRºA»¼°e¸ô®|ªº°ò¥»³W«h¬O¹w³]»¼°e¸ô®|À³¸Ó¬O«ü¦Vºô¸ô¦ì§}¸¹½X³Ì¦hªº¨º¤@­Ó¡D
¹ï©ó¨ä¥¦ªººô¸ô«h¦b»¼°eªí®æ¤¤¿é¤J«ü©w»¼°e¸ô®|¡D



§Ú°ß¤@¥´ºâ¦b³o¸Ì¤¶²Ðªº±¡ªp¬O§Aªº Linux ¾÷¾¹¦b¤@­Ó¨S¦³³s¤Wºô»Úºô¸ôªº°Ï°ìºô¸ô¤W ¡Ð ¦Ó§A·Q­n¦b¤´µM³s±µµÛ°Ï°ìºô¸ôªº±¡ªp¤U¼·±µ¨ìºô»Úºô¸ô¤W¨Ñ¦Û¤v¨Ï¥Î¡D



­º¥ý¡A½T©w§Aªº¤A¤Óºô¸ô»¼°e¸ô®|¬O³]©¹¯à°÷³q¹L§Aªº°Ï°ìºô¸ôªº«ü©wºô¸ô¦ì§} ¡Ð ¤£¬O³]©¹¹w³]»¼°e¸ô®|!



ÂÇ¥Ñµo¥X route  «ü¥OÀË¬d¤§¡A§AÀ³¸Ó·|¬Ý¨£¦p¤Uªº°T®§:

\begin{tscreen}
\begin{verbatim}
[root@hwin /root]# route -n
Kernel routing table
Destination     Gateway         Genmask         Flags MSS    Window Use Iface
loopback        *               255.255.255.0   U     1936   0       50 lo
10.0.0.0        *               255.255.255.0   U     1436   0      565 eth0
\end{verbatim}
\end{tscreen}




¦pªG§Aªº¤A¤Óºô¸ô¬É­± (eth0) «ü¦V¹w³]»¼°e¸ô®|¡A¡]¦b eth0 ¸Ó¦æªº²Ä¤@¦C¤W·|Åã¥Ü "default" ¦r¼Ë¡^¨º»ò§A±o­nÅÜ§ó§Aªº¤A¤Óºô¸ô°_©l«ü¥O½Z¨Ï¥¦«ü¦V¯S©wªººô¸ô¸¹½X¦Ó«D¹w³]»¼°e¸ô®|¡]°Ñ·Ó  Net2 HOWTO ¥H¤Î NAG¡^¡D



³o±N¤¹³\ pppd ³]¥ß§Aªº¹w³]»¼°e¸ô®|¡A¦p¤U©Ò¥Ü:

\begin{tscreen}
\begin{verbatim}
[root@hwin /root]# route -n
Kernel routing table

Destination     Gateway         Genmask         Flags MSS    Window Use Iface
10.144.153.51   *               255.255.255.255 UH    488    0        0 ppp0
127.0.0.0       *               255.255.255.0   U     1936   0       50 lo
10.1.0.0        *               255.255.255.0   U     1436   0      569 eth0
default         10.144.153.51   *               UG    488    0        3 ppp0
\end{verbatim}
\end{tscreen}




¦p¦P§A©Ò¨£¨ìªº¡A§Ú­Ì¾Ö¦³¸g¥Ñ ppp0 ¨ì PPP ¦øªA¾¹(10.144.153.51)ªº¥D¾÷»¼°e³]©w¦Ó¥B¤]¾Ö¦³¨Ï¥Î PPP ¦øªA¾¹§@¬°¹h¹Dªº¹w³]ºô¸ô»¼°e³]©w¡D



¦pªG§Aªº³]©w±o­n¤ñ¦¹§ó½ÆÂø ¡Ð ¾\Åª¤w¸g´£¹L¦³Ãö»¼°eªº¤å¥ó¨Ã½Ð±Ð¦b§A¨­®Çªº±M®a!



¦pªG§Aªº°Ï°ìºô¸ô¤W¤w¸g¦³¸ô¥Ñ¾¹¡A¨º»ò¦b§A¨º¸Ì¤w¸g«Ø¥ß¤F³q©¹¼e¼sºô¸ô¥@¬Éªº¹h¹D¡D
§A¤´À³§â§Aªº¹w³]»¼°e¸ô®|«ü©¹ PPP ¬É­± ¡Ð ¨Ã¥B¨Ï¨ä¥¦ªº»¼°e¸ô®|«ü©w¨ì¥Ñ¸ô¥Ñ¾¹ªA°Èªººô¸ô¡D




\subsection{¦w¥þ¤Wªºª`·N¨Æ¶µ}

·í§A¦b²{¦³ªº°Ï°ìºô¸ô¤W³]©w¤@¥x Linux ¾÷¾¹³sµ²¨ìºô»Úºô¸ô¤W¡A§A¦b¤£ª¾¤£Ä±¤¤¤w¸g¹ïºô»Úºô¸ô ¡Ð ¥H¤Î¦b¨º¸ÌªºÀb«È­Ì ¡Ð ¶}©ñ¤F§Aªº¾ã­Ó°Ï°ìºô¸ô¡D
¦b§A³o¼Ë°µ¤§«e¡A§Ú±j¯P¦a¹ªÀy§A½Ð±Ð§Aªººô¸ôºÞ²zªÌ¨Ã°Ñ¦Ò¸Ó³Bªº¦w¥þµ¦²¤¡D
¦pªG§Aªº PPP ³s½u³Q¦¨¥\¦a¥Î¨Ó§ðÀ»§Aªº¯¸¥xªº¸Ü¡A¨º»ò§A³Ì¤Ö¤]·|©Û­P¦P¹Ùªº¨Ï¥ÎªÌ¡Aºô¸ô¤Î¨t²ÎªººÞ²zªÌ±j¯Pªº¼««ã¡D
§A¤]¥i¯à·|µo²{§A¦Û¤v¸m¨­©ó«D±`ÄY­«ªº³Â·Ð!

¦b§A³s±µ°Ï°ìºô¸ô¨ìºô»Úºô¸ô¤W¥h¤§«e¡A¬Æ¦Ü¬O°ÊºAªº³s½u§A³£À³¸Ó­n¦Ò¼{¦w¥þªºÁô¼~ ¡Ð ¦]¦¹¦­ÂI°Ñ¦Ò O'Reilly ªº "Building Internet Firewalls"!




\section{«Ø¥ß PPP ¦øªA¾¹\label{ppp-server}}

¦p¦P«e­±´£¹Lªº¡A³o¥ó¤u§@¦³³\¦h¤èªk¥i¥H¥i¥H¹F¦¨¡D
§Ú¦b³o¸Ì©Ò¤¶²Ðªº¬O§Ú«ç»ò°µªº¤èªk¡]¨Ï¥Î Cyclades ¦h°ð¦ê¦C¥d¡^¥H¤Î¤@²Õ¦Û°ÊÂà±µªº¹q¸Ü½u¸ô¡D



¦pªG§A¤£³ßÅw§Ú¦b³o¸Ì¤¶²Ðªº¤èªk¡A½Ð¦Û¥Ñ¦a¨Ï¥Î§A¦Û¤vªº¤èªk¡D
¤£¹L¡A§Ú«Ü¼Ö·N¦b³o¥÷¨Ï¥Î»¡©ú¥¼¨Óªºª©¥»¤¤¥]§tÃB¥~ªº¤è¦¡¡D©Ò¥H¡A½Ð§â§Aªºµû½×¸ò¤èªk±Hµ¹§Ú!



½Ðª`·N¡A³o¤@¸`¥u¸ò¦p¦ó³]©w Linux  §@¬° PPP ¦øªA¾¹¦³Ãö¡D§Ú¤£·Q¡]¤£´¿¡^¥]§t¦³Ãö³]©w¯S®í²×ºÝ¾÷¦øªA¾¹¤Î³o¤@Ãþªº¸ê°T¡D



¦Ó¥B¡A§Ú©|¥¼¹êÅç¹L°t¦X shadow ±K½X¨Ï¥Î¡]¦ýÀ³¸Ó·|°µ¡^¡D¦]¦¹¥Ø«e¤¶²Ðªº¸ê°T¨Ã¤£¥]§t¥ô¦ó shadow »Ý­nªº³]©w¡D




\subsection{½sÄ¶®Ö¤ß}

©Ò¦³¦­¥ý´£¹LÃö©ó½sÄ¶®Ö¤ß¥H¤Î®Ö¤ß»P pppd ª©¥»ªº»¡©ú³£¾A¥Î¡D³o¸`°²³]§A¤w¸gÅª¹L³o¥÷¤å¥ó«e­±ªº³¹¸`!



¹ï©ó PPP  ¦øªA¾¹¡A§A¥²¶·¦b§Aªº®Ö¤ß¤¤¥]§t IP forwarding ªº¥\¯à¡D
§A¤]¥i¯à·|§Æ±æ¥]§t¨ä¥¦ªº¥\¯à¡]¹³¬O IP firewalls, accounting µ¥µ¥¡^¡D



¦pªG§A¨Ï¥Î¦h°ð¦ê¦C¥d¡A¨º»ò§A¤]¥²¶·©ú½T¦a¦b§Aªº®Ö¤ß¤¤¥]§t¥²­nªºÅX°Êµ{¦¡!




\subsection{¦øªA¾¹¨t²Îªº·§Æ[}

§Ú­Ì¨Ï¥Î¬Û¦Pªº¨Ï¥ÎªÌ¦WºÙ¡þ±K½X°t¹ï´£¨Ñ¼·±µ PPP (and SLIP) ±b¸¹¥H¤Î shell ±b¸¹¡D
³o¼Ë°µªº¦n³B¡]¹ï§Ú­Ì¦Ó¨¥¡^¬O¨Ï¥ÎªÌ¥u»Ý­n¤@­Ó±b¸¹´N¥i¥H¨Ï¥Î©Ò¦³ºØÃþªº³s½u¡D



¦]¬°§Ú­Ì¬O±Ð¨|²ÕÂ´¡A§Ú­Ì¨Ã¤£¹ïÂ¾­û¥H¤Î¾Ç¥Íªº¨Ï¥Î¦¬¶O¡A©Ò¥H¤£¥²¾á¤ß­pºâ»P¦¬¶Oªº°ÝÃD¡D



¦b§Ú­Ìªº¸`ÂI»Pºô»Úºô¸ô¤§¶¡§Ú­Ì³]¸m¦³¤@¥x¨¾¤õÀð¡A¦Ó³o·|­­¨î¬Y¨Ç¨Ï¥ÎªÌªº¦s¨ú¡A¦]¬°¼·±µ½u¸ô¬O¦b§Ú­Ìªº¡]ºô»Úºô¸ô¡^¨¾¤õÀð¤º¡]²z¥Ñ«Ü©úÅã¡A¨ä¥Lºô»Úºô¸ô¨¾¤õÀðªº²Ó¸`¤]¤£·|¦b¦¹¥X²{¦Ó¥B¦b¥ô¦ó±¡ªp¤U³£¨S¦³Ãö«Y¡^¡D



¨Ï¥ÎªÌ«Ø¥ß³s©¹§Ú­Ì¸`ÂI¤§ PPP ³sµ²ªºµ{§Ç¡]·íµM¬O¦b¥L­Ì¾Ö¦³¦³®Äªº±b¸¹«á¡^¬O:
\begin{itemize}
\item ¼·¤J§Ú­Ìªº¦Û°ÊÂà±µ¼·¸¹¾¹¡]³o¬O³sµ²¤@°ï¼Æ¾Ú¾÷ªº³æ¤@¹q¸Ü¸¹½X ¡Ð ²Ä¤@¥xªÅ¶¢ªº¼Æ¾Ú¾÷·|±µ°_¼·¤Jªº¹q¸Ü¡^¡D
\item ¨Ï¥Î¤@¹ï¦³®Äªº¨Ï¥ÎªÌ¦WºÙ¥H¤Î±K½XÃ±¤J¡D
\item ¦b shell ´£¥Ü²Å¸¹¤U¡Aµo¥X {\ttfamily ppp} «ü¥O¥H±Ò°Ê¦øªA¾¹¤Wªº PPP µ{§Ç¡D
\item ±Ò°Ê¥L­Ì¾÷¾¹¤Wªº PPP¡]¥i¥H¬O°õ¦æ Windows, DOS, Linux, MAC OS ©Î¥ô¦ó§@·~¨t²Îªº¾÷¾¹ ¡Ð ³o¬O¥L­Ìªº°ÝÃD¡^¡D
\end{itemize}




³o¥x¦øªA¾¹¬°¨C­Ó¼·¤Jªº°ð¨Ï¥Î­Ó§Oªº {\ttfamily /etc/ppp/options.ttyXX} ÀÉ®×¡A¦Ó³o¬°°ÊºAªº IP ¤À°t³]©w»·ºÝªº IP ¸¹½X¡D
¦øªA¾¹¬°»·¦aªº«È¤áºÝ¨Ï¥Î¥N²z¦ì§}¸ÑªR¨ó©w(proxyarp)¨Ó»¼°e«Ê¥]¡]¸g¥Ñ¾A·íªº pppd ¿ï¶µ¥[¥H³]©w¡^¡D
³oÁ×§K¤F¨Ï¥Î routed ©Î¬O gated ªº»Ý¨D¡D



·í¨Ï¥ÎªÌ±q¥L­Ì¨ººÝ±¾Â_®É¡Apppd ·|°»´ú¥X¨Ó¨Ã§i¶D¼Æ¾Ú¾÷­n¥¦±¾Â_¡A¦P®É°±±¼ PPP ³sµ²¡D




\subsection{©Ò»Ýªº¥þ³¡³nÅé}

§A±N·|»Ý­n¤U¦Cªº³nÅé:-
\begin{itemize}
\item Linux¡A¾A·í¦a½sÄ¶¥H¥]§t¥²­nªº¿ï¶µ¡D
\item ¾A¦X©ó§A®Ö¤ßªº pppd ª©¥»¡D
\item ¤@®M¯à°÷Áo©ú¦a³B²z¼Æ¾Ú¾÷³q°Tªº 'getty' µ{¦¡¡D\\ 
¦b³o¸Ì§Ú­Ì¨Ï¥Îªº¬O getty\_ps2.0.7h ¡A¦ý¿n·¥¦Ò¼{ mgetty¡D
§Ú¤F¸Ñ mgetty ¥i¥H°»´ú¥X¨Ï¥Î pap/chap ªº©I¥s¡] pap ¬O Windows 95 ¨Ï¥Îªº¼Ð·Ç¡^¨Ã¦Û°Ê¦a°_°Ê pppd¡A¦ý¬O§Ú©|¥¼¬ã¨s¹L¥¦¡D
\item §Aªº¼·±µ¨Ï¥ÎªÌ¯à°÷¦s¨úªº¤@¥x»â°ì¦WºÙ¦øªA¾¹ (DNS)¡D\\ 
¦pªG¦³¥i¯àªº¸Ü§A¯uªºÀ³¸Ó°õ¦æ§A¦Û¤vªº»â°ì¦WºÙ¦øªA¾¹...
\end{itemize}





\subsection{³]©w¼Ð·Çªº¼·±µ(shell access)}

¦b§A¥i¥H³]¥ß§Aªº PPP  ¦øªA¾¹¤§«e¡A§Aªº Linux ¾÷¾¹¥²¶·¯à°÷³B²z¼Ð·Çªº¼·±µ¦s¨ú¡D



{\bfseries ³o¥÷¨Ï¥Î»¡©ú¨Ã¤£²[»\³o¶µ³]©w¤èªk¡D½Ð°Ñ¾\§A¿ï¾Ü¤§ getty ªº¤å¥ó¥H¤Î \onlynameurl{Serial HOWTO} ¸Ì¦³Ãö³o¶µ³]©wªº¸ê°T¡D}




\subsection{³]¥ß PPP ¿ï¶µÀÉ®×}

§A±N±o¬°©Ò¦³¼·±µ°ð³]¥ß¤@­Ó¥þÅéªº {\ttfamily /etc/ppp/options} ÀÉ®×¡A¨ä¤¤¬O³q¥Îªº¿ï¶µ¡D
§Ú­Ì¨Ï¥Îªº¿ï¶µ¬O:

\par
\addvspace{\medskipamount}
\nopagebreak\hrule
\begin{verbatim}
asyncmap 0
netmask 255.255.254.0
proxyarp
lock
crtscts
modem
\end{verbatim} 
\nopagebreak\hrule 
\addvspace{\medskipamount}




ª`·N - §Ú­Ì¨S¦³¨Ï¥Î¥ô¦ó(©úÅãªº)»¼°e³]©w - ¯S§O¬O³o¸Ì¨S¦³ {\ttfamily defaultroute} ¿ï¶µ¡D
³o²z¥Ñ¬O¦]¬°©Ò¦³§A(°µ¬° PPP ¦øªA¾¹)©Ò­n°µªº´N¬O±N«Ê¥]{\bfseries ±q} PPP «È¤áºÝ»¼°e¨ì§Aªº°Ï°ìºô¸ô©Îºô»Úºô¸ô¨Ã¥B±N«Ê¥]¥Ñ§Aªº°Ï°ìºô¸ô»¼°e{\bfseries ¨ì}§Aªº«È¤áºÝ¡D



¥þ³¡©Ò»Ýªº¥u¬O¨ì«È¤á¾÷¾¹ªº¥D¾÷»¼°e¡A¦Ó¨Ï¥Î pppd ªº '{\ttfamily proxyarp}' ¿ï¶µ¹F¦¨¡D



³o­Ó '{\ttfamily proxyarp}' ¿ï¶µ³]¥ß¤@­Ó¥N²z¦ì§}¸ÑªR¨ó©wªº¶µ¥Ø©ó PPP ¦øªA¾¹ªº¦ì§}¸ÑªR¨ó©w(ARP)ªí®æ¤¤¡A¨º°ò¥»¤W´N¬O»¡ '±N©Ò¦³­nµ¹ PPP «È¤áºÝªº«Ê¥]°eµ¹§Ú'¡D
³o¬O«Ø¥ß³æ¤@ PPP «È¤áºÝªº»¼°e¸ô®|³ÌÂ²³æªº¤@­Ó¤è¦¡ - ¦ý§A¤£¯à¥Î³oºØ¤è¦¡¦b¨â­Ó°Ï°ìºô¸ô¤§¶¡»¼°e«Ê¥] - §A¥²¶·¥[¤J¾A·íªººô¸ô»¼°e¦Ó¤£¯à¨Ï¥Î¥N²z¦ì§}¸ÑªR¨ó©w¡D



§A´X¥G¤@©w·|§Æ±æ´£¨Ñ°ÊºA¤À°tªº IP ¸¹½Xµ¹§Aªº¼·±µ¨Ï¥ÎªÌ¡D§A¥i¥HÂÇ¥Ñ¤À°t IP ¸¹½Xµ¹¨C­Ó¼·±µ°ð¨Ó¹F¦¨¥Øªº¡D
²{¦b¡A¬°§Aªº¨C­Ó¼·±µ°ð«Ø¥ß¤@­Ó {\ttfamily /etc/ppp/options.ttyXX} ÀÉ®×¡D



¦b³o¸Ì­±¡A¥u­nÂ²³æ¦a©ñ¤J¥»¦a¡]¦øªA¾¹¡^ªº IP ¸¹½X¤Î¸Ó°ð©Ò­n¨Ï¥Îªº IP ¸¹½X¡D¨Ò¦p

\par
\addvspace{\medskipamount}
\nopagebreak\hrule
\begin{verbatim}
kepler:slip01
\end{verbatim} 
\nopagebreak\hrule 
\addvspace{\medskipamount}


¯S§Oª`·N¡A¦b³o­ÓÀÉ®×¸Ì§A¥i¥H¨Ï¥Î¦Xªkªº¥D¾÷¦WºÙ¡]§Úµo²{§Ú¥u°O±o¦b§Úºô¸ô¤W­«­n¾÷¾¹»P³]³Æªº IP ¸¹½X ¡Ð ¦WºÙ·|§ó¦³·N¸q¤~¹ï¡^!




\subsection{³]©w pppd ¥H«KÅý¨Ï¥ÎªÌ¡]¦¨¥\¦a¡^°õ¦æ¥¦}

¦]¬°°_°Ê ppp ³sµ²Áô§tµÛ°t¸m®Ö¤ß³]³Æ¡]ºô¸ô¬É­±¡^¤Î¾Þ±±®Ö¤ß»¼°eªí®æªº°Ê§@¡A©Ò¥H»Ý­n¯S§OªºÅv­­ ¡Ð ¨Æ¹ê¤W»Ý­n§¹¾ãªº root Åv­­¡D



©¯¹Bªº¬O¡A pppd ¤w¸g³]­p¦¨¥i¥H¦w¥þ¦a³]©w¬°¥H root ªº¨­¤À°õ¦æ¡D©Ò¥H§A¥²¶·
\par
\addvspace{\medskipamount}
\nopagebreak\hrule
\begin{verbatim}
chmod u+s /usr/sbin/pppd
\end{verbatim} 
\nopagebreak\hrule 
\addvspace{\medskipamount}




·í§A¦C¥X³o­ÓÀÉ®×®É¡A¥¦À³¸Ó·|¦p¦P³o¼Ë
\par
\addvspace{\medskipamount}
\nopagebreak\hrule
\begin{verbatim}
-rwsr-xr-x   1 root     root        74224 Apr 28 07:17 /usr/sbin/pppd
\end{verbatim} 
\nopagebreak\hrule 
\addvspace{\medskipamount}




¦pªG§A¨S¦³³o¼Ë°µ¡A¨Ï¥ÎªÌ±N¤£¯à³]¥ß¥L­Ìªº PPP ³sµ²¡D




\subsection{¬° pppd ³]©w¤@­Ó¥þ°ìªº§O¦W(alias)}

¬°¤FÂ²¤Æ§Ú­Ì¼·±µ PPP ¨Ï¥ÎªÌªº³s½uµ{§Ç¡A§Ú­Ì«Ø¥ß¤@­Ó¥þ°ìªº§O¦W(©ñ¦b {\ttfamily /etc/bashrc})¦p¦¹¤@¥¹¥L­ÌÃ±¤J¤§«á¥u­n¤@­ÓÂ²³æªº«ü¥O´N¯à°_°Ê¦øªAºÝªº ppp¡D



³o¬Ý°_¨Ó¹³
\par
\addvspace{\medskipamount}
\nopagebreak\hrule
\begin{verbatim}
alias ppp="exec /usr/sbin/pppd -detach"
\end{verbatim} 
\nopagebreak\hrule 
\addvspace{\medskipamount}




¥¦©Ò§@ªº¬O
\begin{itemize}
\item exec : ·N«ü¥H³o­Ó«ü¥O©Ò°õ¦æªºµ{¦¡´À´«¥¿¦b°õ¦æªºµ{¦¡¡]¦b³o­Ó¨Ò¤l¤¤¬O shell¡^¡D
\item pppd -detach : °_°Ê pppd ¨Ã¥B¤£­n§â²£¥Íªºµ{§Ç©ñ¤J­I´º°õ¦æ¡D³o½T«O·í pppd µ²§ô®É¤£·|¯d¤U¥ô¦óµ{§Ç¡D
\end{itemize}


·í¤@­Ó¨Ï¥ÎªÌ¹³³o¼ËÃ±¤J®É¡A¥L­Ì¦b 'w' ªº¿é¥X¤¤¬Ý°_¨Ó·|¹³³o¼Ë
\par
\addvspace{\medskipamount}
\nopagebreak\hrule
\begin{verbatim}
  6:24pm  up 3 days,  7:00,  4 users,  load average: 0.05, 0.03, 0.00
User     tty       login@  idle   JCPU   PCPU  what
hartr    ttyC0     3:05am  9:14                -
\end{verbatim} 
\nopagebreak\hrule 
\addvspace{\medskipamount}




´N³o¼Ë... §Ú§i¶D¹L§A³o¬O¤@­Ó«ÜÂ²³æªº¡A°ò¥»ªº PPP ¦øªA¨t²Î!




\section{¦b null modem (ª½±µ³s½u)¤W¨Ï¥Î PPP\label{direct}}

³o«D±`¦aÂ²³æ - ¦]¬°¨S¦³¼Æ¾Ú¾÷©Ò¥H¨Æ±¡ÅÜ±o§ó®e©ö¡D



­º¥ý¡A¿ï¾Ü¨ä¤¤¤@³¡¾÷¾¹°µ¬°'¦øªA¾¹'¡A¦b¦ê¦C°ð¤W³]¥ß getty ¥H«KÅý§A¥i¥H±q'«È¤áºÝ'¨Ï¥Î minicom ¥h¨ú¥Î¦¹¦ê¦C°ð¥H´ú¸Õ³s±µ©Ê¡D



¤@¥¹§A¦¨¥\¤F¡A§A¥i¥H°£¥h³o­Ó getty¡A°£«D§A·Q¥Î¨Ï¥ÎªÌ¦WºÙ/±K½X¨Ó½T»{³s½u¡D
¦]¬°§A¦³¨â³¡¾÷¾¹ªº'¹êÅé±±¨îÅv'¡A§Ú°²³]§A¨Ã¤£·Q¦p¦¹°µ¡D



²{¦b¡A¦b¦øªA¾¹ºÝ°£¥h getty ¨Ã½T»{§A¤w¦b¨â³¡¾÷¾¹¤W¥¿½T¦a¨Ï¥Î 'setserial' ¨Ó³]©w¦ê¦C°ð¡D



©Ò¦³§A­n°µªº´N¬O¦b¨â­Ó¨t²Î¤W±Ò°Ê pppd¡D
§Ú°²³]§A¦b¨â¥x¾÷¾¹¤W³£¨Ï¥Î {\ttfamily /dev/ttyS3} «Ø¥ß³s½u¡D 
¦]¦¹¡A¦b¨â³¡¾÷¾¹¤W°õ¦æ«ü¥O:-

\par
\addvspace{\medskipamount}
\nopagebreak\hrule
\begin{verbatim}
pppd -detach crtscts lock <local IP>:<remote IP> /dev/ttyS3 38400 &
\end{verbatim} 
\nopagebreak\hrule 
\addvspace{\medskipamount}




³o±N·|«Ø¥ß°_³sµ² - ¦ý¥Ø«e¬°¤î§AÁÙ¥¼«ü©w»¼°e¸ô®|¡D
§A¥i¥H¦b¨C³¡¾÷¾¹¤W¥Î ping «ü¥O¨Ó´ú¸Õ³sµ²¡D¦pªG³o¼Ë¥i¥Hªº¸Ü¡A²×¤î¨ä¤¤¤@­Ó pppd µ{§Ç¥Hµ²§ô³sµ²¡D



§A»Ý­nªº»¼°e¸ô®|¹ê»Ú¤W¬Ý§A¨s³º·Q°µ¤°»ò¦Ó©w¡D
¤@¯ë¨Ó»¡¡A¨ä¤¤¤@³¡¾÷¾¹·|³s¤W¤A¤Óºô¸ô(¨ä¤Î«áªººô¸ô)¦]¦¹©Ò»Ýªº»¼°e§¹¥þ©M PPP ¦øªA¾¹»P«È¤áºÝ¤@¼Ë¡D



¦]¦¹¦b¨ã¦³¤A¤Óºô¸ôªº¾÷¾¹¤W¡Apppd ªº«ü¥OÀ³¸Ó¬O

\par
\addvspace{\medskipamount}
\nopagebreak\hrule
\begin{verbatim}
pppd -detach crtscts lock proxyarp <local IP>:<remote IP> /dev/ttyS3 38400 &
\end{verbatim} 
\nopagebreak\hrule 
\addvspace{\medskipamount}




¦Ó¥t¤@³¡¾÷¾¹¤W¬O

\par
\addvspace{\medskipamount}
\nopagebreak\hrule
\begin{verbatim}
pppd -detach crtscts lock defaultroute <local IP>:<remote IP> /dev/ttyS3 38400 &
\end{verbatim} 
\nopagebreak\hrule 
\addvspace{\medskipamount}




¦pªG§A³s±µ¨â­Óºô¸ô(¨Ï¥Î¦ê¦C³sµ²!)©Î¦³§ó½ÆÂøªº»¼°e»Ý¨D¡A§A¥i¥H§¹¥þ«ö·Ó³o¥÷¤å¥ó«e­±©Ò´£ªº¤èªk¨Ó¨Ï¥Î {\ttfamily /etc/ppp/ip-up}¡D



{\bfseries Robert Hart}\\ 
Port Hedland, Western Australia\\ 
Melbourne, Victoria, Australia
August/October 1996
January/March 1997



\end{document}
