\documentclass[letterpaper,english]{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{¦p¦ó±q VMS Âà²¾¨ì Linux (From VMS to Linux HOWTO)}
\author{By Guido Gonzato, \nameurl{guido ``at'' ibogeo.df.unibo.it}{},
and Mike Miller, \nameurl{miller5@uiuc.edu}{},
Ä¶ªÌ¡G®p¦à}
\date{v1.1.3, 17 September 1999}
\abstract{³o¥÷ HOWTO ¥D­n¬O°w¹ï¨º¨Ç¤w¸g¥Î¹L VMX ¨t²Î¡M¦Ó²{¦b¥i¯à¦]»Ý­n¦ÓÂà«¬¨Ï¥Î Linux §@·~¨t²Îªº¤H¡C§Æ±æÂÇ¥Ñ¤ñ¸û¨âªÌ§@·~¨t²Î¶¡«ü¥Oªº®t²§¡M¦Ó´`§Çº¥¶iªº±a»â±z¶i¤J Linux ªº¥@¬É¡C}


\begin{document}
\maketitle
\tableofcontents

\section{Â²¤¶ \label{Introduction}}


\subsection{¬°¦ó­n¨Ï¥Î Linux ?}



±z´¿¸gÅ¥¹L UNIX Á}²`ÃøÀ´«K¬ÈÄß¥á¶} VMS ¶Ü¡H§O·Ð´o¡MLinux¡M³Ì¦nªº UNIX ¬Û®e¾÷ºØ¤§¤@¡M
¤@ÂI¤]¤£·|¤ñ VMS Ãø¨Ï¥Î¡F¬Û¤Ïªº¡M§Úµo²{ Linux ¤ñ VMS §ó®e©ö¤W¤â¡CÁöµM¡MVMS °g¥i¯à¤£¥H¬°µM¡M
¦ý¬O¡M¸g¹L³\¦h¤Hªº«ØÄ³¬O¡GLinux ½T¹ê¬O¤ñ VMS §ó¦³®Ä¤O¥B§ó¬O¦h¥\¡C

Linux ©M VMS ¨âªÌ³£¬O«Ü¦nªº§@·~¨t²Î¡M¦Ó¥B¥»½è¤W³£¥i¥H«D±`¦³®Ä²vªº§¹¦¨¬Û¦Pªº§@·~¡C
¦ý¬O¡MLinux ¦³¤@¨Ç«D±`§l¤Þ¤Hªº¯S¦â¡M¦Ó¨Ï±o¦o¦¨¬° VMS «Ü¦nªº¥t¤@­Ó¿ï¾Ü¡C¨Ã¥B¡M
Linux ¥i¥H¦b­Ó¤H¹q¸£ (PC) ¤W¨Ï¥Î¡M¦Ó VMS «o¤£¦æ¡C²{¦b¥ô¦ó¤@¥x©bÄË(Pentium)ªº¹q¸£¡M
¨Ï¥Î Linux ¬°§@·~¨t²Îªº®Ä¯à§ó¥i»·»·¦a³Ó¹L VMS ªº¾÷¾¹¡C§ó°g¤Hªº¬O¡M²{¦b¥H¤@¯ëªºÅã¥Ü¥d¡M
´N¥i¥H¦³«D±`Àu¨qªºµøµ¡¹Ï§Î¬É­±¡C´X¥GÁ`¬O§Ö¹L¨º¨Ç±M¥Îªº¹q¸£¡C

§Ú·Q¡M±zÀ³¸Ó¬O¤j¾Ç¸Ìªº¬ã¨s¤H­û©Î¬O¾Ç¥Í¡M¨Ã¥B±z¨C¤Ñ¨Ï¥Î VMS ¨Ó§¹¦¨¤U¦Cªº´X¥ó¨Æ¡G

\begin{itemize}
\item  ¨Ï¥Î TeX/LaTeX ¨Ó¼g³ø§i;
\item  ¨Ï¥Î Fortran ¨Ó¼gµ{¦¡;
\item  §@¤@¨Ç¹Ï§Î¤å¥ó;
\item  ¤Wºô¨Ï¥Î¬Y¨ÇªA°È;
\item  ¤Î¨ä¥Lµ¥µ¥.
\end{itemize}


¦b¤U­±ªº³¹¸`¤¤¡M§Ú±N§Q¥Î±z¦b VMS ¤Wªº¸gÅç¡M¤¶²Ð¦p¦ó¦b Linux ¤W§¹¦¨¤W¦Cªº¨C¤@¥ó¨Æ¡C
­º­n¨Æª«¡G

\begin{itemize}
\item  ½Ð½T©w Linux ©M X Window ³£¤w¸g¦w¸Ë§¹¥þ;
\item  ¦³¤@¦ì¨t²ÎºÞ²z­û¥i¥H§@¬°§Þ³N«ü¾É¡C¡]½Ð§ä¥L­ÌÀ°¦£¡M½Ð¤£­n¨Ó§ä§Ú ;-) ¡^;
\item  ±z¨t²Î¤Wªº shell ¥i¥H¬O bash ¡]½Ð¸ß°Ý±zªº¨t²ÎºÞ²z­û¡^;
\end{itemize}


½Ðª`·N¡M³o¥÷ HOWTO ÁÙ¤£¨¬°÷¨Ï±z¥þ³¡¤F¸Ñ Linux ªººëÅè¡C¦o¥u¥]§t¤F¶È¦³ªº¤@¨Ç¤Jªùªº¥²­nª¾ÃÑ¦Ó¤w¡C
±zÀ³¸Ó¾Ç²ß§ó¦hªº Linux ªºª¾ÃÑ¡M¨Ã¥B¥R¤Àªº§Q¥Î¦o¡C(advanced {\ttfamily bash} 
features, programming, regular expressions...). ±q²{¦b¶}©l¡MRMP ªº·N«ä¬O
`please read the man pages for further details'. ¦b Linux ¤W¡Mman pages ¨ä¹ê´N¬O help ªº·N«ä¡C

The Linux Documentation Project ¤å¥ó¥i¥H¦b \nameurl{ftp://sunsite.unc.edu:/pub/Linux/docs/LDP}{}, Àò±o¡C¦Ó³o¤]¬O­«­n°T®§ªº¨Ó·½¡C
§Ú«ØÄ³±z¥i¥H¾\Åª¥Ñ Larry Greenfield ¼gªº ``Linux User
Guide'' ®Ñ¡C---³o¬O¤@¥»«D±`¾A¦Xªì¾ÇªÌªº¤Jªù®Ñ¡C

²{¦bÅý§Ú­Ì¨B¤J¥¿ÃD§a¡G




\subsection{«ü¥Oªº¤ñ¸û©MÀÉ®×®æ¦¡}



³o­Óªí¦C¥X VMS ©M Linux ¤¤±`¥Îªº«ü¥O¶°¡C½Ð¨c°O¦b¤ß¡M¨ä»yªk¤]±N¤j¤jªº¤£¦P¡C
¸Ô²Ó²Ó¸`½Ð°Ñ¦Ò¬ÛÃö³¹¸`¡C

\begin{tscreen}
\begin{verbatim}
VMS                             Linux                   ª`·N¨Æ¶µ(Linux ³¡¥÷)
------------------------------------------------------------------------------

@COMMAND                        command                 ¥²¶·¥i³Q°õ¦æ
COPY file1 file2                cp file1 file2
CREATE/DIR [.dirname]           mkdir dirname           ¤@¦¸¥u¯à«Ø¤@­Ó¥Ø¿ý
CREATE/DIR [.dir1.dir2]         mkdirhier dir/name
DELETE filename                 rm filename
DIFF file1 file2                diff -c file1 file2
DIRECTORY                       ls
DIRECTORY [...]file             find . -name file
DIRECTORY/FULL                  ls -al
EDIT filename                   vi filename,            ±z¥i¯à¤£·|³ßÅw¨Ï¥Î vi
                                emacs filename,         EDT compatible
                                jed filename            ditto---my favourite
FORTRAN prog.for                g77 prog.f,             ¤£»Ý­n§@ LINK
                                f77 prog.f,
                                fort77 prog.f
HELP command                    man command             must specify `command'
                                info command            ditto
LATEX file.tex                  latex file.tex
LOGIN.COM                       .bash_profile,          `hidden' file
                                .bashrc                 ditto
LOGOUT.COM                      .bash_logout            ditto
MAIL                            mail,                   ³Ì­ì©lªº email µ{¦¡
                                elm,                    ¤ñ mail ¦n¡C
                                pine                    ¤£¿ù¡M¦ý¬O³£¥u¯à³B²z¤å¦r¡C
PRINT file.ps                   lpr file.ps
PRINT/QUEUE=laser file.ps       lpr -Plaser file.ps
PHONE user                      talk user
RENAME file1 file2              mv file1 file2          not for multiple files
RUN progname                    progname
SEARCH file "pattern"           grep pattern file
SET DEFAULT [-]                 cd ..
SET DEFAULT [.dir.name]         cd dir/name
SET HOST hostname               telnet hostname,        ¤£¤Ó¬Û¦P
                                rlogin hostname
SET FILE/OWNER_UIC=joe          chown joe file          §¹¥þ¤£¬Û¦P
SET NOBROADCAST                 mesg
SET PASSWORD                    passwd
SET PROT=(perm) file            chmod perm file         §¹¥þ¤£¬Û¦P
SET TERMINAL                    export TERM=            »yªk¤£¦P
SHOW DEFAULT                    pwd
SHOW DEVICE                     du, df
SHOW ENTRY                      lpq
SHOW PROCESS                    ps -ax
SHOW QUEUE                      lpq
SHOW SYSTEM                     top
SHOW TIME                       date
SHOW USERS                      w
STOP                            kill
STOP/QUEUE                      kill,                   °w¹ï processes
                                lprm                    °w¹ï print queues
SUBMIT command                  command &
SUBMIT/AFTER=time command       at time command
TEX file.tex                    tex file.tex
TYPE/PAGE file                  more file
                                less file               much better
\end{verbatim}
\end{tscreen}


·íµM¡M³o¤£¥u¬O«ü¥Oªº¦WºÙ¤£¤@¼Ë¦Ó¤w¡M½ÐÄ~ÄòÅª¤§¡C






\section{¤û¤M¤p¸Õ \label{Short Intro}}



³o¨Çµ´¹ï¬O±z¦b²Ä¤@¦¸µn¤J¨t²Î«e¥²¶·ª¾¹Dªº¤@¨Ç¨Æ±¡¡M©ñ»´ÃP¡M¤£·|¤Ó½ÆÂøªº¡C




\subsection{ÀÉ®×}



\begin{itemize}
\item  ¦b VMS ¤WªºÀÉ¦Wªºªí¥Üªk¬O {\ttfamily filename.extension;version}¡C
¦ý¬O¦b Linux ¤W¡MÀÉ®×ªºª©¥»¸¹½X±N¤£·|¦A¥X²{¡]­«­nªº­­¨î¡M½Ð°Ñ¾\ \ref{Numbered Backups Under Linux} {(Linux ¤WªºÀÉ®×ª©¥»)}); 
ÀÉ¦W³Ì±`¥u¯à¦³ 255 ­Ó¦r¤¸¡MÀÉ¦W¤¤¥i¥H¥X²{«Ü¦h­ÓÂI ¡§¡E¡¨¡C¨Ò¦p¡G{\ttfamily This.is\_a\_FILEname.txt}.
\item  Linux ¹ïÀÉ¦Wªº¤j¤p¼g¬O¦³¤À§Oªº¡G 
{\ttfamily FILENAME.txt} ©M {\ttfamily filename.txt} ¬O¨â­Ó§¹¥þ¤£¤@¼ËªºÀÉ¦W; 
{\ttfamily ls} ¬O¤@­Ó«ü¥O¡M¥i¥H³Q°õ¦æ¡M¦ý¬O {\ttfamily LS} «o¤£¬O«ü¥O¡M·|¥X²{¿ù»~°T®§¡C
\item  ÀÉ¦Wªº²Ä¤@­Ó¦r¤¸¦pªG¬O¤@ÂI¡§¡E¡¨¡M«h³o­ÓÀÉ¦W¬O`ÁôÂÃÀÉ' ¡]¤]´N¬O»¡¡M¦pªG¤£¥[¯S§O«ü¥Oªº¸Ü¡M¤@¯ëªº ls ±N¤£·|Åã¥Ü¥X³o¨ÇÁôÂÃÀÉ¡^¡M
¦ÓÀÉ®×ªºµ²§À¦pªG¬O¡§³L°C¸¹¡¨'{\ttfamily \~{}}' ¡M³oªí¥Ü³Æ¥÷ÀÉ®×¡]©Î¬O¼È¦sÀÉ¡^¡E

\end{itemize}


²{¦b¡M¤Uªí¾ã²z¥X§â VMS ªº«ü¥O¹ïÀ³¨ì Linux ¤Wªº«ü¥O¡E

\begin{tscreen}
\begin{verbatim}

VMS                                     Linux
---------------------------------------------------------------------

$ COPY file1.txt file2.txt              $ cp file1.txt file2.txt
$ COPY [.dir]file.txt []                $ cp dir/file.txt .
$ COPY [.dir]file.txt [-]               $ cp dir/file.txt ..
$ DELETE *.dat;*                        $ rm *dat
$ DIFF file1 file2                      $ diff -c file1 file2
$ PRINT file                            $ lpr file
$ PRINT/queue=queuename file            $ lpr -Pprintername file
$ SEARCH *.tex;* "geology"              $ grep geology *tex
\end{verbatim}
\end{tscreen}


¨ä¥L¹ï©ó¥Ø¿ý¤è­±ªº«ü¥O¡M½Ð¨£¤@³¹¸`¡FÀÉ®×ªºÄÝ©Ê¡]protections, ownership...¡^½Ð°Ñ·Ó \ref{Advanced Topics} {(¶i¶¥)}¡C




\subsection{¥Ø¿ý}



\begin{itemize}
\item  ¦b¦P¤@­Ó¸`ÂI¡]node¡^©Î¬O¸Ë¸m¡]device¡^¡M¦b VMS ¤W¡M¥Ø¿ýªº§Î¦¡¬Ý°_¨ÓÀ³¸Ó¹³³o¼Ë¡G{\ttfamily [top.dir.subdir]}; 
¦b Linux ¤W¬O¡G{\ttfamily /top/dir/subdir/}. ¹ï¤W¼hªº¥Ø¿ý§Ú­ÌºÙ¬°¡§®Ú¥Ø¿ý¡¨¡]{\ttfamily /}¡^; 
©Ò¦³¤l¥Ø¿ý¡M³£¬O¥Ñ®Ú¥Ø¿ý¦V¤U©µ¦ù¡G {\ttfamily /bin},
{\ttfamily /usr}, {\ttfamily /tmp}, {\ttfamily /etc}, µ¥µ¥¡C
\item  ¥Ø¿ý¦WºÙ {\ttfamily /home} ¬O¦s©ñ¨Ï¥ÎªÌ¥Ø¿ý¡M¨Ò¦p¡G{\ttfamily /home/guido}, {\ttfamily /home/warner}, µ¥µ¥¡C
·í¨Ï¥ÎªÌµn¤Jªº®É­Ô¡M¦o­Ì·|µn¤J¨ì¦o­Ì¦Û¤v¾Ö¦³ªº¨Ï¥ÎªÌ¥Ø¿ý¡F³o©M {\ttfamily SYS\$LOGIN} ¬O¦³²§¦±¦P¤u¤§§®¡C
¤Á´«¨ì¥u¥ÎªÌ¥Ø¿ý¦³­Ó¤è«Kªº¤èªk¡G¨Ï¥Î¡§³L°C¸¹¡¨'{\ttfamily \~{}}'¡C
©Ò¥H¡M{\ttfamily cd \~{}/tmp} ©M {\ttfamily cd /home/guido/tmp} ¬O¤@¼Ëªº·N«ä¡C
\item  ¥Ø¿ý¦WºÙªº©R¦W¤è¦¡©MÀÉ®×¦WºÙªº©R¦W¤è¦¡¬Û¦P¡C ¦AªÌ¡M
¨C­Ó¥Ø¿ý³£·|¦³¨â­Ó¯S§Oªº¥Ø¿ý¦WºÙ¡G¤@­Ó¬O¡G{\ttfamily .} ¡Mªí¥Ü«ü¨ì¦Û¤vªº¥Ø¿ý¡C (¹³ {\ttfamily []})¡F
¤@­Ó¬O¡G{\ttfamily ..} ¡Mªí¥Ü«ü¨ì¤W¤@¼h¥Ø¿ý (¹³ {\ttfamily [-]})¡C
\end{itemize}
 

Åý§Ú­Ì¨Ó¬Ý¬Ý¨ä¥Lªº¨Ò¤l¡G

\begin{tscreen}
\begin{verbatim}

VMS                                     Linux
---------------------------------------------------------------------

$ CREATE/DIR [.dirname]                 $ mkdir dirname
$ CREATE/DIR [.dir1.dir2.dir3]          $ mkdirhier dir1/dir2/dir3
   n/a                                  $ rmdir dirname
                                        (if dirname is empty)
                                        $ rm -R dirname
$ DIRECTORY                             $ ls
$ DIRECTORY [...]file.*;*               $ find . -name "file*"
$ SET DEF SYS$LOGIN                     $ cd
$ SET DEF [-]                           $ cd ..
$ SET DEF [top.dir.subdir]              $ cd /top/dir/subdir
$ SET DEF [.dir.subdir]                 $ cd dir/subdir
$ SHOW DEF                              $ pwd
\end{verbatim}
\end{tscreen}


¹ï©óÀÉ®×ªºÄÝ©Ê¡]protections, ownership¡^¡MÁÙ¦³¤@¨Ç¶i¶¥¥DÃD¡M½Ð°Ñ·Ó \ref{Advanced Topics} {(¶i¶¥)}.




