📄 install
字号:
define pppd - !pppd < \v(line) > \v(line) defaultroute----------------------------------------------------------------------To use this, add the above to your ~/.kermrc file (minus the'---...---' separators). Then start kermit. After you have startedthe remote PPP server by hand and you see garbage being printed on thescreen, return back to your local kermit prompt and execute thecommand 'do pppd'. In this particular circumstance, you will not needto exit completely from kermit.Before you start initial testing, you may want to read the pppd manpage. This will allow you to familiarize yourself with the some ofthe options available to you for starting your local pppd.Of particular interest for most people is the 'defaultroute' option topppd. If you have a standalone machine, then all your foreign trafficmust go to the peer. Adding the 'defaultroute' option to pppdinstructs pppd to set your system up in such a manner.Determining if the link is actually up======================================There are several ways to determine if the link has actaully beenestablished. I will go through some of them.1) You may look at the pppd log file (typically /usr/adm/pppd.log). If you see lines that look similar to: Jan 11 23:13:38 sidney2b pppd[2141]: local IP address 35.9.12.55 Jan 11 23:13:38 sidney2b pppd[2141]: remote IP address 35.9.10.13 You are probably up.2) You may check the status of the PPP interface. Using the command: /usr/etc/ifconfig ppp0 You should see that the interface is UP and that there are valid IP addresses assigned to it (0.0.0.0 is not valid). Here is an example of what you might see: ppp0: flags=51<UP,POINTOPOINT,RUNNING> inet 35.9.12.104 --> 35.9.10.14 netmask ff000000 3) You may check the routing. When the connection comes up, you should get at least one route to the new interface. If you specified 'defaultroute' to pppd, you should also see a default route. The command for checking routes is 'netstat -rn'. Here is an example of what you might see: Routing tables Destination Gateway Flags Refs Use Interface 35.9.10.32 35.9.15.107 UH 0 0 ppp0 127.0.0.1 127.0.0.1 UH 12 2636 lo0 35.9.15.107 127.0.0.1 UH 0 0 lo0 default 35.9.10.32 UG 2 6 ppp0 192.42.172 192.42.172.1 U 15 8872 en0 In the above case, the peer is 35.9.10.32 and my local machine has been assigned 35.9.15.107. All foreign traffic goes through the default route to the peer. If you don't have an ethernet card installed on your system, you will not have an 'en0' interface. The routing issue is important. Discussion of this issue is outsidethe scope of these instructions, but I thought it might be beneficialto list a few other important tools that may help you out. The manpages can give more details: /usr/etc/ping - send packets to an IP address or hostname traceroute - Show the route to a particular machineThe IP address that you use can be negotiated automatically in PPP.Unlike SLIP, you do not have to specify an IP address when the link isbrought up. If no address is specified as an argument to pppd, thenPPP will negotiate the address with the peer. This is the preferredmechanism of operation. Probably the only time you should specify anIP address as an argument to pppd is if you are assigned your own IPaddress by your system administrator. Otherwise, sit back and let PPPdo the work for you. If you are assigned an address by your PPPprovider, that address does _NOT_ go in the hostconfig.app or netinfo.Instead, you provide that IP address as a command line option to pppdwhen you start it up. See the pppd man page for details on specifyinga fixed IP address.A Typical PPP Session=====================A tyipcal PPP session begins when you log into your system. From aterminal window, you will run your dial script by typing its name atthe prompt. If you use the Workspace manager, you can double click onthe scripts icon. This will start the chat process that will dial themodem and log into the remote system. It will then turn control overto pppd. If your script is successful (as described in the"Determining if the link is actually up" section), you will be allset. All your apps, OmniWeb, FTP, telnet, etc should work. Pleasenote that pppd itself will not appear to do anything but sit there.Once you are through using the connection, you can close down the PPPlink by executing the ppp down script. Again, this can be done bytyping the name of the pppdown script in a terminal window, or doubleclicking on the appropriate icon in the Workspace manager. At thispoint, ppp will terminate the phone connection and pppd will die off.You may start and kill the ppp session as many times as you like whileyou are logged on. However, if you do not kill the PPP session, itwill not die once you log out (unless you use the idle timer option topppd). Thus your telephone will remain off the hook and your computerwill remain connected to the net until you log back in and shut downthe connection. Turning off the computer will obviously close theconnection.Name Resolution===============Once you have a ppp connection up, you may notice that your machinewill not be able to resolve the names of machines to their IPaddresses. You can check this by trying to telnet to a machine outsideyour local domain. If "telnet <IP address of machine>" is successful,but "telnet <machinename>" is not, then your name resolution is notconfigured correctly. The fix is to edit the file /etc/resolv.conf.This file contains two important items. The first is your domainname. This is the name that is automatically tacked on to a computername if you don't specify the complete name. For example if my domainis 'cps.msu.edu' and I say 'telnet sidney', the computer will try'telnet sidney.cps.msu.edu' (although, it will not print this name onthe command line).The second thing is a list of name servers. These should be local toyour ppp provider. Your network administrator will be able to provideyou with the appropriate addresses and you should use those, not theones listed below. An example file might look like:----------------------------------------------------------------------domain cps.msu.edu## Insert local name servers here### MSU name servers #nameserver 35.8.2.41nameserver 35.8.2.41nameserver 128.247.160.56----------------------------------------------------------------------You will need to reboot your computer for the new nameservers to takeeffect.Making startup and shutdown scripts===================================By this time, I'm assuming that PPP has been successfully installed.However, there are a few more steps that you must perform so thatusing PPP (now and with future upgrades) will be convenient and easy.These steps are optional, but they are highly recommended.Make scripts 'pppup' and 'pppdown' that bring up and shutdown PPPconnections. There are a number of example scripts that you can copyand modify. Reading the man page for 'chat' will help you understandthese scripts. You should note that once these scripts are made, youprobably won't need to change them for future upgrades to PPP.One note that you should be VERY careful about. These file are shellscripts. This means that the contents are executed in a shell just asif you had typed them in by hand. You must make sure that anycharacters that are treated specially by the shell (such as < > | \ )are inside quotation marks (""). Otherwise, they will be interpretedby the shell in a manner that is probably to your dislike. Forexample, if your peer sends you a prompt like MSUnet> you must add itto the chat portion of your script like "MSUnet>".In order to ensure that these scripts are not removed or modified whennew versions of PPP are installed, you should copy all importantscripts into a new directory. I suggest /usr/local/ppp/scripts. Thisdirectory will not be modified during installation. Further, as youdid earlier for the important binaries, you may want to add importantscripts to a directory that is in the default UNIX Search Path. Themechanism for doing this is as follows. Suppose you have a script'pppup' (found in /usr/local/ppp/scripts) that you want to beavailable on your command line. You could execute the commands: /bin/mkdirs -o root -g wheel -m 755 /usr/local/bin ln -s /usr/local/ppp/scripts/pppup /usr/local/binOnce you log out and log back in, this script will be available. Ifyou want to be able to call this script from a non-root account, youneed to modify the permission on the file to make it suid root.Please note that this can be a potential security hazard. See yoursystem administrator for more details.As mentioned above, of particular interest for most people is the'defaultroute' option to pppd. If you have a standalone machine, thenall your foreign traffic must go to the peer. Remember to add the'defaultroute' option to pppd in your startup scripts if necessary (orplace it in the /etc/ppp/options file).Troubleshooting===============Any time that you have a bug report, please use the includedMailBug.app (in the NeXT directory) to submit an electronic report.If you don't have email capability, please see the WWW site and usethe bug report form found there. Please remember to include your hardware type and the LKS version number in all reports. This numbermay be found in the file /usr/adm/messages (once the LKS has beeninstalled). Also, for most questions, it is best to append a copy ofthe /usr/adm/pppd.log file.If you do have troubles, please see the FAQ on: http://www.peak.org/next/ppp/Updates=======You may want to join the mailing list for PPP. This will keepyou informed of new releases and will provide an arena for discussingproblems with the NeXT specific PPP port. To add yourself to the list(or for any other administrative requests), send an email message to: majordomo@peak.orgwith no subject and message body consisting of: subscribe nextppp (please use your own name ;). To send mail to all the participants onthe list, address your messages to: nextppp@peak.orgIf you want announcements only, there is a second "announcements only"list. To subscribe to this, you may use the alternate body: subscribe nextppp-announce You don't need to subscribe to both. All announcements are forwardedto the regular list.Security========Security issues are not dealt with in this document. Pleasenote that the pppd file is installed suid root. This is a potentialsecurity hazard.Noted bugs==========There have been various problems reported when trying to install LKSsthe way NeXT intended (i.e. placing them in /usr/lib/kern_loader/* andmodifying /etc/kern_loader.conf). The main problem is that if usershave a bad copy of the LKS, the system will panic and will be unableto boot. So, for the time, it is suggested that you install the packagemanually and load the LKS in /etc/rc.local as directed above.Modem Configuration===================It is important to use hardware flow control if you use a high speedmodem. On my supra V.32bis modem, the command to use Hardware FlowControl is 'AT&K3'.Also, you will probably want to set your modem so that when the DTR isdropped, the modem will disconnect. On my modem the command is'AT&D2' This setting disables auto-answer so if you want to allowdialins, you must read your modem manual to determine the correctsetting.Obtaining the Software by Electronic Mail-----------------------------------------Do not send me requests for the software; they will be ignored(without response). If you cannot use FTP at all, there is a servicecalled "ftpmail" available from decwrl.dec.com: you can send e-mail tothis machine and it will use FTP to retrieve files for you and sendyou the files back again via e-mail. To find out more about theftpmail service, send a message to "ftpmail@decwrl.dec.com" whose bodyconsists of the single line "help".ThanksStephen J. Perkins
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -