Radius pararmeters

Работа с серверами доступа Juniper, Cisco, Ericsson
~AsmodeuS~
Site Admin
Сообщения: 5604
Зарегистрирован: Пт янв 28, 2005 3:11 pm
Контактная информация:

Re: Radius pararmeters

Сообщение ~AsmodeuS~ » Сб окт 10, 2015 3:15 pm

для начала сравните вашу таблице журнала ошибок оригинальной

Код: Выделить всё


CREATE TABLE `errors_log` (
  `date` datetime NOT NULL,
  `log_type` tinyint(3) unsigned NOT NULL DEFAULT '0',
  `action` varchar(10) NOT NULL,
  `user` varchar(20) NOT NULL,
  `message` varchar(120) NOT NULL,
  `nas_id` smallint(5) unsigned NOT NULL DEFAULT '0',
  KEY `i_user_date` (`user`, `date`),
  KEY `log_type` (`log_type`)
) COMMENT='Error log';


user_abills
Сообщения: 47
Зарегистрирован: Чт фев 19, 2015 1:16 pm

Re: Radius pararmeters

Сообщение user_abills » Сб окт 10, 2015 3:39 pm

Заметил одну вещь, у меня пакеты аккаунтинга прилетают с параметром Event-Timestamp на час больше чем установлено время.
Снял дамп с интерфейса, пакет от джунипера прилетает с параметром Event-Timestamp таким как нужно
в выводе radisd -X:

Код: Выделить всё

rlm_perl: Added pair Event-Timestamp = Oct 10 2015 19:26:31 MSK
в дампе:

Код: Выделить всё

AVP: l=6 t=Event-Timestamp(55): Oct 10, 2015 18:26:31.000000000 Московское время (зима)

~AsmodeuS~
Site Admin
Сообщения: 5604
Зарегистрирован: Пт янв 28, 2005 3:11 pm
Контактная информация:

Re: Radius pararmeters

Сообщение ~AsmodeuS~ » Вт окт 13, 2015 6:35 am

можно связку auth, acct (start,alive,stop)

user_abills
Сообщения: 47
Зарегистрирован: Чт фев 19, 2015 1:16 pm

Re: Radius pararmeters

Сообщение user_abills » Вт окт 13, 2015 7:02 am

это откуда взять?

~AsmodeuS~
Site Admin
Сообщения: 5604
Зарегистрирован: Пт янв 28, 2005 3:11 pm
Контактная информация:

Re: Radius pararmeters

Сообщение ~AsmodeuS~ » Вт окт 13, 2015 7:12 am

radiusd -X

user_abills
Сообщения: 47
Зарегистрирован: Чт фев 19, 2015 1:16 pm

Re: Radius pararmeters

Сообщение user_abills » Вт окт 13, 2015 8:24 am

Хм, со временем разобрались, на биллинге было напутано с временными зонами.
Но проблемы не ушли:
1)я не могу сделать hangup сессии(тоесть я жму на кнопку hangup в кабинете пользователя и она не сбрасывается)
2)В статистику сессии абонента данные так и не пишутся
3)в ошибках пишет

Код: Выделить всё

2015-10-13 10:35:01	LOG_WARNING	LOST_ALIVE	reave-home	Last Alive: 1145, Session-ID: jnpr ge-1/0/0.1073760622	X.X.X.X
2015-10-13 10:35:01	LOG_WARNING	HANGUP	reave-home	Dublicate ip: Y.Y.Y.Y DEPOSIT: 257.296080 CREDIT: 0.00 SESSION_SUM: 0.000000 STATUS: 0 SESSION_ID: jnpr ge-1/0/0.	X.X.X.X
2015-10-13 10:30:01	LOG_WARNING	HANGUP	reave-home	Lost session (9) DEPOSIT: 257.296080 CREDIT: 0.00 SESSION_SUM: 0.000000 STATUS: 0 SESSION_ID: jnpr ge-1/0/0.1073760622 G	X.X.X.X
2015-10-13 10:30:01	LOG_WARNING	HANGUP	reave-home	Lost session (9) DEPOSIT: 257.296080 CREDIT: 0.00 SESSION_SUM: 0.000000 STATUS: 0 SESSION_ID: jnpr ge-1/0/0.1073760622 G	X.X.X.X
2015-10-13 10:30:01	LOG_WARNING	HANGUP	reave-home	Dublicate ip: Y.Y.Y.Y DEPOSIT: 257.296080 CREDIT: 0.00 SESSION_SUM: 0.000000 STATUS: 0 SESSION_ID: jnpr ge-1/0/0.	X.X.X.X
2015-10-13 10:25:01	LOG_WARNING	HANGUP	reave-home	Lost session (9) DEPOSIT: 257.296080 CREDIT: 0.00 SESSION_SUM: 0.000000 STATUS: 0 SESSION_ID: jnpr ge-1/0/0.1073760622 G	X.X.X.X
2015-10-13 10:25:01	LOG_WARNING	HANGUP	reave-home	Dublicate ip: Y.Y.Y.Y DEPOSIT: 257.296080 CREDIT: 0.00 SESSION_SUM: 0.000000 STATUS: 0 SESSION_ID: jnpr ge-1/0/0.	X.X.X.X
2015-10-13 10:20:01	LOG_WARNING	HANGUP	reave-home	Lost session (9) DEPOSIT: 257.296080 CREDIT: 0.00 SESSION_SUM: 0.000000 STATUS: 0 SESSION_ID: jnpr ge-1/0/0.1073760622 G	X.X.X.X
2015-10-13 10:20:01	LOG_WARNING	HANGUP	reave-home	Dublicate ip: Y.Y.Y.Y DEPOSIT: 257.296080 CREDIT: 0.00 SESSION_SUM: 0.000000 STATUS: 0 SESSION_ID: jnpr ge-1/0/0.	X.X.X.X
2015-10-13 10:15:56	LOG_INFO	AUTH	reave-home	30b5.c2a9.364b/ge-1/0/0.1073760622:1173 GT: 0.01922
при этом в кабинете пользователя начинает отображаться не одна сессия и с разницей в 10 минут их колличество увеличиваются