\subsection{µ{¦¡}



\begin{itemize}
\item  «ü¥O¡M½sÄ¶¹Lªºµ{¦¡¡]°õ¦æÀÉ¡^¡M©M shell scripts (VMS ¤Wªº `command files') ¨Ã¨S¦³±j¨î³W©w»Ý­n¦³¯S©wªº°ÆÀÉ¦W¡C
¹³ {\ttfamily .EXE} or {\ttfamily .COM} µ¥¡M¥u­n±z³ßÅw¡M±z·Q­n¦o¥s¤°»ò¦W¦r³£¥i¥H¡C
¦pªG±z¨Ï¥Î {\ttfamily ls -F} ¨Ó¹î¬Ý°õ¦æÀÉªº®É­Ô¡M±z·|µo²{°õ¦æÀÉ·|³Q¼Ð¥Ü¦¨ '{\ttfamily *}' ¡C
\item  ±ý°õ¦æ¥i°õ¦æªºµ{¦¡¡M¥u­n¿é¤J«ü¥O¦WºÙ´N¥i¥H¤F¡C¡]¨S¦³©Ò¿×ªº {\ttfamily RUN PROGRAM.EXE} ©Î¬O {\ttfamily @COMMAND})¡C 
ª`·N¡G³o­Ó°õ¦æÀÉ¥²¶·«ü©w¬Y¸ô®|¡C°ò¥»¤W¡M¹w³]¿ý¸g¥]§t¤F {\ttfamily /bin},
{\ttfamily /usr/bin}, {\ttfamily /usr/X11R6/bin}, µ¥µ¥¡C ¦pªG¡M±z¦Û¤v¼g¤F¤@­Óµ{¦¡¡M
±z¥i¥H±N³o­Óµ{¦¡©ñ¦b±z¦Û¤vªº¹w³]¸ô®|¤¤¡]¦p¦ó¾Þ§@¡M½Ð°Ñ·Ó \ref{Configuring} {(³]©w)}¡^¡C
©Î¬O±z¤]¥i¥H«ü©w¤@­Óµ´¹ï¸ô®|¨Ó°õ¦æ³o°¦µ{¦¡¡M¨Ò¦p¡G{\ttfamily /home/guido/data/myprog}; ©Î¬O
¨Ï¥Î¬Û¹ï¸ô®| {\ttfamily ./myprog} ¡C
\item  «ü¥Oªº°Ñ¼Æ¦b VMS ¤W¬O¨Ï¥Î {\ttfamily /OPTION=} ¨Ó§¹¦¨¡M¦Ó¦b Linux ¤W¡M
§Ú­Ì¨Ï¥Î {\ttfamily -switch} ©Î¬O {\ttfamily --switch} ¡]{\ttfamily switch} °Ñ¼Æ¥i¯à¬O¤@­Ó¦r¤¸¡M³\¦h¦rªº²Õ¦X¡M©Î¬O¤@­Ó¦r¡^¡C
¤ñ¸û¯S§Oªº¡M°Ñ¼Æ {\ttfamily -R} (recursive) ¦b Linux ¤W©M ¦b VMS ¤W {\ttfamily [...]} §êºtµÛ¬Û¦Pªº¥\¯à;
\item  ¦b©R¥O¦C¤¤¡M±z¥i¥H¤@¦¸¤U«Ü¦h­Ó«ü¥O¡G

\begin{tscreen}
\begin{verbatim}
$ command1 ; command2 ; ... ; commandn
\end{verbatim}
\end{tscreen}

