how to fix ip-address to an user(ppp client) usin chap-secre

PPPoE related questions
Post Reply
psr
Posts: 31
Joined: 07 Dec 2014, 06:37

how to fix ip-address to an user(ppp client) usin chap-secre

Post by psr »

hi ,
I am beginner in pppoe server setting please help

1) I am using accel-ppp version 1.8.
2) my main idea is using chap-secrets file , I want to fix ip address allocated to a ppp client (user) every time.
my chap secrets file looks like.
#####Start of the config############
user0 * user0 10.0.2.17
user1 * user1 10.0.2.18
#####END of the config############
my accel-ppp config file
#########################################
[modules]
log_syslog

#pptp
#l2tp
pppoe

#auth_mschap_v2
#auth_mschap_v1
auth_chap_md5
#auth_pap

ippool

chap-secrets

[core]
log-error=/var/log/accel-ppp/core.log
thread-count=4

[ppp]
verbose=1
min-mtu=1280
mtu=1400
mru=1400
ipv4=require
ipv6=deny

[lcp]
echo-interval=30
echo-failure=3

[pptp]
verbose=1

[pppoe]
interface=eth0
verbose=1

[l2tp]
verbose=1

[dns]
dns1=172.16.0.1
dns2=172.16.1.1

#[client-ip-range]
#192.168.0.0/24

[ip-pool]
gw-ip-address=10.0.2.15
10.0.2.17-255

[log]
log-emerg=/var/log/accel-ppp/emerg.log
#syslog=accel-pppd,daemon
copy=1
level=3

[chap-secrets]
gw-ip-address=10.0.2.15
chap-secrets=/etc/ppp/chap-secrets

[cli]
telnet=127.0.0.1:2000
tcp=127.0.0.1:2001
#password=123
#######################accel-ppp config file ends##############
I want user0 to get 10.0.2.17 always when ever he tries to connect.

Now accel-ppp is allocating randomly for every connectiion.

can some body help me please or provide some pointer to start .


Thanks,
Dmitry
Администратор
Posts: 954
Joined: 09 Oct 2014, 10:06

Re: how to fix ip-address to an user(ppp client) usin chap-s

Post by Dmitry »

do you need dynamic addresses or static only ?
if you don't need dynamic addresses then disable ippool module (remove it from modules)
if you need both static and dynamic addresses then place ippool below chap-secrets:

Code: Select all

[modules]
chap-secrets
ippool
psr
Posts: 31
Joined: 07 Dec 2014, 06:37

Re: how to fix ip-address to an user(ppp client) usin chap-s

Post by psr »

Thanks for the reply .

I want always static ip ,which should be decided by chap-secrets file.

I will try what you asked and tell you,
thank you for your help.
psr
Posts: 31
Joined: 07 Dec 2014, 06:37

Re: how to fix ip-address to an user(ppp client) usin chap-s

Post by psr »

HI Thank you very much for your help.

It is working :)
Post Reply