на juniper при этом сессия не рвётся и пользователь переподключения не производит

~AsmodeuS~
Site Admin
Сообщения: 5604
Зарегистрирован: Пт янв 28, 2005 3:11 pm
Контактная информация:

Re: Radius pararmeters

Сообщение ~AsmodeuS~ » Вт окт 13, 2015 9:36 am

user_abills писал(а):Хм, со временем разобрались, на биллинге было напутано с временными зонами.
Но проблемы не ушли:
1)я не могу сделать hangup сессии(тоесть я жму на кнопку hangup в кабинете пользователя и она не сбрасывается)
user_abills писал(а):
скорее всего пароль не прописан
user_abills писал(а): 2)В статистику сессии абонента данные так и не пишутся
3)в ошибках пишет

Код: Выделить всё

2015-10-13 10:35:01	LOG_WARNING	LOST_ALIVE	reave-home	Last Alive: 1145, Session-ID: jnpr ge-1/0/0.1073760622	X.X.X.X
2015-10-13 10:35:01	LOG_WARNING	HANGUP	reave-home	Dublicate ip: Y.Y.Y.Y DEPOSIT: 257.296080 CREDIT: 0.00 SESSION_SUM: 0.000000 STATUS: 0 SESSION_ID: jnpr ge-1/0/0.	X.X.X.X
2015-10-13 10:30:01	LOG_WARNING	HANGUP	reave-home	Lost session (9) DEPOSIT: 257.296080 CREDIT: 0.00 SESSION_SUM: 0.000000 STATUS: 0 SESSION_ID: jnpr ge-1/0/0.1073760622 G	X.X.X.X
2015-10-13 10:30:01	LOG_WARNING	HANGUP	reave-home	Lost session (9) DEPOSIT: 257.296080 CREDIT: 0.00 SESSION_SUM: 0.000000 STATUS: 0 SESSION_ID: jnpr ge-1/0/0.1073760622 G	X.X.X.X
2015-10-13 10:30:01	LOG_WARNING	HANGUP	reave-home	Dublicate ip: Y.Y.Y.Y DEPOSIT: 257.296080 CREDIT: 0.00 SESSION_SUM: 0.000000 STATUS: 0 SESSION_ID: jnpr ge-1/0/0.	X.X.X.X
2015-10-13 10:25:01	LOG_WARNING	HANGUP	reave-home	Lost session (9) DEPOSIT: 257.296080 CREDIT: 0.00 SESSION_SUM: 0.000000 STATUS: 0 SESSION_ID: jnpr ge-1/0/0.1073760622 G	X.X.X.X
2015-10-13 10:25:01	LOG_WARNING	HANGUP	reave-home	Dublicate ip: Y.Y.Y.Y DEPOSIT: 257.296080 CREDIT: 0.00 SESSION_SUM: 0.000000 STATUS: 0 SESSION_ID: jnpr ge-1/0/0.	X.X.X.X
2015-10-13 10:20:01	LOG_WARNING	HANGUP	reave-home	Lost session (9) DEPOSIT: 257.296080 CREDIT: 0.00 SESSION_SUM: 0.000000 STATUS: 0 SESSION_ID: jnpr ge-1/0/0.1073760622 G	X.X.X.X
2015-10-13 10:20:01	LOG_WARNING	HANGUP	reave-home	Dublicate ip: Y.Y.Y.Y DEPOSIT: 257.296080 CREDIT: 0.00 SESSION_SUM: 0.000000 STATUS: 0 SESSION_ID: jnpr ge-1/0/0.	X.X.X.X
2015-10-13 10:15:56	LOG_INFO	AUTH	reave-home	30b5.c2a9.364b/ge-1/0/0.1073760622:1173 GT: 0.01922
при этом в кабинете пользователя начинает отображаться не одна сессия и с разницей в 10 минут их колличество увеличиваются

на juniper при этом сессия не рвётся и пользователь переподключения не производит
нужен радиус дебаг

radiusd -X

user_abills
Сообщения: 47
Зарегистрирован: Чт фев 19, 2015 1:16 pm

Re: Radius pararmeters

Сообщение user_abills » Вт окт 13, 2015 10:44 am

Код: Выделить всё

Listening on authentication address * port 1812
Listening on accounting address * port 1813
Ready to process requests.
rad_recv: Access-Request packet from host X.X.X.X port 59936, id=1, length=193
        User-Name = "mdv_reave"
        Service-Type = Framed-User
        Framed-Protocol = PPP
        CHAP-Password = 0xf2fd9a03e95d832fdc27c74d6e6ac3c0a6
        CHAP-Challenge = 0x534daa7062d2228de6a01edffc09f61f5f27444de0
        Chargeable-User-Identity = ""
        Acct-Session-Id = "jnpr xe-0/0/1.1073760704:18928"
        ERX-Dhcp-Mac-Addr = "30b5.c2a9.3541"
        NAS-Identifier = "mx_80"
        NAS-Port = 4195477
        NAS-Port-Id = "xe-0/0/1.1073760704:1173"
        NAS-Port-Type = Ethernet
        NAS-IP-Address = X.X.X.X
