Prosíme přihlašte se nebo zaregistrujte.

Přihlašte se svým uživatelským jménem a heslem.
Vaše pomoc je stále potřeba!

Autor Téma: Problem s freeradiusom  (Přečteno 6560 krát)

zvukarmiso

  • Návštěvník
  • Příspěvků: 79
Problem s freeradiusom
« kdy: 12 Března 2014, 20:36:29 »
Ahojte

Trapim sa s rozbehanim freeradius.

Ale vznikol mi nasledovny problem

Kód: [Vybrat]
     Module: Checking accounting {...} for more modules to load
     Module: Checking session {...} for more modules to load
     Module: Checking post-auth {...} for more modules to load
     } # modules
    } # server
    radiusd: #### Opening IP addresses and Ports ####
            bind_address = *
    WARNING: The directive 'bind_address' is deprecated, and will be removed in future versions of FreeRADIUS. Please edit the configuration files to use the directive 'listen'.
    listen {
            type = "acct"
            ipaddr = 127.0.0.1
            port = 0
    Failed binding to accounting address 127.0.0.1 port 1813: Address already in use
    /etc/freeradius/radiusd.conf[62]: Error binding to port for 127.0.0.1 port 1813

takto nejak vyzera moja konfiguracia:
vid priloha:

Debug mi vyhodi nasledovnu chybu.

Kód: [Vybrat]
    root@radius:~# freeradius -XXX | tee testlog.txt
    Mon Mar 10 22:41:19 2014 : Info: FreeRADIUS Version 2.1.12, for host i486-pc-linux-gnu, built on Dec 16 2012 at 22:03:33
    Mon Mar 10 22:41:19 2014 : Info: Copyright (C) 1999-2009 The FreeRADIUS server project and contributors.
    Mon Mar 10 22:41:19 2014 : Info: There is NO warranty; not even for MERCHANTABILITY or FITNESS FOR A
    Mon Mar 10 22:41:19 2014 : Info: PARTICULAR PURPOSE.
    Mon Mar 10 22:41:19 2014 : Info: You may redistribute copies of FreeRADIUS under the terms of the
    Mon Mar 10 22:41:19 2014 : Info: GNU General Public License v2.
    Mon Mar 10 22:41:19 2014 : Info: Starting - reading configuration files ...
    Mon Mar 10 22:41:19 2014 : Debug: including configuration file /etc/freeradius/radiusd.conf
    Mon Mar 10 22:41:19 2014 : Debug: including configuration file /etc/freeradius/clients.conf
    Mon Mar 10 22:41:19 2014 : Debug: including configuration file /etc/freeradius/sql.conf
    Mon Mar 10 22:41:19 2014 : Debug: including configuration file /etc/freeradius/sql/mysql/dialup.conf
    Mon Mar 10 22:41:19 2014 : Debug: main {
    Mon Mar 10 22:41:19 2014 : Debug:       user = "freerad"
    Mon Mar 10 22:41:19 2014 : Debug:       group = "freerad"
    Mon Mar 10 22:41:19 2014 : Debug:       allow_core_dumps = no
    Mon Mar 10 22:41:19 2014 : Debug: }
    Mon Mar 10 22:41:19 2014 : Debug: including dictionary file /etc/freeradius/dictionary
    Mon Mar 10 22:41:19 2014 : Debug: main {
    Mon Mar 10 22:41:19 2014 : Debug:       name = "radiusd"
    Mon Mar 10 22:41:19 2014 : Debug:       prefix = "/usr"
    Mon Mar 10 22:41:19 2014 : Debug:       localstatedir = "/var"
    Mon Mar 10 22:41:19 2014 : Debug:       sbindir = "/usr/sbin"
    Mon Mar 10 22:41:19 2014 : Debug:       logdir = "/var/log/freeradius"
    Mon Mar 10 22:41:19 2014 : Debug:       run_dir = "/var/run/freeradius"
    Mon Mar 10 22:41:19 2014 : Debug:       libdir = "/usr/lib/freeradius"
    Mon Mar 10 22:41:19 2014 : Debug:       radacctdir = "/var/log/freeradius/radacct"
    Mon Mar 10 22:41:19 2014 : Debug:       hostname_lookups = no
    Mon Mar 10 22:41:19 2014 : Debug:       max_request_time = 30
    Mon Mar 10 22:41:19 2014 : Debug:       cleanup_delay = 5
    Mon Mar 10 22:41:19 2014 : Debug:       max_requests = 1024
    Mon Mar 10 22:41:19 2014 : Debug:       pidfile = "/var/run/freeradius/freeradius.pid"
    Mon Mar 10 22:41:19 2014 : Debug:       checkrad = "/usr/sbin/checkrad"
    Mon Mar 10 22:41:19 2014 : Debug:       debug_level = 0
    Mon Mar 10 22:41:19 2014 : Debug:       proxy_requests = no
    Mon Mar 10 22:41:19 2014 : Debug:       log_auth = no
    Mon Mar 10 22:41:19 2014 : Debug:       log_auth_badpass = no
    Mon Mar 10 22:41:19 2014 : Debug:       log_auth_goodpass = no
    Mon Mar 10 22:41:19 2014 : Debug:       log_stripped_names = no
    Mon Mar 10 22:41:19 2014 : Debug:  security {
    Mon Mar 10 22:41:19 2014 : Debug:       max_attributes = 200
    Mon Mar 10 22:41:19 2014 : Debug:       reject_delay = 1
    Mon Mar 10 22:41:19 2014 : Debug:       status_server = no
    Mon Mar 10 22:41:19 2014 : Debug:  }
    Mon Mar 10 22:41:19 2014 : Debug: }
    Mon Mar 10 22:41:19 2014 : Debug: radiusd: #### Loading Realms and Home Servers ####
    Mon Mar 10 22:41:19 2014 : Debug: radiusd: #### Loading Clients ####
    Mon Mar 10 22:41:19 2014 : Debug:  client 127.0.0.1 {
    Mon Mar 10 22:41:19 2014 : Debug:       require_message_authenticator = no
    Mon Mar 10 22:41:19 2014 : Debug:       secret = "somepassword"
    Mon Mar 10 22:41:19 2014 : Debug:       shortname = "localhost"
    Mon Mar 10 22:41:19 2014 : Debug:       nastype = "other"
    Mon Mar 10 22:41:19 2014 : Debug:  }
    Mon Mar 10 22:41:19 2014 : Debug: radiusd: #### Instantiating modules ####
    Mon Mar 10 22:41:19 2014 : Debug:  instantiate {
    Mon Mar 10 22:41:19 2014 : Debug:  }
    Mon Mar 10 22:41:19 2014 : Debug: radiusd: #### Loading Virtual Servers ####
    Mon Mar 10 22:41:19 2014 : Debug: server { # from file /etc/freeradius/radiusd.conf
    Mon Mar 10 22:41:19 2014 : Debug:  modules {
    Mon Mar 10 22:41:19 2014 : Debug:  Module: Checking authenticate {...} for more modules to load
    Mon Mar 10 22:41:19 2014 : Debug:     (Loaded rlm_pap, checking if it's valid)
    Mon Mar 10 22:41:19 2014 : Debug:  Module: Linked to module rlm_pap
    Mon Mar 10 22:41:19 2014 : Debug:  Module: Instantiating module "pap" from file /etc/freeradius/radiusd.conf
    Mon Mar 10 22:41:19 2014 : Debug:   pap {
    Mon Mar 10 22:41:19 2014 : Debug:       encryption_scheme = "crypt"
    Mon Mar 10 22:41:19 2014 : Debug:       auto_header = no
    Mon Mar 10 22:41:19 2014 : Debug:   }
    Mon Mar 10 22:41:19 2014 : Debug:     (Loaded rlm_chap, checking if it's valid)
    Mon Mar 10 22:41:19 2014 : Debug:  Module: Linked to module rlm_chap
    Mon Mar 10 22:41:19 2014 : Debug:  Module: Instantiating module "chap" from file /etc/freeradius/radiusd.conf
    Mon Mar 10 22:41:19 2014 : Debug:     (Loaded rlm_mschap, checking if it's valid)
    Mon Mar 10 22:41:19 2014 : Debug:  Module: Linked to module rlm_mschap
    Mon Mar 10 22:41:19 2014 : Debug:  Module: Instantiating module "mschap" from file /etc/freeradius/radiusd.conf
    Mon Mar 10 22:41:19 2014 : Debug:   mschap {
    Mon Mar 10 22:41:19 2014 : Debug:       use_mppe = no
    Mon Mar 10 22:41:19 2014 : Debug:       require_encryption = no
    Mon Mar 10 22:41:19 2014 : Debug:       require_strong = no
    Mon Mar 10 22:41:19 2014 : Debug:       with_ntdomain_hack = no
    Mon Mar 10 22:41:19 2014 : Debug:       allow_retry = yes
    Mon Mar 10 22:41:19 2014 : Debug:   }
    Mon Mar 10 22:41:19 2014 : Debug:  Module: Checking authorize {...} for more modules to load
    Mon Mar 10 22:41:19 2014 : Debug:     (Loaded rlm_sql, checking if it's valid)
    Mon Mar 10 22:41:19 2014 : Debug:  Module: Linked to module rlm_sql
    Mon Mar 10 22:41:19 2014 : Debug:  Module: Instantiating module "sql" from file /etc/freeradius/sql.conf
    Mon Mar 10 22:41:19 2014 : Debug:   sql {
    Mon Mar 10 22:41:19 2014 : Debug:       driver = "rlm_sql_mysql"
    Mon Mar 10 22:41:19 2014 : Debug:       server = "localhost"
    Mon Mar 10 22:41:19 2014 : Debug:       port = "3306"
    Mon Mar 10 22:41:19 2014 : Debug:       login = "radius"
    Mon Mar 10 22:41:19 2014 : Debug:       password = "radius@xxx"
    Mon Mar 10 22:41:19 2014 : Debug:       radius_db = "radius"
    Mon Mar 10 22:41:19 2014 : Debug:       read_groups = yes
    Mon Mar 10 22:41:19 2014 : Debug:       sqltrace = no
    Mon Mar 10 22:41:19 2014 : Debug:       sqltracefile = "/var/log/freeradius/sqltrace.sql"
    Mon Mar 10 22:41:19 2014 : Debug:       readclients = no
    Mon Mar 10 22:41:19 2014 : Debug:       deletestalesessions = yes
    Mon Mar 10 22:41:19 2014 : Debug:       num_sql_socks = 5
    Mon Mar 10 22:41:19 2014 : Debug:       lifetime = 0
    Mon Mar 10 22:41:19 2014 : Debug:       max_queries = 0
    Mon Mar 10 22:41:19 2014 : Debug:       sql_user_name = "%{User-Name}"
    Mon Mar 10 22:41:19 2014 : Debug:       default_user_profile = ""
    Mon Mar 10 22:41:19 2014 : Debug:       nas_query = "SELECT id, nasname, shortname, type, secret, server FROM nas"
    Mon Mar 10 22:41:19 2014 : Debug:       authorize_check_query = "SELECT id, username, attribute, value, op           FROM radcheck           WHERE username = '%{SQL-User-Name}'           ORDER BY id"
    Mon Mar 10 22:41:19 2014 : Debug:       authorize_reply_query = "SELECT id, username, attribute, value, op           FROM radreply           WHERE username = '%{SQL-User-Name}'           ORDER BY id"
    Mon Mar 10 22:41:19 2014 : Debug:       authorize_group_check_query = "SELECT id, groupname, attribute,           Value, op           FROM radgroupcheck           WHERE groupname = '%{Sql-Group}'           ORDER BY id"
    Mon Mar 10 22:41:19 2014 : Debug:       authorize_group_reply_query = "SELECT id, groupname, attribute,           value, op           FROM radgroupreply           WHERE groupname = '%{Sql-Group}'           ORDER BY id"
    Mon Mar 10 22:41:19 2014 : Debug:       accounting_onoff_query = "          UPDATE radacct           SET              acctstoptime       =  '%S',              acctsessiontime    =  unix_timestamp('%S') -                                    unix_timestamp(acctstarttime),              acctterminatecause =  '%{Acct-Terminate-Cause}',              acctstopdelay      =  %{%{Acct-Delay-Time}:-0}           WHERE acctstoptime IS NULL           AND nasipaddress      =  '%{NAS-IP-Address}'           AND acctstarttime     <= '%S'"
    Mon Mar 10 22:41:19 2014 : Debug:       accounting_update_query = "           UPDATE radacct           SET              framedipaddress = '%{Framed-IP-Address}',              acctsessiontime     = '%{Acct-Session-Time}',              acctinputoctets     = '%{%{Acct-Input-Gigawords}:-0}'  << 32 |                                    '%{%{Acct-Input-Octets}:-0}',              acctoutputoctets    = '%{%{Acct-Output-Gigawords}:-0}' << 32 |                                    '%{%{Acct-Output-Octets}:-0}'           WHERE acctsessionid = '%{Acct-Session-Id}'           AND username        = '%{SQL-User-Name}'           AND nasipaddress    = '%{NAS-IP-Address}'"
    Mon Mar 10 22:41:19 2014 : Debug:       accounting_update_query_alt = "           INSERT INTO radacct             (acctsessionid,    acctuniqueid,      username,              realm,            nasipaddress,      nasportid,              nasporttype,      acctstarttime,     acctsessiontime,              acctauthentic,    connectinfo_start, acctinputoctets,              acctoutputoctets, calledstationid,   callingstationid,              servicetype,      framedprotocol,    framedipaddress,              acctstartdelay,   xascendsessionsvrkey)           VALUES             ('%{Acct-Session-Id}', '%{Acct-Unique-Session-Id}',              '%{SQL-User-Name}',              '%{Realm}', '%{NAS-IP-Address}', '%{NAS-Port}',              '%{NAS-Port-Type}',              DATE_SUB('%S',                       INTERVAL (%{%{Acct-Session-Time}:-0} +                                 %{%{Acct-Delay-Time}:-0}) SECOND),                       '%{Acct-Session-Time}',              '%{Acct-Authentic}', '',              '%{%{Acct-Input-Gigawords}:-0}' << 32 |              '%{%{Acct-Input-Octets}:-0}',              '%{%{Acct-Output-Gigawords}:-0}' << 32 |              '%{%{Acct-Output-Octets}:-0}',              '%{Called-Station-Id}', '%{Calling-Station-Id}',              '%{Service-Type}', '%{Framed-Protocol}',              '%{Framed-IP-Address}',              '0', '%{X-Ascend-Session-Svr-Key}')"
    Mon Mar 10 22:41:19 2014 : Debug:       accounting_start_query = "           INSERT INTO radacct             (acctsessionid,    acctuniqueid,     username,              realm,            nasipaddress,     nasportid,              nasporttype,      acctstarttime,    acctstoptime,              acctsessiontime,  acctauthentic,    connectinfo_start,              connectinfo_stop, acctinputoctets,  acctoutputoctets,              calledstationid,  callingstationid, acctterminatecause,              servicetype,      framedprotocol,   framedipaddress,              acctstartdelay,   acctstopdelay,    xascendsessionsvrkey)           VALUES             ('%{Acct-Session-Id}', '%{Acct-Unique-Session-Id}',              '%{SQL-User-Name}',              '%{Realm}', '%{NAS-IP-Address}', '%{NAS-Port}',              '%{NAS-Port-Type}', '%S', NULL,              '0', '%{Acct-Authentic}', '%{Connect-Info}',              '', '0', '0',              '%{Called-Station-Id}', '%{Calling-Station-Id}', '',              '%{Service-Type}', '%{Framed-Protocol}', '%{Framed-IP-Address}',              '%{%{Acct-Delay-Time}:-0}', '0', '%{X-Ascend-Session-Svr-Key}')"
    Mon Mar 10 22:41:19 2014 : Debug:       accounting_start_query_alt = "           UPDATE radacct SET              acctstarttime     = '%S',              acctstartdelay    = '%{%{Acct-Delay-Time}:-0}',              connectinfo_start = '%{Connect-Info}'           WHERE acctsessionid  = '%{Acct-Session-Id}'           AND username         = '%{SQL-User-Name}'           AND nasipaddress     = '%{NAS-IP-Address}'"
    Mon Mar 10 22:41:19 2014 : Debug:       accounting_stop_query = "           UPDATE radacct SET              acctstoptime       = '%S',              acctsessiontime    = '%{Acct-Session-Time}',              acctinputoctets    = '%{%{Acct-Input-Gigawords}:-0}' << 32 |                                   '%{%{Acct-Input-Octets}:-0}',              acctoutputoctets   = '%{%{Acct-Output-Gigawords}:-0}' << 32 |                                   '%{%{Acct-Output-Octets}:-0}',              acctterminatecause = '%{Acct-Terminate-Cause}',              acctstopdelay      = '%{%{Acct-Delay-Time}:-0}',              connectinfo_stop   = '%{Connect-Info}'           WHERE acctsessionid   = '%{Acct-Session-Id}'           AND username          = '%{SQL-User-Name}'           AND nasipaddress      = '%{NAS-IP-Address}'"
    Mon Mar 10 22:41:19 2014 : Debug:       accounting_stop_query_alt = "           INSERT INTO radacct             (acctsessionid, acctuniqueid, username,              realm, nasipaddress, nasportid,              nasporttype, acctstarttime, acctstoptime,              acctsessiontime, acctauthentic, connectinfo_start,              connectinfo_stop, acctinputoctets, acctoutputoctets,              calledstationid, callingstationid, acctterminatecause,              servicetype, framedprotocol, framedipaddress,              acctstartdelay, acctstopdelay)           VALUES             ('%{Acct-Session-Id}', '%{Acct-Unique-Session-Id}',              '%{SQL-User-Name}',              '%{Realm}', '%{NAS-IP-Address}', '%{NAS-Port}',              '%{NAS-Port-Type}',              DATE_SUB('%S',                  INTERVAL (%{%{Acct-Session-Time}:-0} +                  %{%{Acct-Delay-Time}:-0}) SECOND),              '%S', '%{Acct-Session-Time}', '%{Acct-Authentic}', '',              '%{Connect-Info}',              '%{%{Acct-Input-Gigawords}:-0}' << 32 |              '%{%{Acct-Input-Octets}:-0}',              '%{%{Acct-Output-Gigawords}:-0}' << 32 |              '%{%{Acct-Output-Octets}:-0}',              '%{Called-Station-Id}', '%{Calling-Station-Id}',              '%{Acct-Terminate-Cause}',              '%{Service-Type}', '%{Framed-Protocol}', '%{Framed-IP-Address}',              '0', '%{%{Acct-Delay-Time}:-0}')"
    Mon Mar 10 22:41:19 2014 : Debug:       group_membership_query = "SELECT groupname           FROM usergroup           WHERE username = '%{SQL-User-Name}'           ORDER BY priority"
    Mon Mar 10 22:41:19 2014 : Debug:       connect_failure_retry_delay = 60
    Mon Mar 10 22:41:19 2014 : Debug:       simul_count_query = ""
    Mon Mar 10 22:41:19 2014 : Debug:       simul_verify_query = "SELECT radacctid, acctsessionid, username,                                nasipaddress, nasportid, framedipaddress,                                callingstationid, framedprotocol                                FROM radacct                                WHERE username = '%{SQL-User-Name}'                                AND acctstoptime IS NULL"
    Mon Mar 10 22:41:19 2014 : Debug:       postauth_query = "INSERT INTO radpostauth                           (username, pass, reply, authdate)                           VALUES (                           '%{User-Name}',                           '%{%{User-Password}:-%{Chap-Password}}',                           '%{reply:Packet-Type}', '%S')"
    Mon Mar 10 22:41:19 2014 : Debug:       safe-characters = "@abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789.-_: /"
    Mon Mar 10 22:41:19 2014 : Debug:   }
    Mon Mar 10 22:41:19 2014 : Info: rlm_sql (sql): Driver rlm_sql_mysql (module rlm_sql_mysql) loaded and linked
    Mon Mar 10 22:41:19 2014 : Info: rlm_sql (sql): Attempting to connect to radius@localhost:3306/radius
    Mon Mar 10 22:41:19 2014 : Debug: rlm_sql (sql): starting 0
    Mon Mar 10 22:41:19 2014 : Info: rlm_sql (sql): Attempting to connect rlm_sql_mysql #0
    Mon Mar 10 22:41:19 2014 : Info: rlm_sql_mysql: Starting connect to MySQL server for #0
    Mon Mar 10 22:41:19 2014 : Info: rlm_sql (sql): Connected new DB handle, #0
    Mon Mar 10 22:41:19 2014 : Debug: rlm_sql (sql): starting 1
    Mon Mar 10 22:41:19 2014 : Info: rlm_sql (sql): Attempting to connect rlm_sql_mysql #1
    Mon Mar 10 22:41:19 2014 : Info: rlm_sql_mysql: Starting connect to MySQL server for #1
    Mon Mar 10 22:41:19 2014 : Info: rlm_sql (sql): Connected new DB handle, #1
    Mon Mar 10 22:41:19 2014 : Debug: rlm_sql (sql): starting 2
    Mon Mar 10 22:41:19 2014 : Info: rlm_sql (sql): Attempting to connect rlm_sql_mysql #2
    Mon Mar 10 22:41:19 2014 : Info: rlm_sql_mysql: Starting connect to MySQL server for #2
    Mon Mar 10 22:41:19 2014 : Info: rlm_sql (sql): Connected new DB handle, #2
    Mon Mar 10 22:41:19 2014 : Debug: rlm_sql (sql): starting 3
    Mon Mar 10 22:41:19 2014 : Info: rlm_sql (sql): Attempting to connect rlm_sql_mysql #3
    Mon Mar 10 22:41:19 2014 : Info: rlm_sql_mysql: Starting connect to MySQL server for #3
    Mon Mar 10 22:41:19 2014 : Info: rlm_sql (sql): Connected new DB handle, #3
    Mon Mar 10 22:41:19 2014 : Debug: rlm_sql (sql): starting 4
    Mon Mar 10 22:41:19 2014 : Info: rlm_sql (sql): Attempting to connect rlm_sql_mysql #4
    Mon Mar 10 22:41:19 2014 : Info: rlm_sql_mysql: Starting connect to MySQL server for #4
    Mon Mar 10 22:41:19 2014 : Info: rlm_sql (sql): Connected new DB handle, #4
    Mon Mar 10 22:41:19 2014 : Debug:  Module: Checking preacct {...} for more modules to load
    Mon Mar 10 22:41:19 2014 : Debug:     (Loaded rlm_acct_unique, checking if it's valid)
    Mon Mar 10 22:41:19 2014 : Debug:  Module: Linked to module rlm_acct_unique
    Mon Mar 10 22:41:19 2014 : Debug:  Module: Instantiating module "acct_unique" from file /etc/freeradius/radiusd.conf
    Mon Mar 10 22:41:19 2014 : Debug:   acct_unique {
    Mon Mar 10 22:41:19 2014 : Debug:       key = "User-Name, Acct-Session-Id, NAS-IP-Address, Client-IP-Address, NAS-Port"
    Mon Mar 10 22:41:19 2014 : Debug:   }
    Mon Mar 10 22:41:19 2014 : Debug:  Module: Checking accounting {...} for more modules to load
    Mon Mar 10 22:41:19 2014 : Debug:  Module: Checking session {...} for more modules to load
    Mon Mar 10 22:41:19 2014 : Debug:  Module: Checking post-auth {...} for more modules to load
    Mon Mar 10 22:41:19 2014 : Debug:  } # modules
    Mon Mar 10 22:41:19 2014 : Debug: } # server
    Mon Mar 10 22:41:19 2014 : Debug: radiusd: #### Opening IP addresses and Ports ####
    Mon Mar 10 22:41:19 2014 : Debug:       bind_address = *
    Mon Mar 10 22:41:19 2014 : Info: WARNING: The directive 'bind_address' is deprecated, and will be removed in future versions of FreeRADIUS. Please edit the configuration files to use the directive 'listen'.
    Mon Mar 10 22:41:19 2014 : Debug: listen {
    Mon Mar 10 22:41:19 2014 : Debug:       type = "acct"
    Mon Mar 10 22:41:19 2014 : Debug:       ipaddr = 127.0.0.1
    Mon Mar 10 22:41:19 2014 : Debug:       port = 0
    Mon Mar 10 22:41:19 2014 : Error: Failed binding to accounting address 127.0.0.1 port 1813: Address already in use
    Mon Mar 10 22:41:19 2014 : Error: /etc/freeradius/radiusd.conf[62]: Error binding to port for 127.0.0.1 port 1813

zmenil som parametre ze som bind a port v configu vyhodil a nahradil
namiesto
bind_address = *
port = 0

som dal
listen {
type = auth
ipaddr = *
port = 0
}

Ale ostala mi nasledovna hlaska

Kód: [Vybrat]
    Tue Mar 11 23:39:33 2014 : Debug: radiusd: #### Opening IP addresses and Ports ####
    Tue Mar 11 23:39:33 2014 : Debug: listen {
    Tue Mar 11 23:39:33 2014 : Debug:       type = "auth"
    Tue Mar 11 23:39:33 2014 : Debug:       ipaddr = *
    Tue Mar 11 23:39:33 2014 : Debug:       port = 0
    Tue Mar 11 23:39:33 2014 : Error: Failed binding to authentication address * port 1812: Address already in use
    Tue Mar 11 23:39:33 2014 : Error: /etc/freeradius/radiusd.conf[34]: Error binding to port for 0.0.0.0 port 1812

configy prikladam http://leteckaposta.cz/565237043

Ak viete kde robim chybu budem vam velmi vdacny
Dakujem

Petr Merlin Vaněček

  • Moderátor
  • Závislák
  • ***
  • Příspěvků: 5057
    • Lomítkáři
Re:Problem s freeradiusom
« Odpověď #1 kdy: 12 Března 2014, 20:38:31 »
Sice jsem asi radius nikdy nedělal, ale hláška
Kód: [Vybrat]
Error: Failed binding to authentication address * port 1812: Address already in use
je poměrně jednoznačná - ten port už je obsazený.
Neběží tam zapomenutá instalance radiusu z předchozích pokusů?
Stiskni CTRL + W ...
80% mozku tvoří kapalina ... u některých brzdová

zvukarmiso

  • Návštěvník
  • Příspěvků: 79
Re:Problem s freeradiusom
« Odpověď #2 kdy: 12 Března 2014, 20:44:24 »
ako to zistim ? lebo podla etc/service tam nic nevidim


Petr Merlin Vaněček

  • Moderátor
  • Závislák
  • ***
  • Příspěvků: 5057
    • Lomítkáři
Re:Problem s freeradiusom
« Odpověď #3 kdy: 12 Března 2014, 20:45:17 »
Zkus
Kód: [Vybrat]
ps -wax | grep radius
Stiskni CTRL + W ...
80% mozku tvoří kapalina ... u některých brzdová

zvukarmiso

  • Návštěvník
  • Příspěvků: 79
Re:Problem s freeradiusom
« Odpověď #4 kdy: 12 Března 2014, 20:50:39 »
toto mi to vypise

Kód: [Vybrat]
root@radius:~# ps -wax | grep radius
warning: bad ps syntax, perhaps a bogus '-'?
See http://gitorious.org/procps/procps/blobs/master/Documentation/FAQ
13247 ?        Ssl    0:00 /usr/sbin/freeradius
15280 pts/0    S+     0:00 grep radius

Petr Merlin Vaněček

  • Moderátor
  • Závislák
  • ***
  • Příspěvků: 5057
    • Lomítkáři
Re:Problem s freeradiusom
« Odpověď #5 kdy: 12 Března 2014, 21:04:37 »
No vida ho :)
Kód: [Vybrat]
kill 13247
Stiskni CTRL + W ...
80% mozku tvoří kapalina ... u některých brzdová

zvukarmiso

  • Návštěvník
  • Příspěvků: 79
Re:Problem s freeradiusom
« Odpověď #6 kdy: 12 Března 2014, 21:18:22 »
ako zabranim tomu aby sa po restarte opat nespustilo ? dva krat ?

Petr Merlin Vaněček

  • Moderátor
  • Závislák
  • ***
  • Příspěvků: 5057
    • Lomítkáři
Re:Problem s freeradiusom
« Odpověď #7 kdy: 12 Března 2014, 21:19:14 »
Spíš si myslím, že se neukončil při nějakém restartu během pokusů ... nemyslím si, že by se to mělo nějak výrazně opakovat.
Stiskni CTRL + W ...
80% mozku tvoří kapalina ... u některých brzdová

zvukarmiso

  • Návštěvník
  • Příspěvků: 79
Re:Problem s freeradiusom
« Odpověď #8 kdy: 12 Března 2014, 21:25:01 »
ked dam /etc/init.d/freeradius restart tak mi to spravi opat to iste. aj po restarte masiny

Petr Merlin Vaněček

  • Moderátor
  • Závislák
  • ***
  • Příspěvků: 5057
    • Lomítkáři
Re:Problem s freeradiusom
« Odpověď #9 kdy: 12 Března 2014, 21:36:12 »
Po tom zabití procesu naběhne freeradius ok? A pokud dáš restart, tak to selže?
Stiskni CTRL + W ...
80% mozku tvoří kapalina ... u některých brzdová

zvukarmiso

  • Návštěvník
  • Příspěvků: 79
Re:Problem s freeradiusom
« Odpověď #10 kdy: 12 Března 2014, 21:48:15 »
Ked dam kill normalne zbehne. Doplnim udaje do client config a dam restart radiusu tak opat hodi chybu ze su dva procesy spustene naraz. Dam kill a opat to ide. Ale nebavi ma ked nahodou doplnim dalsi router do siete aby som robil stale kill a pod...

Petr Merlin Vaněček

  • Moderátor
  • Závislák
  • ***
  • Příspěvků: 5057
    • Lomítkáři
Re:Problem s freeradiusom
« Odpověď #11 kdy: 12 Března 2014, 22:06:33 »
A co po tom killu zkusit ne restart, ale start a pak stop?
Vypadá to asi na chybu toho stop scriptu, kdy nedojde k ukončení ....
Stiskni CTRL + W ...
80% mozku tvoří kapalina ... u některých brzdová

zvukarmiso

  • Návštěvník
  • Příspěvků: 79
Re:Problem s freeradiusom
« Odpověď #12 kdy: 12 Března 2014, 22:37:23 »
to iste spravi

Petr Merlin Vaněček

  • Moderátor
  • Závislák
  • ***
  • Příspěvků: 5057
    • Lomítkáři
Re:Problem s freeradiusom
« Odpověď #13 kdy: 13 Března 2014, 07:46:31 »
Takže po stopu nedojde ke zmizení procesu?
V logu po stopu není nějaký záznam?
Stiskni CTRL + W ...
80% mozku tvoří kapalina ... u některých brzdová

zvukarmiso

  • Návštěvník
  • Příspěvků: 79
Re:Problem s freeradiusom
« Odpověď #14 kdy: 13 Března 2014, 07:50:08 »
ked to stopnem vyzera ze ako keby to islo dalej.
V logu nic nie je.

Petr Merlin Vaněček

  • Moderátor
  • Závislák
  • ***
  • Příspěvků: 5057
    • Lomítkáři
Re:Problem s freeradiusom
« Odpověď #15 kdy: 13 Března 2014, 07:52:55 »
Pak se podívej do souboru /etc/init.d/freeradius co se má přesně dít v stop funkci. Asi tam bude krpa.
Stiskni CTRL + W ...
80% mozku tvoří kapalina ... u některých brzdová

zvukarmiso

  • Návštěvník
  • Příspěvků: 79
Re:Problem s freeradiusom
« Odpověď #16 kdy: 13 Března 2014, 08:06:28 »
v tomto sa navyznam, takze posielam cely subor

Kód: [Vybrat]
#!/bin/sh
# Start/stop the FreeRADIUS daemon.

### BEGIN INIT INFO
# Provides:          freeradius
# Required-Start:    $remote_fs $network $syslog
# Should-Start:      $time mysql slapd postgresql samba krb5-kdc
# Required-Stop:     $remote_fs $syslog
# Default-Start:     2 3 4 5
# Default-Stop:      0 1 6
# Short-Description: Radius Daemon
# Description:       Extensible, configurable radius daemon
### END INIT INFO

set -e

. /lib/lsb/init-functions

PROG="freeradius"
PROGRAM="/usr/sbin/freeradius"
PIDFILE="/var/run/freeradius/freeradius.pid"
DESCR="FreeRADIUS daemon"

if [ -r /etc/default/$PROG ]; then
  . /etc/default/$PROG
fi

test -f $PROGRAM || exit 0

# /var/run may be a tmpfs
if [ ! -d /var/run/freeradius ]; then
  mkdir -p /var/run/freeradius
  chown freerad:freerad /var/run/freeradius
fi

export PATH="${PATH:+$PATH:}/usr/sbin:/sbin"

ret=0

case "$1" in
        start)
                log_daemon_msg "Starting $DESCR" "$PROG"
                start-stop-daemon --start --quiet --pidfile $PIDFILE --exec $PROGRAM -- $FREERADIUS_OPTIONS || ret=$?
                log_end_msg $ret
                exit $ret
                ;;
        stop)
                log_daemon_msg "Stopping $DESCR" "$PROG"
                if [ -f "$PIDFILE" ] ; then
                  start-stop-daemon --stop --retry=TERM/30/KILL/5 --quiet --pidfile $PIDFILE || ret=$?
                else
                  log_action_cont_msg "$PIDFILE not found"
                  ret=0
                fi
                log_end_msg $ret
                ;;
        restart)
                $0 stop
                $0 start
                ;;
        reload|force-reload)
                log_daemon_msg "Reloading $DESCR" "$PROG"
                if [ -f "$PIDFILE" ] ; then
                  start-stop-daemon --stop --signal HUP --quiet --pidfile $PIDFILE || ret=$?
                else
                  log_action_cont_msg "$PIDFILE not found"
                  ret=0
                fi
                log_end_msg $ret
                ;;
        *)
                echo "Usage: $0 start|stop|restart|force-reload|reload"
                exit 1
                ;;
esac

exit 0

Petr Merlin Vaněček

  • Moderátor
  • Závislák
  • ***
  • Příspěvků: 5057
    • Lomítkáři
Re:Problem s freeradiusom
« Odpověď #17 kdy: 13 Března 2014, 08:34:48 »
Co to vypíše, když dáš stop?
Jen ještě podotknu, že ten stop se chová tak, že čeká 30s na to, zda se podaří TERM a pokud ne, provede KILL s timeoutem 5s, takže bych po stopu kontroloval, zda běží radius až po min. 35s ...
« Poslední změna: 13 Března 2014, 08:37:15 od Petr Merlin Vaněček »
Stiskni CTRL + W ...
80% mozku tvoří kapalina ... u některých brzdová

zvukarmiso

  • Návštěvník
  • Příspěvků: 79
Re:Problem s freeradiusom
« Odpověď #18 kdy: 13 Března 2014, 11:17:38 »
aj po 10 min je to spustene ak dam stop, proces tam vidim stale spusteny

Petr Merlin Vaněček

  • Moderátor
  • Závislák
  • ***
  • Příspěvků: 5057
    • Lomítkáři
Re:Problem s freeradiusom
« Odpověď #19 kdy: 13 Března 2014, 12:00:27 »
Tak to udělej prasácky takto:
Kód: [Vybrat]
        stop)
                log_daemon_msg "Stopping $DESCR" "$PROG"
                if [ -f "$PIDFILE" ] ; then
                  killall freeradius
                else
                  log_action_cont_msg "$PIDFILE not found"
                  ret=0
                fi
                log_end_msg $ret
                ;;
Stiskni CTRL + W ...
80% mozku tvoří kapalina ... u některých brzdová

zvukarmiso

  • Návštěvník
  • Příspěvků: 79
Re:Problem s freeradiusom
« Odpověď #20 kdy: 14 Března 2014, 00:12:48 »
Dik za radu ale nejak po restarte a vypadku elektriny opat som to musel kilnut. Skusim este posurfovat po netu

Petr Merlin Vaněček

  • Moderátor
  • Závislák
  • ***
  • Příspěvků: 5057
    • Lomítkáři
Re:Problem s freeradiusom
« Odpověď #21 kdy: 14 Března 2014, 07:16:10 »
Pak natvrdo killall -9 freeradius Ale to už je mazec :D :D :D
Stiskni CTRL + W ...
80% mozku tvoří kapalina ... u některých brzdová

zvukarmiso

  • Návštěvník
  • Příspěvků: 79
Re:Problem s freeradiusom
« Odpověď #22 kdy: 14 Března 2014, 12:18:12 »
To je uz moc drasticke riesenie, a nakoniec pride do stadia ze to nejde

Petr Merlin Vaněček

  • Moderátor
  • Závislák
  • ***
  • Příspěvků: 5057
    • Lomítkáři
Re:Problem s freeradiusom
« Odpověď #23 kdy: 15 Března 2014, 18:29:10 »
To je uz moc drasticke riesenie, a nakoniec pride do stadia ze to nejde

Tak teď nerozumím, nejde ani kill -9 ?
Stiskni CTRL + W ...
80% mozku tvoří kapalina ... u některých brzdová

 

Provoz zaštiťuje spolek OpenAlt.