Linux
Reply Return

Ǣ : Դ

ͤ
: sakchai
ѹ : 08 áҤ, 1998 at 20:58:16 [ IP : 203.144.255.66 ]
Ǣ : Դ
¢ͤ:
˹еԴ繨ԧ

ͺ 1
: Jonix
ѹ : 08 áҤ, 1998 at 22:45:47 [ IP 203.148.200.249 ]
Ǣ : Re: Դ
ͺ :
º Դ power ºѺ

Ҥس terminal server Ẻ password Ẻ manual
dip ФѺ

ҧ
username nathanan
password mypassword
phone 771144
com port = com1 = ttyS0
= com2 = ttyS1
= com3 = ttyS2
-------------------------------------------------------------------------------->8
main:
port ttyS2
speed 115200
reset
get $local 0.0.0.0
send ATZ\r
wait OK 2
if $errlvl != 0 goto modem_trouble
dial 771144
if $errlvl != 1 goto modem_trouble
login:
wait name 40
send nathanan\n
wait word 40
send mypassword\n
sleep 3
print CONNECTED to the remote PPP server
mode PPP
goto exit
prompt_error:
print TIME-OUT waiting for the PPP server to fire up...
goto error
login_error:
print Trouble waiting for the Login: prompt...
goto error
password_error:
print Trouble waiting for the Password: prompt...
goto error
modem_trouble:
print Trouble ocurred with the modem...
error:
print CONNECT FAILED to the PPP server.
quit
exit:
reset
exit
---------------------------------------------------------------------------------------------->8
save ppp.dip
login root ҡ
dip -v ppp

աԸդ chat script
Ҷ username password Ẻ manual 仴ٷ
http://www.thailinux.org/02_94linuxnet4.html
¤Ѻ ´ҡ

terminal server ͧس PAP (Password Authentication Protocol)
ҧСӵѺ

ҧ /etc/ppp/ppp-on-dialer Ѻ

------------------------------------------------->8
#!/bin/sh
#
# This is part 2 of the ppp-on script. It will perform the connection
# protocol for the desired connection.
#
exec 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 ''
------------------------------------------------->8

ҧ /etc/ppp/pap-secrets
------------------------------------------------->8
nathanan * mypassword
------------------------------------------------->8

/etc/ppp/options
------------------------------------------------->8
name nathanan
------------------------------------------------->8


/usr/sbin/ppp-on
------------------------------------------------>8
#!/bin/sh
TELEPHONE=748727 # The telephone number for the connection
NETMASK=255.255.255.0
export TELEPHONE

DIALER_SCRIPT=/etc/ppp/ppp-on-dialer

exec /usr/sbin/pppd -d -detach crtscts /dev/ttyS2 38400 \
noipdefault netmask $NETMASK defaultroute connect $DIALER_SCRIPT
------------------------------------------------>8

ԴºѾǡ
ppp-on ¤Ѻ

ͨҧ١ ppp-off


*** ش

Ҥس LAN ź default route ͹¤
route del default ( ppp-on Ѻ)
pppd default route ѹͧ

(͡Ҩҡ Lulu Ѻ ͺͧ )


ҹ سҪµͺԸѭ˹¤Ѻ ͺسҡѺ :

:
E-Mail :
Ǣ :
ͤ :