# Executing section authorize from file /usr/local/etc/raddb/sites-enabled/abills_default
+group authorize {
++[preprocess] = ok
++[mschap] = noop
[files] users: Matched entry DEFAULT at line 38
++[files] = ok
rlm_perl: Added pair NAS-Port = 4195477
rlm_perl: Added pair NAS-Port-Type = Ethernet
rlm_perl: Added pair Framed-Protocol = PPP
rlm_perl: Added pair Service-Type = Framed-User
rlm_perl: Added pair ERX-Dhcp-Mac-Addr = 30b5.c2a9.3541
rlm_perl: Added pair User-Name = mdv_reave
rlm_perl: Added pair NAS-IP-Address = X.X.X.X
rlm_perl: Added pair NAS-Identifier = mx_80
rlm_perl: Added pair NAS-Port-Id = xe-0/0/1.1073760704:1173
rlm_perl: Added pair Chargeable-User-Identity =
rlm_perl: Added pair Acct-Session-Id = jnpr xe-0/0/1.1073760704:18928
rlm_perl: Added pair CHAP-Challenge = 0x534daa7062d2228de6a01edffc09f61f5f27444de0
rlm_perl: Added pair CHAP-Password = 0xf2fd9a03e95d832fdc27c74d6e6ac3c0a6
rlm_perl: Added pair Framed-IP-Address = Y.Y.Y.Y
rlm_perl: Added pair Framed-IP-Netmask = 255.255.255.255
rlm_perl: Added pair ERX-Service-Activate:3 = svc-global-pppoe(20480000,20480000)
rlm_perl: Added pair Acct-Interim-Interval = 300
rlm_perl: Added pair Auth-Type = Accept
++[perl] = ok
+} # group authorize = ok
Found Auth-Type = Accept
Auth-Type = Accept, accepting the user
  WARNING: Empty post-auth section.  Using default return values.
# Executing section post-auth from file /usr/local/etc/raddb/sites-enabled/abills_default
Sending Access-Accept of id 1 to X.X.X.X port 59936
        Framed-IP-Address = Y.Y.Y.Y
        Framed-IP-Netmask = 255.255.255.255
        ERX-Service-Activate:3 += "svc-global-pppoe(20480000,20480000)"
        Acct-Interim-Interval = 300
Finished request 0.
Going to the next request
Waking up in 4.9 seconds.
rad_recv: Accounting-Request packet from host X.X.X.X port 59936, id=2, length=213
        User-Name = "mdv_reave"
        Acct-Status-Type = Start
        Acct-Session-Id = "jnpr xe-0/0/1.1073760704:18928"
        Service-Type = Framed-User
        Framed-Protocol = PPP
        ERX-Attr-177 = 0x506f72742053706565643a2031303030303030306b
        Acct-Authentic = RADIUS
        Acct-Delay-Time = 0
        ERX-Dhcp-Mac-Addr = "30b5.c2a9.3541"
        Event-Timestamp = "Oct 13 2015 13:38:19 GMT-3"
        Framed-IP-Address = Y.Y.Y.Y
        Framed-IP-Netmask = 255.255.255.255
        NAS-Identifier = "mx_80"
        NAS-Port = 4195477
        NAS-Port-Id = "xe-0/0/1.1073760704:1173"
        NAS-Port-Type = Ethernet
        NAS-IP-Address = X.X.X.X
# Executing section preacct from file /usr/local/etc/raddb/sites-enabled/abills_default
+group preacct {
++[preprocess] = ok
+} # group preacct = ok
# Executing section accounting from file /usr/local/etc/raddb/sites-enabled/abills_default
+group accounting {
rlm_perl: Added pair Framed-IP-Address = Y.Y.Y.Y
rlm_perl: Added pair Acct-Session-Id = jnpr xe-0/0/1.1073760704
rlm_perl: Added pair ERX-Attr-177 = 0x506f72742053706565643a2031303030303030306b
rlm_perl: Added pair NAS-Identifier = mx_80
rlm_perl: Added pair User-Name = mdv_reave
rlm_perl: Added pair Framed-IP-Netmask = 255.255.255.255
rlm_perl: Added pair ERX-Dhcp-Mac-Addr = 30b5.c2a9.3541
rlm_perl: Added pair Framed-Protocol = PPP
rlm_perl: Added pair Event-Timestamp = Oct 13 2015 13:38:19 GMT-3
rlm_perl: Added pair NAS-Port-Type = Ethernet
rlm_perl: Added pair NAS-Port = 4195477
rlm_perl: Added pair Acct-Status-Type = Start
rlm_perl: Added pair Acct-Delay-Time = 0
rlm_perl: Added pair NAS-Port-Id = xe-0/0/1.1073760704:1173
rlm_perl: Added pair NAS-IP-Address = X.X.X.X
rlm_perl: Added pair Service-Type = Framed-User
rlm_perl: Added pair Acct-Authentic = RADIUS
++[perl] = ok
+} # group accounting = ok
Sending Accounting-Response of id 2 to X.X.X.X port 59936
Finished request 1.
Cleaning up request 1 ID 2 with timestamp +3
Going to the next request
Waking up in 4.6 seconds.
rad_recv: Accounting-Request packet from host X.X.X.X port 59936, id=3, length=351
        User-Name = "mdv_reave"
        Acct-Status-Type = Interim-Update
        Acct-Session-Id = "jnpr xe-0/0/1.1073760704:18928"
        Acct-Input-Octets = 0
        Acct-Output-Octets = 0
        Acct-Session-Time = 1
        Acct-Input-Packets = 0
        Acct-Output-Packets = 0
        Service-Type = Framed-User
        Framed-Protocol = PPP
        ERX-Attr-177 = 0x506f72742053706565643a2031303030303030306b
        Acct-Authentic = RADIUS
        Acct-Delay-Time = 0
        ERX-Dhcp-Mac-Addr = "30b5.c2a9.3541"
        Event-Timestamp = "Oct 13 2015 13:38:20 GMT-3"
        Framed-IP-Address = Y.Y.Y.Y
        Framed-IP-Netmask = 255.255.255.255
        ERX-Input-Gigapkts = 0
        Acct-Input-Gigawords = 0
        NAS-Identifier = "mx_80"
        NAS-Port = 4195477
        NAS-Port-Id = "xe-0/0/1.1073760704:1173"
        NAS-Port-Type = Ethernet
        ERX-Output-Gigapkts = 0
        Acct-Output-Gigawords = 0
        ERX-IPv6-Acct-Input-Octets = 0
        ERX-IPv6-Acct-Output-Octets = 0
        ERX-IPv6-Acct-Input-Packets = 0
        ERX-IPv6-Acct-Output-Packets = 0
        ERX-IPv6-Acct-Input-Gigawords = 0
        ERX-IPv6-Acct-Output-Gigawords = 0
        NAS-IP-Address = X.X.X.X
