You are not logged in.

#1 2007-02-21 12:03:39

yellowfox
Member
Registered: 2007-02-16
Posts: 19

I can`t force DNS adress

Hi, I use ppp protocol to connecting with net, system use the setting from /etc/ppp/resolv.conf not from /etc/resolv.conf I tried to do symlink but it

doesn`t help. All time when I do type pppd call .... /etc/ppp/resolv.conf is changing to standard DNS setting as beginning. Then I try type my DNS

server adress, save and ones again type pppd call .... but it is the same. What`s changed me this setting, How can I test this. I suppose it`s depend

of my /etc/ppp/options setting but I can`t understand what`s wrong

Thanks in advice

Last edited by yellowfox (2007-02-21 12:04:08)

Offline

#2 2007-02-21 16:57:36

pelle.k
Member
From: Åre, Sweden (EU)
Registered: 2006-04-30
Posts: 667

Re: I can`t force DNS adress

Well, if your ppp0 (or whatever interface you are using) is using dhcp, then /etc/resolv.conf will be overwritten. That's what dhcp client does, amongst other things.


"Your beliefs can be like fences that surround you.
You must first see them or you will not even realize that you are not free, simply because you will not see beyond the fences.
They will represent the boundaries of your experience."

SETH / Jane Roberts

Offline

#3 2007-02-21 18:38:56

yellowfox
Member
Registered: 2007-02-16
Posts: 19

Re: I can`t force DNS adress

No i have normal ASDL modem thomson speedtouch 330 without dhcp client. I haven`t this problem on Slackware, only on Arch

Offline

#4 2007-02-21 22:50:19

berbae
Member
From: France
Registered: 2007-02-12
Posts: 1,302

Re: I can`t force DNS adress

Hi yellowfox
The system uses /etc/resolv.conf for the DNS addresses.
If the usepeerdns option is used in the called options file pppd will write the DNS addresses in /etc/ppp/resolv.conf
from man pppd :

usepeerdns
              Ask the peer for up to 2 DNS server addresses.  The addresses  sup-
              plied  by the peer (if any) are passed to the /etc/ppp/ip-up script
              in the environment variables DNS1 and  DNS2,  and  the  environment
              variable  USEPEERDNS will be set to 1.  In addition, pppd will cre-
              ate an /etc/ppp/resolv.conf file containing one or  two  nameserver
              lines with the address(es) supplied by the peer.

So it's necessary to write the DNS addresses in the /etc/resolv.conf.
here is my /etc/ppp/ip-up script file to do that:

#!/bin/sh
#
# This script is run by pppd when there's a successful ppp connection.
#
[ -z "$USEPEERDNS" ] && return
echo "nameserver $DNS1" >/etc/resolv.conf
echo "nameserver $DNS2" >>/etc/resolv.conf
sleep 1
ntpd -qgx &

The last line is for synchronizing the system clock when I connect to the web.

I don't know if that will work for you, but without knowing the options passed to pppd I cannot say if you can use a similar method.
pppd call ... the options are in the file given for the ..., probably in the  /etc/ppp/peers directory.
Good luck.

Offline

#5 2007-02-22 11:27:18

yellowfox
Member
Registered: 2007-02-16
Posts: 19

Re: I can`t force DNS adress

OMG now I have even with connecting problem ( I didn`t try you solution yet)

Plugin pppoatm.so loaded.
PPPoATM plugin_init
PPPoATM setdevname_pppoatm - SUCCESS:0.35
Using interface ppp0
Connect: ppp0 <--> 0.35
LCP terminated by peer
Connection terminated.
Modem hangup

I searched internet about 6 hours but I didn`t find any solution, please help me, I`m weary sad

Offline

#6 2007-02-22 14:24:39

berbae
Member
From: France
Registered: 2007-02-12
Posts: 1,302

Re: I can`t force DNS adress

The solution I propose works if you pass the 'usepeerdns' option to pppd.
Can you post the content of the options file after the call in the command 'pppd call ...' ?
If it contains a connexion password, replace it with **** before posting.

Offline

#7 2007-02-23 20:07:30

yellowfox
Member
Registered: 2007-02-16
Posts: 19

Re: I can`t force DNS adress

Now I know what`s wrong, It isn`t setting in /etc/ppp/
I can`t load firmware, I tried it on another distro but it was te same, modem don`t respond, It sholud blink (diode) after I loading firmware but that isn`t. I haven`t this problem on windows. Very strange 8|


I tried reload usb controler, speedtch and pppoatm moduls but it nothing change

Last edited by yellowfox (2007-02-23 20:09:33)

Offline

Board footer

Powered by FluxBB