Hitchhiker's Guide to Openbsd


Initial Setup - for PPP(8)


Download 1.27 Mb.
Pdf ko'rish
bet93/258
Sana04.04.2023
Hajmi1.27 Mb.
#1328980
1   ...   89   90   91   92   93   94   95   96   ...   258
Bog'liq
obsd-faq49

Initial Setup - for PPP(8)
Initial Setup for the userland PPP daemon consists of editing your /etc/ppp/ppp.conf file. This file 
doesn't exist by default, but there is a file /etc/ppp/ppp.conf.sample which you can simply edit to create 
your own ppp.conf file. Here I will start with the simplest and probably most used setup. Here is a quick 
ppp.conf file that simply sets some defaults: 
default:
set log Phase Chat LCP IPCP CCP tun command
set device /dev/cua01
http://www.openbsd.org/faq/faq6.html (12 of 33)9/4/2011 10:02:06 AM


6 - Networking
set speed 115200
set dial "ABORT BUSY ABORT NO\\sCARRIER TIMEOUT 5 \"\" AT 
OK-AT-OK ATE1Q0 OK \\dATDT\\T TIMEOUT 40 CONNECT"
The section under the 
default:
tag gets executed each time. Here we set up all our critical 
information. With "set log" we set our logging levels. This can be changed: refer to 
ppp(8)
 for more info 
on setting up logging levels. Our device gets set with "set device". This is the device that the modem is 
on. In this example the modem is on com port 2. Therefore com port 1 would be /dev/cua00. With "set 
speed" we set the speed of our dial-up connection and with "set dial" we set our dial-up parameters. 
With this we can change our timeout time, etc. This line should stay pretty much as it is though. 
Now we can move on and set up information specific to our ISP. We do this by adding another tag under 
our 
default:
section. This tag can be called anything you want - easiest to just use the name of your 
ISP. Here I will use 
myisp:
as our tag referring to our ISP. Here is a simple setup incorporating all we 
need to get ourselves connected: 
myisp:
set phone 1234567
set login "ABORT NO\\sCARRIER TIMEOUT 5 ogin:--ogin: ppp 
word: ppp"
set timeout 120
set ifaddr 10.0.0.1/0 10.0.0.2/0 255.255.255.0 0.0.0.0
add default HISADDR 
enable dns
Here we have set up essential info for that specific ISP. The first option "set phone" sets your ISP's dial-
up number. The "set login" sets our login options. Here we have the timeout set to 5; this means that we 
will abort our login attempt after 5 seconds if no carrier is found. Otherwise it will wait for "login:" to be 
sent and send in your username and password. 
In this example our Username = ppp and Password = ppp. These values will need to be changed. The 
line "set timeout" sets the idle timeout for the entire connection duration to 120 seconds. The "set ifaddr" 
line is a little tricky. Here is a more extensive explanation. 
set ifaddr 10.0.0.1/0 10.0.0.2/0 255.255.255.0 0.0.0.0
In the above line, we have it set in the format of "set ifaddr [myaddr[/nn] [hisaddr[/nn] [netmask 

Download 1.27 Mb.

Do'stlaringiz bilan baham:
1   ...   89   90   91   92   93   94   95   96   ...   258




Ma'lumotlar bazasi mualliflik huquqi bilan himoyalangan ©fayllar.org 2025
ma'muriyatiga murojaat qiling