# Executing section preacct from file /usr/local/etc/raddb/sites-enabled/abills_default
+group preacct {
++[preprocess] = ok
+} # group preacct = ok
# Executing section accounting from file /usr/local/etc/raddb/sites-enabled/abills_default
+group accounting {
rlm_perl: Added pair Acct-Output-Packets = 0
rlm_perl: Added pair ERX-Output-Gigapkts = 0
rlm_perl: Added pair ERX-Input-Gigapkts = 0
rlm_perl: Added pair Acct-Session-Time = 1
rlm_perl: Added pair Framed-IP-Address = Y.Y.Y.Y
rlm_perl: Added pair Acct-Output-Gigawords = 0
rlm_perl: Added pair ERX-IPv6-Acct-Input-Gigawords = 0
rlm_perl: Added pair NAS-Port = 4195477
rlm_perl: Added pair NAS-Port-Type = Ethernet
rlm_perl: Added pair Acct-Input-Packets = 0
rlm_perl: Added pair User-Name = mdv_reave
rlm_perl: Added pair ERX-IPv6-Acct-Output-Gigawords = 0
rlm_perl: Added pair NAS-Port-Id = xe-0/0/1.1073760704:1173
rlm_perl: Added pair ERX-IPv6-Acct-Output-Packets = 0
rlm_perl: Added pair Acct-Output-Octets = 0
rlm_perl: Added pair Acct-Authentic = RADIUS
rlm_perl: Added pair ERX-IPv6-Acct-Output-Octets = 0
rlm_perl: Added pair NAS-IP-Address = X.X.X.X
rlm_perl: Added pair Service-Type = Framed-User
rlm_perl: Added pair NAS-Identifier = mx_80
rlm_perl: Added pair ERX-Attr-177 = 0x506f72742053706565643a2031303030303030306b
rlm_perl: Added pair Acct-Session-Id = jnpr xe-0/0/1.1073760704
rlm_perl: Added pair Acct-Input-Gigawords = 0
rlm_perl: Added pair ERX-IPv6-Acct-Input-Packets = 0
rlm_perl: Added pair ERX-IPv6-Acct-Input-Octets = 0
rlm_perl: Added pair Acct-Status-Type = Interim-Update
rlm_perl: Added pair Acct-Delay-Time = 0
rlm_perl: Added pair Framed-Protocol = PPP
rlm_perl: Added pair Event-Timestamp = Oct 13 2015 13:38:20 GMT-3
rlm_perl: Added pair Acct-Input-Octets = 0
rlm_perl: Added pair ERX-Dhcp-Mac-Addr = 30b5.c2a9.3541
rlm_perl: Added pair Framed-IP-Netmask = 255.255.255.255
++[perl] = ok
+} # group accounting = ok
Sending Accounting-Response of id 3 to X.X.X.X port 59936
Finished request 2.
Cleaning up request 2 ID 3 with timestamp +3
Going to the next request
Waking up in 4.1 seconds.
rad_recv: Access-Request packet from host X.X.X.X port 59936, id=4, length=204
        User-Name = "reave-home"
        Service-Type = Framed-User
        Framed-Protocol = PPP
        CHAP-Password = 0x8e9c0b6974085271d7e73c235fb4279660
        CHAP-Challenge = 0xac83915ecd6fedbf5af9cc965813297fb4d8d335810a8c3260d085d6d9bb95
        Chargeable-User-Identity = ""
        Acct-Session-Id = "jnpr ge-1/0/0.1073760705:18930"
        ERX-Dhcp-Mac-Addr = "30b5.c2a9.364b"
        NAS-Identifier = "mx_80"
        NAS-Port = 268436629
        NAS-Port-Id = "ge-1/0/0.1073760705:1173"
        NAS-Port-Type = Ethernet
        NAS-IP-Address = X.X.X.X
# Executing section authorize from file /usr/local/etc/raddb/sites-enabled/abills_default
+group authorize {
++[preprocess] = ok
++[mschap] = noop
[files] users: Matched entry DEFAULT at line 38
++[files] = ok
rlm_perl: Added pair Chargeable-User-Identity =
rlm_perl: Added pair NAS-Port-Id = ge-1/0/0.1073760705:1173
rlm_perl: Added pair NAS-Identifier = mx_80
rlm_perl: Added pair CHAP-Challenge = 0xac83915ecd6fedbf5af9cc965813297fb4d8d335810a8c3260d085d6d9bb95
rlm_perl: Added pair CHAP-Password = 0x8e9c0b6974085271d7e73c235fb4279660
rlm_perl: Added pair Acct-Session-Id = jnpr ge-1/0/0.1073760705:18930
rlm_perl: Added pair NAS-Port-Type = Ethernet
rlm_perl: Added pair NAS-Port = 268436629
rlm_perl: Added pair Framed-Protocol = PPP
rlm_perl: Added pair User-Name = reave-home
rlm_perl: Added pair NAS-IP-Address = X.X.X.X
rlm_perl: Added pair ERX-Dhcp-Mac-Addr = 30b5.c2a9.364b
rlm_perl: Added pair Service-Type = Framed-User
rlm_perl: Added pair ERX-Service-Activate:3 = svc-global-pppoe(20480000,20480000)
rlm_perl: Added pair Framed-IP-Netmask = 255.255.255.255
rlm_perl: Added pair Framed-IP-Address = Z.Z.Z.Z
rlm_perl: Added pair Acct-Interim-Interval = 300
rlm_perl: Added pair Auth-Type = Accept
++[perl] = ok
+} # group authorize = ok
Found Auth-Type = Accept
Auth-Type = Accept, accepting the user
  WARNING: Empty post-auth section.  Using default return values.
