Script de inicialização do Ubuntu

1
Mon Jul 28 14:30:29 2014 : Error: Failed to load virtual server inner-tunnel
Mon Jul 28 14:30:29 2014 : Error: /etc/freeradius/sites-enabled/inner-tunnel[47]: Errors parsing authorize section.
Mon Jul 28 14:30:29 2014 : Error: /etc/freeradius/sites-enabled/inner-tunnel[131]: Failed to load module "sql".
Mon Jul 28 14:30:29 2014 : Error: /etc/freeradius/sql.conf[22]: Instantiation failed for module "sql"
Mon Jul 28 14:30:29 2014 : Info: rlm_sql (sql): Closing sqlsocket 0
Mon Jul 28 14:30:29 2014 : Info: rlm_sql (sql): Closing sqlsocket 1
Mon Jul 28 14:30:29 2014 : Info: rlm_sql (sql): Closing sqlsocket 2
Mon Jul 28 14:30:29 2014 : Info: rlm_sql (sql): Closing sqlsocket 3
Mon Jul 28 14:30:29 2014 : Info: rlm_sql (sql): Closing sqlsocket 4
Mon Jul 28 14:30:29 2014 : Error: Failed to load clients from SQL.
Mon Jul 28 14:30:29 2014 : Info: rlm_sql (sql): There are no DB handles to use! skipped 5, tried to connect 0
Mon Jul 28 14:30:29 2014 : Error: rlm_sql (sql): Failed to connect DB handle #0
Mon Jul 28 14:30:29 2014 : Error: rlm_sql_mysql: Mysql error 'Can't connect to local MySQL server through socket '/var/run/mysqld/mysqld.sock' (2)'
Mon Jul 28 14:30:29 2014 : Error: rlm_sql_mysql: Couldn't connect socket to MySQL server radius@localhost:radius
Mon Jul 28 14:30:29 2014 : Info: rlm_sql_mysql: Starting connect to MySQL server for #0
Mon Jul 28 14:30:29 2014 : Info: rlm_sql (sql): Attempting to connect rlm_sql_mysql #0
Mon Jul 28 14:30:29 2014 : Info: rlm_sql (sql): Attempting to connect to radius@localhost:/radius
Mon Jul 28 14:30:29 2014 : Info: rlm_sql (sql): Driver rlm_sql_mysql (module rlm_sql_mysql) loaded and linked
Mon Jul 28 14:30:28 2014 : Error: Failed to load virtual server inner-tunnel
Mon Jul 28 14:30:28 2014 : Error: /etc/freeradius/sites-enabled/inner-tunnel[47]: Errors parsing authorize section.
Mon Jul 28 14:30:28 2014 : Error: /etc/freeradius/sites-enabled/inner-tunnel[131]: Failed to load module "sql".
Mon Jul 28 14:30:28 2014 : Error: /etc/freeradius/sql.conf[22]: Instantiation failed for module "sql"
Mon Jul 28 14:30:28 2014 : Info: rlm_sql (sql): Closing sqlsocket 0
Mon Jul 28 14:30:28 2014 : Info: rlm_sql (sql): Closing sqlsocket 1
Mon Jul 28 14:30:28 2014 : Info: rlm_sql (sql): Closing sqlsocket 2
Mon Jul 28 14:30:28 2014 : Info: rlm_sql (sql): Closing sqlsocket 3
Mon Jul 28 14:30:28 2014 : Info: rlm_sql (sql): Closing sqlsocket 4
Mon Jul 28 14:30:28 2014 : Error: Failed to load clients from SQL.
Mon Jul 28 14:30:28 2014 : Info: rlm_sql (sql): There are no DB handles to use! skipped 5, tried to connect 0
Mon Jul 28 14:30:28 2014 : Error: rlm_sql (sql): Failed to connect DB handle #0
Mon Jul 28 14:30:28 2014 : Error: rlm_sql_mysql: Mysql error 'Can't connect to local MySQL server through socket '/var/run/mysqld/mysqld.sock' (2)'
Mon Jul 28 14:30:28 2014 : Error: rlm_sql_mysql: Couldn't connect socket to MySQL server radius@localhost:radius
Mon Jul 28 14:30:28 2014 : Info: rlm_sql_mysql: Starting connect to MySQL server for #0
Mon Jul 28 14:30:28 2014 : Info: rlm_sql (sql): Attempting to connect rlm_sql_mysql #0
Mon Jul 28 14:30:28 2014 : Info: rlm_sql (sql): Attempting to connect to radius@localhost:/radius
Mon Jul 28 14:30:28 2014 : Info: rlm_sql (sql): Driver rlm_sql_mysql (module rlm_sql_mysql) loaded and linked

este é o log daloradius, e alguém me disse, é serviços sql não começaram, é por isso que eu gostaria de atrasar o serviço start daloradius. belowing é o meu método para deixar o serviço daloradius iniciar após 200 segundos.

eu gostaria de deixar o roteiro dormir 200 segundos apenas iniciar o daloradius. este é o comando que eu tentei, mas parece que não está funcionando.

start on login-session-start
script
sleep 200000
exec > freeradius -X
end script

OR

start on login-session-start
script
sleep 200000
freeradius -X
end script

e o script eu salvei como etc/init/VPN.conf

    
por Ng chin ye 28.07.2014 / 08:38

2 respostas

1

Aqui está o seu problema:

Mon Jul 28 14:30:29 2014 : Error: rlm_sql_mysql: Mysql error 'Can't connect to local MySQL server through socket '/var/run/mysqld/mysqld.sock' (2)'

Isso (2) significa No such file or directory , ou seja, o soquete não está presente.

Você realmente instalou o servidor MySQL?

sudo apt-get install mysql-server

Você iniciou o servidor?

sudo service mysql restart
    
por 28.07.2014 / 13:48
0

Por que não colocar (/ bin / sleep 200 & / caminho / para / freeradius -X) em /etc/rc.local?

link

P: a função sleep usa segundos.

    
por 28.07.2014 / 09:43

Tags