Command line ppp works but not chat script?

Command line ppp works but not chat script?

Post by oa » Fri, 15 Oct 1999 04:00:00



I'm able to make a ppp connection on the command line but I'm rather
baffled why I can't connect with that same information using the
chat scripts.

Anyone know how I might translate this working command line:

pppd connect 'chat -v "" ATDTmyispnumber CONNECT "" ogin: \#mylogin
word: mypassword' /dev/modem 57600 noipdefault debug crtscts modem defaultroute

into the chat scripts so they'll behave the same way?

I can also get a successful ppp connection with xisp.

Some of the problems included stu like this left in /var/log/message:

Connect: ppp0 <--> /dev/modem
pppd[863]: LCP: timeout sending Config-Requests
pppd[863]: Connection terminated.
pppd[863]: Receive serial link is not 8-bit clean:
pppd[863]: Problem: all had bit 7 set to 0
pppd[863]: tcflush failed: Invalid argument
pppd[863]: Hangup (SIGHUP)
pppd[863]: Exit.

Is there any problem with just making a file with the command line I
have above and executing that every time instead?

Thanks,

-Tony

 
 
 

Command line ppp works but not chat script?

Post by Clifford Ki » Fri, 15 Oct 1999 04:00:00



> I'm able to make a ppp connection on the command line but I'm rather
> baffled why I can't connect with that same information using the
> chat scripts.
> Anyone know how I might translate this working command line:
> pppd connect 'chat -v "" ATDTmyispnumber CONNECT "" ogin: \#mylogin
> word: mypassword' /dev/modem 57600 noipdefault debug crtscts modem defaultroute
> into the chat scripts so they'll behave the same way?

Not all of the command is a chat script.  That said, one way to write
the chat script is

"" ATDTmyispnumber
CONNECT ""
ogin: \#mylogin
word: mypassword

although I *think* all you need is to separate the various strings with
either spaces, tabs, or end-of-line.  You then need the -f option for
chat in the pppd argument list to specify the filename for the chat
script.

Quote:> I can also get a successful ppp connection with xisp.
> Some of the problems included stu like this left in /var/log/message:
> Connect: ppp0 <--> /dev/modem
> pppd[863]: LCP: timeout sending Config-Requests
> pppd[863]: Connection terminated.
> pppd[863]: Receive serial link is not 8-bit clean:
> pppd[863]: Problem: all had bit 7 set to 0
> pppd[863]: tcflush failed: Invalid argument
> pppd[863]: Hangup (SIGHUP)
> pppd[863]: Exit.

This almost always means the chat script has done something that has
confused teh ISP, or omitted something it needs to start PPP on it's
end, or you are trying a login/password when you should have configured
for PAP or CHAP authentication.  There should be chat messages somewhere
in a file in /var/log that may provide a clue as to what's wrong.  One
common thing is the  CONNECT ""  in your script which sends a carriage
return and can confuse an ISP into presenting a text prompt or menu.

Quote:> Is there any problem with just making a file with the command line I
> have above and executing that every time instead?

Nope, except I'd lose the \# unless it actually is part of the login name.
My regular pppd scripts are just that, one line.

--

/* Governments should be changed like diapers - often and for the
 * same reason. */

 
 
 

1. PPP/Chat: Working chat script Linux==>SCO?

: I am using ppp/chat to connect by Linux box to a SCO box and am having a
: strange problem.

: The chat script fails to log me into the SCO box reliably (only works 1 out of
: 20 times). I originally was doing this on a modem and when I had problems with
: that, I arranged a setup on a direct cable with the two systems right next
: to each other.

: The chat script sees the login fine and attempts to sent the nppp login, but
: never sees the password prompt come back. Its as if the login wasn't sent
: with a carriage return.

Try putting a one second delay before sending the login name, then
one second after, and then the newline/carriage return.

Do the same for the password.  

SCO getty sometimes has problems dealing with fast input at the login: prompt.

--


"Nice shark...pretty shark..." -- Londo, "The Gathering"

2. termcap entry for aixterm

3. PPP works with manual connection, but not with chat script

4. Where to get info on memory config in sparcs

5. PPP chat script not working...

6. where to find patches for 0.98pl3

7. why does i=`echo -n $b` work on command line, but not in script?

8. FTPd permissions

9. works on command line, but not in script

10. Can't Get PPP Working - Chat (ppp-on) script won't dial

11. Chat line in script not passing to modem

12. ppp in chat mode, how to debug chat script