# Executing section post-auth from file /usr/local/etc/raddb/sites-enabled/abills_default
Sending Access-Accept of id 4 to X.X.X.X port 59936
        ERX-Service-Activate:3 += "svc-global-pppoe(20480000,20480000)"
        Framed-IP-Netmask = 255.255.255.255
        Framed-IP-Address = Z.Z.Z.Z
        Acct-Interim-Interval = 300
Finished request 3.
Going to the next request
Waking up in 1.6 seconds.
rad_recv: Accounting-Request packet from host X.X.X.X port 59936, id=5, length=213
        User-Name = "reave-home"
        Acct-Status-Type = Start
        Acct-Session-Id = "jnpr ge-1/0/0.1073760705:18930"
        Service-Type = Framed-User
        Framed-Protocol = PPP
        ERX-Attr-177 = 0x506f72742053706565643a20313030303030306b
        Acct-Authentic = RADIUS
        Acct-Delay-Time = 0
        ERX-Dhcp-Mac-Addr = "30b5.c2a9.364b"
        Event-Timestamp = "Oct 13 2015 13:38:23 GMT-3"
        Framed-IP-Address = Z.Z.Z.Z
        Framed-IP-Netmask = 255.255.255.255
        NAS-Identifier = "mx_80"
        NAS-Port = 268436629
        NAS-Port-Id = "ge-1/0/0.1073760705:1173"
        NAS-Port-Type = Ethernet
        NAS-IP-Address = X.X.X.X
# Executing section preacct from file /usr/local/etc/raddb/sites-enabled/abills_default
+group preacct {
++[preprocess] = ok
+} # group preacct = ok
# Executing section accounting from file /usr/local/etc/raddb/sites-enabled/abills_default
+group accounting {
rlm_perl: Added pair Acct-Authentic = RADIUS
rlm_perl: Added pair Service-Type = Framed-User
rlm_perl: Added pair NAS-IP-Address = X.X.X.X
rlm_perl: Added pair NAS-Port-Id = ge-1/0/0.1073760705:1173
rlm_perl: Added pair Acct-Delay-Time = 0
rlm_perl: Added pair Acct-Status-Type = Start
rlm_perl: Added pair NAS-Port = 268436629
rlm_perl: Added pair NAS-Port-Type = Ethernet
rlm_perl: Added pair ERX-Dhcp-Mac-Addr = 30b5.c2a9.364b
rlm_perl: Added pair Framed-IP-Netmask = 255.255.255.255
rlm_perl: Added pair User-Name = reave-home
rlm_perl: Added pair Event-Timestamp = Oct 13 2015 13:38:23 GMT-3
rlm_perl: Added pair Framed-Protocol = PPP
rlm_perl: Added pair Acct-Session-Id = jnpr ge-1/0/0.1073760705
rlm_perl: Added pair NAS-Identifier = mx_80
rlm_perl: Added pair ERX-Attr-177 = 0x506f72742053706565643a20313030303030306b
rlm_perl: Added pair Framed-IP-Address = Z.Z.Z.Z
++[perl] = ok
+} # group accounting = ok
Sending Accounting-Response of id 5 to X.X.X.X port 59936
Finished request 4.
Cleaning up request 4 ID 5 with timestamp +6
Going to the next request
Waking up in 1.3 seconds.
rad_recv: Accounting-Request packet from host X.X.X.X port 59936, id=6, length=351
        User-Name = "reave-home"
        Acct-Status-Type = Interim-Update
        Acct-Session-Id = "jnpr ge-1/0/0.1073760705:18930"
        Acct-Input-Octets = 0
        Acct-Output-Octets = 0
        Acct-Session-Time = 1
        Acct-Input-Packets = 0
        Acct-Output-Packets = 0
        Service-Type = Framed-User
        Framed-Protocol = PPP
        ERX-Attr-177 = 0x506f72742053706565643a20313030303030306b
        Acct-Authentic = RADIUS
        Acct-Delay-Time = 0
        ERX-Dhcp-Mac-Addr = "30b5.c2a9.364b"
        Event-Timestamp = "Oct 13 2015 13:38:23 GMT-3"
        Framed-IP-Address = Z.Z.Z.Z
        Framed-IP-Netmask = 255.255.255.255
        ERX-Input-Gigapkts = 0
        Acct-Input-Gigawords = 0
        NAS-Identifier = "mx_80"
        NAS-Port = 268436629
        NAS-Port-Id = "ge-1/0/0.1073760705:1173"
        NAS-Port-Type = Ethernet
        ERX-Output-Gigapkts = 0
        Acct-Output-Gigawords = 0
        ERX-IPv6-Acct-Input-Octets = 0
        ERX-IPv6-Acct-Output-Octets = 0
        ERX-IPv6-Acct-Input-Packets = 0
        ERX-IPv6-Acct-Output-Packets = 0
        ERX-IPv6-Acct-Input-Gigawords = 0
        ERX-IPv6-Acct-Output-Gigawords = 0
        NAS-IP-Address = X.X.X.X