\item  Linux ¤j³¡¤Àªº¼u©Ê¨Ó¦Û©ó¨â­Ó¯S©Ê¡M¦Ó³o¨â­Ó¯S©Ê¦b VMS ¤W«o«ÜÃø³Qªí¥Ü¥X¨Ó¡M©Î¬O®Ú¥»´N¨S¦³¡C
¦o­Ì¤À§O¬O¡GI/O ­«¾É(redirection) ©M ºÞ¹D (piping)¡C ¡]´¿¸g¦³¤H§i¶D§Ú³Ìªñªº DCL ª©¥»¦³¤ä´©­«¾É(redirection)©MºÞ¹D(piping)¡M
¥i¬O§Ú¨S¦³¨º­Óª©¥»¡^¡C­«¾É(redirection) ¦b VMS ¤W¥u¬O±qÄÝªº¯S¼x¡]¹³«ü¥O¸Ìªº°Ñ¼Æ {\ttfamily /OUTPUT=} ¡^¡M 
©Î¬O¤@­ÓÃø°Q¦nªº¦æµ{(process)¡C
¨Ò¦p¡G

\begin{tscreen}
\begin{verbatim}
$ DEFINE /USER SYS$OUTPUT OUT 
$ DEFINE /USER SYS$INPUT IN
$ RUN PROG
\end{verbatim}
\end{tscreen}


¦b Linux ´N¥u­n³o¼Ë´N¥i¥H¹F¦¨¡G

\begin{tscreen}
\begin{verbatim}
$ prog < in > out
\end{verbatim}
\end{tscreen}


Piping ¹ê»Ú¤W¦b VMS ¤W¨Ã¨S¦³´£¨Ñ¡M¦ý¬O¦b Linux «o¬O¤@­Ó­«­nªº¨¤¦â¡C
¨å«¬ªº¨Ò¤l¦p¤U¡G

\begin{tscreen}
\begin{verbatim}
$ myprog < datafile | filter_1 | filter_2 >> result.dat 2> errors.log &
\end{verbatim}
\end{tscreen}


·N«ä¬O»¡¡Gµ{¦¡ {\ttfamily myprog} ¾É¤J¤@­ÓÀÉ®×¬° input ¡]¥Ñ ¡§{\ttfamily $<$}¡¨Åª¤JÀÉ®× {\ttfamily datafile}¡^¡C
¨ä°õ¦æ«áªºµ²ªG³QÂà¬°(pipe)¥t¤@­Óµ{¦¡(filter\_1) ªº input¡M³B²z«á±o¨ìªºµ²ªG¦AÂà¬°¥t¥~¤@°¦µ{¦¡(filter\_2)ªº input¡M
¦A§@¶i¤@¨Bªº³B²z«á¡M³Ì«áªºµ²ªG³Qªþ¥[¨ì result.dat ÀÉ®×¤W¡M±N¿ù»~°T®§ÂÐ»\¨ì errors.log ªºÀÉ®×¤W¡C
¦Ó³o¤@¤Áªº°Ê§@¡M³£¦b­I´º°õ¦æ¡C
·Q­n¬Ý§óºë±mªº¨Ò¤l¡M½Ð°Ñ·Ó \ref{Examples} {(¹ê¨Ò)}.
\end{itemize}
 

¹ï©ó¦h¤u¡M`queues', ©Î¨ä¥LÃþ¦ü¥DÃD¡M½Ð°Ñ¾\ \ref{Advanced Topics} {(¶i¶¥)}.




\subsection{§Ö³tÂsÄý \label{Quick Tour}}



²{¦b±z¥i¥H¨Ó¸Õ¸Õ Linux ªº«Â¤O¤F¡C¿é¤J±zªº login name ©M password¡C°²³]±zªº login name ¬O
{\ttfamily john} ¡MPassword ¬O {\ttfamily My\_PassWd}, {\itshape ¤£­n\/} ¿é¤J {\ttfamily John} ©Î¬O {\ttfamily my\_passwd}¡C
°O¦í¡M¤j¤p¼g¹ï Unix ¨Ó»¡¡M¬O¤£¦Pªº·N«ä¡C

¤@·í±zµn¤J«á¡M±z´N·|¬Ý¨ì¨t²Î´£¥Ü²Å¸¹(prompt)¡F¥i¯à¬Ý°_¨Ó¹³ {\ttfamily machinename:\$}¡C 
¦pªG±z·Q§ó§ï±zªº¨t²Î´£¥Ü²Å¸¹¡M©Î¬O¦b±z¤@ Login «á´N¦Û°Ê°õ¦æ¤@¨Çµ{¦¡¡M±z¥i¯à»Ý­n¥h½s¿è¤@­ÓÁôÂÃÀÉ¡]{\ttfamily .profile} ©Î¬O {\ttfamily .bash\_profile}¡^¡C
¡]¹ê¨Ò½Ð°Ñ·Ó¡§²ÕºA³]©w¡¨¤@³¹¸` \ref{Configuring} {(³]©w)}¡^¡C
³o©M VMS ¤Wªº{\ttfamily LOGIN.COM} ¦³²§¦±¦P¤u¤§§®¡C

±z¥i¥H¨Ï¥Î ALT--F1, ALT--F2, ... ALT--F6 ¨Ó¤Á´«¤»­Ó `virtual consoles'¡C
·í±z¨ä¤¤ªº¤@­Ó virtual consoles ¥¿¦b¦£©ó³B²z¬Y¤@°¦µ{¦¡ªº®É­Ô¡M±z¥i¥H¥ô·Nªº¤Á´«¨ì¥ô¦ó¤@­Ó virtual consoles Ä~Äò±z¨ä¥Lªº¤u§@¡C
¸ÕµÛ¤Á´«µn¤J¨ì¨ä¥Lªº virtual consoles §a¡I

²{¦b±z¥i¯à·Q­n¶}©l°õ¦æ X Windows ¤F§a¡]¥H«á§Ú­ÌÂ²ºÙ¬° X¡^¡CX ¬O¹Ï§Î¬É­±Àô¹Ò¡M
¦³ÂI¹³ DECWindows --- ¹ê»Ú¤W¡MDECWindows ¬O­l¥Í¦Û X Window system.
½Ð¿é¤J {\ttfamily startx} ¨Ã¥Bµ¥«Ý´X¬í±z±N·|¬Ý¨ì {\ttfamily xterm} ©Î¬O¨ä¥LÃþ¦üªº²×ºÝ¾÷¼ÒÀÀµ{¦¡³Q¶}±Ò¡M
¥i¯àÁÙ·|¦³¤@­Ó¤u§@¦C¡C¡]µø±z¨t²ÎºÞ²z­û¦p¦ó³]©w¡M¤£¤@¼Ëªº³]©w¡M©Ò¬Ý¨ìªºµ²ªG±N·|¤£¦P¡^¡C
¸ÕµÛ¦b®à­±¤W¦P®É«ö¤U·Æ¹«ªº¥ª¥kÁä¡M±z¥i¥H¬Ý¨ì¤@­Ó¼u¸õµø¿ï³æ¥X²{¡]·Æ¹««öÁäªº¥\¯à¤]¦]³]©w¤£¦P¦Ó¦³¤£¦Pªº¥\¯à¡^¡C

¶i¤J X «á¡M¦pªG·Q­n°õ¦æ¤å¦r¼Ò¦¡ªº²×ºÝ¾÷ (`console') ¦P®É«ö¦í¤U¦C¥ô¤@²Õ«öÁä¡G
CTRL--ALT--F1 ... CTRL--ALT--F6 ¡]»Ý­n¦P®É«ö¡^¡C¬O¬Ý¬Ý¡I¦pªG·Q­n¸õ¦^µøµ¡¬É­±¡M¥i¥H
¦P®É«ö¤U ALT--F7 ´N¥i¥H¤F¡C±ýµ²§ô X ¡M³oµÛ¿ï³æ¤Wªº exit ¿ï¶µµ²§ô¡M©Î¬O¦P®É«ö¤U
CTRL--ALT--BS.

¿é¤J¤U¦C«ü¥O¡M¥i¥H¦C¥X±z²{¦b¥Ø¿ý¤UªºÀÉ®×¡]¥]¬AÁôÂÃÀÉ¡^¡G

\begin{tscreen}
\begin{verbatim}
$ ls -al
\end{verbatim}
\end{tscreen}


«ö SHIFT--PAG UP ¥i¥H©¹¦^±²¨ì¥H«eªº¿Ã¹õ¡C

²{¦b§Ú­Ì¨Ó¬Ý¬Ý«ü¥O {\ttfamily ls} ªº»¡©úÀÉ(help)¡M
¿é¤J¡G

\begin{tscreen}
\begin{verbatim}
$ man ls
\end{verbatim}
\end{tscreen}


«ö¤U 'q' ¥i¥H¸õ¥X¡C¦pªG­nµn¥X¡M¥i¥H¿é¤J {\ttfamily exit} µn¥X¥Ø«e²×ºÝ¾÷¡C
¦pªG·Q­nÃö¾÷¡M¥i¥H¦P®É«ö¤U CTRL--ALT--DEL ¨Ã¥Bµ¥±a¼Æ¬í´N¥i¥H¤F¡C
({\itshape ª`·N¡G\/} µ´¹ï¤£­nª½±µ´NÃö±¼±z¹q¸£¤Wªº¹q·½¡M½Ð«ö·Ó¤@©wªºÃö¾÷µ{§Ç¤~¥i¥HÃö±¼¹q·½¡M¤£µM¥i¯à·|¶Ë®`¨ìÀÉ®×¨t²Î¡^¡C

¦pªG±z·Q±z¤w¸g¥i¥H¤W¸ô¤F¡M¨º´N©ñ¤â¥h§@§a¡I¦ý¬O¡M¦pªG§Ú¬O±zªº¸Ü¡M¥i·|¥ý¸õ¨ì¶i¶¥¥DÃD³o¤@³¹¸`¡G
\ref{Advanced Topics} {(¶i¶¥)}.






\section{ÀÉ®×½s¿è \label{Editing Files}}



Linux ¨S¦³ {\ttfamily EDT} ½s¿è¾¹¡M¦ý¬O¦³«Ü¦hªº½s¿è¾¹¿ï¾Ü¥i¨Ñ¨Ï¥Î¡C
¦b©Ò¦³UNIX ¨t²Î¤¤¡M°ß¤@«OÃÒ¤@©w¦³{\ttfamily vi} ³o­Ó½s¿è¾¹---ºâ¤F§a¡M
±zªº¨t²ÎºÞ²z­û¤@©w¤w¸g¦w¸Ë¤ñ vi §ó¦n¥Îªº½s¿è¾¹¤F¡C¥i¯à¤ñ¸û¨üÅwªïªº½s¿è¾¹¬O
{\ttfamily emacs}¡M³o¥i¥H¥Î¨Ó¼ÒÀÀ VMS ¤Wªº {\ttfamily EDT} ; {\ttfamily jed} 
¬O¥t¤@ºØÃþ¦ü {\ttfamily EDT} ªº½s¿è¾¹¡C

³o¨âºØ½s¿è¾¹¥Î¨Ó½s¼gµ{¦¡½X¬Û·íªº¹ê¥Î¡M¦]¬°¦o­Ì¦³¨â­Ó {\ttfamily EDT} ¨S¦³ªº¥\¯à¡G
°ª«G«×¬ÛÃö¦r¡]syntax hilighting¡^©M¦Û°ÊÁY±Æ¡]automatic indentation¡^¡C 
¦Ó¥B¡M±z¥i¥H¤£»Ý­n¸õ¥X½s¿è¾¹¡M´N¥i¥Hª½±µ¦b½s¿è¾¹¸Ì½sÄ¶¡]Compile¡^±zªºµ{¦¡¡C
(command {\ttfamily ESC-X compile}); ¦pªG¦³»yªk¿ù»~¡M´å¼Ð±N·|¦Û°Ê¸õ¨ì¦³¿ù»~ªº¦a¤è¡C
§Ú´±¥´½ä±z±N¤£·|·Q¦A¬Ý¨ì¨º¥u¦³ÂÅ¦âªº {\ttfamily EDT} ¤F¡C

¦pªG±z¦³ {\ttfamily emacs}: ±Ò°Ê¦o¡MµM«á¿é¤J {\ttfamily ESC-X edt-emulation-on}¡C
Áä¤J ALT--X or ESC-X ¥i¥H¸õ¥X {\ttfamily emacs}¡M¹³ {\ttfamily EDT} ªº CTRL--Z¡C
±q²{¦b¶}©l¡M{\ttfamily emacs} ´N¹³ {\ttfamily EDT} ¤@¼Ë¡M°£¤F¤@¨Ç«ü¥O¤£¤Ó¤@¼Ë¡C
¤£¦P³B¡G

\begin{itemize}
\item  {\itshape ¤£¦æ\/} ¨Ï¥Î CTRL--Z ¨Ó°õ¦æ©R¥O¦C«ü¥O¡C (¦pªG±z°µ¤F¡M±zªº emacs ±N·|°±¤î¤u§@¡M
¤£¹L±z¥i¥H¸ÕµÛ¿é¤J {\ttfamily fg} ¨ÓÄ~Äò±zªº emacs);
\item  Emacs ¦³¤j¶qªº½u¤W»¡©ú¡]on-line help¡^¡C«ö CTRL-H ?, ©Î¬O CTRL-H T ±Ò°Ê¡C;
\item  ¦sÀÉ¡G CTRL-X CTRL-S;
\item  Â÷¶}¡G CTRL-X CTRL-C;
\item  ·s¼W¤@­ÓÀÉ®×¡G CTRL-X CTRL-F, µM«á CTRL-X B ¥i¥H¦b­ÓÀÉ®×¤¤§@¤Á´«¡C
\end{itemize}


¦pªG±z¦³ {\ttfamily jed}¡G ¥i¥H½Ð±zªº¨t²ÎºÞ²z­û«ê·í¦a³]©w {\ttfamily jed} ¡C
·í±z±Ò°Ê¦o«á¡M¼ÒÀÀ¾¹´N¤w¸g¦Û°Ê¸ü¤J¡C¥i¥H¨Ï¥Î CTRL--H CTRL--H or CTRL-? 
±Ò°Ê½u¤W»¡©ú¡C«ü¥O³¡¥÷¡M¤j­P¤W©M {\ttfamily emacs} ¬Û¦P¡C ¦¹¥~¡M
ÁÙ¦³¤@¨Ç©ö©ó¾Þ§@ªº¾Þ§@Áä¨S¦³³Q¸Ë­q¦b­ì¨Óªº {\ttfamily EDT} ¤¤; 
³o¨Ç¾Þ§@Áä¥i¥H¨Ì±zªº­Ó¤H³ß¦n¦Û¦æ³]©w¡M½Ð¸ß°Ý±zªº¨t²ÎºÞ²z­û¡C

©Î³\±z¥i¯à·|¨Ï¥Î¥t¤@­Ó§¹¥þ¤£¤@¼Ë¾Þ§@¬É­±ªº½s¿è¾¹¡C¦ý¬O {\ttfamily emacs} ª½Ä±¤W·|¬O¤@­Ó¤£¿ùªº¿ï¾Ü¡C
¥t¤@­Ó¤Q¤À¨üÅwªïªº½s¿è¾¹¬O¡G{\ttfamily joe}, ¦o¥i¥H¼ÒÀÀ¨ä¥L½s¿è¾¹¡M¹³ {\ttfamily emacs} ¡C
(¬Æ¦Ü§ó®e©ö¤W¤â) ©Î¬O Dos ªº½s¿è¾¹¡C ±Ò°Ê³o­Ó½s¿è¾¹´N¹³ {\ttfamily jmacs} ©Î¬O {\ttfamily jstar} ¤@¼Ë¡M
¥i¥H¨Ï¥Î CTRL-X H ©Î¬O CTRL-J ±o¨ìÂ×´Iªº½u¤W»¡©ú¡C
{\ttfamily emacs} ©M {\ttfamily jed} ¤ñ {\ttfamily EDT} §ó¨ã¦³«Â¤O¡C






\section{TeXing \label{TeXing}}



TeX ©M LaTeX ¦b Linux ¤W§¹¥þ©M VMS ¤@¼Ë---¤£¦Pªº¦a¤è¬O¡MLinuxªº°õ¦æ³t«×§ó§Ö :-),
³o­Ó¤u¨ã¥Î¨Ó³B²z {\ttfamily .dvi} ©M {\ttfamily .ps} ªºÀÉ®×§ó­ÑÀu¶Õ¡G

\begin{itemize}
\item  ¥Ñ TeX °õ¦æ TeX ÀÉ¡M´N¹³¥­±`¤@¼Ë¡G {\ttfamily tex file.tex};
\item  Âà´« {\ttfamily .dvi} ¾×¨ì {\ttfamily .ps} ÀÉ¡M¿é¤J
{\ttfamily dvips -o filename.ps filename.dvi};
\item  ÀËµø {\ttfamily .dvi} ÀÉ¡M¦b X Window ¤U¿é¤J¡G
{\ttfamily xdvi filename.dvi \&}. ¦bÅã¥Ü­¶«ö¤U·Æ¹«¥i¥H©ñ¤j¡C
³o¬O¤@­Ó´¼¼z«¬ªºµ{¦¡¡G¦pªG±z½s¿è¥B°õ¦æ TeX ²£¥Í¤@­Ó¸û·sª©¥»ªº {\ttfamily .dvi} 
ÀÉ®×¡M{\ttfamily xdvi} ·|¦Û°Ê§ó·s;
\item  ÀËµø {\ttfamily .ps} ÀÉ¡M ¦b X Window ¤U¿é¤J {\ttfamily ghostview
filename.ps \&}. «ö·Æ¹«¥i¥HÁY©ñ¡C ¥þ³¡ªºÀÉ®×©Î¬O³¡¥÷ÀÉ®×¥i¥H³Q¦C¦L¥X¨Ó¡C
µM¦ÓÁÙ¦³¤@­Ó¤ñ TeX §ó¦nªºµ{¦¡¡G{\ttfamily gv}.
\item  ¦C¦L {\ttfamily .ps}: ³q±`«ü¥O¬O {\ttfamily lpr mypaper.ps} ¡M¦ý¬O¦pªG PostScript ¦Cªí¾÷³Q©I¥s¡]°²³]¨Ï¥Î ps «ü¥O¡^
±z±N·|¬O°õ¦æ¡G {\ttfamily lpr -Pps mypaper.ps}¡C¹ï©ó§ó¦h¦³Ãö print queues ªº°T®§¡M½Ð°Ñ·Ó
\ref{Print Queues} {(¦C¦L°ð)}.
\end{itemize}







\section{µ{¦¡ \label{Programming}}



¦b Linux ¤W¼gµ{¦¡§ó¬OµÎªA¡G¦³³\¦h¦n¥Î±o¤u¨ã¥i¥HÅý¼gµ{¦¡§ó¥[§Ö³t§ó¥[Â²³æ¡C
¨Ò¦p¡G¼gµ{¦¡µL«D¬O³æ½Õ¨H´eªº¤u§@¡G½s¿è--¦sÀÉ--Â÷¶}--½sÄ¶--­«·s½s¿è ¤@ª½¤ÏÂÐªº°õ¦æ¦P¼Ëªº°Ê§@¡C
¦ý¬O¡M¦pªG¨Ï¥Î¹³ {\ttfamily emacs} ©Î¬O {\ttfamily jed} µ¥¤u¨ã¡M¤W­z¨º¨Ç°Ê§@¡M±N²Î¤@¾ã¦X¦b½s¿è¾¹¸Ì¡M¤@¦¸§¹¦¨¡C




\subsection{Fortran}



¤jÅé¤W¡M¨S¦³¦h¤jªº®t§O¡M¦ý¬O½Ðª`·N¡M³o­Ó§K¶Oªº½sÄ¶¾¹¥i¤£¬O¦Ê¤À¤§¦Êªº©M VMS ¬Û®eªº¡C
¥i¯à·|¦³¨Ç©_©Çªºµ²ªGµo¥Í¡C¡]¹ê»Ú¤W¡MVMS ªº Fortran ½sÄ¶¾¹¨Ã¤£¬O¤@­Ó¥i¥H¼Ð·Ç©µ¦ùªº(non-standard)¡^¡C
¸Ô²Ó±¡§Î½Ð¬Ý {\ttfamily /usr/doc/g77/DOC} or {\ttfamily /usr/doc/f2c/f2c.ps}
¡C

±zªº¨t²ÎºÞ²z­û¤w¸g¦w¸Ë¤F¤@­Ó¥s°µ {\ttfamily g77} ªº compiler (¤£¿ù¦ý¬O, ¦b
0.5.21 ª©, ÁÙ¬O¨S¦³§¹¥þ©M DEC ªº Fortran ¦Ê¤À¦Ê¦a¬Û®e) ¡M©Î¬O¤@­Ó§â Fortran Âà¦¨ C »y¨¥ªºÂà´«¾¹¡M¥s°µ {\ttfamily f2c}¡C 
¥[¤W¦oªº¤@­Ó«eºÝ(front-ends)¸Ë¸m¡M¼ÒÀÀ´N¹³¬O¤@­Ó Fortran ½sÄ¶¾¹¡C
¨Ì§Úªº¸gÅç¡M{\ttfamily yaf77} ®M¥ó´£¨Ñ³Ì¦nªº¸Ñ¨M¤è®×¡C

±ý¨Ï¥Î {\ttfamily g77} ¨Ó compile ±zªº Fortran µ{¦¡, ¥ý¥Î¥ô·N½s¿è°O½s¿èµ{¦¡½X¡M¥H°ÆÀÉ¦W {\ttfamily .f} ¦sÀÉ¡M
µM«á°õ¦æ¦p¤U¡G

\begin{tscreen}
\begin{verbatim}
$ g77 myprog.f
\end{verbatim}
\end{tscreen}


¦o·|¦Û°ÊÀ°±z²£ºÙ {\ttfamily a.out} ªº°õ¦æÀÉ¡C(±z¤£»Ý­n§@¥ô¦ó link ªº°Ê§@¡^
¦pªG·Q­n²£¥Í¤£¦Pªº°õ¦æÀÉÀÉ¦W¡M¥i¥H¤U°Ñ¼Æ¡G

\begin{tscreen}
\begin{verbatim}
$ g77 -O2 -o myprog myprog.f
\end{verbatim}
\end{tscreen}


½Ðª`·N³Ì¨Î¤Æ¡I­n¨D±zªº¨t²ÎºÞ²z­û²ÓÅª½sÄ¶¾¹ªº»¡©ú¤å¥ó¡M¨Ã¥B§iª¾±z¬O§_ÁÙ¦³¥ô¦óªº¦s¦b°ÝÃD¡C

½sÄ¶¤¤¶¡½X(subroutine)¡G

\begin{tscreen}
\begin{verbatim}
$ g77 -c mysub.f
\end{verbatim}
\end{tscreen}


³o·|²£¥Í {\ttfamily mysub.o} ³o­ÓÀÉ®×¡C µM«á±z»Ý­n§@³sµ²(link)ªº°Ê§@¡C

\begin{tscreen}
\begin{verbatim}
$ g77 -o myprog myprog.f mysub.o
\end{verbatim}
\end{tscreen}


¦pªG±z·Q§@¦¨¨ç¼Æ®w(library)¡M±z¥i¥H³o¼Ë§@¡G

\begin{tscreen}
\begin{verbatim}
$ cd subroutines/
$ cat *f >mylib.f ; g77 -c mylib.f
\end{verbatim}
\end{tscreen}


³o·|²£¥Í¥X {\ttfamily mylib.o} ¡M±z¥i¥H¨Ï¥Î¦o¨Ó³sµ²±zªºµ{¦¡¡C

³Ì«á¡M¦pªG­n link ¨ä¥Lªº¨ç¼Æ®w(library)¡M§Ú­Ì°²³] {\ttfamily libdummy.so}:

\begin{tscreen}
\begin{verbatim}
$ g77 -o myprog myprog.f -ldummy
\end{verbatim}
\end{tscreen}


¦pªG±z¨Ï¥Î {\ttfamily f2c}, ±z¥u¯à¨Ï¥Î {\ttfamily f77} ©Î¬O {\ttfamily fort77} ¡M¦Ó¤£¯à¨Ï¥Î {\ttfamily g77}¡C

¥t¤@­Ó¦³¥Îªº¤u¨ã¬O {\ttfamily make}, ¸Ô­z¦p¤U¡G






\subsection{¦p¦ó¨Ï¥Î {\ttfamily make}}



{\ttfamily make} ¥i¥H¥Î¨Ó½s¿è«Ü¦h¤À´²©ó­ÓÀÉ®×ªº­ì©l½X¡C¦b VMS ¤W§Ú­ÌºÙ¬° {\ttfamily MMS}
©M {\ttfamily MMK}, ¦ý¬O¦o­Ì©M Linux ¦³¤£¦Pªº»yªk¡C

°²³]±z¦³¤@¨Ç­ì©lµ{¦¡¡M»Ý­n§@¨Ç¨Ò¦æµ{§Ç¡Cµ{¦¡¤À§O¬° {\ttfamily file\_1.f,
file\_2.f, file\_3.f}, ¥Dµ{¦¡¬° {\ttfamily myprog.f}¡C ¦pªG±z¬O¤â°Ê½sÄ¶±zªºµ{¦¡¡M¨C·í±z­×§ï±zªºµ{¦¡½X«á¡M
±z¥²¶·ª¾¹D­þ­ÓÀÉ®×©M­þ­ÓÀÉ®×¦³Ãö³s¡M­þ­ÓÀÉ®×¥²¶·¥ý½sÄ¶¡Mµ¥µ¥¡C

»P¨äµoºÆ¡M¤£¦p±z¥i¥H¼g­Ó `makefile'¡C ³o¬O¤@­Ó¤å¦rÀÉ¡M¸Ì­±°O¿ýµÛ±zµ{¦¡½X»Pµ{¦¡½X¤§¶¡ªºÃö³s©Ê¡C
·í¨ä¤¤¤@­ÓÀÉ®×³Q­×§ï«á¡M¥u¦³»P³o­Ó³Q­×§ïªºÀÉ®×¦³¬ÛÃöªºÀÉ®×»Ý­n³Q­«·s½sÄ¶¡C

¨Ò¦p¡M±z¼g¤F¤@­Ó makefile ¦p¤U¡G

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

# ³o¬O¤@­Ó makefile
# ¨Ï¥Î <TAB> Áä¡M·í±z¨£¨ì <TAB> ¼ÐÅÒ®É!
# ³o«D±`ªº­«­n¡M½Ð¤£­n¨Ï¥ÎªÅ¥ÕÁä¥N´À¡C

myprog: myprog.o file_1.o file_2.o file_3.o
<TAB>g77 -o myprog myprog.o file_1.o file_2.o file_3.o
# myprog depends on four object files

myprog.o: myprog.f
<TAB>g77 -c myprog.f
# myprog.o depends on its source file

file_1.o: file_1.f
<TAB>g77 -c file_1.f
# file_1.o depends on its source file

file_2.o: file_2.f file_1.o
<TAB>g77 -c file_2.f file_1.o
# file_2.o depends on its source file and an object file

file_3.o: file_3.f file_2.o
<TAB>g77 -c file_3.f file_2.o
# file_3.o depends on its source file and an object file

# end of makefile.
\end{verbatim} 
\nopagebreak\hrule 
\addvspace{\medskipamount}


Àx¦s³o­ÓÀÉ®×¡M©R¦W¬° {\ttfamily Makefile} ¥B¦b©R¥O¦C¿é¤J {\ttfamily make} ¨Ó½sÄ¶±zªºµ{¦¡;
©Î¬O±z¤]¥i¥H±N¦o¦s¦¨ {\ttfamily myprog.mak} µM«á¨Ï¥Î {\ttfamily make -f myprog.mak} ¨Ó½sÄ¶.
±µ¤U¨Óªº«áÄò°Ê§@, RMP.¡]ÁÙ°O±o¤°»ò¬O RMP §a¡I¡^






\subsection{Shell Scripts}



Shell scripts ´N¹³ VMS ¤Wªº command files¡C, ³o¥i¥H«Øºc¥X«D±`¦³¥Îªº¥\¯à¡C

­n¼g¤@­Ó script, ±z©Ò­n§@ªº´N¥u¬O¼g¤@­Ó¥]§t¤@¨Ç«ü¥Oªº¤å¦rÀÉ¡MµM«á¦sÀÉ¡M§ïÅÜ¦¨¥i°õ¦æªº¼Ò¦¡
¡]¨Ï¥Î {\ttfamily chmod +x $<$scriptfile{$>$}}¡^¡C ¥u­n¿é¤J¸Ó Script ªº¦W¦r´N¥i¥H°õ¦æ¤F¡C

¼g¤@­Ó Script ¬O¤@­Ó«D±`­«¤jªº¤uµ{¡M³o»Ý­n¤@¥»®Ñ¡C³o¸Ì§Ú´N¤£¦A¦h°µ»¡©ú¤F¡C

§Ú¥uµ¹±z¤@­Ó©Î¦h©Î¤Öªººî¦Xªº¡]§Æ±æ¡^¦³¥Îªº¨Ò¤l¡M±z©Î³\¥i¥H±q³o­Ó¨Ò¤l¤¤±o¨ì¤@¨Ç°ò¥»ªº³W«h¡C

EXAMPLE: sample.sh

\par
\addvspace{\medskipamount}
\nopagebreak\hrule
\begin{verbatim}
#!/bin/sh
# sample.sh
# I am a comment
# ¤£­n­×§ï²Ä¤@¦æ¡M¦o¥²¶·¥H³oºØ§Î¦¡¦s¦b¦b²Ä¤@¦æ¡I¡I¡I
echo "This system is: `uname -a`" # use the output of the command
echo "My name is $0" # built-in variables
echo "You gave me the following $# parameters: "$*
echo "First parameter is: "$1
echo -n "What's your name? " ; read your_name
echo notice the difference: "hi $your_name" # quoting with "
echo notice the difference: 'hi $your_name' # quoting with '
DIRS=0 ; FILES=0
for file in `ls .` ; do
  if [ -d ${file} ] ; then # if file is a directory
    DIRS=`expr $DIRS + 1`  # this means DIRS = DIRS + 1
  elif [ -f ${file} ] ; then
    FILES=`expr $FILES + 1`
  fi
  case ${file} in
    *.gif|*jpg) echo "${file}: graphic file" ;;
    *.txt|*.tex) echo "${file}: text file" ;;
    *.c|*.f|*.for) echo "${file}: source file" ;;
    *) echo "${file}: generic file" ;;
  esac
done
echo "there are ${DIRS} directories and ${FILES} files"
ls | grep "ZxY--!!!WKW"
if [ $? != 0 ] ; then # exit code of last command
  echo "ZxY--!!!WKW not found"
fi
echo "enough... type 'man bash' if you want more info."
\end{verbatim} 
\nopagebreak\hrule 
\addvspace{\medskipamount}





\subsection{C »y¨¥\label{C}}



Linux ¬O¤@­Ó¼g ¢Ñ»y¨¥ªº¦n¦a¤è¡C´N°²³]±z·|¢Ñ»y¨¥§a¡I³o¸Ì¤]´X­Ó«ü¾É¤è°w¡C
½sÄ¶±zªºµ{¦¡{\ttfamily hello.c} ¡M±z·|¨Ï¥Î¨ì {\ttfamily gcc} compiler, ³o¤w¬O Linux ªº¤@³¡¥÷¤F¡C
¦Ó¥B©M {\ttfamily g77} ¦³¬Û¦Pªº¨Ï¥Î¤èªk:

\begin{tscreen}
\begin{verbatim}
$ gcc -O2 -o hello hello.c
\end{verbatim}
\end{tscreen}


³sµ²(link)¨ç¼Æ®w(library)¡M¥[¤J°Ñ¼Æ {\ttfamily -l$<$libname$>$}¡C
¨Ò¦p¡M­n link ¼Æ¾Ç¨ç¼Æ®w©M³Ì¨Î¤Æ¡M¥i¥H¤U¦p¤U«ü¥O¡G

\begin{tscreen}
\begin{verbatim}
$ gcc -O2 -o mathprog mathprog.c -lm
\end{verbatim}
\end{tscreen}


( {\ttfamily -l$<$libname$>$} °Ñ¼Æ±j­¢ {\ttfamily gcc} ³sµ²(link)¨ç¼Æ®w(library)
{\ttfamily /usr/lib/lib$<$libname$>$.a}; ©Ò¥H {\ttfamily -lm} ´N³sµ²¤F
{\ttfamily /usr/lib/libm.a}).

¦pªG±zªºµ{¦¡¬O¥Ñ³\¦hÀÉ®×²Õ¦¨ªº¡M±z¥i¯à¤]»Ý­n¨Ï¥Î«e­±©Ò´£¨ìªº {\ttfamily make} ³o­Ó¤u¨ã¡C
¦b makefile ¨Ï¥Î {\ttfamily gcc} ©M ¢Ñ»y¨¥ªº­ì©l½XÀÉ®×´N¥i¥H¤F¡C

±z¤]¥i¥HÀò±o¦³Ãö C »y¨¥ªº¨ç¼Æªº»¡©ú¡C³o¨Ç»¡©ú¤å¥ó³£¤w¸g³Q½s¦¨ man pages¡M²Ä¤T¸`(section 3) ¤F¡C
¨Ò¦p:

\begin{tscreen}
\begin{verbatim}
$ man 3 printf
\end{verbatim}
\end{tscreen}


¦P®É¡M¦³³\³\¦h¦hªº¨ç¼Æ®w¥i¨Ñ¨Ï¥Î¡C¨ä¤¤±z²Ä¤@·Q­n¨Ï¥Îªº¬O {\ttfamily ncurses}, 
³o¥i¥H¥Î¨Ó³B²z¤å¦r¼Ò¦¡¤Uªº¯S®Ä¡C©Î¬O {\ttfamily svgalib}, ³o¥i¥H¥Î¨Ó³B²z¹Ï§Î¼Ò¦¡¡C




\section{¹Ï§Î¬É­± \label{Graphics}}



¦b³\¦h¹Ï§Î®M¥ó¤¤¡M{\ttfamily gnuplot} ¯u¬O¨ä¤¤¤§Â¼·¡¡C¶i¤J X Window «á¿é¤J {\ttfamily gnuplot}, 
¥i¬OµÛÅª¤J¨â­Ó½d¨ÒÀÉ: {\ttfamily 2D-data.dat} (¨C¦æ¦³¨âµ§¸ê®Æ), ©M 
{\ttfamily 3D-data.dat} (¨C¦æ¦³¤Tµ§¸ê®Æ).

¨Ò¡G2-D graphs:

\begin{tscreen}
\begin{verbatim}
gnuplot> set title "my first graph"
gnuplot> plot '2D-data.dat'
gnuplot> plot '2D-data.dat' with linespoints
gnuplot> plot '2D-data.dat', sin(x)
gnuplot> plot [-5:10] '2D-data.dat'
\end{verbatim}
\end{tscreen}


¨Ò¡G3-D graphs (¨C¤@¦æ¤¤ªº¸ê®Æ¥HªÅ¥ÕÁä³Ì¬°¤À¹j):

\begin{tscreen}
\begin{verbatim}
gnuplot> set parametric ; set hidden3d ; set contour
gnuplot> splot '3D-data.dat' using 1:2:3 with linespoints
\end{verbatim}
\end{tscreen}


¥u¦³¤@¦æ¸ê®ÆªºÀÉ®×(¦p®É¶¡§Ç¦C)¤]¥i¥H³QÃ¸»s¦¨ 2-D ªº¹Ï§Î¡G

\begin{tscreen}
\begin{verbatim}
gnuplot> plot [-5:15] '2D-data-1col.dat' with linespoints
\end{verbatim}
\end{tscreen}


©Î¬OÃ¸¦¨ 3-D graph :

\begin{tscreen}
\begin{verbatim}
gnuplot> set noparametric ; set hidden3d
gnuplot> splot '3D-data-1col.dat' using 1 with linespoints
\end{verbatim}
\end{tscreen}


¦C¦L¹Ï§Î¡G°²³]±zªº Postscript ¦Cªí¾÷ªº«ü¥O¬O
{\ttfamily lpr -Pps file.ps}¡M¨BÆJ¦p¤U:

\begin{tscreen}
\begin{verbatim}
gnuplot> set term post
gnuplot> set out '| lpr -Pps'
gnuplot> replot
\end{verbatim}
\end{tscreen}


µM«á¿é¤J {\ttfamily set term x11} ¦^´_¦¨ x11 ¼Ò¦¡¡C
§OÃhºÃ¡M·í±zÂ÷¶} {\ttfamily gnuplot} «á¡M¤å¥ó±N·|¦Û°Ê¦C¦L¥X¨Ó¡C

§ó¦h°T®§¡M¥i¿é¤J {\ttfamily help} ©Î¬O°Ñ¨£¥Ø¿ý¤¤ªº½d¨Ò¡C
¡]{\ttfamily /usr/lib/gnuplot/demos/}¡^






\section{Mail ©M Internet ¤u¨ã \label{Mail and Internet Tools}}



¦]¬°ºô¸ô¬O½Ï¥Í¦b Unix ªº¾÷¾¹¤W¡M±z¥i¥H¦b Linux ¤Wµo²{³\¦h¦n¥Î¥B©ö¤W¤âªº³nÅé¡C
ªÌ¸Ì©Ò¦C¡M¥u¬O¨ä¤¤ªº¤@³¡¥÷¦Ó¤w¡G

\begin{itemize}
\item  {\bfseries Mail}: ¨Ï¥Î {\ttfamily elm} ©Î¬O {\ttfamily pine} ¨Ó³B²z±zªº email; ³o¨â­ÓÀ³¥Îµ{¦¡³£¦³½u¤W»¡©ú(Online Help)¡C
¹ï©ó¸ûµuªº°T®§¡M±z¥i¯à¨Ï¥Î {\ttfamily mail}, ¦p {\ttfamily mail -s "hello mate" user@somewhere {$<$} msg.txt}. 
±z¥i¯à·|·R¤W¹³ {\ttfamily xmail} ³o¼ËªºÀ³¥Îµ{¦¡¡M©Î¬OÃþ¦üªºµ{¦¡¡C
\item  {\bfseries Newsgroups}: ¥i¨Ï¥Î {\ttfamily tin} ©Î¬O {\ttfamily slrn}, ¨âªÌ³£¬Oª½Ä±¦¡¡M¥B¦Û§Ú¸ÑÅª(self-explanatory).
\item  {\bfseries ftp}: ±ý²æÂ÷¤å¦r¬É­±ªº {\ttfamily ftp} À³¥Îµ{¦¡, ­n¨D±zªº¨t²ÎºÞ²z­û¦w¸Ë¥þ¿Ã¹õ(full-screen)¼Ò¦¡ªº ftp ³nÅé¡M¦p {\ttfamily ncftp} ¡M
©Î¬O¹Ï§Î¬É­±ªº {\ttfamily xftp}.
\item  {\bfseries WWW}: ´¶¹M¦s¦bªº {\ttfamily netscape}, ©Î¬O {\ttfamily xmosaic},
{\ttfamily chimera}, ©M {\ttfamily arena} ³£¬O¹Ï§Î¬É­±ªºÂsÄý¾¹¡C¥t¥~ÁÙ¦³¤@­Ó¤å¦r¬É­±ªºÂsÄý¾¹ {\ttfamily lynx}, «D±`ªº§Ö³t¦Ó¥B¤S¦³®Ä²v¡C
\end{itemize}





\section{¶i¶¥ \label{Advanced Topics}}



¨ì³o­Ó¶¥¬q¡M¹CÀ¸´N¤ñ¸û½ÆÂø¤F¡C¾Ç§¹³o¨ÇªF¦è¡M±z´N¥i¥H»¡¡M§ÚÀ´¤@¨Ç Linux ªºªF¦è ;-)






\subsection{¤¹³\Åv(Permissions) ¤Î ©Ò¦³Åv(Ownership) \label{Permissions}}



ÀÉ®×©M¥Ø¿ý³£¦³¤¹³\Åv(Permission) (§Y VMS ¤Wªº `protections') ©M©Ò¦³Åv(ownership), 
³o­ÓÆ[©À¤£Ãø²z¸Ñ¡M¦]¬° VMS ¤W¤]¦³¡C¦pªG±z¤£¯à°õ¦æ¤@°¦µ{¦¡¡M©Î¬O±z¤£¯à­×§ï¬Y¤@ÀÉ®×¡M
©Î¬O¤£¯à¶i¤J¬Y¥Ø¿ý¡M³o¬O¦]¬°±z¨S¦³³Q½á¤©¨Ï¥Î³o¨Ç¸ê·½ªºÅv¤OªºÃö«Y¡]¨S¦³¤¹³\Åv¡^¡M
©ÎªÌ¬O³o­ÓÀÉ®×ªº®Ú¥»´N¤£ÄÝ©ó±zªº¡]¨S¦³©Ò¦³Åv¡^¡M
Åý§Ú­Ì¬Ý¬Ý¤U­±ªº¨Ò¤l§a¡G

\begin{tscreen}
\begin{verbatim}
$ ls -l /bin/ls
-rwxr-xr-x   1 root     bin         27281 Aug 15  1995 /bin/ls*
\end{verbatim}
\end{tscreen}


²Ä¤@­ÓÄæ¦ìÅã¥Ü¥X³o­ÓÀÉ®×ªº¨Ï¥ÎÅv­­ {\ttfamily ls} (¾Ö¦³ªÌ(owner) ¬O root, 
¸s²Õ(group) ¬O bin). ¾Ö¦³Åv¥i¥H¤À¦¨¤TºØ¼Ò¦¡: ¾Ö¦³ªÌ(owner), ¸s²Õ(group), ©M ¨ä¥L¨Ï¥ÎªÌ(others)¡C
¡]©M VMS ªº owner, group, world ¬Û¦ü¡^¡F¦³¤TºØ¤£¦Pªº¤¹³\Åv(permissions): 
Åª(read), ¼g(write) (¥]§t²¾°£(delete)), ©M°õ¦æ(execute).

±q¥ª¨ì¥k¡M{\ttfamily -} ¬OÀÉ®×¼Ò¦¡ ({\ttfamily -} = ¤@¯ëÀÉ®×(ordinary file), {\ttfamily d}
= ¥Ø¿ý(directory), {\ttfamily l} = ³sµ²(link), µ¥); {\ttfamily rwx} ¬O¤¹³\ÀÉ®×¾Ö¦³ªÌ¥i¥H¹ï¸ÓÀÉ®×§@Åª¡M¼g¡M©M°õ¦æªº°Ê§@¡F
{\ttfamily r-x} ¬O¤¹³\¸s²Õ¨Ï¥ÎªÌ¥i¥H¹ï¸ÓÀÉ®×§@Åª©M°õ¦æªº°Ê§@¡M¦ý¬O¤£¥i¥H§@¼gªº°Ê§@¡C¡F
{\ttfamily r-x} ¬O­­¨î¨ä¥Lªº¨Ï¥ÎªÌ¹ï¸ÓÀÉ®×¥u¦³Åª©M°õ¦æªºÅv­­¡M«o¨S¦³¼gªºÅv­­¡C

¦p¦ó§ïÅÜÀÉ®×ªº¨Ï¥ÎÅv­­¡G

\begin{tscreen}
\begin{verbatim}
$ chmod <whoXperm> <file>
\end{verbatim}
\end{tscreen}


¨ä¤¤ who ¬O {\ttfamily u} (user¡]¨Ï¥ÎªÌ¡^, §YÀÉ®×ªº¾Ö¦³ªÌ), {\ttfamily g} (¸s²Õ group), {\ttfamily o} (¨ä¥L other), 
X ªí¥Ü¥i¥H¬° {\ttfamily +} ©Î {\ttfamily -}, perm ¥i¥H¬° {\ttfamily r} (Åª read), {\ttfamily w} (¼g write), ©Î¬O 
{\ttfamily x} (¥i°õ¦æ execute). 
Á|¨Ò»¡©ú¡G

\begin{tscreen}
\begin{verbatim}
$ chmod u+x file
\end{verbatim}
\end{tscreen}


³o¬O°w¹ï¸ÓÀÉ®×¡M¶}©ñ¥i°õ¦æªºÅv­­µ¹¸ÓÀÉ®×ªº¾Ö¦³ªÌ¡C¥iÁY¼g¦¨¡G
{\ttfamily chmod +x file}.

\begin{tscreen}
\begin{verbatim}
$ chmod go-wx file
\end{verbatim}
\end{tscreen}


³o¬O¹ï¸ÓÀÉ®×¡M²¾°£¸s²Õ¨Ï¥ÎªÌ©M¨ä¥L¨Ï¥ÎªÌ¹ï¸ÓÀÉ®×ªº¡§¼g¡¨ªºÅv­­©M¡§°õ¦æ¡¨ªºÅv­­¡C

\begin{tscreen}
\begin{verbatim}
$ chmod ugo+rwx file
\end{verbatim}
\end{tscreen}


³o¬O¶}©ñ¸ÓÀÉ®×ªºÅª¡M¼g¡M©M°õ¦æªºÅv­­µ¹©Ò¦³ªº¨Ï¥ÎªÌ¡C

¥t¤@­Ó§Ö³tªí¥Üªk¬°¨Ï¥Î¤@²Õ¼Æ¦r¡G{\ttfamily rwxr-xr-x} ¥i¥H¥Î 755 ¨Óªí¥Ü (¨C¤@¦ì¼Æ¦r¹ïÀ³¤@­Ó±±¨î¦ì¤¸: {\ttfamily ---} ªí¬O 0, 
{\ttfamily --x} ªí¥Ü 1, {\ttfamily -w-} ªí¥Ü 2...).

©Ò¥H¡Mrwx = 4+2+1 = 7¡Mr-x = 4+0+1 = 5¡M©Ò¥H¡M{\ttfamily rwxr-xr-x} ¥i¥H¥Î 755 ¨Óªí¥Ü¡C

¹ï¥Ø¿ý¦Ó¨¥¡M{\ttfamily rx} ªí¥Ü±z¥i¥H¤Á´«¨ì¸Ó¥Ø¿ý¡G {\ttfamily cd} , ¦Ó
{\ttfamily w} ªí¥Ü±z¥i¥H§R°£¸Ó¥Ø¿ýªºÀÉ®×(·íµM»Ý­nµø¸ÓÀÉ®×ªº¨Ï¥ÎÅv­­¦Ó©w), ©Î¬O¥Ø¿ý¥»¨­. 
³o¨ÇÁÙ¥u¬O¦B¤sªº¤@¨¤¦Ó¤w¡M·Q­nª¾¹D§ó¦h---RMP.

¦p¦ó§ïÅÜÀÉ®×ªº¾Ö¦³Åv¡G

\begin{tscreen}
\begin{verbatim}
$ chown username file
\end{verbatim}
\end{tscreen}


§Ú¾ã²z¦¨¤Uªí¡G

\begin{tscreen}
\begin{verbatim}
VMS                             Linux                   Notes
------------------------------------------------------------------------------

SET PROT=(O:RW) file.txt        $ chmod u+rw file.txt
                                $ chmod 600 file.txt
SET PROT=(O:RWED,W) file        $ chmod u+rwx file
                                $ chmod 700 file
SET PROT=(O:RWED,W:RE) file     $ chmod 755 file
SET PROT=(O:RW,G:RW,W) file     $ chmod 660 file
SET FILE/OWNER_UIC=JOE file     $ chown joe file
SET DIR/OWNER_UIC=JOE [.dir]    $ chown joe dir/
\end{verbatim}
\end{tscreen}







\subsection{¦h¤u(Multitasking): µ{§Ç(Processes) ©M ¤u§@(Jobs) \label{Multitasking}}



±ý°õ¦æ«Ü¦hµ{¦¡¡M¦b Linux ¤W¨S¦³©Ò¿×ªº `batch queues' ; ¦h¤u¨ä¹ê¥H«D±`¤£¤@¼Ëªº¤âªk³B²z¡C
¥H¤U¬O¤@¯ë±`¨£ªº©R¥O¦C¡G

\begin{tscreen}
\begin{verbatim}
$ command -s1 -s2 ... -sn par1 par2 ... parn < input > output &
\end{verbatim}
\end{tscreen}


¨ä¤¤ {\ttfamily -s1}, ..., {\ttfamily -sn} ¬O¸Óµ{¦¡ªº°Ñ¼Æ¡]switch¡^, 
{\ttfamily par1}, ..., {\ttfamily parn} ¬Oµ{¦¡ªº¿é¤JÅÜ¼Æ(parameters).

²{¦bÅý§Ú­Ì¨Ó¬Ý¬Ý¦b Linux ¤W¦p¦ó¦h¤u¡Cµ{§Ç¡]processes¡^¬O¤@°¦¤£½×¦b«e´º©Î¬O­I´º³Q°õ¦æªºµ{¦¡¡C

\begin{itemize}
\item  ¦b­I´º°õ¦æµ{§Ç:
\begin{tscreen}
\begin{verbatim}
$ progname [-switches] [parameters] [< input] [> output] &
[1] 234
\end{verbatim}
\end{tscreen}


shell ·|´£¥Ü±z¸Óµ{§Ç(process)ªº¤u§@¸¹½X¡]`job number'¡^ (²Ä¤@­Ó¼Æ¦r; ½Ð¬Ý¤U¤å) 
©M¸Óµ{§Çªºµ{§ÇÃÑ§O½X PID (Process IDentifier). ¨C¤@­Óµ{§Ç³£¦³¤@²Õ¿W¤@µL¤Gªº PID.
\item  ÀËµø¦³¦h¤Ö Processes ³Q°õ¦æ¡G
\begin{tscreen}
\begin{verbatim}
$ ps -ax
\end{verbatim}
\end{tscreen}

³o·|¿é¥X¤@¤j¦ê¥¿¦b°õ¦æªºµ{§Ç(processes)¡C

\item  ±þ±¼µ{§Ç¡G
\begin{tscreen}
\begin{verbatim}
$ kill <PID>
\end{verbatim}
\end{tscreen}

¦pªG±z¤£ª¾¹D­n¦p¦ó¥¿½Tªº²×¤î¬Y¤@­Óµ{§Ç¡M³o®É±z¥i¯à´N­n¤â°Ê§âµ{§Çµ¹±þ¦º³á¡I... ;-). 
¦³¨Ç®É­Ô¡M¤@­Óµ{§Ç¥u¯à³Q¤U¦C¤@­Ó«ü¥O±þ¦º¡G

\begin{tscreen}
\begin{verbatim}
$ kill -15 <PID>
$ kill -9 <PID>
\end{verbatim}
\end{tscreen}

\end{itemize}


ªþ±a¤@´£¡MSell ¤¹³\±z°±¤î©Î¬O¼È®É°±¤î¤@­Óµ{§Ç¡M±Nµ{§Ç°e¨ì­I´º¤u§@¡M©Î¬O±Nµ{§Ç±q­I´º±a¨ì«e´º¡C
¦b³o¸Ì¡Mµ{§Ç(processes)§Ú­ÌºÙ¤§¬°¤u§@(`jobs').

\begin{itemize}
\item  ÀËµø¦³¦h¤Ö¤u§@¡]jobs¡^¥¿¦b°õ¦æ¡G
\begin{tscreen}
\begin{verbatim}
$ jobs
\end{verbatim}
\end{tscreen}

¤u§@(jobs)¬O¥Ñ Shell µ¹ªº¤u§@¸¹½X¡]job number¡^¨Ó§@°Ï§O¡Mª`·N¡M¤£¬O PID ³á.
\item  ²×¤î¦b«e´º¤u§@ªºµ{§Ç(processes):

\begin{tscreen}
\begin{verbatim}
$ CTRL-C
\end{verbatim}
\end{tscreen}

(¤£¤@©w¨C¤@¦¸«µ®Ä)
\item  ¼È°±¦b«e´º¤u§@ªºµ{§Ç(process):
\begin{tscreen}
\begin{verbatim}
$ CTRL-Z
\end{verbatim}
\end{tscreen}

(¦P¤W)
\item  ±N¼È°±ªºµ{§ÇÂà´«¦¨­I´º¤u§@(background jobs):
\begin{tscreen}
\begin{verbatim}
$ bg <job>
\end{verbatim}
\end{tscreen}

\item  ±N­I´º¤u§@±a¨ì«e´º:
\begin{tscreen}
\begin{verbatim}
$ fg <job>
\end{verbatim}
\end{tscreen}

\item  ±þ±¼¤@­Ó¤u§@(job):
\begin{tscreen}
\begin{verbatim}
$ kill <%job>
\end{verbatim}
\end{tscreen}

\end{itemize}





\subsection{¦b³XÀÉ®×(files)}



§ó¦h¦³ÃöÀÉ®×ªº°T®§¡C

\begin{itemize}
\item  {\bfseries stdin, stdout, stderr}: ¦b UNIX ¤¤¡M¥ô¦ó¤@­Ó¨t²Î¤¸¥ó³£³Qµø¬°¬O¤@­ÓÀÉ®×¡C
«ü¥O©Î¬OÀ³¥Îµ{¦¡Åª¤J¤@­Ó©Ò¿×¼Ð·Ç¿é¤JªºÀÉ®×¡]{\ttfamily stdin}¡G³q±`¬°Áä½L¡^¡M
¿é¥Xµ²ªG¨ì©Ò¿×¼Ð·Ç¿é¥XªºÀÉ®×¡]{\ttfamily stdout} ¡G³q¦¨¬°¿Ã¹õ¡^¡M¦Ó¿ù»~¿é¥X¤]¬O¿é¥X¨ì¤@­ÓÀÉ®×¡M
§Ú­ÌºÙ¤§¬° {\ttfamily stderr} (³q±`¤]¬O¿Ã¹õ).

¨Ï¥Î {\ttfamily $<$} ©M {\ttfamily $>$} ¡M±z¥i¥H±N¿é¥X©M¿é¤J­«·s¾É¦V¨ì¥t¥~¤@­ÓÀÉ®×¡C
µM¦Ó¡M {\ttfamily $>$$>$} ¬O±Nµ²ªGªþ¥[¨ìÀÉ®×ªºÀÉ§À¡M¦Ó¤£¬OÂÐ»\­ì¨ÓªºÀÉ®×¡C; 
{\ttfamily 2$>$} ­«¾É¿ù»~°T®§(stderr); 2$>$\&1
­«¾É¿ù»~°T®§¨ì¼Ð·Ç¿é¥X, ¦Ó 1$>$\&2 «h¬O­«¾É¼Ð·Ç¿é¥X¨ì¿ù»~¿é¥X¡C
¦³¤@­Ó¶Â¬}¡]`black hole'¡^¥s°µ {\ttfamily /dev/null}: ©Ò¦³¾É¨ì³o­ÓÀÉ®×ªºªF¦è¡M
³£±N®ø¥¢ªºµL¼vµLÂÜ¡C
\item  {\bfseries wildcards}: ¸U¥Î¦r¤¸ '{\ttfamily *}' ¦³¬Û¦Pªº¥\¯à¡C¥Îªk: * ²Å¦X©Ò¦³ÀÉ®×¡M°£¤FÁôÂÃÀÉ¥H¥~¡C
.* ²Å¦X©Ò¦³ÁôÂÃÀÉ; *.* ²Å¦X¥u¦³¤@­ÓÂI '.' ¦b¤¤¶¡ªºÀÉ®×¡C¸òÀHµÛ¨ä¥L¦r¤¸¡G 
p*r ªí¥Ü `peter' ©Î¬O `piper' ³£¦³¥i¯à; *c* ¥i¯à²Å¦X `picked' ©Î¬O `peck'¡C
'{\ttfamily \%}' ´«¦¨ '{\ttfamily ?}'¡C ÁÙ¦³¥t¥~¤@ºØ¸U¥Î¦r¤¸¡G{\ttfamily []}. ¥Îªk: {\ttfamily [abc]*} ªí¥ÜÀÉ®×¥²¶·¥H¦r¤¸ a, b, c ³Ì¬°¶}ÀY; 
{\ttfamily *[I-N,1,2,3]} ªí¥ÜÀÉ®×¦WºÙ¥Ñ I, J, K, L, M, N, 1, 2, 3 §@¬°µ²§À¡C
\item  {\ttfamily mv} ({\ttfamily ­«·s©R¦W}) ¤£¥i¥H¤@¦¸¦h­ÓÀÉ®×¡C§Y {\ttfamily mv *.xxx *.yyy} ±N¤£·|°õ¦æ¦¨¥\;
\item  ¨Ï¥Î {\ttfamily cp -i} ©M {\ttfamily mv -i} ¥i¥H´£¿ô±z¬O§_­nÂÐ»\¥H¦s¦bªºÀÉ®×¡C
\end{itemize}







\subsection{¦C¦L¦î¦C \label{Print Queues}}



´N¹³ VMS ¡M¦C¦L¤u§@·|¥ý³Q©ñ¨ì¦î¦C·í¤¤(queues)¡M·í±z¤U¦C¦L«ü¥Oªº®É­Ô¡M±z©Î³\·|«ü©w¦Cªí¾÷ªº¦WºÙ¡C
¨Ò¦p¡G

\begin{tscreen}
\begin{verbatim}
$ lpr file.txt          # ³o±N«ü¥Î¨ì¹w³]ªº¦Cªí¾÷
$ lpr -Plaser file.ps   # ³o±N¨Ï¥Î¦W¬° 'laser' ªº¦Cªí¾÷
\end{verbatim}
\end{tscreen}


³B²z¦C¦L¦î¦C(print queues), ±z¥i¯à»Ý­n¤U¦C«ü¥O¡G

\begin{tscreen}
\begin{verbatim}

VMS                                     Linux
------------------------------------------------------------------------------

$ PRINT file.ps                         $ lpr file.ps
$ PRINT/QUEUE=laser file.ps             $ lpr -Plaser file.ps
$ SHOW QUEUE                            $ lpq
$ SHOW QUEUE/QUEUE=laser                $ lpq -Plaser
$ STOP/QUEUE                            $ lprm <item>
\end{verbatim}
\end{tscreen}







\section{³]©w \label{Configuring}}



±zªº¨t²ÎºÞ²z­û¤w¸g´£¨Ñ±z¤@¨Ç²ÕºA³]©wÀÉ¡M¦p¡G {\ttfamily .xinitrc}, {\ttfamily .bash\_profile}, {\ttfamily .inputrc}, µ¥µ¥¡C
¨ä¤¤±z·Q­n½s¿èªº¬O¡G

\begin{itemize}
\item  {\ttfamily  .bash\_profile} ©Î¬O {\ttfamily .profile}: ¦b login ®É¡M³o­ÓÀÉ®×´N³Q Shell µ¹Åª¶i¨Ó¤F¡C´N¹³ VMS ¤Wªº {\ttfamily LOGIN.COM};
\item  {\ttfamily  .bash\_logout}: ·í­nµn¥Xªº®É­Ô¡MÅª¨ú³o­ÓÀÉ®×¡C³o´N¹³ VMS ¤Wªº {\ttfamily LOGOUT.COM};
\item  {\ttfamily  .bashrc}: ³Q non--login shells Åª¨ú.
\item  {\ttfamily  .inputrc}: ³o­ÓÀÉ®×¥i¥H©w°µ¤@²Õ¦XÁä©M³]©w shell ªº¦æ¬°¡C
\end{itemize}


§Ú±N¥H§Úªº {\ttfamily .bash\_profile} ³Ì¬°¹ê¨Ò¡C

\par
\addvspace{\medskipamount}
\nopagebreak\hrule
\begin{verbatim}
# $HOME/.bash_profile

# ¦pªG¤£»Ý­n¡M½Ð¤£­n­«·s©w¸q $PATH ÅÜ¼Æ¡C
echo $PATH | grep $LOGNAME > /dev/null
if [ $? != 0 ]
then
  export PATH="$PATH:/home/$LOGNAME/bin"  # add my dir to the PATH
fi

export PS1='LOGNAME:\w\$ '
export PS2='Continued...>'

# aliases §O¦W

alias bin="cd ~/bin" ; alias cp="cp -i" ; alias d="dir"
alias del="delete" ; alias dir="/bin/ls $LS_OPTIONS --format=vertical"
alias ed="jed" ; alias mv='mv -i'
alias u="cd .." ; alias undel="undelete"

# A few useful functions ¤@¨Ç¦³¥Îªº¨ç¼Æ¡I»Å¡I

inst() # Install a .tar.gz archive in current directory.
{
  gzip -dc $1 | tar xvf -
}
cz() # List the contents of a .zip archive.
{
  unzip -l $*
}
ctgz() # List the contents of a .tar.gz archive.
{
  for file in $* ; do
    gzip -dc ${file} | tar tf -
  done
}
tgz() # Create a .tgz archive a la zip.
{
  name=$1 ; tar -cvf $1 ; shift
  tar -rf ${name} $* ; gzip -S .tgz ${name}
}
\end{verbatim} 
\nopagebreak\hrule 
\addvspace{\medskipamount}


³o¬O§Úªº {\ttfamily .inputrc}:

\par
\addvspace{\medskipamount}
\nopagebreak\hrule
\begin{verbatim}
# $HOME/.inputrc
# ¤W¦¸­×§ï¤é´Á: 16 January 1997.
#
# ¥H¤U¬Oµù¸Ñ¡M»¡©ú³o­Ó Script ªº¥Î·N¡C
# This file is read by bash and defines key bindings to be used by the shell;
# what follows fixes the keys END, HOME, and DELETE, plus accented letters.
# For more information, man readline.

"\e[1~": beginning-of-line
"\e[3~": delete-char
"\e[4~": end-of-line

set bell-style visible
set meta-flag On
set convert-meta Off
set output-meta On
set horizontal-scroll-mode On
set show-all-if-ambiguous On

# (F1 .. F5) are "\e[[A" ... "\e[[E"

"\e[[A": "info "
\end{verbatim} 
\nopagebreak\hrule 
\addvspace{\medskipamount}







\section{¦³¥Îªºµ{¦¡ \label{Useful Programs}}






\subsection{ÂsÄýÀÉ®×: {\ttfamily less}}



±z±N·|»Ý­n¨C¤Ñ¨Ï¥Î³o­ÓÀÉ®×ÂsÄý¾¹¡C©Ò¥H§Ú±Nµ¹±z¤@¨Ç¯¦ÓDÅý±z¯à¦n¦nªº§Q¥Î³o­Ó¤u¨ã¡C
­º¥ý¡M­n¨D±zªº¨t²ÎºÞ²z­û³o©w {\ttfamily less} ¨Ï¦o¤£¥u¥i¥HÅã¥Ü¤å¦rÀÉ¡M§ó¥i¥HÀ£ÁYÀÉ®×¤å¥ó¡Mµ¥¡C

´N¹³²{¦bª©¥»ªº {\ttfamily TYPE}, {\ttfamily less} ¥i¥HÅý±zÂsÄý±z¥Ø«e¥Ø¿ý¤UªºÀÉ®×¡C
¦o¦P®É¤]¥i¥H±µ¨ü³\¦hÃB¥~¥ÑÁä½L¿é¤Jªº«öÁä«ü¥O¡M¤ñ¸û¦³¥Îªº¬O¡G

\begin{itemize}
\item  ²Ä¤@, «ö¤U {\ttfamily q} ¥i¥HÂ÷¶}ÀÉ®×ÂsÄý;
\item  {\ttfamily h} ´£¨Ñ±z³\¦hªº½u¤W»¡©ú;
\item  {\ttfamily g} ¸õ¨ìÀÉÀY, {\ttfamily G} ²¾¦ÜÀÉ§À, ¼Æ¦r n ¥[ {\ttfamily g} ªí¥Ü¨ì§Ì n ¦æ¡C(¨Ò¦p {\ttfamily 125g}), 
¼Æ¦r¥[ {\ttfamily \%} ªí¥Ü¤@¨ì¸ÓÀÉ®×¤§¦Ê¤À¤ñ¤j¤pªº¦a¤è;
\item  {\ttfamily /pattern} ¦V¤U·j´M `pattern'; {\ttfamily n} ¦V¤U·j´M¤Uµ§¸ê®Æ; {\ttfamily ?pattern} ©M {\ttfamily N} ªí¥Ü¦V¤W´M§ä¡C

\item  {\ttfamily m}+letter ¼Ð¥Ü¥Ø«e¦a¤è (¦p {\ttfamily ma}); {\ttfamily '}+letter ¨ì³Q¼Ð¥Üªº¦a¤è.
\item  {\ttfamily :e} ÀË¬d·sÀÉ®×;
\item  {\ttfamily !command} °õ¦æ©R¥O¦CÀÉ®×.
\end{itemize}







\subsection{¦b Linux ¤Uªºª©¥»³Æ¥÷ \label{Numbered Backups Under Linux}}





­ü, Linux ¨Ã¨S¦³´£¨ÑÀÉ®×ª©¥»ªº¥\¯à¡C¦ý¬O±z¥i¥H¥Î¨âºØµoªk¸Ñ¨M³o­Ó°ÝÃD¡C
²Ä¤@¡M¨Ï¥Î RCS, ª©¥»ºÞ²z¨t²Î¡]the Revision Control System¡^, 
¦o¥i¥HÅý±zºÞ²z¥ý«eªºÀÉ®×ª©¥»¡CRCS ¥i¥H¦b ``The RCS MINI-HOWTO'' (\nameurl{http://sunsite.unc.edu/mdw/HOWTO/mini/RCS.html}{}) ¤¤§ä¨ì.

²Ä¤GºØ¤èªk¡M¨Ï¥Îª¾¹D¦p¦ó³B²zª©¥»½s¸¹ªº½s¿è¾¹¡G{\ttfamily emacs} ©M {\ttfamily jed} ³£¦³³o­Ó¥\¯à¡C
¦b {\ttfamily emacs}, ¦b {\ttfamily .emacs} ¨º¥[¤J¤U¦C´X¦æ:

\begin{tscreen}
\begin{verbatim}
(setq version-control t)
(setq kept-new-versions 15) ;;; or any other value
(setq kept-old-versions 15)
(setq backup-by-copying-when-linked t)
(setq backup-by-copying-when-mismatch t)
\end{verbatim}
\end{tscreen}


¦pªG¨Ï¥Î {\ttfamily jed}, ½Ð½T©w±zªºª©¥»¦b 0.98.7 ¥H¤W; ¦oªº§ó·sÀÉ¡M¥i¥H¨Ï¨ä¤ä´©¼Æ¦rª©¥»³Æ¥÷¡C
¬ÛÃö¤å¥ó¥i¥H¦b {\ttfamily  \nameurl{http://ibogeo.df.unibo.it/guido/slang/backups.sl}{} } ¤¤§ä¨ì.






\subsection{ÀÉ®×À]¡]Archiving¡^: tar \& gzip}



¦b UNIX ¸Ì¡M¦³¤@¨Ç±`¥Î¨ìªºÀ³¥Îµ{¦¡¨Ó¶°¤¤ºÞ²z¤ÎÀ£ÁYÀÉ®×¡C
{\ttfamily tar} ¥i¥H¥Î¨Ó¥]«ÊÀÉ®×¡C±ý¥]«ÊÀÉ®×¥i¥Î¤U¦C«ü¥O¡C

\begin{tscreen}
\begin{verbatim}
$ tar -cvf <archive_name.tar> <file> [file...]
\end{verbatim}
\end{tscreen}


¸Ñ¶}¥]«ÊÀÉ®×¥i¥Î¡G

\begin{tscreen}
\begin{verbatim}
$ tar -xpvf <archive_name.tar> [file...]
\end{verbatim}
\end{tscreen}


¦C®Ñ¥]«ÊÀÉ®×¤¤©Ò¦³ªºÀÉ®×¡G

\begin{tscreen}
\begin{verbatim}
$ tar -tf <archive_name.tar> | less
\end{verbatim}
\end{tscreen}


¥i¥H¨Ï¥Î {\ttfamily compress} ©Î¬O {\ttfamily gzip} ¨ÓÀ£ÁYÀÉ«ö¥H¸`¬ÙµwºÐªÅ¶¡:

\begin{tscreen}
\begin{verbatim}
$ compress <file>
$ gzip <file>
\end{verbatim}
\end{tscreen}


¦pªG¨Ï¥Î {\ttfamily compress} ¨ÓÀ£ÁYÀÉ®×¡M¦o¬°À°±z²£¥Í°ÆÀÉ¦W¬° .Z ªºÀ£ÁYÀÉ¡M¦Ó {\ttfamily gzip} «h¬O¥H .gz ¬°°ÆÀÉ¦W¡C
³o¨ÇÀ³¥Îµ{¦¡¨Ã¤£¯à¥Î¨Ó¥]«ÊÀÉ®×¡M¦ý¬O¥i¥H¥Î¨ÓÀ£ÁYÀÉ®×¡C¸ÑÀ£ÁY¥i¥Î¡G

\begin{tscreen}
\begin{verbatim}
$ compress -d <file.Z>
$ gzip -d <file.gz>
\end{verbatim}
\end{tscreen}


¸Ô²Ó±¡§Î¡M½Ð RMP.

¦¹¥~¡M{\ttfamily unarj}, {\ttfamily zip} ©M {\ttfamily unzip} ¨Ç¤u¨ã¤]¥i¥H§Q¥Î¡C
ÀÉ®×ªº°ÆÀÉ¦W¦pªG¬O {\ttfamily .tar.gz} ©Î¬O {\ttfamily .tgz} (ªí¥Ü³o¬O¤@­Ó«Ê¸ËÀÉ®× {\ttfamily tar}, µM«á¡M
¨Ï¥Î {\ttfamily gzip}) À£ÁY³nÅé¦AÀ£ÁY¦Ó¦¨ªº¡C¦b UNIX ªº¥@¬É¡M³oºØ®æ¦¡±`±`·|·|¨£¨ì¡C
¥H¤U¬O¥Ü½d¦p¦ó¹î¬Ý {\ttfamily .tar.gz} ÀÉ¤ºªº¤º®e¡C

\begin{tscreen}
\begin{verbatim}
$ tar -ztf <file.tar.gz> | less
\end{verbatim}
\end{tscreen}


¥H¤U¬O¥Ü½d¦p¦ó¸Ñ¶} {\ttfamily .tar.gz} ÀÉ:

\begin{tscreen}
\begin{verbatim}
$ tar -zxf <file.tar.gz>
\end{verbatim}
\end{tscreen}







\section{À³¥Î \label{Examples}}



UNIX ªº¥D­n´n©À¬O§Æ±æ³z¹LºÞ½u(piping)©M­«¾É(redirection)ªºÆ[©À±N©Ò¦³Â²³æªº«ü¥O¦ê³s°_¨Ó¦Ó¥i¥H¨¬°÷À³¥I¯u¹ê¥Í¬¡¤W©Ò¦³½ÆÂøªº¤u§@¡C
Åý§Ú­Ì¨Ó¬Ý¬Ý¤U­±ªº¨Ò¤l¡M§Ú±N¥u¸ÑÄÀ¤ñ¸û½ÆÂøªº¨Ò¤l¡F¨ä¥LÂ²³æªº¨Ò¤l¡M½Ð§Q¥Î¤W­±§Ú©Ò¤¶²ÐªºÆ[©À©M»¡©ú¤å¥ó(man pages)¡M¬Û«H±z¤@©w¥i¥H«Ü§Öªº¶i¤J±¡ªp¡C

{\bfseries °ÝÃD}: ¦pªG¥u¨Ï¥Î {\ttfamily ls} ³o­Ó«ü¥O¨ÓÅã¥ÜÀÉ®×¡M¦pªGÀÉ®×¤Ó¦hªº¸Ü¡M±`±`´N¤@­¸¦Ó³u¡MÁÙ¨Ó¤£¤Î¬Ý§¹¡Mµ²ªG´N³Q±²¤W¥h¤F¡G

{\bfseries ¸Ñ¨M¤è®×}:

\begin{tscreen}
\begin{verbatim}
$ ls | less
\end{verbatim}
\end{tscreen}


{\bfseries °ÝÃD}: §Ú¦³¤@­ÓÀÉ®×¡M¸Ì­±¥]§t¤F³\¦h¤å¦r¡M§Ú·Q±N¤§¤Ï¦V±Æ§Ç«á¦C¦L¥X¨Ó¡G

{\bfseries ¸Ñ¨M¤è®×}:

\begin{tscreen}
\begin{verbatim}
$ cat myfile.txt | sort -r | lpr
\end{verbatim}
\end{tscreen}


{\bfseries °ÝÃD}: §Úªº¸ê®ÆÀÉ¤º¦³³\¦h­«½Æªº¸ê®Æ¡M§Ú­n¦p¦ó§R°£­«½Æªº¸ê®Æ©O¡H

{\bfseries ¸Ñ¨M¤è®×}:

\begin{tscreen}
\begin{verbatim}
$ sort datafile.dat | uniq > newfile.dat
\end{verbatim}
\end{tscreen}


{\bfseries °ÝÃD}: §Ú¦³¤@­Ó¥s°µ 'mypaper.txt' ©Î¬O 'mypaper.tex' ªºÀÉ®×¡M©Î¬OÃþ¦ü³o¼ËªºÀÉ®×¦WºÙ¡M¦ý¬O§Ú§Ñ°O§Ú±N¦o­Ì¦s©ñ¦b¤°»ò¦a¤è¤F¡M§Ú­n¦p¦ó§ä¨ì¦o­Ì©O¡H

{\bfseries ¸Ñ¨M¤è®×}:

\begin{tscreen}
\begin{verbatim}
$ find ~ -name "mypaper*" 
\end{verbatim}
\end{tscreen}


»¡©ú: {\ttfamily find} ¬O¤@­Ó«D±`¦³¥Îªº«ü¥O¡M¦o¥i¥H¦C¥X¾ðª¬¥Ø¿ý¤Uªº©Ò¦³ÀÉ®×¡M(¦b¥»¨Ò¤¤¡M§Ú­Ì¬O±q {\ttfamily \~{}} ³o¸Ì¶}©l´M§ä¡M¤]´N¬O \$HOME ªº¥Ø¿ý)¡C
¦oªº¿é¥Xµ²ªG¥i¥H³z¹L³\¦h±ø¥ó³]©w¡M¦Ó¹F¨ì³\¦h¤£¤@¼Ëªº»Ý¨D¡C¨Ò¦p {\ttfamily -name} ¡C

{\bfseries °ÝÃD}: §Ú·Q§ä¤@­ÓÀÉ®×¤ºªº¬Y¤@­Ó¦r¡M¨Ò¦p 'entropy'¡M§Ú­n¦p¦ó§@©O¡H¦³¨S¦³Ãþ¦ü¹³ {\ttfamily SEARCH} ³oºØ«ü¥O©O?

{\bfseries ¸Ñ¨M¤è®×}: ¦³ªº, ¸Õ¸Õ¬Ý grep ³o­Ó«ü¥O¡G

\begin{tscreen}
\begin{verbatim}
$ grep -l 'entropy' *
\end{verbatim}
\end{tscreen}


»¡©ú¡G¡¯ªí¥Ü©Ò¦³ªºÀÉ®×¡C

{\bfseries °ÝÃD}: ¦b¬Y­Ó¦a¤è¡Mªº¬Y­ÓÀÉ®×ªº¤º®e¦³ 'entropy' ³o­Ó¦r, §Ú·Qª¾¹D¬O­þ¤@­ÓÀÉ®×¡M¥B©ñ¦b­þ¸Ì¡M
¦b VMS ¤W§Ú¥i¥H¨Ï¥Î {\ttfamily search entropy
[...]*.*;*}, ¦ý¬O {\ttfamily grep} ³o­Ó«ü¥O¤£¥i¥H¦¬´M¤l¥Ø¿ý¡M²{¦b§Ú­n¦p¦ó¸Ñ¨M©O¡H

{\bfseries ¸Ñ¨M¤è®×}: 

\begin{tscreen}
\begin{verbatim}
$ find . -exec grep -l "entropy" {} \; 2> /dev/null
\end{verbatim}
\end{tscreen}


»¡©ú: {\ttfamily find .} ¿é¥X±q¥Ø«e³o­Ó¥Ø¿ý¤U©Ò¦³ªºÀÉ®×¡]¥]§t³o­Ó¥Ø¿ý¤U©Ò¦³¤l¥Ø¿ý¡^¡M
{\ttfamily -exec grep -l "entropy"} ¬O¹ï¨C¤@µ§¥Ñ find ¶Ç¥X¨ÓªºÀÉ®×­«½Æ°õ¦æ°õ¦æ(represented by {\ttfamily $\{$$\}$}), 
{\ttfamily $\backslash$} 
¬°µ²§ô³o­Ó«ü¥O¡C¦pªG±zÄ±±oªº¨ÇªF¦è¤Ó¥i©È¤F¡M¨S¿ù¡M¤£¹L±z¥i¥H¸ÕµÛ¼g¼g¤U­±ªº Script¡C



\par
\addvspace{\medskipamount}
\nopagebreak\hrule
\begin{verbatim}
#!/bin/sh
# rgrep: recursive grep
# »¼°j¦¡Â^¨ú

if [ $# != 3 ]
then
  echo "Usage: rgrep --switches 'pattern' 'directory'"
  exit 1
fi
find $3 -name "*" -exec grep $1 $2 {} \; 2> /dev/null
\end{verbatim} 
\nopagebreak\hrule 
\addvspace{\medskipamount}


»¡©ú: {\ttfamily grep} ´N¹³ {\ttfamily search}, µ²¦X¤F
{\ttfamily find} ¡M§Ú­Ì±o¨ì¤F¨âªÌªººëµØ¡C

{\bfseries °ÝÃD}: §Ú¦³¤@­Ó¸ê®ÆÀÉ®×¡M³o­ÓÀÉ®×¦@¦³¨â¦CÀÉÀY(header lines)¡]¤]´N¬O»¡¡M²Ä¤Tµ§¸ê®Æ¤~¬O§Ú¯u¥¿ªº¸ê®Æ¡^¡M
¦pªG§Ú·Q­nÂ^¨ú¨Cµ§¸ê®Æªº²Ä¤G©M²Ä¤­Äæªº¸ê®Æ¡M§Ú»Ý­n¼g¤@­Ó Fortran ªºµ{¦¡¶Ü¡H

{\bfseries ¸Ñ¨M¤è®×}: ¤£»Ý­n¡C¨Ó¬Ý¬Ý³o­Ó¨ã¦³±þ¶Ë¤Oªº«ü¥O¡I

\begin{tscreen}
\begin{verbatim}
$ awk 'NL > 2 {print $2, "\t", $5}' datafile.dat > newfile.dat
\end{verbatim}
\end{tscreen}


»¡©ú: {\ttfamily awk} ³o­Ó«ü¥O¹ê»Ú¤W¥i¥H»¡¬O¤@ºØµ{¦¡»y¨¥¡G¤W­±ªº·N«ä¬O»¡¡G
¦b {\ttfamily datafile.dat} ³o­ÓÀÉ®×¸Ì¡M±qÀÉ®×ªº²Ä¤T¦æ¶}©lªº¨C¤@¦æ¡M¦L¥X¨C¤@¦æªº²Ä¤G©M²Ä¤­Äæ¦ì¡M
¥H tab ¬°¤À¹j²Å¸¹¡C¾Ç·|¤F {\ttfamily awk} ¤@©w·|Åý±z¨Æ¥b¥\­¿ªº¡C

{\bfseries °ÝÃD}: §Ú±q FTP ¯¸¤U¸ü¤F {\ttfamily ls-lR.gz} ³o­ÓÀÉ®×¡M·Q­n¹î¬ÝÀÉ®×¤º®e¡C
¹ï¨C¤@­Ó¤l¥Ø¿ý¦Ó¨¥¡M¦o¦³¤@¦æ¼g»¡ "total xxxx", ¨ä¤¤ xxxx ªí¥ÜÀÉ®×¤j¤p¡]kbytes¡^
§Ú·Qª¾¹D©Ò¦³ xxxx ­ÈªºÁ`©M¡M§Ú­n¦p¦ó§@©O¡H

{\bfseries ¸Ñ¨M¤è®×}:

\begin{tscreen}
\begin{verbatim}
$ zcat ls-lR.gz | awk ' $1 == "total" { i += $2 } END {print i}'
\end{verbatim}
\end{tscreen}


»¡©ú: {\ttfamily zcat} ¥i¥H¦C¥X {\ttfamily .gz} ªºÀÉ®×¤º®e¡CµM«á±N zcat ±o¨ìªºµ²ªGÂà°e(pipe)¨ì
{\ttfamily awk}¡C¬Ý¨ì¤F§a¡I¤F¸Ñ awk ¯uªº¹ï±z¦³«Ü¤jªºÀ°§U³á¡CRMP¡I

{\bfseries °ÝÃD}: §Ú¤w¸g¼g¤F¤@°¦ {\ttfamily myprog} ªº Fortran ªºµ{¦¡¡M¥i¥H­pºâ¥Ñ©R¥O¦C¶Ç¶i¨ÓªºÀÉ®×ªº¸ê®Æ¡M
¥i¬O¡M§Ú¦³«Ü¦h­Ó¸ê®ÆÀÉ»Ý­n¿é¤J¨ì³o°¦µ{¦¡¡M¨C¤@­ÓÀÉ®×±N·|¦³¤@­Óµ²ªGÀÉ®×¡C¦ý¬O¨C¦¸³£­n¿é¤JÀÉ¦W¹ê¦b«Ü·Ð¤H¡M
¦b VMS ¤W¡M§Ú»Ý­n¼g¤@­ÓÅo­öªº©R¥OÀÉ(command file)¤~¥i¥H¸Ñ¨M¡M¨º»ò¦b Linux ¤W©O¡H

{\bfseries ¸Ñ¨M¤è®×}: ¥u­n¤@­Ó¤p¤pªº Script ´N¥i¥H¸Ñ¨M¤F¡C­×§ï±zªºµ{¦¡¡MÅý±zªºµ{¦¡¥i¥H¹w©wÅª¤J '{\ttfamily mydata.dat}' ³o­ÓÀÉ®×¡M
±Nµ²ªG¿é¥X¨ì¿Ã¹õ(stdout), µM«á½s¿è¤U­±ªº Script¡G

\par
\addvspace{\medskipamount}
\nopagebreak\hrule
\begin{verbatim}
#!/bin/sh
# myprog.sh: run the same command on many different files
# usage: myprog.sh *.dat
for file in $*  # for all parameters (e.g. *.dat)
do
  # append the file name to result.dat
  echo -n "${file}:    " >> results.dat
  # copy current argument to mydata.dat, run myprog 
  # and append the output to results.dat
  cp ${file} mydata.dat ; myprog >> results.dat
done
\end{verbatim} 
\nopagebreak\hrule 
\addvspace{\medskipamount}


{\bfseries °ÝÃD}: §Ú§Æ±æ±N©Ò¦³ÀÉ®×¤ºªº `geology' ¦r´À´«¦¨ `geophysics' ¡M§Ú»Ý­n¤â°Ê½s¿è¶Ü¡H¡I

{\bfseries ¸Ñ¨M¤è®×}: ¤£»Ý­n¡C ¤U­±ªº Shell Script ¥i¥HÀ°±z¿ì¨ì¡G

\par
\addvspace{\medskipamount}
\nopagebreak\hrule
\begin{verbatim}
#!/bin/sh
# replace $1 with $2 in $*
# usage: replace "old-pattern" "new-pattern" file [file...]
OLD=$1          # first parameter of the script
NEW=$2          # second parameter
shift ; shift   # discard the first 2 parameters: the next are the file names
for file in $*  # for all files given as parameters
do
# replace every occurrence of OLD with NEW, save on a temporary file
  sed "s/$OLD/$NEW/g" ${file} > ${file}.new
# rename the temporary file as the original file
  /bin/mv ${file}.new ${file}
done
\end{verbatim} 
\nopagebreak\hrule 
\addvspace{\medskipamount}


{\bfseries °ÝÃD}: §Ú¦³¤@¨ÇÀÉ®×¡M§Ú¤£ª¾¹D¦o­ÌªºÀÉ®×ªø«×¡M§Ú¥²¶·²¾°£³o¨ÇÀÉ®×¤ºªº­Ë¼Æ²Ä¤G©M­Ë¼Æ²Ä¤T¦æ¡M»Ý­n¤â°Ê¶Ü¡H

{\bfseries ¸Ñ¨M¤è®×}: ·íµM¤£»Ý­n¡MÁÙ¬O¨Ï¥Î Shell Script:

\par
\addvspace{\medskipamount}
\nopagebreak\hrule
\begin{verbatim}
#!/bin/sh
# prune.sh: removes n-1th and n-2th lines from files
# usage: prune.sh file [file...]
for file in $*   # for every parameter
do
  LINES=`wc -l $file | awk '{print $1}'`  # ­pºâÁ`¦@¦³´X¦æ
  LINES=`expr $LINES - 3`                 # LINES = LINES - 3 
  head -n $LINES $file > $file.new        # ¿é¥X«e LINES ¦æ
  tail -n 1 $file >> $file.new            # ¦A±N³Ì«á¤@¦æªþ¥[¨ìÀÉ®×³Ì«á
done
\end{verbatim} 
\nopagebreak\hrule 
\addvspace{\medskipamount}


§Æ±æ¥H¤W³o¨Ç¹ê¨Ò¼W¥[±z¤£¤Öªº­¹¼¤...






\section{¤£¥i¤Öªº¤p°¾¤è}



\begin{itemize}
\item  {\bfseries Command completion}: ·í±z¦b©R¥O¦C±ý¿é¤J¬Y¤@«ü¥Oªº®É­Ô¡M±z¤£»Ý­n§¹¥þ¿é¤J³o­Ó«ü¥Oªº©Ò¦³¦WºÙ¡M
¿é¤J«e´X­Ó¦r¤¸«á¡M¦A«ö $<$TAB$>$ ¡M¨t²Î·|À°±z§¹¦¨¿é¤J©Ò¦³ªº«ü¥O¦WºÙ; ¨Ò¦p: 
±z¥²¶·¿é¤J {\ttfamily less this\_is\_a\_long\_name}; ²{¦b±z¥u­n¿é¤J {\ttfamily less thi$<$TAB$>$} 
¨t²Î´N·|À°±z¿é¤J³Ñ¤Uªº³¡¥÷¡M¤£»Ý­n¦A®Ñ¦p¥þ³¡ªºÀÉ¦W¤F¡C
(¦pªG±z¦³«Ü¦hÀÉ®×³£¬O¥H³o¨Ç¦r¤¸§@¶}ÀY¡M·íµM¨t²Î´N·|Åã¥Ü¥X©Ò¦³¥H³o´X­Ó¦r¤¸¶}ÀYªºÀÉ®×¡M¦ý¬O¡M±z¥i¥H¿é¤J¨¬°÷ªº¦r¤¸¡M´N¥i¥H±o¨ì±z»Ý­nªº°ß¤@ÀÉ®×¡C)
\item  {\bfseries Back-scrolling}: ¦P®É«ö SHIFT--PAG UP ¥i¥HÅý±zªº¿Ã¹õ©¹¦^±²¨ì¥H«eÅã¥Ü¹Lªº¡M
¦ý¬O¥i¥H©¹¦^±²´X­¶¡M«h»Ý­nµø±zªºÅã¥Ü¥dªº°O¾ÐÅé¦Ó©w¤F¡C
\item  {\bfseries Resetting the screen}: ¤£ªG±z¤£¤p¤ß¥Î {\ttfamily more} ©Î {\ttfamily cat} 
¶}±Ò¤F¤@­Ó¤G¶i¦ìÀÉ(binary file), ¨º±zªº¿Ã¹õ¥i¯à¬°¦]¦¹¦Ó¶Ã±¼¡C³o®É­Ô±z¥i¥H¨Ï¥Î
{\ttfamily reset} ©Î¬O¨Ï¥Î {\ttfamily echo CTRL-V ESC c RETURN} ¥i¥HÅý±zªº¿Ã¹õ«ì´_¥¿±`¡C
\item  {\bfseries Pasting text}: ¦b X ¤U¡M¥H·Æ¹«¦b {\ttfamily xterm} µøµ¡©ì¦²¥X¤@­Ó°Ï°ì¡M
µM«á«ö·Æ¹«¤¤Áä¡]¦pªG±zªº·Æ¹«¨S¦³¤¤Áä¡M¥i¥H¦P®É«ö·Æ¹«ªº¥ª¥kÁä¼ÒÀÀ¤¤Áä¡^´N¥i¥H¶K¤W±z½Æ»sªº¤å¦r¡C
\item  {\bfseries Using the mouse}: ¦b²×ºÝ¾÷¼Ò¦¡¤U¡M±z¥i¯à»Ý­n´M¬°±zªº¨t²ÎºÞ²z­û¦³¨S¦³¦w¸Ë {\ttfamily gpm} ³o°¦µ{¦¡, 
¦pªG¦³¡M±z´N¥i¥H¥Î·Æ¹«©ì¦²¥X¤@­Ó°Ï°ì¡MµM«á«ö·Æ¹«ªº¥ªÁä¡M´N¥i¥H¶K¤W±z­è­è©ì¦²¥X¨Óªº¤å¦r°Ï°ì¡C
¡]¤£¦PªºµêÀÀ²×ºÝ¾÷(VC)¥i¯à·|¦³¤£¤@¼Ëªº¾Þ§@¤è¦¡¡^¡C
\end{itemize}







\section{¦b Linux ¤WÅª¨ú VMS ªººÏ±a}



(¥H¤U³o¬q¬O¥Ñ Mike Miller ¥ý¥Í©ÒµÛ)




\subsection{Â²¤¶}



¦³®É­Ô±z¥i¯à»Ý­nÅª¥Ñ VMS °µ¥X¨ÓªººÏ±a¡]©Î¬O¬°¤FÅý VMS ªº¾÷¾¹©M *nix ¨t²Î¥i¥HÅª¨úªººÏ±a¡^¡M
¤j­P¤W¡M¹ï DECFILES11A ºÏ±a¨Ã¤£·|¤ÓÃø¡C

©Î³\±z´¿Åª¹L Linux ªº mini-HOWTO, ¦ý¬O¡M§Ú¬Û«H¡M§Ú¦b³o¸Ì´£¤Îªº¤@¨ÇÆ[©À¤]¬O©M¥ô¦ó¤@ºØ *nix ¨t²Î¡C
§Ú´¿¸g¦b Linux, HP, Sun and DEC *nix µ¥¨t²Î¤¤¸Õ¹L¡C¤ñ¸û¤£¤@¼Ëªº¦a¤è¬O¡M¨CºØ§@·~¨t²Î¹ï¸Ë¸m¦WºÙ¡]device names¡^¥i¯à·|¦³©Ò¤£¦P¡M
¦Ó mt ¦b«ü©ú¸Ë¸m¦WºÙ(device name)ªº®É­Ô¡M¨ä¿ï¶µ(options)¤]¥i¯à¦]§@·~¨t²Î¦Ó²§¡C
¨Ò¦p¡G¦b Linux ¤W¬O mt -f ¡M¦ý¬O¦b HPUX 9 ¤W«o¬O mt -t¡C



ª`·N - §Ú¥u¥H Exabyte 8mm SCSI tape drives ¹ê§@¹L¡M¦pªG±z¤w¸gÅª¹L¨ä¥Lªº®æ¦¡¡M
½ÐÅý§Úª¾¹D¡M§Ú±N·|§â¦o¼W¥[¨ì³o¥÷ Note ¤¤¡C






\subsection{¤@¨Ç°ò¥»±`ÃÑ}



·íÅª¨ú VMS ¥Ñ ``copy'' «ü¥O§@¦¨ªººÏ±a®É¡M¡]©Î¬O¬Ý°_¨Ó¹³¬O¥Ñ copy «ü¥O§@¦¨ªººÏ±a¡^¡M
±z¥²¶·­nª¾¹D¡M¨C­Ó¹ê»ÚªºÀÉ®×±N·|¤À¦¨¤TªºÀÉ®×¦s©ñ¦bºÏ±a¤W¡M¤À§O¬O¡§ÀÉÀY(header)¡¨, ¡§¸ê®Æ(data)¡¨, ©M¡§ÀÉ§À(trailer)¡¨¡C
¨ä¤¤ÀÉÀY(header) ©M ÀÉ§À(trailer)¦s©ñµÛÀÉ®×ªº°T®§¡M©M¦b VMS ¤Wªº¦ì¸m¡C¦Ó¸ê®Æ(data)·íµM´N¬O¦s©ñ­ì¨Óªº¸ê®Æ°Õ¡I
³o¨ÇÀÉ®×³£¥i¥H¥Ñ dd ³o­Ó«ü¥O±qºÏ±a(tape)¤WµÑ¨ú¥X¨Ó¡C
¥Ñ mt «ü¥O¡M¥i¥H±NºÏ±aÂà¨ì©Ò»Ý­nªº¦ì¸m¡C

½d¨Ò¡G§Ú¦³¤@­Ó³sÄò¦s©ñµÛÀÉ®×ªººÏ±a¡C³Ì«e­±¨â­Ó¦b VMS ¤WªºÀÉ¦W¬° ce66-2.evt ©M ce66-3.evt 
ºÏ±aªº¼ÐÅÒ(label)¬O c66a2¡C

¦pªG§Ú°õ¦æ¤U¦C«ü¥O¡G

\begin{tscreen}
\begin{verbatim}
> dd if=$TAPE bs=16k of=header1
> dd if=$TAPE bs=16k of=data1
> dd if=$TAPE bs=16k of=trailer1
> dd if=$TAPE bs=16k of=header2
> dd if=$TAPE bs=16k of=data2
> dd if=$TAPE bs=16k of=trailer2
\end{verbatim}
\end{tscreen}


§Ú dd ¤F¤»­ÓÀÉ®×¡Gheader1, data1, trailer1, header2, data2 ©M trailer2.  
¨Ï¥Î»yªk¦p¤U¡Gif="input file", bs="block size" ©M of="output file".  
TAPE ³o­Ó«K¬O¶·µø±zªº¾÷¾¹¤Wªº¸Ë¸m¦WºÙ¦Ó©w¡M¨Ò¦p¡G¦pªG±z¦b Linux ¤W¨Ï¥Î SCSI ªººÏ±a¸Ë¸m¡M
±zªº¸Ë¸m¦WºÙ¥i¯à¬O /dev/nts0 ¡C

¦pªG±z·Q­nÅª²Ä¤G­ÓÀÉ®×¡M¤£¬O²Ä¤@­Ó¡C±z¤£¦b·NÀÉÀY(header)¡M¦Ó¥B±z·Q­n¨Ï¥Î­ì¨ÓªºÀÉ¦W¡M±z¥i¥H³o»ò§@¡G

\begin{tscreen}
\begin{verbatim}
> mt -f $TAPE fsf 4
> dd if=$TAPE bs=16k of=ce66-2.evt
> mt -f $TAPE fsf 1
\end{verbatim}
\end{tscreen}


ª`·N ¡§4¡¨ - ¸õ¹L²Ä¤@­ÓÀÉ®×©ÒªþÄÝªº¤T­ÓÀÉ®×¡M©Ò¥H¤U¤@¤ñ¡]²Ä¤Gµ§¡^ªºÀÉÀY±N·|¬O±q²Ä¥|µ§¶}©l¡C
²Ä¤G­Ó mt ¬°¸õ¹L²Ä¤Gµ§ÀÉ®×ªºÀÉ§À(tailer)¨Ã¥B«ü¨ì¤U¤@µ§ÀÉ®×(²Ä¤Tµ§¸ê®ÆªºÀÉÀY)¡C
·íµM¡M±z¤]¥i¥H¨Ï¥Î mt ¨ÏºÏ±a§ÖÂà(bsf), ­ËÂà(rewind)¡M©Î¬O ºÏÀYÂk¦ì(offline, rewoffl).




\subsection{§ó¦h²Ó¸`}



ÀÉÀY(header) ©M ÀÉ§À(trailer) ¥]§t¤Fµ¹ VMS Àx¦sÀÉ®×ªº¤@¨Ç°T®§¡M¨Ò¦p°Ï¶ô¤j¤p(block size)¡C
¦P®É¦o­Ì¤]¥]§t¤FÀÉ®×¦WºÙ¡M¤è«K±z«Ø¥ß Script ÀÉ¨Ó¦Û°ÊÅª¨úÀÉ®×©Î¬O·j´M¯S©wªºÀÉ®×¡C
µM¦Ó¡M¦bºÏ±a¤Wªº²Ä¤@­ÓÀÉÀYÀÉ(header file)¡M©M¨ä¥LºÏ±a¤WªºÀÉÀYÀÉ¦³¨Ç³\ªº®t²§¡C

¹ï©ó¦bºÏ±a¤Wªº²Ä¤@­ÓÀÉ®×(°²³]¬° header1)¡M³Ì«e­±ªº¥|­Ó¦r¤¸±N·|¬O "VOL1" ¡M¨ä«á¦ñÀHµÛª©¥»¦WºÙ(volume name)¡C
¥»¨Ò¤¤¡Mheader1 ªº³Ìªì¤º®eÀ³¸Ó¬O "VOL1C66A2"¡CÀH«á¬O¤@­Ó¦r¦ê"HDR1" ¡Mªí¥Ü³o¬O¤@­ÓÀÉÀYÀÉ(header file)¡C
µM«á¤~¬OÀÉ®×¦WºÙ(file name)¡C¥»¨Ò¤¤¡M¦o·|¬O "HDR1CE66-2.EVT"¡C¤U¤@­ÓÄæ¦ì¤S¬Oª©¥»¦WºÙ(volume name)¡C

¹ï©ó¨ä¥Lªº¤£¬OºÏ±a¤W²Ä¤@­ÓÀÉÀYÀÉªºÀÉÀYÀÉ¡M³Ìªìªº VOL1 Äæ¦ì±N¤£·|¦s¦b¡C
¨ä¥LªºÄæ¦ì´N©M«e­±©Ò¤¶²Ðªº²Ä¤@­ÓÀÉÀYÀÉªºµ²ºc¤@¼Ò¤@¼Ë¡C¥t¤@­Ó¤ñ¸û¦³¥ÎªºÄæ¦ì¬O²Ä¤C­ÓÄæ¦ì¡C
¦o¬O¥H "DECFILES11A" ¬°µ²§À¡C¦o¥²¶·¦s¦b¡M¥ÎÁÙ½T»{ DEC Files11A standard.

\begin{tscreen}
\begin{verbatim}
       field     initial header         subsequent headers
       =====     =============          ==================
         1       VOL1 + volume name     HDR1 + file name
         2       3HDR1 + file name      volume name
         3       volume name            

         6                              ...DECFILES11A
         7      ...DECFILES11A
\end{verbatim}
\end{tscreen}


¨ä¥L§ó¸Ô²ÓªºÀÉÀY©MÀÉ§Àªºµ²ºc¡M½Ð°Ñ¦Ò DEC FILES11A ªº»¡©ú¤å¥ó¡C
(on the orange/grey wall - ask your local VMS folks :-).






\subsection{°Ï¶ô¤j¤pªº«ØÄ³(Block Size)}



¦b¨Ò¤l¤¤¡M§Ú¨Ï¥Îªº°Ï¶ô¤j¤p¬O 16K¡C¦b *nix ¨t²Î¤W¡MºÏºÐ¤WªºÀÉ®×¨Ã¨S¦³©M°Ï¶ô¤j¤p¦³Ãö³s¡M
µM¦Ó¡M¦b VMS ¤W¡M¨C¤@­ÓÀÉ®×³£¦³¤@­Ó©ú½Tªº°Ï¶ô¤j¤p(block size)¡C¤]´N¬O»¡¡M¦b Linux ºÝ¡M
°Ï¶ô¤j¤p¨Ã¨S¦h¤Ó¤jªºÃö«Y¡M°£«D·í¤£®e©ö±qºÏ±a¤¤Åª¥XÀÉ®×ªº®É­Ô¡C¦pªG±z§ä¤£¨ì°Ï¶ô¤j¤p(block size)¡M
±z¥i¥H¸ÕµÛ¦bºÏºÐ¸Ë¸m¤W¡M¥Î `mt -f \$TAPE setblk 0' ¨Ó³]©wµwÅéªº°Ï¶ô¤j¤p¡C
¥Î setblk ¿ï¶µªºµÑ¨úªº§Î¦¡¥i¯à·|ÀHµÛ mt ªºª©¥»¤£¦P¦Ó¦³©Ò¤£¤@¼Ë¡M
±zªººÏ±a¸Ë¸mªºµwÅé¬É­±¡MÁÙ¦³±z³ß·Rªº *nix ¨t²Î¤]·Q¬Û·íªºÃö«Y¡C

(·PÁÂ Wojtek Skulski (\nameurl{skulski@nsrlc6.nsrl.rochester.edu}{}) 
´£¥X setblk ¬ÛÃö³¡¥÷.)






\section{Á`µ²}






\subsection{ª©Åv}



°£«D¦³¯S§OÁn©ú¡MLinux HowTo ¤å¥óªºª©ÅvÂk©ó­Ó§O¡]­ì¡^§@ªÌ©Ò¦³¡C
¥u­n³o¥÷ª©ÅvÁn©ú«O¯d¦b©Ò¦³ªº¤å¥ó¤¤¡MLinux HowTo ¤å¥ó¥i¥H¥þ³¡©Î³¡¥÷¦a¥H¥ô¦ó§Î¦¡ªº´CÅé­×§ï©Î´²¼½¡C
¬Æ¦Ü¤¹³\¦³Àç§Q©Ê½èªº¦æ¬°¡CµM¦Ó¡M§Æ±æ¯à¥ýª¾·|­ì§@ªÌ¬ÛÃö¤å¥óªº´²§G¡C

¥ô¦óªºÂ½Ä¶¡M¤Þ¥Î¡M©Î¬O¾ã¦Xªº§@«~¡M¤Z¥]§t¨ì Linux HowTo ¤å¥óªÌ¡M³£ÄÝ©ó³o¥÷ª©ÅvÁn©úªº½d³ò¡C
¤]´N¬O»¡¡M±z¤£¤¹³\±q HOWTO ¤¤µoªí­l¥Í§@«~¡M©Î¬O¼W¥[ÃB¥~ªº­­¨î¡C
¦ý¦b¬Y¨Ç°²©wªº±¡ªp¤U¡M³o¨Ç³W©w¥i¥H¦³¨Ò¥~¡C¬ÛÃö²Ó¸`½ÐÁpÃ´ Linux HOWTO ªº¨ó½Õ¤H¡C
³sµ¸¤è¦¡¥i¦b¤U¤å¤¤§ä¨ì¡C

Á`¤§¡M§Ú­Ì§Æ±æ¾¨¥i¯àªº³z¹L¥ô¦ó§Î¦¡ªººÞ¹D´£¤É³o¥÷¤å¥óªº«Å¶Ç¡C¦ý¬O§Ú­Ì§Æ±æ¯à°÷«O¯d³o¥÷ª©ÅvÁn©ú¡C
¨Ã¥B¦p¦³¥ô¦óªº­×§ï¡M§Ú­Ì±N·|«Ü¼Ö¥Hªº³Q§iª¾¡C

¦pªG±z¦³¥ô¦óªººÃ°Ý¡M½Ð³sÁpÃ´ Linux HOWTO ªº¨ó½ÕªÌ Tim Bynum¡M
±z¥i¥H¨Ï¥Î email: \nameurl{linux-howto@sunsite.unc.edu}{} »P¨äÁpÃ´¡C






\subsection{«á§Ç}



³o¥÷§@«~¬O§Ú¦b Settore di Geofisica of the Universita' di Bologna (Italy) ªº¹ê§@¸gÅç¡C
¨ä VAX 4000 ¤]¤w¸g³Q¥H Linux ¬°§@·~¨t²Îªº©bÄË(pentium)ªº­Ó¤H¹q¸£©Ò¥N´À¤F¡C
§Ú¤j³¡¤Àªº¦P¨Æ¥H«e³£¬O VMS ªº·R¥ÎªÌ¡M¥i¬O²{¦b¦o­Ì³£¤w¸gÂà´«¨ì Linux ¤W¤F¡C

``From VMS to Linux HOWTO''¡]±q VMS ¨ì Linux¡^³o¥÷¤å¥ó¥D­n¬O¥Ñ Guido Gonzato ©Ò¼¶¼gªº, \nameurl{guido ``at'' ibogeo.df.unibo.it}{}, Mike Miller ¥ý¥Í, 
\nameurl{miller5@uiuc.edu}{}, ¥L°^Äm¦p¦ó±q Linux ¤WÅª¨ú VMS ªº³Æ¥÷ºÏ±a³o¤@³¡¥÷¤å³¹¡C
¤Q¤À·PÁÂ§Úªº¦P¨Æ©MªB¤Í­Ì¡M¥L­ÌÀ°§Ú¸ÑÄÀ¤F¤j³¡¤À VMS ¨Ï¥ÎªÌªº»Ý­n©M²ßºD¡M¤×¨ä·PÁÂ Dr. Warner Marzocchi¡C

½ÐÀ°§Ú§ïµ½³o¥÷ HOWTO ¤å¥ó¡C¦]¬°§Ú¤£¬O VMS ±M®a¡M¦Ó¥B¤]¤£¥i¯à¬O¡M©Ò¥H¤Q¤ÀÅwªï±zªº«ØÄ³¡M©M¿ù»~¦^³ø¡C

Åwªï±z¶i¤J Linux ªº·µ°ó,

Guido {\ttfamily =8-)}






\subsection{Ä¶ªÌ§Ç}

¦bÂ½Ä¶³o½g¤å³¹ªº®É­Ô¡M§ÚÃäÂ½Ä¶Ãä·Q¡M¥xÆW²{¦bÁÙ¦³¤H¦b¨Ï¥Î VMS ¶Ü¡H
¬Æ¦ÜÁÙ¤£¬O«Ü¦h¤Hª¾¹D VMS©O¡I·í§ÚÂ½Ä¶§¹«áµo²{¡M¨ä¹ê³o½g¤å³¹¤£¥u¾A¦X VMS ªº¨Ï¥ÎªÌ¡M
¥ô¦ó·Q­n¶i¤J Linux ¥@¬Éªº¤H³£¥i¥H°Ñ¦Ò¬Ý¬Ý¡M¦]¬°¡M³o½g¤å³¹ªºÆ[©ÀÁÙ¤£ºâ¤ÓÃø¡M
Åª§¹«á¡M¤j­P¤W¥i¥H¤F¸Ñ Linux ªº°ò¥»¾Þ§@¡C(¬Æ¬O±z¥i¥H§â¥L·Q¹³¦¨±q dos ¨ì Linux¡^¡C
¦ý¬O¡M»¡¯uªº¡M¥ú¾Ì³o½g¤å³¹ÁÙ¬O¤£°÷ªº¡M§Ú·Q¡M¦pªG Linux ªº¸ô­n¨«±o¥­¶¶¤@ÂIªº¸Ü¡M
¶R¤@¥»¦n®Ñµ´¹ï¬O¥²­nªº¡C

©Î³\¡M¦³¨Ç¦a¤èÂ½ªº¤£¬O«Ü¶K¤Á¡M¦pªG¦³¦nªº«ØÄ³¡M©Î¬O¦³¥ô¦ó¦a¤èªº»~ÂÕ¡M
½Ð¤£§[½ç±Ð¡ILinux ªº¥@¬É¡M¬O¤@­ÓÀH®ÉÀH¦a³£¦b¾Ç²ßªº¥@¬É¡I

Linux ·R¦nªÌ,

®p¦à
email: \nameurl{sonnystone@kimo.com.tw}{}

Dec 27, 2000 ¤_ MI¡C



\end{document}