# Executing section preacct from file /usr/local/etc/raddb/sites-enabled/abills_default
+group preacct {
++[preprocess] = ok
+} # group preacct = ok
# Executing section accounting from file /usr/local/etc/raddb/sites-enabled/abills_default
+group accounting {
rlm_perl: Added pair ERX-Input-Gigapkts = 0
rlm_perl: Added pair ERX-Output-Gigapkts = 0
rlm_perl: Added pair Acct-Output-Packets = 0
rlm_perl: Added pair User-Name = reave-home
rlm_perl: Added pair ERX-IPv6-Acct-Output-Gigawords = 0
rlm_perl: Added pair Acct-Input-Packets = 0
rlm_perl: Added pair ERX-IPv6-Acct-Input-Gigawords = 0
rlm_perl: Added pair NAS-Port-Type = Ethernet
rlm_perl: Added pair NAS-Port = 268436629
rlm_perl: Added pair Framed-IP-Address = Z.Z.Z.Z
rlm_perl: Added pair Acct-Output-Gigawords = 0
rlm_perl: Added pair Acct-Session-Time = 1
rlm_perl: Added pair Service-Type = Framed-User
rlm_perl: Added pair NAS-IP-Address = X.X.X.X
rlm_perl: Added pair ERX-IPv6-Acct-Output-Octets = 0
rlm_perl: Added pair Acct-Authentic = RADIUS
rlm_perl: Added pair Acct-Output-Octets = 0
rlm_perl: Added pair ERX-IPv6-Acct-Output-Packets = 0
rlm_perl: Added pair NAS-Port-Id = ge-1/0/0.1073760705:1173
rlm_perl: Added pair ERX-Dhcp-Mac-Addr = 30b5.c2a9.364b
rlm_perl: Added pair Framed-IP-Netmask = 255.255.255.255
rlm_perl: Added pair Acct-Input-Octets = 0
rlm_perl: Added pair Event-Timestamp = Oct 13 2015 13:38:23 GMT-3
rlm_perl: Added pair Framed-Protocol = PPP
rlm_perl: Added pair Acct-Delay-Time = 0
rlm_perl: Added pair Acct-Status-Type = Interim-Update
rlm_perl: Added pair ERX-IPv6-Acct-Input-Octets = 0
rlm_perl: Added pair ERX-IPv6-Acct-Input-Packets = 0
rlm_perl: Added pair Acct-Input-Gigawords = 0
rlm_perl: Added pair Acct-Session-Id = jnpr ge-1/0/0.1073760705
rlm_perl: Added pair NAS-Identifier = mx_80
rlm_perl: Added pair ERX-Attr-177 = 0x506f72742053706565643a20313030303030306b
++[perl] = ok
+} # group accounting = ok
Sending Accounting-Response of id 6 to X.X.X.X port 59936
Finished request 5.
Cleaning up request 5 ID 6 with timestamp +7
Going to the next request
Waking up in 0.8 seconds.
Cleaning up request 0 ID 1 with timestamp +2
Waking up in 3.3 seconds.
Cleaning up request 3 ID 4 with timestamp +6
Ready to process requests.


user_abills
Сообщения: 47
Зарегистрирован: Чт фев 19, 2015 1:16 pm

Re: Radius pararmeters

Сообщение user_abills » Вт окт 13, 2015 10:57 am

Код: Выделить всё

rad_recv: Accounting-Request packet from host X.X.X.X port 59936, id=7, length=351
        User-Name = "reave-home"
        Acct-Status-Type = Interim-Update
        Acct-Session-Id = "jnpr ge-1/0/0.1073760705:18930"
        Acct-Input-Octets = 1868
        Acct-Output-Octets = 15040
        Acct-Session-Time = 577
        Acct-Input-Packets = 29
        Acct-Output-Packets = 30
        Service-Type = Framed-User
        Framed-Protocol = PPP
        ERX-Attr-177 = 0x506f72742053706565643a20313030303030306b
        Acct-Authentic = RADIUS
        Acct-Delay-Time = 0
        ERX-Dhcp-Mac-Addr = "30b5.c2a9.364b"
        Event-Timestamp = "Oct 13 2015 13:47:59 GMT-3"
        Framed-IP-Address = Z.Z.Z.Z
        Framed-IP-Netmask = 255.255.255.255
        ERX-Input-Gigapkts = 0
        Acct-Input-Gigawords = 0
        NAS-Identifier = "mx_80"
        NAS-Port = 268436629
        NAS-Port-Id = "ge-1/0/0.1073760705:1173"
        NAS-Port-Type = Ethernet
        ERX-Output-Gigapkts = 0
        Acct-Output-Gigawords = 0
        ERX-IPv6-Acct-Input-Octets = 0
        ERX-IPv6-Acct-Output-Octets = 0
        ERX-IPv6-Acct-Input-Packets = 0
        ERX-IPv6-Acct-Output-Packets = 0
        ERX-IPv6-Acct-Input-Gigawords = 0
        ERX-IPv6-Acct-Output-Gigawords = 0
        NAS-IP-Address = X.X.X.X
# Executing section preacct from file /usr/local/etc/raddb/sites-enabled/abills_default
+group preacct {
++[preprocess] = ok
+} # group preacct = ok
# Executing section accounting from file /usr/local/etc/raddb/sites-enabled/abills_default
+group accounting {
rlm_perl: Added pair Acct-Input-Gigawords = 0
rlm_perl: Added pair NAS-Identifier = mx_80
rlm_perl: Added pair ERX-Attr-177 = 0x506f72742053706565643a20313030303030306b
rlm_perl: Added pair Acct-Session-Id = jnpr ge-1/0/0.1073760705
rlm_perl: Added pair Acct-Input-Octets = 1868
rlm_perl: Added pair Event-Timestamp = Oct 13 2015 13:47:59 GMT-3
rlm_perl: Added pair Framed-Protocol = PPP
rlm_perl: Added pair Framed-IP-Netmask = 255.255.255.255
rlm_perl: Added pair ERX-Dhcp-Mac-Addr = 30b5.c2a9.364b
rlm_perl: Added pair ERX-IPv6-Acct-Input-Packets = 0
rlm_perl: Added pair Acct-Status-Type = Interim-Update
rlm_perl: Added pair Acct-Delay-Time = 0
rlm_perl: Added pair ERX-IPv6-Acct-Input-Octets = 0
rlm_perl: Added pair Acct-Output-Octets = 15040
rlm_perl: Added pair NAS-Port-Id = ge-1/0/0.1073760705:1173
rlm_perl: Added pair ERX-IPv6-Acct-Output-Packets = 0
rlm_perl: Added pair ERX-IPv6-Acct-Output-Octets = 0
rlm_perl: Added pair Service-Type = Framed-User
rlm_perl: Added pair NAS-IP-Address = X.X.X.X
rlm_perl: Added pair Acct-Authentic = RADIUS
rlm_perl: Added pair Acct-Output-Gigawords = 0
rlm_perl: Added pair Framed-IP-Address = Z.Z.Z.Z
rlm_perl: Added pair Acct-Session-Time = 577
rlm_perl: Added pair Acct-Input-Packets = 29
rlm_perl: Added pair User-Name = reave-home
rlm_perl: Added pair ERX-IPv6-Acct-Output-Gigawords = 0
rlm_perl: Added pair ERX-IPv6-Acct-Input-Gigawords = 0
rlm_perl: Added pair NAS-Port-Type = Ethernet
rlm_perl: Added pair NAS-Port = 268436629
rlm_perl: Added pair ERX-Output-Gigapkts = 0
rlm_perl: Added pair Acct-Output-Packets = 30
rlm_perl: Added pair ERX-Input-Gigapkts = 0
++[perl] = ok
+} # group accounting = ok
Sending Accounting-Response of id 7 to X.X.X.X port 59936
Finished request 6.
Cleaning up request 6 ID 7 with timestamp +582
Going to the next request
Ready to process requests.
rad_recv: Accounting-Request packet from host X.X.X.X port 59936, id=8, length=351
        User-Name = "mdv_reave"
        Acct-Status-Type = Interim-Update
        Acct-Session-Id = "jnpr xe-0/0/1.1073760704:18928"
        Acct-Input-Octets = 1292
        Acct-Output-Octets = 10379
        Acct-Session-Time = 580
        Acct-Input-Packets = 20
        Acct-Output-Packets = 24
        Service-Type = Framed-User
        Framed-Protocol = PPP
        ERX-Attr-177 = 0x506f72742053706565643a2031303030303030306b
        Acct-Authentic = RADIUS
        Acct-Delay-Time = 0
        ERX-Dhcp-Mac-Addr = "30b5.c2a9.3541"
        Event-Timestamp = "Oct 13 2015 13:47:59 GMT-3"
        Framed-IP-Address = Y.Y.Y.Y
        Framed-IP-Netmask = 255.255.255.255
        ERX-Input-Gigapkts = 0
        Acct-Input-Gigawords = 0
        NAS-Identifier = "mx_80"
        NAS-Port = 4195477
        NAS-Port-Id = "xe-0/0/1.1073760704:1173"
        NAS-Port-Type = Ethernet
        ERX-Output-Gigapkts = 0
        Acct-Output-Gigawords = 0
        ERX-IPv6-Acct-Input-Octets = 0
        ERX-IPv6-Acct-Output-Octets = 0
        ERX-IPv6-Acct-Input-Packets = 0
        ERX-IPv6-Acct-Output-Packets = 0
        ERX-IPv6-Acct-Input-Gigawords = 0
        ERX-IPv6-Acct-Output-Gigawords = 0
        NAS-IP-Address = X.X.X.X
# Executing section preacct from file /usr/local/etc/raddb/sites-enabled/abills_default
+group preacct {
++[preprocess] = ok
+} # group preacct = ok
# Executing section accounting from file /usr/local/etc/raddb/sites-enabled/abills_default
+group accounting {
rlm_perl: Added pair NAS-IP-Address = X.X.X.X
rlm_perl: Added pair Service-Type = Framed-User
rlm_perl: Added pair ERX-IPv6-Acct-Output-Octets = 0
rlm_perl: Added pair Acct-Authentic = RADIUS
rlm_perl: Added pair Acct-Output-Octets = 10379
rlm_perl: Added pair ERX-IPv6-Acct-Output-Packets = 0
rlm_perl: Added pair NAS-Port-Id = xe-0/0/1.1073760704:1173
rlm_perl: Added pair ERX-Dhcp-Mac-Addr = 30b5.c2a9.3541
rlm_perl: Added pair Framed-IP-Netmask = 255.255.255.255
rlm_perl: Added pair Event-Timestamp = Oct 13 2015 13:47:59 GMT-3
rlm_perl: Added pair Framed-Protocol = PPP
rlm_perl: Added pair Acct-Input-Octets = 1292
rlm_perl: Added pair ERX-IPv6-Acct-Input-Octets = 0
rlm_perl: Added pair Acct-Delay-Time = 0
rlm_perl: Added pair Acct-Status-Type = Interim-Update
rlm_perl: Added pair ERX-IPv6-Acct-Input-Packets = 0
rlm_perl: Added pair Acct-Input-Gigawords = 0
rlm_perl: Added pair Acct-Session-Id = jnpr xe-0/0/1.1073760704
rlm_perl: Added pair ERX-Attr-177 = 0x506f72742053706565643a2031303030303030306b
rlm_perl: Added pair NAS-Identifier = mx_80
rlm_perl: Added pair ERX-Input-Gigapkts = 0
rlm_perl: Added pair Acct-Output-Packets = 24
rlm_perl: Added pair ERX-Output-Gigapkts = 0
rlm_perl: Added pair ERX-IPv6-Acct-Output-Gigawords = 0
rlm_perl: Added pair User-Name = mdv_reave
rlm_perl: Added pair Acct-Input-Packets = 20
rlm_perl: Added pair ERX-IPv6-Acct-Input-Gigawords = 0
rlm_perl: Added pair NAS-Port-Type = Ethernet
rlm_perl: Added pair NAS-Port = 4195477
rlm_perl: Added pair Framed-IP-Address = Y.Y.Y.Y
rlm_perl: Added pair Acct-Output-Gigawords = 0
rlm_perl: Added pair Acct-Session-Time = 580
++[perl] = ok
+} # group accounting = ok
Sending Accounting-Response of id 8 to X.X.X.X port 59936
Finished request 7.
Cleaning up request 7 ID 8 with timestamp +583
Going to the next request
Ready to process requests.


user_abills
Сообщения: 47
Зарегистрирован: Чт фев 19, 2015 1:16 pm

Re: Radius pararmeters

Сообщение user_abills » Вт окт 13, 2015 12:17 pm

еще заметил такую ошибку в файле /tmp/sql_errors

Код: Выделить всё

2015-10-13 15:14:37 LOG_ERR:  [] index:
select aa.id, u.id AS login, aa.datetime, aa.actions, a.id as admin_login,
      INET_NTOA(aa.ip) AS ip, aa.module,
      aa.action_type,
      aa.uid,

      aa.aid
   FROM admin_actions aa
      LEFT JOIN admins a ON (aa.aid=a.aid)
      LEFT JOIN users u ON (aa.uid=u.uid)

   WHERE aa.uid='16' and aa.action_type IN ('4', '8', '9', '14') and u.uid='16' ORDER BY 1 desc LIMIT 0, 1;
 --1054
 --Unknown column 'aa.action_type' in 'field list'
 --AutoCommit: 1

~AsmodeuS~
Site Admin
Сообщения: 5604
Зарегистрирован: Пт янв 28, 2005 3:11 pm
Контактная информация:

Re: Radius pararmeters

Сообщение ~AsmodeuS~ » Вт окт 13, 2015 12:49 pm

user_abills писал(а):еще заметил такую ошибку в файле /tmp/sql_errors

Код: Выделить всё

2015-10-13 15:14:37 LOG_ERR:  [] index:
select aa.id, u.id AS login, aa.datetime, aa.actions, a.id as admin_login,
      INET_NTOA(aa.ip) AS ip, aa.module,
      aa.action_type,
      aa.uid,

      aa.aid
   FROM admin_actions aa
      LEFT JOIN admins a ON (aa.aid=a.aid)
      LEFT JOIN users u ON (aa.uid=u.uid)

   WHERE aa.uid='16' and aa.action_type IN ('4', '8', '9', '14') and u.uid='16' ORDER BY 1 desc LIMIT 0, 1;
 --1054
 --Unknown column 'aa.action_type' in 'field list'
 --AutoCommit: 1

плохо вводили данные с ченжлога

ALTER TABLE admin_actions add COLUMN action_type TINYINT(2) NOT NULL DEFAULT '0';



http://abills.net.ua/wiki/doku.php/abil ... n&s[]=type

user_abills
Сообщения: 47
Зарегистрирован: Чт фев 19, 2015 1:16 pm

Re: Radius pararmeters

Сообщение user_abills » Вт окт 13, 2015 3:23 pm

С базой понял, спасибо, а что делать с остальным, ума не приложу(

user_abills
Сообщения: 47
Зарегистрирован: Чт фев 19, 2015 1:16 pm

Re: Radius pararmeters

Сообщение user_abills » Ср окт 14, 2015 1:41 pm

Похоже разобрался в проблеме, это моя секция конфига:

Код: Выделить всё

#show access profile clients
accounting-order radius;
authentication-order radius;
radius {
    authentication-server X.X.X.X;
    accounting-server X.X.X.X;
    options {
        nas-identifier mx_40;
        [code]accounting-session-id-format
description;
}
}
accounting {
order radius;
immediate-update;
coa-immediate-update;
update-interval 10;
statistics volume-time;
}
[/code]
так вот проблема была в настройке параметра

Код: Выделить всё

accounting-session-id-format
тоесть в базу в поле

Код: Выделить всё

acct_session_id
попадало значение вида

Код: Выделить всё

jnpr ge-1/0/0.1073760808
а для нормальной работы требуется, как я понял, значение вида После удаления этой настройки всё начало работать.
Жаль что у вас в вики это не оговорено,много времени ушло на то, чтоб понять в чём проблема.
Только один ньюанс остался для выяснения: при установлении сессии никаких ошибок, статистика пишется, но выполняя команду

Код: Выделить всё

# /usr/abills/libexec/billd mx80_checklines SHOW
получаю

Код: Выделить всё

# /usr/abills/libexec/billd mx80_checklines SHOW
Not found mdv_reave IP: Y.Y.Y.Y
Not found reave-home IP: Z.Z.Z.Z
где и ip подключившихся клиентов. Если я правильно понимаю то при валидных подключениях никаких записей быть не должно?
И еще хотел спросить вас, нигде не нашел описания значений поля status в таблице dv_calls, при валидном подключении появляются зписи со значением 3, при проблемных 1, 2, 9. Интересно было бы узнать что они значат.

Ответить