|
|
@@ -1,3 +1,26 @@
|
|
|
+-- phpMyAdmin SQL Dump
|
|
|
+-- version 5.2.1
|
|
|
+-- https://www.phpmyadmin.net/
|
|
|
+--
|
|
|
+-- Хост: localhost
|
|
|
+-- Время создания: Мар 05 2023 г., 00:09
|
|
|
+-- Версия сервера: 10.5.18-MariaDB-0+deb11u1-log
|
|
|
+-- Версия PHP: 7.4.33
|
|
|
+
|
|
|
+SET SQL_MODE = "NO_AUTO_VALUE_ON_ZERO";
|
|
|
+START TRANSACTION;
|
|
|
+SET time_zone = "+00:00";
|
|
|
+
|
|
|
+
|
|
|
+/*!40101 SET @OLD_CHARACTER_SET_CLIENT=@@CHARACTER_SET_CLIENT */;
|
|
|
+/*!40101 SET @OLD_CHARACTER_SET_RESULTS=@@CHARACTER_SET_RESULTS */;
|
|
|
+/*!40101 SET @OLD_COLLATION_CONNECTION=@@COLLATION_CONNECTION */;
|
|
|
+/*!40101 SET NAMES utf8mb4 */;
|
|
|
+
|
|
|
+--
|
|
|
+-- База данных: `stat`
|
|
|
+--
|
|
|
+
|
|
|
-- --------------------------------------------------------
|
|
|
|
|
|
--
|
|
|
@@ -9,7 +32,8 @@ CREATE TABLE `auth_rules` (
|
|
|
`user_id` int(11) DEFAULT NULL,
|
|
|
`ou_id` int(11) DEFAULT NULL,
|
|
|
`type` int(11) NOT NULL,
|
|
|
- `rule` varchar(40) COLLATE utf8mb4_unicode_ci DEFAULT NULL
|
|
|
+ `rule` varchar(40) DEFAULT NULL,
|
|
|
+ `comment` varchar(250) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci DEFAULT NULL
|
|
|
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci;
|
|
|
|
|
|
-- --------------------------------------------------------
|
|
|
@@ -20,8 +44,8 @@ CREATE TABLE `auth_rules` (
|
|
|
|
|
|
CREATE TABLE `building` (
|
|
|
`id` int(11) NOT NULL,
|
|
|
- `name` varchar(50) COLLATE utf8mb4_unicode_ci NOT NULL,
|
|
|
- `comment` text COLLATE utf8mb4_unicode_ci DEFAULT NULL
|
|
|
+ `name` varchar(50) NOT NULL,
|
|
|
+ `comment` varchar(250) DEFAULT NULL
|
|
|
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci;
|
|
|
|
|
|
--
|
|
|
@@ -39,16 +63,28 @@ INSERT INTO `building` (`id`, `name`, `comment`) VALUES(1, 'Earth', 'Somewhere')
|
|
|
CREATE TABLE `config` (
|
|
|
`id` int(11) NOT NULL,
|
|
|
`option_id` int(11) DEFAULT NULL,
|
|
|
- `value` varchar(250) COLLATE utf8mb4_unicode_ci DEFAULT NULL
|
|
|
+ `value` varchar(250) DEFAULT NULL
|
|
|
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci;
|
|
|
|
|
|
--
|
|
|
-- Дамп данных таблицы `config`
|
|
|
--
|
|
|
|
|
|
-INSERT INTO `config` (`id`, `option_id`, `value`) VALUES(1, 1, '1024');
|
|
|
-INSERT INTO `config` (`id`, `option_id`, `value`) VALUES(77, 41, '/usr/local/scripts/fetch_new_arp.pl');
|
|
|
-INSERT INTO `config` (`id`, `option_id`, `value`) VALUES(78, 37, '/usr/local/scripts/sync_mikrotik.pl');
|
|
|
+INSERT INTO `config` (`id`, `option_id`, `value`) VALUES(1, 1, '0');
|
|
|
+INSERT INTO `config` (`id`, `option_id`, `value`) VALUES(2, 11, 'public');
|
|
|
+INSERT INTO `config` (`id`, `option_id`, `value`) VALUES(3, 32, 'ORG');
|
|
|
+INSERT INTO `config` (`id`, `option_id`, `value`) VALUES(123, 19, '1');
|
|
|
+INSERT INTO `config` (`id`, `option_id`, `value`) VALUES(124, 35, '120');
|
|
|
+INSERT INTO `config` (`id`, `option_id`, `value`) VALUES(125, 9, '2');
|
|
|
+INSERT INTO `config` (`id`, `option_id`, `value`) VALUES(126, 41, '/usr/local/scripts/fetch_new_arp.pl');
|
|
|
+INSERT INTO `config` (`id`, `option_id`, `value`) VALUES(127, 26, '3');
|
|
|
+INSERT INTO `config` (`id`, `option_id`, `value`) VALUES(128, 27, '10');
|
|
|
+INSERT INTO `config` (`id`, `option_id`, `value`) VALUES(129, 48, '90');
|
|
|
+INSERT INTO `config` (`id`, `option_id`, `value`) VALUES(130, 49, '365');
|
|
|
+INSERT INTO `config` (`id`, `option_id`, `value`) VALUES(131, 47, '365');
|
|
|
+INSERT INTO `config` (`id`, `option_id`, `value`) VALUES(132, 53, '2');
|
|
|
+INSERT INTO `config` (`id`, `option_id`, `value`) VALUES(133, 55, '10');
|
|
|
+INSERT INTO `config` (`id`, `option_id`, `value`) VALUES(134, 56, '30');
|
|
|
|
|
|
-- --------------------------------------------------------
|
|
|
|
|
|
@@ -58,11 +94,12 @@ INSERT INTO `config` (`id`, `option_id`, `value`) VALUES(78, 37, '/usr/local/scr
|
|
|
|
|
|
CREATE TABLE `config_options` (
|
|
|
`id` int(11) NOT NULL,
|
|
|
- `option_name` varchar(50) COLLATE utf8mb4_unicode_ci NOT NULL,
|
|
|
- `description` text COLLATE utf8mb4_unicode_ci DEFAULT NULL,
|
|
|
+ `option_name` varchar(50) NOT NULL,
|
|
|
+ `description.russian` text DEFAULT NULL,
|
|
|
+ `description.english` text DEFAULT NULL,
|
|
|
`uniq` tinyint(1) NOT NULL DEFAULT 1,
|
|
|
- `type` varchar(10) COLLATE utf8mb4_unicode_ci NOT NULL,
|
|
|
- `default_value` varchar(250) COLLATE utf8mb4_unicode_ci DEFAULT NULL,
|
|
|
+ `type` varchar(10) NOT NULL,
|
|
|
+ `default_value` varchar(250) DEFAULT NULL,
|
|
|
`min_value` int(11) NOT NULL DEFAULT 0,
|
|
|
`max_value` int(11) NOT NULL DEFAULT 0
|
|
|
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci;
|
|
|
@@ -71,51 +108,51 @@ CREATE TABLE `config_options` (
|
|
|
-- Дамп данных таблицы `config_options`
|
|
|
--
|
|
|
|
|
|
-INSERT INTO `config_options` (`id`, `option_name`, `description`, `uniq`, `type`, `default_value`, `min_value`, `max_value`) VALUES(1, 'KB', 'Число байт в килобайте', 1, 'int', '1024', 1000, 1024);
|
|
|
-INSERT INTO `config_options` (`id`, `option_name`, `description`, `uniq`, `type`, `default_value`, `min_value`, `max_value`) VALUES(3, 'dns server', 'ip-адрес DNS-сервера', 1, 'text', '127.0.0.1', 0, 0);
|
|
|
-INSERT INTO `config_options` (`id`, `option_name`, `description`, `uniq`, `type`, `default_value`, `min_value`, `max_value`) VALUES(5, 'dhcp server', 'ip-адрес DHCP-сервера', 1, 'text', '127.0.0.1', 0, 0);
|
|
|
-INSERT INTO `config_options` (`id`, `option_name`, `description`, `uniq`, `type`, `default_value`, `min_value`, `max_value`) VALUES(9, 'default snmp version', 'Версия snmp по умолчанию. В настоящий момент поддерживаются 1 и 2. Поддержка версии 3 в разработке.', 1, 'int', '2', 1, 3);
|
|
|
-INSERT INTO `config_options` (`id`, `option_name`, `description`, `uniq`, `type`, `default_value`, `min_value`, `max_value`) VALUES(11, 'default snmp community', 'Read snmp community по умолчанию', 1, 'text', 'public', 0, 0);
|
|
|
-INSERT INTO `config_options` (`id`, `option_name`, `description`, `uniq`, `type`, `default_value`, `min_value`, `max_value`) VALUES(17, 'mac discavery', 'Выполнять опрос mac-таблицы коммутаторов при сканировании сети. Если опция отключена будет нельзя сопоставить ip-адрес порту коммутатора', 1, 'bool', '1', 0, 0);
|
|
|
-INSERT INTO `config_options` (`id`, `option_name`, `description`, `uniq`, `type`, `default_value`, `min_value`, `max_value`) VALUES(19, 'arp discavery', 'Выполнять сканирование arp-таблицы роутеров при сканировании сети. Если опция отключена сопоставление mac-адреса ip-адресу будет возможно только из логов dhcp-сервера.', 1, 'bool', '1', 0, 0);
|
|
|
-INSERT INTO `config_options` (`id`, `option_name`, `description`, `uniq`, `type`, `default_value`, `min_value`, `max_value`) VALUES(21, 'admin email', 'E-mail администратора', 1, 'text', 'root', 0, 0);
|
|
|
-INSERT INTO `config_options` (`id`, `option_name`, `description`, `uniq`, `type`, `default_value`, `min_value`, `max_value`) VALUES(22, 'add user from netflow', 'Создавать ли новые записи для неизвестных адресов из анализа трафика netflow. Обычно выключается, поскольку может создавать много фэйковых адресов - например при пинге подсети, когда пакеты идут на все, даже не существующие адреса. Имеет смысл включать только на маршрутизаторах во внешние сети.', 1, 'bool', '0', 0, 0);
|
|
|
-INSERT INTO `config_options` (`id`, `option_name`, `description`, `uniq`, `type`, `default_value`, `min_value`, `max_value`) VALUES(23, 'save traffic detail', 'Сохранять ли детализацию трафика из netflow по ip-адресам пользователей', 1, 'bool', '1', 0, 0);
|
|
|
-INSERT INTO `config_options` (`id`, `option_name`, `description`, `uniq`, `type`, `default_value`, `min_value`, `max_value`) VALUES(26, 'history detail traffic', 'Глубина хранения детализации в сутках. Установка значения больше 3-7 дней приведёт к разрастанию базы данных и увеличит время отображения детализации в интерфейсе администратора', 1, 'int', '3', 1, 7);
|
|
|
-INSERT INTO `config_options` (`id`, `option_name`, `description`, `uniq`, `type`, `default_value`, `min_value`, `max_value`) VALUES(27, 'history dhcp lease', 'Глубина хранения аренды dhcp-сервера', 1, 'int', '1', 0, 0);
|
|
|
-INSERT INTO `config_options` (`id`, `option_name`, `description`, `uniq`, `type`, `default_value`, `min_value`, `max_value`) VALUES(28, 'router_login', 'Логин для входа на маршрутизаторы Mikrotik для управления dhcp-сервером и контролем доступа', 1, 'text', 'admin', 0, 0);
|
|
|
-INSERT INTO `config_options` (`id`, `option_name`, `description`, `uniq`, `type`, `default_value`, `min_value`, `max_value`) VALUES(29, 'router_password', 'Пароль для входа на маршрутизаторы Mikrotik для управления dhcp-сервером и контролем доступа', 1, 'text', 'admin', 0, 0);
|
|
|
-INSERT INTO `config_options` (`id`, `option_name`, `description`, `uniq`, `type`, `default_value`, `min_value`, `max_value`) VALUES(30, 'router_port', 'Порт ssh маршрутизатора', 1, 'int', '22', 22, 0);
|
|
|
-INSERT INTO `config_options` (`id`, `option_name`, `description`, `uniq`, `type`, `default_value`, `min_value`, `max_value`) VALUES(32, 'org name', 'Название организации', 1, 'text', 'ORG', 0, 0);
|
|
|
-INSERT INTO `config_options` (`id`, `option_name`, `description`, `uniq`, `type`, `default_value`, `min_value`, `max_value`) VALUES(33, 'office domain', 'Домен организации', 1, 'text', 'local', 0, 0);
|
|
|
-INSERT INTO `config_options` (`id`, `option_name`, `description`, `uniq`, `type`, `default_value`, `min_value`, `max_value`) VALUES(34, 'debug', 'Включить отладку', 1, 'bool', '0', 0, 0);
|
|
|
-INSERT INTO `config_options` (`id`, `option_name`, `description`, `uniq`, `type`, `default_value`, `min_value`, `max_value`) VALUES(35, 'connections history, days', 'Время хранения истории мест подключения ip-адресов', 1, 'int', '90', 1, 365);
|
|
|
-INSERT INTO `config_options` (`id`, `option_name`, `description`, `uniq`, `type`, `default_value`, `min_value`, `max_value`) VALUES(37, 'refresh access lists', 'Расположение скрипта управления контролем доступа для роутеров Mikrotik', 1, 'text', '/usr/local/scripts/sync_user_list.pl', 0, 0);
|
|
|
-INSERT INTO `config_options` (`id`, `option_name`, `description`, `uniq`, `type`, `default_value`, `min_value`, `max_value`) VALUES(38, 'regenerate dhcp cconfig', 'Расположение скрипта управления конфигурацией dhcp-серверами', 1, 'text', '/usr/local/scripts/update-dnsmasq', 0, 0);
|
|
|
-INSERT INTO `config_options` (`id`, `option_name`, `description`, `uniq`, `type`, `default_value`, `min_value`, `max_value`) VALUES(39, 'regenerate dns cconfig', 'Расположение скрипта управления dns-сервером', 1, 'text', '/usr/local/scripts/update-dns', 0, 0);
|
|
|
-INSERT INTO `config_options` (`id`, `option_name`, `description`, `uniq`, `type`, `default_value`, `min_value`, `max_value`) VALUES(40, 'regenerate nagios cconfig', 'Расположение скрипта конфигурирования Nagios', 1, 'text', '/etc/nagios/restart_nagios', 0, 0);
|
|
|
-INSERT INTO `config_options` (`id`, `option_name`, `description`, `uniq`, `type`, `default_value`, `min_value`, `max_value`) VALUES(41, 'discavery network', 'Расположение скрипта сканирования сети', 1, 'text', '/usr/local/scripts/fetch_new_arp.pl', 0, 0);
|
|
|
-INSERT INTO `config_options` (`id`, `option_name`, `description`, `uniq`, `type`, `default_value`, `min_value`, `max_value`) VALUES(44, 'Ignore hotspot dhcp log', 'Не писать лог событий dhcp-сервера хотспота. Имеет смысл вклчючать, поскольку время аренды в хот-споте как правило маленькое и в записях хот-спота становятся незаметны логи обычных пользователей', 1, 'bool', '1', 0, 0);
|
|
|
-INSERT INTO `config_options` (`id`, `option_name`, `description`, `uniq`, `type`, `default_value`, `min_value`, `max_value`) VALUES(45, 'ignore update dhcp event', 'Не писать события обновления ip-адреса dhcp-сервера. ', 1, 'bool', '0', 0, 0);
|
|
|
-INSERT INTO `config_options` (`id`, `option_name`, `description`, `uniq`, `type`, `default_value`, `min_value`, `max_value`) VALUES(46, 'update hostname from dhcp', 'Обновлять имя хоста в DNS при получении адреса по DHCP', 1, 'bool', '0', 0, 0);
|
|
|
-INSERT INTO `config_options` (`id`, `option_name`, `description`, `uniq`, `type`, `default_value`, `min_value`, `max_value`) VALUES(47, 'history worklog', 'Глубина хранения логов работы в интерфейсе администратора', 1, 'int', '90', 30, 1095);
|
|
|
-INSERT INTO `config_options` (`id`, `option_name`, `description`, `uniq`, `type`, `default_value`, `min_value`, `max_value`) VALUES(48, 'history syslog', 'Глубина хранения логов работы syslog-сервера', 1, 'int', '90', 30, 1095);
|
|
|
-INSERT INTO `config_options` (`id`, `option_name`, `description`, `uniq`, `type`, `default_value`, `min_value`, `max_value`) VALUES(49, 'history traffic stats', 'Глубина хранения статистики трафика юзеров', 1, 'int', '365', 30, 0);
|
|
|
-INSERT INTO `config_options` (`id`, `option_name`, `description`, `uniq`, `type`, `default_value`, `min_value`, `max_value`) VALUES(50, 'urgent sync access', 'Немедленное изменение списков доступа на роутере после правки записи пользователя', 1, 'bool', '0', 0, 0);
|
|
|
-INSERT INTO `config_options` (`id`, `option_name`, `description`, `uniq`, `type`, `default_value`, `min_value`, `max_value`) VALUES(51, 'Email_alert', 'Отправлять e-mail сообщения для уровней сообщений WARNING & ERROR', 1, 'bool', '1', 0, 0);
|
|
|
-INSERT INTO `config_options` (`id`, `option_name`, `description`, `uniq`, `type`, `default_value`, `min_value`, `max_value`) VALUES(52, 'Sender email', 'E-mail адрес, с которого рассылается почта', 1, 'text', 'root', 0, 0);
|
|
|
-INSERT INTO `config_options` (`id`, `option_name`, `description`, `uniq`, `type`, `default_value`, `min_value`, `max_value`) VALUES(53, 'log level', 'Каждый уровень включает в себя предыдущий:\r\n0 - ERROR - писать только ошибки\r\n1 - WARNING - писать предупреждения\r\n2 - INFO - писать информационные сообщения\r\n3 - VERBOSE - писать подробную информацию о выполняемых операциях', 1, 'int', '2', 0, 3);
|
|
|
-INSERT INTO `config_options` (`id`, `option_name`, `description`, `uniq`, `type`, `default_value`, `min_value`, `max_value`) VALUES(54, 'enable_quotes', 'Включить обработку квот по трафику', 1, 'bool', '0', 0, 0);
|
|
|
-INSERT INTO `config_options` (`id`, `option_name`, `description`, `uniq`, `type`, `default_value`, `min_value`, `max_value`) VALUES(55, 'netflow_step', 'Интервал сброса данных из коллектора netflow, минуты', 1, 'int', '10', 1, 60);
|
|
|
-INSERT INTO `config_options` (`id`, `option_name`, `description`, `uniq`, `type`, `default_value`, `min_value`, `max_value`) VALUES(56, 'traffic_ipstat_history', 'Время хранения полной статистики по трафику для каждого ip-адреса в сутках. Таблица в 6 раз больше обычной часовой статистики. Врядли кому-то потребуется глубина хранения более месяца.', 1, 'int', '30', 7, 365);
|
|
|
-INSERT INTO `config_options` (`id`, `option_name`, `description`, `uniq`, `type`, `default_value`, `min_value`, `max_value`) VALUES(57, 'nagios_url', 'Адрес сайта nagios', 1, 'text', 'http://127.0.0.1/nagios', 0, 0);
|
|
|
-INSERT INTO `config_options` (`id`, `option_name`, `description`, `uniq`, `type`, `default_value`, `min_value`, `max_value`) VALUES(58, 'cacti_url', 'Адрес сайта cacti', 1, 'text', 'http://127.0.0.1/cacti', 0, 0);
|
|
|
-INSERT INTO `config_options` (`id`, `option_name`, `description`, `uniq`, `type`, `default_value`, `min_value`, `max_value`) VALUES(59, 'torrus_url', 'Адрес сайта Torrus', 1, 'text', 'http://127.0.0.1/torrus/CollectorName/', 0, 0);
|
|
|
-INSERT INTO `config_options` (`id`, `option_name`, `description`, `uniq`, `type`, `default_value`, `min_value`, `max_value`) VALUES(60, 'wiki_url', 'Адрес wiki', 1, 'text', 'http://127.0.0.1/wiki', 0, 0);
|
|
|
-INSERT INTO `config_options` (`id`, `option_name`, `description`, `uniq`, `type`, `default_value`, `min_value`, `max_value`) VALUES(61, 'wiki_path', 'Путь к каталогу данных вики', 1, 'text', '/var/www/foswiki/data/', 0, 0);
|
|
|
-INSERT INTO `config_options` (`id`, `option_name`, `description`, `uniq`, `type`, `default_value`, `min_value`, `max_value`) VALUES(62, 'stat_url', 'Адрес этого сайта', 1, 'text', 'http://127.0.0.1/stat', 0, 0);
|
|
|
-INSERT INTO `config_options` (`id`, `option_name`, `description`, `uniq`, `type`, `default_value`, `min_value`, `max_value`) VALUES(63, 'wiki_web', 'Web for Wiki. Default - Main. http://example.local/Main/WebHome', 1, 'text', 'Main', 0, 0);
|
|
|
-INSERT INTO `config_options` (`id`, `option_name`, `description`, `uniq`, `type`, `default_value`, `min_value`, `max_value`) VALUES(64, 'auto_mac_rule', 'Создавать автоматическую привязку мак-адреса к юзеру. Т.е. все ip-адреса для найденного мака будут привязываться к одном и тому же юзеру.', 1, 'bool', '0', 0, 1);
|
|
|
+INSERT INTO `config_options` (`id`, `option_name`, `description.russian`, `description.english`, `uniq`, `type`, `default_value`, `min_value`, `max_value`) VALUES(1, 'KB', 'Еденица измерения трафика - Килобайт (1000b) или кибибайт(1024b,default)', 'Traffic measurement unit - Kilobyte (1000b) or kibibyte (1024b,default)', 1, 'bool', '1', 0, 1);
|
|
|
+INSERT INTO `config_options` (`id`, `option_name`, `description.russian`, `description.english`, `uniq`, `type`, `default_value`, `min_value`, `max_value`) VALUES(3, 'dns server', 'ip-адрес DNS-сервера', 'DNS server ip address', 1, 'text', '127.0.0.1', 0, 0);
|
|
|
+INSERT INTO `config_options` (`id`, `option_name`, `description.russian`, `description.english`, `uniq`, `type`, `default_value`, `min_value`, `max_value`) VALUES(5, 'dhcp server', 'ip-адрес DHCP-сервера', 'ip address of the DHCP server', 1, 'text', '127.0.0.1', 0, 0);
|
|
|
+INSERT INTO `config_options` (`id`, `option_name`, `description.russian`, `description.english`, `uniq`, `type`, `default_value`, `min_value`, `max_value`) VALUES(9, 'default snmp version', 'Версия snmp по умолчанию. В настоящий момент поддерживаются 1 и 2. Поддержка версии 3 в разработке.', 'The default version of snmp. Currently, 1 and 2 are supported. Support for version 3 is in development.', 1, 'int', '2', 1, 3);
|
|
|
+INSERT INTO `config_options` (`id`, `option_name`, `description.russian`, `description.english`, `uniq`, `type`, `default_value`, `min_value`, `max_value`) VALUES(11, 'default snmp community', 'Read snmp community по умолчанию', 'Read snmp community by default', 1, 'text', 'public', 0, 0);
|
|
|
+INSERT INTO `config_options` (`id`, `option_name`, `description.russian`, `description.english`, `uniq`, `type`, `default_value`, `min_value`, `max_value`) VALUES(17, 'mac discavery', 'Выполнять опрос mac-таблицы коммутаторов при сканировании сети. Если опция отключена будет нельзя сопоставить ip-адрес порту коммутатора', 'Poll the mac table of switches when scanning the network. If the option is disabled, it will be impossible to map the ip address to the switch port', 1, 'bool', '1', 0, 0);
|
|
|
+INSERT INTO `config_options` (`id`, `option_name`, `description.russian`, `description.english`, `uniq`, `type`, `default_value`, `min_value`, `max_value`) VALUES(19, 'arp discavery', 'Выполнять сканирование arp-таблицы роутеров при сканировании сети. Если опция отключена сопоставление mac-адреса ip-адресу будет возможно только из логов dhcp-сервера.', 'Perform a scan of the router arp table when scanning the network. If the option is disabled, mapping the mac address to the ip address be possible only from the logs of the dhcp server.', 1, 'bool', '1', 0, 0);
|
|
|
+INSERT INTO `config_options` (`id`, `option_name`, `description.russian`, `description.english`, `uniq`, `type`, `default_value`, `min_value`, `max_value`) VALUES(21, 'admin email', 'E-mail администратора', 'Administrator e-mail', 1, 'text', 'root', 0, 0);
|
|
|
+INSERT INTO `config_options` (`id`, `option_name`, `description.russian`, `description.english`, `uniq`, `type`, `default_value`, `min_value`, `max_value`) VALUES(22, 'add user from netflow', 'Создавать ли новые записи для неизвестных адресов из анализа трафика netflow. Не включать, если netflow снимает данные с маршрутизатора локальной сети', 'Whether to create new records for unknown addresses from netflow traffic analysis. Do not enable if netflow get data from the local network router', 1, 'bool', '0', 0, 0);
|
|
|
+INSERT INTO `config_options` (`id`, `option_name`, `description.russian`, `description.english`, `uniq`, `type`, `default_value`, `min_value`, `max_value`) VALUES(23, 'save traffic detail', 'Сохранять ли детализацию трафика из netflow по ip-адресам пользователей', 'Whether to keep the details of traffic from netflow by ip addresses of users', 1, 'bool', '1', 0, 0);
|
|
|
+INSERT INTO `config_options` (`id`, `option_name`, `description.russian`, `description.english`, `uniq`, `type`, `default_value`, `min_value`, `max_value`) VALUES(26, 'history detail traffic', 'Глубина хранения детализации в сутках. Установка значения больше 3-7 дней приведёт к разрастанию базы данных и увеличит время отображения детализации в интерфейсе администратора', 'Depth of detail storage in days. Setting a value greater than 3-7 days will cause the database to grow and increase the time about to display details in the admin interface', 1, 'int', '3', 1, 7);
|
|
|
+INSERT INTO `config_options` (`id`, `option_name`, `description.russian`, `description.english`, `uniq`, `type`, `default_value`, `min_value`, `max_value`) VALUES(27, 'history dhcp lease', 'Глубина хранения аренды dhcp-сервера', 'Storage depth of the dhcp server lease', 1, 'int', '1', 0, 0);
|
|
|
+INSERT INTO `config_options` (`id`, `option_name`, `description.russian`, `description.english`, `uniq`, `type`, `default_value`, `min_value`, `max_value`) VALUES(28, 'router_login', 'Логин для входа на маршрутизаторы Mikrotik для управления dhcp-сервером и контролем доступа', 'Login to Mikrotik routers to manage the dhcp server and access control', 1, 'text', 'admin', 0, 0);
|
|
|
+INSERT INTO `config_options` (`id`, `option_name`, `description.russian`, `description.english`, `uniq`, `type`, `default_value`, `min_value`, `max_value`) VALUES(29, 'router_password', 'Пароль для входа на маршрутизаторы Mikrotik для управления dhcp-сервером и контролем доступа', 'Password to log in to Mikrotik routers for managing the dhcp server and access control', 1, 'text', 'admin', 0, 0);
|
|
|
+INSERT INTO `config_options` (`id`, `option_name`, `description.russian`, `description.english`, `uniq`, `type`, `default_value`, `min_value`, `max_value`) VALUES(30, 'router_port', 'Порт ssh маршрутизатора', 'Router ssh port', 1, 'int', '22', 22, 0);
|
|
|
+INSERT INTO `config_options` (`id`, `option_name`, `description.russian`, `description.english`, `uniq`, `type`, `default_value`, `min_value`, `max_value`) VALUES(32, 'org name', 'Название организации', 'Organization name', 1, 'text', 'ORG', 0, 0);
|
|
|
+INSERT INTO `config_options` (`id`, `option_name`, `description.russian`, `description.english`, `uniq`, `type`, `default_value`, `min_value`, `max_value`) VALUES(33, 'office domain', 'Домен организации', 'Organization domain', 1, 'text', 'local', 0, 0);
|
|
|
+INSERT INTO `config_options` (`id`, `option_name`, `description.russian`, `description.english`, `uniq`, `type`, `default_value`, `min_value`, `max_value`) VALUES(34, 'debug', 'Включить отладку', 'Enable debugging', 1, 'bool', '0', 0, 0);
|
|
|
+INSERT INTO `config_options` (`id`, `option_name`, `description.russian`, `description.english`, `uniq`, `type`, `default_value`, `min_value`, `max_value`) VALUES(35, 'connections history, days', 'Время хранения истории мест подключения ip-адресов', 'Storage time of the history of connection locations of ip addresses', 1, 'int', '90', 1, 365);
|
|
|
+INSERT INTO `config_options` (`id`, `option_name`, `description.russian`, `description.english`, `uniq`, `type`, `default_value`, `min_value`, `max_value`) VALUES(37, 'refresh access lists', 'Расположение скрипта управления контролем доступа для роутеров Mikrotik', 'Location of the access control script for Mikrotik routers', 1, 'text', '/usr/local/scripts/sync_mikrotik.pl', 0, 0);
|
|
|
+INSERT INTO `config_options` (`id`, `option_name`, `description.russian`, `description.english`, `uniq`, `type`, `default_value`, `min_value`, `max_value`) VALUES(38, 'regenerate dhcp cconfig', 'Расположение скрипта управления конфигурацией dhcp-серверами', 'Location of the dhcp server configuration management script', 1, 'text', '/usr/local/scripts/update-dnsmasq', 0, 0);
|
|
|
+INSERT INTO `config_options` (`id`, `option_name`, `description.russian`, `description.english`, `uniq`, `type`, `default_value`, `min_value`, `max_value`) VALUES(39, 'regenerate dns cconfig', 'Расположение скрипта управления dns-сервером', 'Location of the dns server management script', 1, 'text', '/usr/local/scripts/update-dns', 0, 0);
|
|
|
+INSERT INTO `config_options` (`id`, `option_name`, `description.russian`, `description.english`, `uniq`, `type`, `default_value`, `min_value`, `max_value`) VALUES(40, 'regenerate nagios cconfig', 'Расположение скрипта конфигурирования Nagios', 'Location of the Nagios configuration script', 1, 'text', '/etc/nagios/restart_nagios', 0, 0);
|
|
|
+INSERT INTO `config_options` (`id`, `option_name`, `description.russian`, `description.english`, `uniq`, `type`, `default_value`, `min_value`, `max_value`) VALUES(41, 'discavery network', 'Расположение скрипта сканирования сети', 'Location of the network scan script', 1, 'text', '/usr/local/scripts/fetch_new_arp.pl', 0, 0);
|
|
|
+INSERT INTO `config_options` (`id`, `option_name`, `description.russian`, `description.english`, `uniq`, `type`, `default_value`, `min_value`, `max_value`) VALUES(44, 'Ignore hotspot dhcp log', 'Не писать лог событий dhcp-сервера хотспота. Имеет смысл вклчючать, поскольку время аренды в хот-споте как правило маленькое и в записях хот-спота становятся незаметны логи обычных пользователей', 'Do not write the event log of the hotspot dhcp server. It makes sense to include it, since the rental time in the hotspot is usually small and the logs of ordinary users become invisible in the hotspot records', 1, 'bool', '1', 0, 0);
|
|
|
+INSERT INTO `config_options` (`id`, `option_name`, `description.russian`, `description.english`, `uniq`, `type`, `default_value`, `min_value`, `max_value`) VALUES(45, 'ignore update dhcp event', 'Не писать события обновления ip-адреса dhcp-сервера. ', 'Do not write events for updating the IP address of the dhcp server. ', 1, 'bool', '0', 0, 0);
|
|
|
+INSERT INTO `config_options` (`id`, `option_name`, `description.russian`, `description.english`, `uniq`, `type`, `default_value`, `min_value`, `max_value`) VALUES(46, 'update hostname from dhcp', 'Обновлять имя хоста в DNS при получении адреса по DHCP', 'Update the hostname in DNS when receiving the address via DHCP', 1, 'bool', '0', 0, 0);
|
|
|
+INSERT INTO `config_options` (`id`, `option_name`, `description.russian`, `description.english`, `uniq`, `type`, `default_value`, `min_value`, `max_value`) VALUES(47, 'history worklog', 'Глубина хранения логов работы в интерфейсе администратора', 'Depth of work logs storage in the admin interface', 1, 'int', '90', 30, 1095);
|
|
|
+INSERT INTO `config_options` (`id`, `option_name`, `description.russian`, `description.english`, `uniq`, `type`, `default_value`, `min_value`, `max_value`) VALUES(48, 'history syslog', 'Глубина хранения логов работы syslog-сервера', 'Syslog server logs storage depth', 1, 'int', '90', 30, 1095);
|
|
|
+INSERT INTO `config_options` (`id`, `option_name`, `description.russian`, `description.english`, `uniq`, `type`, `default_value`, `min_value`, `max_value`) VALUES(49, 'history traffic stats', 'Глубина хранения статистики трафика юзеров', 'User traffic statistics storage depth', 1, 'int', '365', 30, 0);
|
|
|
+INSERT INTO `config_options` (`id`, `option_name`, `description.russian`, `description.english`, `uniq`, `type`, `default_value`, `min_value`, `max_value`) VALUES(50, 'urgent sync access', 'Немедленное изменение списков доступа на роутере после правки записи пользователя', 'Immediate change of access lists on the router after editing the user record ', 1, 'bool', '0', 0, 0);
|
|
|
+INSERT INTO `config_options` (`id`, `option_name`, `description.russian`, `description.english`, `uniq`, `type`, `default_value`, `min_value`, `max_value`) VALUES(51, 'Email_alert', 'Отправлять e-mail сообщения для уровней сообщений WARNING & ERROR', 'Send e-mail messages for message levels WARNING & ERROR', 1, 'bool', '1', 0, 0);
|
|
|
+INSERT INTO `config_options` (`id`, `option_name`, `description.russian`, `description.english`, `uniq`, `type`, `default_value`, `min_value`, `max_value`) VALUES(52, 'Sender email', 'E-mail адрес, с которого рассылается почта', 'E-mail address from which mail is sent', 1, 'text', 'root', 0, 0);
|
|
|
+INSERT INTO `config_options` (`id`, `option_name`, `description.russian`, `description.english`, `uniq`, `type`, `default_value`, `min_value`, `max_value`) VALUES(53, 'log level', 'Каждый уровень включает в себя предыдущий:\n0 - ERROR - писать только ошибки\n1 - WARNING - писать предупреждения\n2 - INFO - писать информационные сообщения\n3 - VERBOSE - писать подробную информацию о выполняемых операциях', 'Each level includes the previous one:\r\n0 - ERROR - write only errors\r\n1 - WARNING - write warnings\r\n2 - INFO - write informational\r\n3 - VERBOSE - write detailed information about the operations performed ', 1, 'int', '2', 0, 3);
|
|
|
+INSERT INTO `config_options` (`id`, `option_name`, `description.russian`, `description.english`, `uniq`, `type`, `default_value`, `min_value`, `max_value`) VALUES(54, 'enable_quotes', 'Включить обработку квот по трафику', 'Enable traffic quota processing', 1, 'bool', '0', 0, 0);
|
|
|
+INSERT INTO `config_options` (`id`, `option_name`, `description.russian`, `description.english`, `uniq`, `type`, `default_value`, `min_value`, `max_value`) VALUES(55, 'netflow_step', 'Интервал сброса данных из коллектора netflow, минуты', 'Data reset interval from netflow collector, minutes', 1, 'int', '10', 1, 60);
|
|
|
+INSERT INTO `config_options` (`id`, `option_name`, `description.russian`, `description.english`, `uniq`, `type`, `default_value`, `min_value`, `max_value`) VALUES(56, 'traffic_ipstat_history', 'Время хранения полной статистики по трафику для каждого ip-адреса в сутках. Таблица в 6 раз больше обычной часовой статистики. Врядли кому-то потребуется глубина хранения более месяца.', 'The storage time of complete traffic statistics for each ip address in days. The table is 6 times larger than the usual hourly statistic Hardly anyone will need a storage depth of more than a month.', 1, 'int', '30', 7, 365);
|
|
|
+INSERT INTO `config_options` (`id`, `option_name`, `description.russian`, `description.english`, `uniq`, `type`, `default_value`, `min_value`, `max_value`) VALUES(57, 'nagios_url', 'Адрес сайта nagios', 'nagios site address', 1, 'text', 'http://127.0.0.1/nagios', 0, 0);
|
|
|
+INSERT INTO `config_options` (`id`, `option_name`, `description.russian`, `description.english`, `uniq`, `type`, `default_value`, `min_value`, `max_value`) VALUES(58, 'cacti_url', 'Адрес сайта cacti', 'cacti site address', 1, 'text', 'http://127.0.0.1/cacti', 0, 0);
|
|
|
+INSERT INTO `config_options` (`id`, `option_name`, `description.russian`, `description.english`, `uniq`, `type`, `default_value`, `min_value`, `max_value`) VALUES(59, 'torrus_url', 'Адрес сайта Torrus', 'Torrus website address', 1, 'text', 'http://127.0.0.1/torrus/CollectorName/', 0, 0);
|
|
|
+INSERT INTO `config_options` (`id`, `option_name`, `description.russian`, `description.english`, `uniq`, `type`, `default_value`, `min_value`, `max_value`) VALUES(60, 'wiki_url', 'Адрес wiki', 'Wiki website address', 1, 'text', 'http://127.0.0.1/wiki', 0, 0);
|
|
|
+INSERT INTO `config_options` (`id`, `option_name`, `description.russian`, `description.english`, `uniq`, `type`, `default_value`, `min_value`, `max_value`) VALUES(61, 'wiki_path', 'Путь к каталогу данных вики', 'Path to wiki data directory', 1, 'text', '/var/www/foswiki/data/', 0, 0);
|
|
|
+INSERT INTO `config_options` (`id`, `option_name`, `description.russian`, `description.english`, `uniq`, `type`, `default_value`, `min_value`, `max_value`) VALUES(62, 'stat_url', 'Адрес этого сайта', 'Address of this site', 1, 'text', 'http://127.0.0.1/stat', 0, 0);
|
|
|
+INSERT INTO `config_options` (`id`, `option_name`, `description.russian`, `description.english`, `uniq`, `type`, `default_value`, `min_value`, `max_value`) VALUES(63, 'wiki_web', 'Web for Wiki. Default - Main. http://example.local/Main/WebHome', 'Web for Wiki. Default - Main. http://example.local/Main/WebHome', 1, 'text', 'Main', 0, 0);
|
|
|
+INSERT INTO `config_options` (`id`, `option_name`, `description.russian`, `description.english`, `uniq`, `type`, `default_value`, `min_value`, `max_value`) VALUES(64, 'auto_mac_rule', 'Создавать автоматическую привязку мак-адреса к юзеру. Т.е. все ip-адреса для найденного мака будут привязываться к одном и тому же юзеру.', 'Create an automatic binding of the mac address to the user. I.e. all ip addresses for the found mac will be bound to the same user.', 1, 'bool', '0', 0, 1);
|
|
|
|
|
|
-- --------------------------------------------------------
|
|
|
|
|
|
@@ -138,8 +175,8 @@ CREATE TABLE `connections` (
|
|
|
|
|
|
CREATE TABLE `Customers` (
|
|
|
`id` int(11) NOT NULL,
|
|
|
- `Login` varchar(20) COLLATE utf8mb4_unicode_ci DEFAULT 'NULL',
|
|
|
- `Pwd` varchar(32) COLLATE utf8mb4_unicode_ci DEFAULT 'NULL',
|
|
|
+ `Login` varchar(20) DEFAULT 'NULL',
|
|
|
+ `Pwd` varchar(32) DEFAULT 'NULL',
|
|
|
`readonly` tinyint(1) NOT NULL DEFAULT 0
|
|
|
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci;
|
|
|
|
|
|
@@ -159,28 +196,28 @@ CREATE TABLE `devices` (
|
|
|
`id` int(11) NOT NULL,
|
|
|
`device_type` int(11) NOT NULL DEFAULT 1,
|
|
|
`device_model_id` int(11) DEFAULT 89,
|
|
|
- `firmware` varchar(100) COLLATE utf8mb4_unicode_ci DEFAULT NULL,
|
|
|
+ `firmware` varchar(100) DEFAULT NULL,
|
|
|
`vendor_id` int(11) NOT NULL DEFAULT 1,
|
|
|
- `device_name` varchar(50) COLLATE utf8mb4_unicode_ci DEFAULT NULL,
|
|
|
+ `device_name` varchar(50) DEFAULT NULL,
|
|
|
`building_id` int(11) NOT NULL DEFAULT 1,
|
|
|
- `ip` varchar(15) COLLATE utf8mb4_unicode_ci DEFAULT NULL,
|
|
|
+ `ip` varchar(15) DEFAULT NULL,
|
|
|
`port_count` int(11) NOT NULL DEFAULT 0,
|
|
|
- `SN` varchar(80) COLLATE utf8mb4_unicode_ci DEFAULT NULL,
|
|
|
- `comment` varchar(255) COLLATE utf8mb4_unicode_ci DEFAULT NULL,
|
|
|
+ `SN` varchar(80) DEFAULT NULL,
|
|
|
+ `comment` varchar(255) DEFAULT NULL,
|
|
|
`snmp_version` tinyint(4) NOT NULL DEFAULT 0,
|
|
|
- `snmp3_user_rw` varchar(20) COLLATE utf8mb4_unicode_ci DEFAULT NULL,
|
|
|
- `snmp3_user_rw_password` varchar(20) COLLATE utf8mb4_unicode_ci DEFAULT NULL,
|
|
|
- `snmp3_user_ro` varchar(20) COLLATE utf8mb4_unicode_ci DEFAULT NULL,
|
|
|
- `snmp3_user_ro_password` varchar(20) COLLATE utf8mb4_unicode_ci DEFAULT NULL,
|
|
|
- `community` varchar(50) COLLATE utf8mb4_unicode_ci NOT NULL DEFAULT 'public',
|
|
|
- `rw_community` varchar(50) COLLATE utf8mb4_unicode_ci NOT NULL DEFAULT 'private',
|
|
|
+ `snmp3_user_rw` varchar(20) DEFAULT NULL,
|
|
|
+ `snmp3_user_rw_password` varchar(20) DEFAULT NULL,
|
|
|
+ `snmp3_user_ro` varchar(20) DEFAULT NULL,
|
|
|
+ `snmp3_user_ro_password` varchar(20) DEFAULT NULL,
|
|
|
+ `community` varchar(50) NOT NULL DEFAULT 'public',
|
|
|
+ `rw_community` varchar(50) NOT NULL DEFAULT 'private',
|
|
|
`fdb_snmp_index` tinyint(1) NOT NULL DEFAULT 0,
|
|
|
`discovery` tinyint(1) NOT NULL DEFAULT 1,
|
|
|
`user_acl` tinyint(1) NOT NULL DEFAULT 0,
|
|
|
`dhcp` tinyint(1) NOT NULL DEFAULT 0,
|
|
|
`nagios` tinyint(1) NOT NULL DEFAULT 0,
|
|
|
`active` tinyint(1) NOT NULL DEFAULT 1,
|
|
|
- `nagios_status` varchar(10) COLLATE utf8mb4_unicode_ci NOT NULL DEFAULT 'UP',
|
|
|
+ `nagios_status` varchar(10) NOT NULL DEFAULT 'UP',
|
|
|
`queue_enabled` tinyint(1) NOT NULL DEFAULT 0,
|
|
|
`connected_user_only` tinyint(1) NOT NULL DEFAULT 1,
|
|
|
`user_id` int(11) DEFAULT NULL,
|
|
|
@@ -197,7 +234,7 @@ CREATE TABLE `device_l3_interfaces` (
|
|
|
`id` int(11) NOT NULL,
|
|
|
`device_id` int(11) DEFAULT NULL,
|
|
|
`interface_type` int(11) NOT NULL DEFAULT 0,
|
|
|
- `name` varchar(100) COLLATE utf8mb4_unicode_ci DEFAULT NULL
|
|
|
+ `name` varchar(100) DEFAULT NULL
|
|
|
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci;
|
|
|
|
|
|
-- --------------------------------------------------------
|
|
|
@@ -208,9 +245,9 @@ CREATE TABLE `device_l3_interfaces` (
|
|
|
|
|
|
CREATE TABLE `device_models` (
|
|
|
`id` int(11) NOT NULL,
|
|
|
- `model_name` varchar(200) COLLATE utf8mb4_unicode_ci DEFAULT NULL,
|
|
|
+ `model_name` varchar(200) DEFAULT NULL,
|
|
|
`vendor_id` int(11) DEFAULT 1,
|
|
|
- `nagios_template` varchar(200) COLLATE utf8mb4_unicode_ci DEFAULT NULL
|
|
|
+ `nagios_template` varchar(200) DEFAULT NULL
|
|
|
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci;
|
|
|
|
|
|
--
|
|
|
@@ -321,6 +358,9 @@ INSERT INTO `device_models` (`id`, `model_name`, `vendor_id`, `nagios_template`)
|
|
|
INSERT INTO `device_models` (`id`, `model_name`, `vendor_id`, `nagios_template`) VALUES(104, 'MES2324B', 2, NULL);
|
|
|
INSERT INTO `device_models` (`id`, `model_name`, `vendor_id`, `nagios_template`) VALUES(105, 'MES2324FB', 2, NULL);
|
|
|
INSERT INTO `device_models` (`id`, `model_name`, `vendor_id`, `nagios_template`) VALUES(106, 'MES2124P', 2, NULL);
|
|
|
+INSERT INTO `device_models` (`id`, `model_name`, `vendor_id`, `nagios_template`) VALUES(107, 'MES2428P', 2, NULL);
|
|
|
+INSERT INTO `device_models` (`id`, `model_name`, `vendor_id`, `nagios_template`) VALUES(108, 'Symmetra LX 16000', 20, 'symmetra.cfg');
|
|
|
+INSERT INTO `device_models` (`id`, `model_name`, `vendor_id`, `nagios_template`) VALUES(109, 'SNR-UPS-ONT20', 6, 'ups.cfg');
|
|
|
|
|
|
-- --------------------------------------------------------
|
|
|
|
|
|
@@ -333,9 +373,9 @@ CREATE TABLE `device_ports` (
|
|
|
`device_id` int(11) DEFAULT NULL,
|
|
|
`snmp_index` int(11) DEFAULT NULL,
|
|
|
`port` int(11) DEFAULT NULL,
|
|
|
- `ifName` varchar(40) COLLATE utf8mb4_unicode_ci DEFAULT NULL,
|
|
|
- `port_name` varchar(40) COLLATE utf8mb4_unicode_ci DEFAULT NULL,
|
|
|
- `comment` varchar(50) COLLATE utf8mb4_unicode_ci DEFAULT NULL,
|
|
|
+ `ifName` varchar(40) DEFAULT NULL,
|
|
|
+ `port_name` varchar(40) DEFAULT NULL,
|
|
|
+ `comment` varchar(50) DEFAULT NULL,
|
|
|
`target_port_id` int(11) NOT NULL DEFAULT 0,
|
|
|
`auth_id` int(11) DEFAULT NULL,
|
|
|
`last_mac_count` int(11) DEFAULT 0,
|
|
|
@@ -353,7 +393,7 @@ CREATE TABLE `device_ports` (
|
|
|
|
|
|
CREATE TABLE `device_types` (
|
|
|
`id` int(11) NOT NULL,
|
|
|
- `name` varchar(50) COLLATE utf8mb4_unicode_ci DEFAULT NULL
|
|
|
+ `name` varchar(50) DEFAULT NULL
|
|
|
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci;
|
|
|
|
|
|
--
|
|
|
@@ -374,12 +414,13 @@ INSERT INTO `device_types` (`id`, `name`) VALUES(5, 'Сетевое устрой
|
|
|
|
|
|
CREATE TABLE `dhcp_log` (
|
|
|
`id` int(10) UNSIGNED NOT NULL,
|
|
|
- `mac` varchar(17) COLLATE utf8mb4_unicode_ci NOT NULL,
|
|
|
+ `mac` varchar(17) NOT NULL,
|
|
|
`ip_int` int(10) UNSIGNED NOT NULL,
|
|
|
- `ip` varchar(15) COLLATE utf8mb4_unicode_ci NOT NULL,
|
|
|
- `action` varchar(10) COLLATE utf8mb4_unicode_ci NOT NULL,
|
|
|
+ `ip` varchar(15) NOT NULL,
|
|
|
+ `action` varchar(10) NOT NULL,
|
|
|
`timestamp` timestamp NOT NULL DEFAULT current_timestamp(),
|
|
|
- `auth_id` int(11) NOT NULL
|
|
|
+ `auth_id` int(11) NOT NULL,
|
|
|
+ `dhcp_hostname` varchar(250) DEFAULT NULL
|
|
|
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci;
|
|
|
|
|
|
-- --------------------------------------------------------
|
|
|
@@ -390,7 +431,7 @@ CREATE TABLE `dhcp_log` (
|
|
|
|
|
|
CREATE TABLE `dns_cache` (
|
|
|
`id` int(11) NOT NULL,
|
|
|
- `dns` varchar(250) COLLATE utf8mb4_unicode_ci DEFAULT NULL,
|
|
|
+ `dns` varchar(250) DEFAULT NULL,
|
|
|
`ip` int(11) DEFAULT NULL,
|
|
|
`timestamp` timestamp NOT NULL DEFAULT current_timestamp()
|
|
|
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci;
|
|
|
@@ -403,51 +444,52 @@ CREATE TABLE `dns_cache` (
|
|
|
|
|
|
CREATE TABLE `Filter_list` (
|
|
|
`id` int(11) NOT NULL,
|
|
|
- `name` varchar(20) COLLATE utf8mb4_unicode_ci NOT NULL DEFAULT '',
|
|
|
- `proto` varchar(10) COLLATE utf8mb4_unicode_ci DEFAULT NULL,
|
|
|
- `dst` text COLLATE utf8mb4_unicode_ci DEFAULT NULL,
|
|
|
- `dstport` varchar(20) COLLATE utf8mb4_unicode_ci DEFAULT NULL,
|
|
|
+ `name` varchar(50) DEFAULT NULL,
|
|
|
+ `comment` varchar(250) DEFAULT NULL,
|
|
|
+ `proto` varchar(10) DEFAULT NULL,
|
|
|
+ `dst` text DEFAULT NULL,
|
|
|
+ `dstport` varchar(20) DEFAULT NULL,
|
|
|
+ `srcport` varchar(20) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci DEFAULT NULL,
|
|
|
`action` int(11) NOT NULL DEFAULT 0,
|
|
|
`type` int(10) UNSIGNED NOT NULL DEFAULT 0
|
|
|
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci;
|
|
|
|
|
|
-
|
|
|
-INSERT INTO `Filter_list` (`id`, `name`, `proto`, `dst`, `dstport`, `action`, `type`) VALUES(1, 'pop3', 'tcp', '0/0', '110', 1, 0);
|
|
|
-INSERT INTO `Filter_list` (`id`, `name`, `proto`, `dst`, `dstport`, `action`, `type`) VALUES(3, 'http', 'tcp', '0/0', '80', 1, 0);
|
|
|
-INSERT INTO `Filter_list` (`id`, `name`, `proto`, `dst`, `dstport`, `action`, `type`) VALUES(4, 'https', 'tcp', '0/0', '443', 1, 0);
|
|
|
-INSERT INTO `Filter_list` (`id`, `name`, `proto`, `dst`, `dstport`, `action`, `type`) VALUES(5, 'icq', 'tcp', '0/0', '5190', 1, 0);
|
|
|
-INSERT INTO `Filter_list` (`id`, `name`, `proto`, `dst`, `dstport`, `action`, `type`) VALUES(6, 'jabber', 'tcp', '0/0', '5222', 1, 0);
|
|
|
-INSERT INTO `Filter_list` (`id`, `name`, `proto`, `dst`, `dstport`, `action`, `type`) VALUES(9, 'allow_all', 'all', '0/0', '0', 1, 0);
|
|
|
-INSERT INTO `Filter_list` (`id`, `name`, `proto`, `dst`, `dstport`, `action`, `type`) VALUES(10, 'icmp', 'icmp', '0/0', '0', 1, 0);
|
|
|
-INSERT INTO `Filter_list` (`id`, `name`, `proto`, `dst`, `dstport`, `action`, `type`) VALUES(11, 'ftp', 'tcp', '0/0', '20-21', 1, 0);
|
|
|
-INSERT INTO `Filter_list` (`id`, `name`, `proto`, `dst`, `dstport`, `action`, `type`) VALUES(14, 'radmin', 'tcp', '0/0', '4899', 1, 0);
|
|
|
-INSERT INTO `Filter_list` (`id`, `name`, `proto`, `dst`, `dstport`, `action`, `type`) VALUES(15, 'telnet', 'tcp', '0/0', '23', 1, 0);
|
|
|
-INSERT INTO `Filter_list` (`id`, `name`, `proto`, `dst`, `dstport`, `action`, `type`) VALUES(16, 'ssh', 'tcp', '0/0', '22', 1, 0);
|
|
|
-INSERT INTO `Filter_list` (`id`, `name`, `proto`, `dst`, `dstport`, `action`, `type`) VALUES(28, 'smtp', 'tcp', '0/0', '25', 1, 0);
|
|
|
-INSERT INTO `Filter_list` (`id`, `name`, `proto`, `dst`, `dstport`, `action`, `type`) VALUES(32, 'tsclient', 'tcp', '0/0', '3389', 1, 0);
|
|
|
-INSERT INTO `Filter_list` (`id`, `name`, `proto`, `dst`, `dstport`, `action`, `type`) VALUES(34, 'sberbank', 'udp', '0/0', '87', 1, 0);
|
|
|
-INSERT INTO `Filter_list` (`id`, `name`, `proto`, `dst`, `dstport`, `action`, `type`) VALUES(40, 'ntp', 'udp', '0/0', '123', 1, 0);
|
|
|
-INSERT INTO `Filter_list` (`id`, `name`, `proto`, `dst`, `dstport`, `action`, `type`) VALUES(44, 'vnc', 'tcp', '0/0', '5800-5900', 1, 0);
|
|
|
-INSERT INTO `Filter_list` (`id`, `name`, `proto`, `dst`, `dstport`, `action`, `type`) VALUES(55, 'unprivileged tcp', 'tcp', '0/0', '1024-65500', 1, 0);
|
|
|
-INSERT INTO `Filter_list` (`id`, `name`, `proto`, `dst`, `dstport`, `action`, `type`) VALUES(76, 'ipsec', 'udp', '0/0', '500', 1, 0);
|
|
|
-INSERT INTO `Filter_list` (`id`, `name`, `proto`, `dst`, `dstport`, `action`, `type`) VALUES(77, 'isakmp', 'udp', '0/0', '4500', 1, 0);
|
|
|
-INSERT INTO `Filter_list` (`id`, `name`, `proto`, `dst`, `dstport`, `action`, `type`) VALUES(79, 'pop3s', 'tcp', '0/0', '995', 1, 0);
|
|
|
-INSERT INTO `Filter_list` (`id`, `name`, `proto`, `dst`, `dstport`, `action`, `type`) VALUES(80, 'smtps', 'tcp', '0/0', '465,587', 1, 0);
|
|
|
-INSERT INTO `Filter_list` (`id`, `name`, `proto`, `dst`, `dstport`, `action`, `type`) VALUES(81, 'imap', 'tcp', '0/0', '143', 1, 0);
|
|
|
-INSERT INTO `Filter_list` (`id`, `name`, `proto`, `dst`, `dstport`, `action`, `type`) VALUES(82, 'imaps', 'tcp', '0/0', '993', 1, 0);
|
|
|
-INSERT INTO `Filter_list` (`id`, `name`, `proto`, `dst`, `dstport`, `action`, `type`) VALUES(83, 'unprivileged udp', 'udp', '0/0', '1024-65000', 1, 0);
|
|
|
-INSERT INTO `Filter_list` (`id`, `name`, `proto`, `dst`, `dstport`, `action`, `type`) VALUES(84, 'pptp', 'tcp', '0/0', '1723', 1, 0);
|
|
|
-INSERT INTO `Filter_list` (`id`, `name`, `proto`, `dst`, `dstport`, `action`, `type`) VALUES(85, 'openvpn-udp', 'udp', '0/0', '1194', 1, 0);
|
|
|
-INSERT INTO `Filter_list` (`id`, `name`, `proto`, `dst`, `dstport`, `action`, `type`) VALUES(88, 'pos-server', 'tcp', '0/0', '21101', 1, 0);
|
|
|
-INSERT INTO `Filter_list` (`id`, `name`, `proto`, `dst`, `dstport`, `action`, `type`) VALUES(89, 'ofdp.platformaofd.ru', 'all', '185.170.204.91', '0', 1, 0);
|
|
|
-INSERT INTO `Filter_list` (`id`, `name`, `proto`, `dst`, `dstport`, `action`, `type`) VALUES(90, 'dns_udp', 'udp', '0/0', '53', 1, 0);
|
|
|
-INSERT INTO `Filter_list` (`id`, `name`, `proto`, `dst`, `dstport`, `action`, `type`) VALUES(91, 'dns_tcp', 'tcp', '0/0', '53', 1, 0);
|
|
|
-INSERT INTO `Filter_list` (`id`, `name`, `proto`, `dst`, `dstport`, `action`, `type`) VALUES(92, 'sber-online', 'tcp', '0/0', '4477', 1, 0);
|
|
|
-INSERT INTO `Filter_list` (`id`, `name`, `proto`, `dst`, `dstport`, `action`, `type`) VALUES(93, 'devline.tv', 'tcp', '0/0', '843', 1, 0);
|
|
|
-INSERT INTO `Filter_list` (`id`, `name`, `proto`, `dst`, `dstport`, `action`, `type`) VALUES(96, 'cvs', 'tcp', '0/0', '5000-5012', 1, 0);
|
|
|
-INSERT INTO `Filter_list` (`id`, `name`, `proto`, `dst`, `dstport`, `action`, `type`) VALUES(97, 'devline', 'tcp', '0/0', '9780-9786,9877', 1, 0);
|
|
|
-INSERT INTO `Filter_list` (`id`, `name`, `proto`, `dst`, `dstport`, `action`, `type`) VALUES(101, 'snmp', 'udp', '0/0', '161', 1, 0);
|
|
|
-INSERT INTO `Filter_list` (`id`, `name`, `proto`, `dst`, `dstport`, `action`, `type`) VALUES(104, 'sberbank2', 'tcp', '0/0', '9443', 1, 0);
|
|
|
+--
|
|
|
+-- Дамп данных таблицы `Filter_list`
|
|
|
+--
|
|
|
+
|
|
|
+INSERT INTO `Filter_list` (`id`, `name`, `comment`, `proto`, `dst`, `dstport`, `srcport`, `action`, `type`) VALUES(1, 'pop3', NULL, 'tcp', '0/0', '110', NULL, 1, 0);
|
|
|
+INSERT INTO `Filter_list` (`id`, `name`, `comment`, `proto`, `dst`, `dstport`, `srcport`, `action`, `type`) VALUES(3, 'http', NULL, 'tcp', '0/0', '80', NULL, 1, 0);
|
|
|
+INSERT INTO `Filter_list` (`id`, `name`, `comment`, `proto`, `dst`, `dstport`, `srcport`, `action`, `type`) VALUES(4, 'https', NULL, 'tcp', '0/0', '443', NULL, 1, 0);
|
|
|
+INSERT INTO `Filter_list` (`id`, `name`, `comment`, `proto`, `dst`, `dstport`, `srcport`, `action`, `type`) VALUES(5, 'icq', NULL, 'tcp', '0/0', '5190', NULL, 1, 0);
|
|
|
+INSERT INTO `Filter_list` (`id`, `name`, `comment`, `proto`, `dst`, `dstport`, `srcport`, `action`, `type`) VALUES(6, 'jabber', NULL, 'tcp', '0/0', '5222', NULL, 1, 0);
|
|
|
+INSERT INTO `Filter_list` (`id`, `name`, `comment`, `proto`, `dst`, `dstport`, `srcport`, `action`, `type`) VALUES(9, 'allow_all', 'разрешить всё', 'all', '0/0', '0', '0', 1, 0);
|
|
|
+INSERT INTO `Filter_list` (`id`, `name`, `comment`, `proto`, `dst`, `dstport`, `srcport`, `action`, `type`) VALUES(10, 'icmp', NULL, 'icmp', '0/0', '0', NULL, 1, 0);
|
|
|
+INSERT INTO `Filter_list` (`id`, `name`, `comment`, `proto`, `dst`, `dstport`, `srcport`, `action`, `type`) VALUES(11, 'ftp', NULL, 'tcp', '0/0', '20-21', NULL, 1, 0);
|
|
|
+INSERT INTO `Filter_list` (`id`, `name`, `comment`, `proto`, `dst`, `dstport`, `srcport`, `action`, `type`) VALUES(15, 'telnet', NULL, 'tcp', '0/0', '23', NULL, 1, 0);
|
|
|
+INSERT INTO `Filter_list` (`id`, `name`, `comment`, `proto`, `dst`, `dstport`, `srcport`, `action`, `type`) VALUES(16, 'ssh', NULL, 'tcp', '0/0', '22', NULL, 1, 0);
|
|
|
+INSERT INTO `Filter_list` (`id`, `name`, `comment`, `proto`, `dst`, `dstport`, `srcport`, `action`, `type`) VALUES(28, 'smtp', NULL, 'tcp', '0/0', '25', NULL, 1, 0);
|
|
|
+INSERT INTO `Filter_list` (`id`, `name`, `comment`, `proto`, `dst`, `dstport`, `srcport`, `action`, `type`) VALUES(32, 'rdp', NULL, 'tcp', '0/0', '3389', NULL, 1, 0);
|
|
|
+INSERT INTO `Filter_list` (`id`, `name`, `comment`, `proto`, `dst`, `dstport`, `srcport`, `action`, `type`) VALUES(40, 'ntp', NULL, 'udp', '0/0', '123', NULL, 1, 0);
|
|
|
+INSERT INTO `Filter_list` (`id`, `name`, `comment`, `proto`, `dst`, `dstport`, `srcport`, `action`, `type`) VALUES(44, 'vnc', NULL, 'tcp', '0/0', '5800-5900', NULL, 1, 0);
|
|
|
+INSERT INTO `Filter_list` (`id`, `name`, `comment`, `proto`, `dst`, `dstport`, `srcport`, `action`, `type`) VALUES(55, 'unprivileged tcp', NULL, 'tcp', '0/0', '1024-65500', NULL, 1, 0);
|
|
|
+INSERT INTO `Filter_list` (`id`, `name`, `comment`, `proto`, `dst`, `dstport`, `srcport`, `action`, `type`) VALUES(76, 'ipsec', NULL, 'udp', '0/0', '500', NULL, 1, 0);
|
|
|
+INSERT INTO `Filter_list` (`id`, `name`, `comment`, `proto`, `dst`, `dstport`, `srcport`, `action`, `type`) VALUES(77, 'isakmp', NULL, 'udp', '0/0', '4500', NULL, 1, 0);
|
|
|
+INSERT INTO `Filter_list` (`id`, `name`, `comment`, `proto`, `dst`, `dstport`, `srcport`, `action`, `type`) VALUES(79, 'pop3s', NULL, 'tcp', '0/0', '995', NULL, 1, 0);
|
|
|
+INSERT INTO `Filter_list` (`id`, `name`, `comment`, `proto`, `dst`, `dstport`, `srcport`, `action`, `type`) VALUES(80, 'smtps', NULL, 'tcp', '0/0', '465,587', NULL, 1, 0);
|
|
|
+INSERT INTO `Filter_list` (`id`, `name`, `comment`, `proto`, `dst`, `dstport`, `srcport`, `action`, `type`) VALUES(81, 'imap', NULL, 'tcp', '0/0', '143', NULL, 1, 0);
|
|
|
+INSERT INTO `Filter_list` (`id`, `name`, `comment`, `proto`, `dst`, `dstport`, `srcport`, `action`, `type`) VALUES(82, 'imaps', NULL, 'tcp', '0/0', '993', NULL, 1, 0);
|
|
|
+INSERT INTO `Filter_list` (`id`, `name`, `comment`, `proto`, `dst`, `dstport`, `srcport`, `action`, `type`) VALUES(83, 'unprivileged udp', NULL, 'udp', '0/0', '1024-65000', NULL, 1, 0);
|
|
|
+INSERT INTO `Filter_list` (`id`, `name`, `comment`, `proto`, `dst`, `dstport`, `srcport`, `action`, `type`) VALUES(84, 'pptp', NULL, 'tcp', '0/0', '1723', NULL, 1, 0);
|
|
|
+INSERT INTO `Filter_list` (`id`, `name`, `comment`, `proto`, `dst`, `dstport`, `srcport`, `action`, `type`) VALUES(85, 'openvpn-udp', NULL, 'udp', '0/0', '1194', NULL, 1, 0);
|
|
|
+INSERT INTO `Filter_list` (`id`, `name`, `comment`, `proto`, `dst`, `dstport`, `srcport`, `action`, `type`) VALUES(90, 'dns_udp', NULL, 'udp', '0/0', '53', NULL, 1, 0);
|
|
|
+INSERT INTO `Filter_list` (`id`, `name`, `comment`, `proto`, `dst`, `dstport`, `srcport`, `action`, `type`) VALUES(91, 'dns_tcp', NULL, 'tcp', '0/0', '53', NULL, 1, 0);
|
|
|
+INSERT INTO `Filter_list` (`id`, `name`, `comment`, `proto`, `dst`, `dstport`, `srcport`, `action`, `type`) VALUES(94, 'squid', NULL, 'tcp', '0/0', '3128', NULL, 1, 0);
|
|
|
+INSERT INTO `Filter_list` (`id`, `name`, `comment`, `proto`, `dst`, `dstport`, `srcport`, `action`, `type`) VALUES(101, 'snmp', NULL, 'udp', '0/0', '161', NULL, 1, 0);
|
|
|
+INSERT INTO `Filter_list` (`id`, `name`, `comment`, `proto`, `dst`, `dstport`, `srcport`, `action`, `type`) VALUES(105, 'http_udp', NULL, 'udp', '0/0', '80', NULL, 1, 0);
|
|
|
+INSERT INTO `Filter_list` (`id`, `name`, `comment`, `proto`, `dst`, `dstport`, `srcport`, `action`, `type`) VALUES(106, 'https_udp', NULL, 'udp', '0/0', '443', NULL, 1, 0);
|
|
|
+INSERT INTO `Filter_list` (`id`, `name`, `comment`, `proto`, `dst`, `dstport`, `srcport`, `action`, `type`) VALUES(107, 'l2tp-ipsec', NULL, 'udp', '0/0', '1701,4500,500', NULL, 1, 0);
|
|
|
+INSERT INTO `Filter_list` (`id`, `name`, `comment`, `proto`, `dst`, `dstport`, `srcport`, `action`, `type`) VALUES(108, 'gre', NULL, 'gre', '0/0', NULL, NULL, 1, 0);
|
|
|
|
|
|
-- --------------------------------------------------------
|
|
|
|
|
|
@@ -501,15 +543,34 @@ INSERT INTO `Group_filters` (`id`, `group_id`, `filter_id`, `order`) VALUES(192,
|
|
|
INSERT INTO `Group_filters` (`id`, `group_id`, `filter_id`, `order`) VALUES(193, 3, 83, 15);
|
|
|
INSERT INTO `Group_filters` (`id`, `group_id`, `filter_id`, `order`) VALUES(194, 3, 3, 16);
|
|
|
INSERT INTO `Group_filters` (`id`, `group_id`, `filter_id`, `order`) VALUES(195, 3, 16, 17);
|
|
|
+INSERT INTO `Group_filters` (`id`, `group_id`, `filter_id`, `order`) VALUES(196, 4, 86, 1);
|
|
|
+INSERT INTO `Group_filters` (`id`, `group_id`, `filter_id`, `order`) VALUES(197, 4, 87, 2);
|
|
|
INSERT INTO `Group_filters` (`id`, `group_id`, `filter_id`, `order`) VALUES(198, 5, 90, 1);
|
|
|
INSERT INTO `Group_filters` (`id`, `group_id`, `filter_id`, `order`) VALUES(199, 5, 88, 2);
|
|
|
INSERT INTO `Group_filters` (`id`, `group_id`, `filter_id`, `order`) VALUES(200, 5, 89, 3);
|
|
|
INSERT INTO `Group_filters` (`id`, `group_id`, `filter_id`, `order`) VALUES(201, 5, 3, 4);
|
|
|
INSERT INTO `Group_filters` (`id`, `group_id`, `filter_id`, `order`) VALUES(202, 2, 90, 15);
|
|
|
+INSERT INTO `Group_filters` (`id`, `group_id`, `filter_id`, `order`) VALUES(204, 3, 91, 18);
|
|
|
INSERT INTO `Group_filters` (`id`, `group_id`, `filter_id`, `order`) VALUES(205, 3, 90, 19);
|
|
|
INSERT INTO `Group_filters` (`id`, `group_id`, `filter_id`, `order`) VALUES(206, 2, 92, 16);
|
|
|
+INSERT INTO `Group_filters` (`id`, `group_id`, `filter_id`, `order`) VALUES(207, 2, 93, 17);
|
|
|
INSERT INTO `Group_filters` (`id`, `group_id`, `filter_id`, `order`) VALUES(208, 2, 40, 18);
|
|
|
+INSERT INTO `Group_filters` (`id`, `group_id`, `filter_id`, `order`) VALUES(209, 2, 95, 19);
|
|
|
+INSERT INTO `Group_filters` (`id`, `group_id`, `filter_id`, `order`) VALUES(212, 2, 98, 22);
|
|
|
INSERT INTO `Group_filters` (`id`, `group_id`, `filter_id`, `order`) VALUES(213, 5, 4, 5);
|
|
|
+INSERT INTO `Group_filters` (`id`, `group_id`, `filter_id`, `order`) VALUES(214, 5, 99, 6);
|
|
|
+INSERT INTO `Group_filters` (`id`, `group_id`, `filter_id`, `order`) VALUES(215, 6, 86, 1);
|
|
|
+INSERT INTO `Group_filters` (`id`, `group_id`, `filter_id`, `order`) VALUES(216, 6, 87, 2);
|
|
|
+INSERT INTO `Group_filters` (`id`, `group_id`, `filter_id`, `order`) VALUES(217, 6, 102, 3);
|
|
|
+INSERT INTO `Group_filters` (`id`, `group_id`, `filter_id`, `order`) VALUES(218, 4, 102, 3);
|
|
|
+INSERT INTO `Group_filters` (`id`, `group_id`, `filter_id`, `order`) VALUES(219, 2, 104, 23);
|
|
|
+INSERT INTO `Group_filters` (`id`, `group_id`, `filter_id`, `order`) VALUES(220, 2, 105, 24);
|
|
|
+INSERT INTO `Group_filters` (`id`, `group_id`, `filter_id`, `order`) VALUES(221, 2, 106, 25);
|
|
|
+INSERT INTO `Group_filters` (`id`, `group_id`, `filter_id`, `order`) VALUES(222, 3, 105, 20);
|
|
|
+INSERT INTO `Group_filters` (`id`, `group_id`, `filter_id`, `order`) VALUES(223, 3, 106, 21);
|
|
|
+INSERT INTO `Group_filters` (`id`, `group_id`, `filter_id`, `order`) VALUES(224, 3, 107, 22);
|
|
|
+INSERT INTO `Group_filters` (`id`, `group_id`, `filter_id`, `order`) VALUES(225, 3, 108, 23);
|
|
|
+INSERT INTO `Group_filters` (`id`, `group_id`, `filter_id`, `order`) VALUES(226, 5, 109, 7);
|
|
|
|
|
|
-- --------------------------------------------------------
|
|
|
|
|
|
@@ -519,16 +580,17 @@ INSERT INTO `Group_filters` (`id`, `group_id`, `filter_id`, `order`) VALUES(213,
|
|
|
|
|
|
CREATE TABLE `Group_list` (
|
|
|
`id` int(11) NOT NULL,
|
|
|
- `group_name` varchar(30) COLLATE utf8mb4_unicode_ci NOT NULL DEFAULT ''
|
|
|
+ `group_name` varchar(50) DEFAULT NULL,
|
|
|
+ `comment` varchar(250) DEFAULT NULL
|
|
|
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci;
|
|
|
|
|
|
--
|
|
|
-- Дамп данных таблицы `Group_list`
|
|
|
--
|
|
|
|
|
|
-INSERT INTO `Group_list` (`id`, `group_name`) VALUES(0, 'default');
|
|
|
-INSERT INTO `Group_list` (`id`, `group_name`) VALUES(1, 'Allow all');
|
|
|
-INSERT INTO `Group_list` (`id`, `group_name`) VALUES(2, 'Users');
|
|
|
+INSERT INTO `Group_list` (`id`, `group_name`, `comment`) VALUES(0, 'default', NULL);
|
|
|
+INSERT INTO `Group_list` (`id`, `group_name`, `comment`) VALUES(1, 'Allow all', 'Разрешено всё');
|
|
|
+INSERT INTO `Group_list` (`id`, `group_name`, `comment`) VALUES(2, 'Users', 'Для пользователей');
|
|
|
|
|
|
-- --------------------------------------------------------
|
|
|
|
|
|
@@ -538,12 +600,13 @@ INSERT INTO `Group_list` (`id`, `group_name`) VALUES(2, 'Users');
|
|
|
|
|
|
CREATE TABLE `mac_history` (
|
|
|
`id` int(10) UNSIGNED NOT NULL,
|
|
|
- `mac` varchar(12) COLLATE utf8mb4_unicode_ci DEFAULT NULL,
|
|
|
+ `mac` varchar(12) DEFAULT NULL,
|
|
|
`timestamp` timestamp NOT NULL DEFAULT current_timestamp(),
|
|
|
`device_id` int(11) DEFAULT NULL,
|
|
|
`port_id` int(11) DEFAULT NULL,
|
|
|
- `ip` varchar(16) COLLATE utf8mb4_unicode_ci NOT NULL DEFAULT '',
|
|
|
- `auth_id` int(11) DEFAULT NULL
|
|
|
+ `ip` varchar(16) NOT NULL DEFAULT '',
|
|
|
+ `auth_id` int(11) DEFAULT NULL,
|
|
|
+ `dhcp_hostname` varchar(250) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci DEFAULT NULL
|
|
|
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci;
|
|
|
|
|
|
-- --------------------------------------------------------
|
|
|
@@ -554,11 +617,12 @@ CREATE TABLE `mac_history` (
|
|
|
|
|
|
CREATE TABLE `mac_vendors` (
|
|
|
`id` int(11) NOT NULL,
|
|
|
- `oui` varchar(20) COLLATE utf8mb4_unicode_ci NOT NULL,
|
|
|
- `companyName` varchar(255) COLLATE utf8mb4_unicode_ci DEFAULT NULL,
|
|
|
- `companyAddress` varchar(255) COLLATE utf8mb4_unicode_ci DEFAULT NULL,
|
|
|
+ `oui` varchar(20) DEFAULT NULL,
|
|
|
+ `companyName` varchar(255) DEFAULT NULL,
|
|
|
+ `companyAddress` varchar(255) DEFAULT NULL
|
|
|
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci;
|
|
|
|
|
|
+-- --------------------------------------------------------
|
|
|
|
|
|
--
|
|
|
-- Структура таблицы `OU`
|
|
|
@@ -566,13 +630,14 @@ CREATE TABLE `mac_vendors` (
|
|
|
|
|
|
CREATE TABLE `OU` (
|
|
|
`id` int(11) NOT NULL,
|
|
|
- `ou_name` varchar(40) COLLATE utf8mb4_unicode_ci DEFAULT NULL,
|
|
|
+ `ou_name` varchar(40) DEFAULT NULL,
|
|
|
+ `comment` varchar(250) DEFAULT NULL,
|
|
|
`default_users` tinyint(1) NOT NULL DEFAULT 0,
|
|
|
`default_hotspot` tinyint(1) NOT NULL DEFAULT 0,
|
|
|
- `nagios_dir` varchar(255) COLLATE utf8mb4_unicode_ci DEFAULT NULL,
|
|
|
- `nagios_host_use` varchar(50) COLLATE utf8mb4_unicode_ci DEFAULT NULL,
|
|
|
+ `nagios_dir` varchar(255) DEFAULT NULL,
|
|
|
+ `nagios_host_use` varchar(50) DEFAULT NULL,
|
|
|
`nagios_ping` tinyint(1) NOT NULL DEFAULT 1,
|
|
|
- `nagios_default_service` varchar(100) COLLATE utf8mb4_unicode_ci DEFAULT NULL,
|
|
|
+ `nagios_default_service` varchar(100) DEFAULT NULL,
|
|
|
`enabled` int(11) NOT NULL DEFAULT 0,
|
|
|
`filter_group_id` int(11) NOT NULL DEFAULT 0,
|
|
|
`queue_id` int(11) NOT NULL DEFAULT 0
|
|
|
@@ -582,22 +647,22 @@ CREATE TABLE `OU` (
|
|
|
-- Дамп данных таблицы `OU`
|
|
|
--
|
|
|
|
|
|
-INSERT INTO `OU` (`id`, `ou_name`, `default_users`, `default_hotspot`, `nagios_dir`, `nagios_host_use`, `nagios_ping`, `nagios_default_service`, `enabled`, `filter_group_id`, `queue_id`) VALUES(0, '!Всё', 0, 0, '/etc/nagios/any', 'generic-host', 1, NULL, 0, 0, 0);
|
|
|
-INSERT INTO `OU` (`id`, `ou_name`, `default_users`, `default_hotspot`, `nagios_dir`, `nagios_host_use`, `nagios_ping`, `nagios_default_service`, `enabled`, `filter_group_id`, `queue_id`) VALUES(1, 'Сервера', 0, 0, NULL, NULL, 1, NULL, 1, 1, 0);
|
|
|
-INSERT INTO `OU` (`id`, `ou_name`, `default_users`, `default_hotspot`, `nagios_dir`, `nagios_host_use`, `nagios_ping`, `nagios_default_service`, `enabled`, `filter_group_id`, `queue_id`) VALUES(2, 'Администраторы', 0, 0, NULL, NULL, 1, NULL, 0, 0, 0);
|
|
|
-INSERT INTO `OU` (`id`, `ou_name`, `default_users`, `default_hotspot`, `nagios_dir`, `nagios_host_use`, `nagios_ping`, `nagios_default_service`, `enabled`, `filter_group_id`, `queue_id`) VALUES(3, 'Пользователи', 0, 0, NULL, NULL, 1, NULL, 0, 0, 0);
|
|
|
-INSERT INTO `OU` (`id`, `ou_name`, `default_users`, `default_hotspot`, `nagios_dir`, `nagios_host_use`, `nagios_ping`, `nagios_default_service`, `enabled`, `filter_group_id`, `queue_id`) VALUES(4, 'VOIP', 0, 0, 'voip', 'voip', 1, NULL, 0, 0, 0);
|
|
|
-INSERT INTO `OU` (`id`, `ou_name`, `default_users`, `default_hotspot`, `nagios_dir`, `nagios_host_use`, `nagios_ping`, `nagios_default_service`, `enabled`, `filter_group_id`, `queue_id`) VALUES(5, 'IPCAM', 0, 0, 'videocam', 'ip-cam', 0, NULL, 0, 0, 0);
|
|
|
-INSERT INTO `OU` (`id`, `ou_name`, `default_users`, `default_hotspot`, `nagios_dir`, `nagios_host_use`, `nagios_ping`, `nagios_default_service`, `enabled`, `filter_group_id`, `queue_id`) VALUES(6, 'Принтеры', 0, 0, 'printers', 'printers', 1, 'printer-service', 0, 0, 0);
|
|
|
-INSERT INTO `OU` (`id`, `ou_name`, `default_users`, `default_hotspot`, `nagios_dir`, `nagios_host_use`, `nagios_ping`, `nagios_default_service`, `enabled`, `filter_group_id`, `queue_id`) VALUES(7, 'Свичи', 0, 0, 'switches', 'switches', 1, NULL, 0, 0, 0);
|
|
|
-INSERT INTO `OU` (`id`, `ou_name`, `default_users`, `default_hotspot`, `nagios_dir`, `nagios_host_use`, `nagios_ping`, `nagios_default_service`, `enabled`, `filter_group_id`, `queue_id`) VALUES(8, 'UPS', 0, 0, 'ups', 'ups', 1, NULL, 0, 0, 0);
|
|
|
-INSERT INTO `OU` (`id`, `ou_name`, `default_users`, `default_hotspot`, `nagios_dir`, `nagios_host_use`, `nagios_ping`, `nagios_default_service`, `enabled`, `filter_group_id`, `queue_id`) VALUES(9, 'Охрана', 0, 0, 'security', 'security', 1, NULL, 0, 0, 0);
|
|
|
-INSERT INTO `OU` (`id`, `ou_name`, `default_users`, `default_hotspot`, `nagios_dir`, `nagios_host_use`, `nagios_ping`, `nagios_default_service`, `enabled`, `filter_group_id`, `queue_id`) VALUES(10, 'Роутеры', 0, 0, 'routers', 'routers', 1, NULL, 0, 0, 0);
|
|
|
-INSERT INTO `OU` (`id`, `ou_name`, `default_users`, `default_hotspot`, `nagios_dir`, `nagios_host_use`, `nagios_ping`, `nagios_default_service`, `enabled`, `filter_group_id`, `queue_id`) VALUES(12, 'WiFi AP', 0, 0, 'ap', 'ap', 1, NULL, 0, 0, 0);
|
|
|
-INSERT INTO `OU` (`id`, `ou_name`, `default_users`, `default_hotspot`, `nagios_dir`, `nagios_host_use`, `nagios_ping`, `nagios_default_service`, `enabled`, `filter_group_id`, `queue_id`) VALUES(23, 'WiFi', 0, 0, NULL, NULL, 1, NULL, 1, 1, 4);
|
|
|
-INSERT INTO `OU` (`id`, `ou_name`, `default_users`, `default_hotspot`, `nagios_dir`, `nagios_host_use`, `nagios_ping`, `nagios_default_service`, `enabled`, `filter_group_id`, `queue_id`) VALUES(24, 'VPN', 0, 0, NULL, NULL, 1, NULL, 0, 0, 0);
|
|
|
-INSERT INTO `OU` (`id`, `ou_name`, `default_users`, `default_hotspot`, `nagios_dir`, `nagios_host_use`, `nagios_ping`, `nagios_default_service`, `enabled`, `filter_group_id`, `queue_id`) VALUES(27, 'DHCP', 1, 0, NULL, NULL, 1, NULL, 0, 0, 0);
|
|
|
-INSERT INTO `OU` (`id`, `ou_name`, `default_users`, `default_hotspot`, `nagios_dir`, `nagios_host_use`, `nagios_ping`, `nagios_default_service`, `enabled`, `filter_group_id`, `queue_id`) VALUES(28, 'Гости', 0, 0, NULL, NULL, 1, NULL, 0, 0, 0);
|
|
|
+INSERT INTO `OU` (`id`, `ou_name`, `comment`, `default_users`, `default_hotspot`, `nagios_dir`, `nagios_host_use`, `nagios_ping`, `nagios_default_service`, `enabled`, `filter_group_id`, `queue_id`) VALUES(0, '!Всё', NULL, 0, 0, '/etc/nagios/any', 'generic-host', 1, NULL, 0, 0, 0);
|
|
|
+INSERT INTO `OU` (`id`, `ou_name`, `comment`, `default_users`, `default_hotspot`, `nagios_dir`, `nagios_host_use`, `nagios_ping`, `nagios_default_service`, `enabled`, `filter_group_id`, `queue_id`) VALUES(1, 'Сервера', NULL, 0, 0, NULL, NULL, 1, NULL, 1, 1, 0);
|
|
|
+INSERT INTO `OU` (`id`, `ou_name`, `comment`, `default_users`, `default_hotspot`, `nagios_dir`, `nagios_host_use`, `nagios_ping`, `nagios_default_service`, `enabled`, `filter_group_id`, `queue_id`) VALUES(2, 'Администраторы', NULL, 0, 0, NULL, NULL, 1, NULL, 0, 0, 0);
|
|
|
+INSERT INTO `OU` (`id`, `ou_name`, `comment`, `default_users`, `default_hotspot`, `nagios_dir`, `nagios_host_use`, `nagios_ping`, `nagios_default_service`, `enabled`, `filter_group_id`, `queue_id`) VALUES(3, 'Пользователи', NULL, 0, 0, NULL, NULL, 1, NULL, 0, 0, 0);
|
|
|
+INSERT INTO `OU` (`id`, `ou_name`, `comment`, `default_users`, `default_hotspot`, `nagios_dir`, `nagios_host_use`, `nagios_ping`, `nagios_default_service`, `enabled`, `filter_group_id`, `queue_id`) VALUES(4, 'VOIP', NULL, 0, 0, 'voip', 'voip', 1, NULL, 1, 4, 5);
|
|
|
+INSERT INTO `OU` (`id`, `ou_name`, `comment`, `default_users`, `default_hotspot`, `nagios_dir`, `nagios_host_use`, `nagios_ping`, `nagios_default_service`, `enabled`, `filter_group_id`, `queue_id`) VALUES(5, 'IPCAM', NULL, 0, 0, 'videocam', 'ip-cam', 1, NULL, 0, 0, 0);
|
|
|
+INSERT INTO `OU` (`id`, `ou_name`, `comment`, `default_users`, `default_hotspot`, `nagios_dir`, `nagios_host_use`, `nagios_ping`, `nagios_default_service`, `enabled`, `filter_group_id`, `queue_id`) VALUES(6, 'Принтеры', NULL, 0, 0, 'printers', 'printers', 1, 'printer-service', 0, 0, 0);
|
|
|
+INSERT INTO `OU` (`id`, `ou_name`, `comment`, `default_users`, `default_hotspot`, `nagios_dir`, `nagios_host_use`, `nagios_ping`, `nagios_default_service`, `enabled`, `filter_group_id`, `queue_id`) VALUES(7, 'Свичи', NULL, 0, 0, 'switches', 'switches', 1, NULL, 0, 0, 0);
|
|
|
+INSERT INTO `OU` (`id`, `ou_name`, `comment`, `default_users`, `default_hotspot`, `nagios_dir`, `nagios_host_use`, `nagios_ping`, `nagios_default_service`, `enabled`, `filter_group_id`, `queue_id`) VALUES(8, 'UPS', NULL, 0, 0, 'ups', 'ups', 1, NULL, 0, 0, 0);
|
|
|
+INSERT INTO `OU` (`id`, `ou_name`, `comment`, `default_users`, `default_hotspot`, `nagios_dir`, `nagios_host_use`, `nagios_ping`, `nagios_default_service`, `enabled`, `filter_group_id`, `queue_id`) VALUES(9, 'Охрана', NULL, 0, 0, 'security', 'security', 1, NULL, 0, 0, 0);
|
|
|
+INSERT INTO `OU` (`id`, `ou_name`, `comment`, `default_users`, `default_hotspot`, `nagios_dir`, `nagios_host_use`, `nagios_ping`, `nagios_default_service`, `enabled`, `filter_group_id`, `queue_id`) VALUES(10, 'Роутеры', NULL, 0, 0, 'routers', 'routers', 1, NULL, 0, 0, 0);
|
|
|
+INSERT INTO `OU` (`id`, `ou_name`, `comment`, `default_users`, `default_hotspot`, `nagios_dir`, `nagios_host_use`, `nagios_ping`, `nagios_default_service`, `enabled`, `filter_group_id`, `queue_id`) VALUES(11, 'WiFi AP', NULL, 0, 0, 'ap', 'ap', 1, NULL, 0, 0, 0);
|
|
|
+INSERT INTO `OU` (`id`, `ou_name`, `comment`, `default_users`, `default_hotspot`, `nagios_dir`, `nagios_host_use`, `nagios_ping`, `nagios_default_service`, `enabled`, `filter_group_id`, `queue_id`) VALUES(12, 'WiFi', NULL, 0, 0, NULL, NULL, 1, NULL, 1, 1, 4);
|
|
|
+INSERT INTO `OU` (`id`, `ou_name`, `comment`, `default_users`, `default_hotspot`, `nagios_dir`, `nagios_host_use`, `nagios_ping`, `nagios_default_service`, `enabled`, `filter_group_id`, `queue_id`) VALUES(13, 'VPN', NULL, 0, 0, NULL, NULL, 1, NULL, 0, 0, 0);
|
|
|
+INSERT INTO `OU` (`id`, `ou_name`, `comment`, `default_users`, `default_hotspot`, `nagios_dir`, `nagios_host_use`, `nagios_ping`, `nagios_default_service`, `enabled`, `filter_group_id`, `queue_id`) VALUES(14, 'DHCP', NULL, 1, 0, NULL, NULL, 1, NULL, 0, 0, 0);
|
|
|
+INSERT INTO `OU` (`id`, `ou_name`, `comment`, `default_users`, `default_hotspot`, `nagios_dir`, `nagios_host_use`, `nagios_ping`, `nagios_default_service`, `enabled`, `filter_group_id`, `queue_id`) VALUES(15, 'Гости', NULL, 0, 0, NULL, NULL, 1, NULL, 1, 1, 4);
|
|
|
|
|
|
-- --------------------------------------------------------
|
|
|
|
|
|
@@ -607,7 +672,7 @@ INSERT INTO `OU` (`id`, `ou_name`, `default_users`, `default_hotspot`, `nagios_d
|
|
|
|
|
|
CREATE TABLE `Queue_list` (
|
|
|
`id` int(11) NOT NULL,
|
|
|
- `queue_name` varchar(20) COLLATE utf8mb4_unicode_ci NOT NULL,
|
|
|
+ `queue_name` varchar(20) NOT NULL,
|
|
|
`Download` int(11) NOT NULL DEFAULT 0,
|
|
|
`Upload` int(11) NOT NULL DEFAULT 0
|
|
|
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci;
|
|
|
@@ -635,8 +700,8 @@ CREATE TABLE `remote_syslog` (
|
|
|
`id` int(11) NOT NULL,
|
|
|
`date` timestamp NOT NULL DEFAULT current_timestamp(),
|
|
|
`device_id` int(11) NOT NULL,
|
|
|
- `ip` varchar(15) COLLATE utf8mb4_unicode_ci NOT NULL,
|
|
|
- `message` text COLLATE utf8mb4_unicode_ci NOT NULL
|
|
|
+ `ip` varchar(15) NOT NULL,
|
|
|
+ `message` text NOT NULL
|
|
|
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci;
|
|
|
|
|
|
-- --------------------------------------------------------
|
|
|
@@ -647,7 +712,7 @@ CREATE TABLE `remote_syslog` (
|
|
|
|
|
|
CREATE TABLE `subnets` (
|
|
|
`id` int(11) NOT NULL,
|
|
|
- `subnet` varchar(18) COLLATE utf8mb4_unicode_ci DEFAULT NULL,
|
|
|
+ `subnet` varchar(18) DEFAULT NULL,
|
|
|
`ip_int_start` bigint(20) NOT NULL,
|
|
|
`ip_int_stop` bigint(20) NOT NULL,
|
|
|
`dhcp_start` bigint(20) NOT NULL DEFAULT 0,
|
|
|
@@ -662,40 +727,14 @@ CREATE TABLE `subnets` (
|
|
|
`static` tinyint(1) NOT NULL DEFAULT 0,
|
|
|
`dhcp_update_hostname` tinyint(1) NOT NULL DEFAULT 0,
|
|
|
`discovery` tinyint(1) NOT NULL DEFAULT 1,
|
|
|
- `comment` varchar(250) COLLATE utf8mb4_unicode_ci DEFAULT NULL
|
|
|
+ `comment` varchar(250) DEFAULT NULL
|
|
|
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci;
|
|
|
|
|
|
--
|
|
|
-- Дамп данных таблицы `subnets`
|
|
|
--
|
|
|
|
|
|
-INSERT INTO `subnets` (`id`, `subnet`, `ip_int_start`, `ip_int_stop`, `dhcp_start`, `dhcp_stop`, `dhcp_lease_time`, `gateway`, `office`, `hotspot`, `vpn`, `free`, `dhcp`, `static`, `dhcp_update_hostname`, `discovery`, `comment`) VALUES(1, '192.168.2.0/24', 3232236032, 3232236287, 3232236132, 3232236182, 480, 3232236033, 1, 0, 0, 0, 1, 0, 0, 1, 'Сервера');
|
|
|
-INSERT INTO `subnets` (`id`, `subnet`, `ip_int_start`, `ip_int_stop`, `dhcp_start`, `dhcp_stop`, `dhcp_lease_time`, `gateway`, `office`, `hotspot`, `vpn`, `free`, `dhcp`, `static`, `dhcp_update_hostname`, `discovery`, `comment`) VALUES(2, '192.168.3.0/24', 3232236288, 3232236543, 3232236388, 3232236438, 480, 3232236289, 1, 0, 0, 0, 1, 0, 0, 1, 'Сотрудники, Можаевская');
|
|
|
-INSERT INTO `subnets` (`id`, `subnet`, `ip_int_start`, `ip_int_stop`, `dhcp_start`, `dhcp_stop`, `dhcp_lease_time`, `gateway`, `office`, `hotspot`, `vpn`, `free`, `dhcp`, `static`, `dhcp_update_hostname`, `discovery`, `comment`) VALUES(3, '192.168.5.0/24', 3232236800, 3232237055, 3232236900, 3232237000, 480, 3232236801, 1, 0, 0, 0, 1, 0, 0, 1, 'Сотрудники, Дзержинского');
|
|
|
-INSERT INTO `subnets` (`id`, `subnet`, `ip_int_start`, `ip_int_stop`, `dhcp_start`, `dhcp_stop`, `dhcp_lease_time`, `gateway`, `office`, `hotspot`, `vpn`, `free`, `dhcp`, `static`, `dhcp_update_hostname`, `discovery`, `comment`) VALUES(4, '192.168.8.0/24', 3232237568, 3232237823, 3232237668, 3232237718, 480, 3232237569, 1, 0, 0, 0, 1, 0, 0, 1, 'Удалёнщики - прямой линк');
|
|
|
-INSERT INTO `subnets` (`id`, `subnet`, `ip_int_start`, `ip_int_stop`, `dhcp_start`, `dhcp_stop`, `dhcp_lease_time`, `gateway`, `office`, `hotspot`, `vpn`, `free`, `dhcp`, `static`, `dhcp_update_hostname`, `discovery`, `comment`) VALUES(5, '192.168.9.0/24', 3232237824, 3232238079, 3232237924, 3232238024, 480, 3232237825, 1, 0, 0, 0, 1, 0, 0, 1, 'Литовская, сотрудники');
|
|
|
-INSERT INTO `subnets` (`id`, `subnet`, `ip_int_start`, `ip_int_stop`, `dhcp_start`, `dhcp_stop`, `dhcp_lease_time`, `gateway`, `office`, `hotspot`, `vpn`, `free`, `dhcp`, `static`, `dhcp_update_hostname`, `discovery`, `comment`) VALUES(6, '192.168.13.0/24', 3232238848, 3232239103, 3232238911, 3232239039, 480, 3232238849, 1, 0, 0, 0, 1, 0, 0, 1, 'Облако');
|
|
|
-INSERT INTO `subnets` (`id`, `subnet`, `ip_int_start`, `ip_int_stop`, `dhcp_start`, `dhcp_stop`, `dhcp_lease_time`, `gateway`, `office`, `hotspot`, `vpn`, `free`, `dhcp`, `static`, `dhcp_update_hostname`, `discovery`, `comment`) VALUES(7, '192.168.12.0/24', 3232238592, 3232238847, 3232238602, 3232238846, 480, 3232238593, 1, 0, 0, 0, 1, 0, 0, 1, 'Управление, Дзержинского');
|
|
|
-INSERT INTO `subnets` (`id`, `subnet`, `ip_int_start`, `ip_int_stop`, `dhcp_start`, `dhcp_stop`, `dhcp_lease_time`, `gateway`, `office`, `hotspot`, `vpn`, `free`, `dhcp`, `static`, `dhcp_update_hostname`, `discovery`, `comment`) VALUES(8, '192.168.22.0/24', 3232241152, 3232241407, 3232241162, 3232241406, 480, 3232241153, 1, 0, 0, 0, 1, 0, 0, 1, 'Управление, Литовская');
|
|
|
-INSERT INTO `subnets` (`id`, `subnet`, `ip_int_start`, `ip_int_stop`, `dhcp_start`, `dhcp_stop`, `dhcp_lease_time`, `gateway`, `office`, `hotspot`, `vpn`, `free`, `dhcp`, `static`, `dhcp_update_hostname`, `discovery`, `comment`) VALUES(9, '192.168.32.0/24', 3232243712, 3232243967, 3232243722, 3232243966, 480, 3232243713, 1, 0, 0, 0, 1, 0, 0, 1, 'Управление, Можаевская');
|
|
|
-INSERT INTO `subnets` (`id`, `subnet`, `ip_int_start`, `ip_int_stop`, `dhcp_start`, `dhcp_stop`, `dhcp_lease_time`, `gateway`, `office`, `hotspot`, `vpn`, `free`, `dhcp`, `static`, `dhcp_update_hostname`, `discovery`, `comment`) VALUES(10, '10.160.0.0/24', 178257920, 178258175, 178258020, 178258070, 1440, 178257921, 1, 0, 0, 0, 1, 0, 0, 1, 'Жуково');
|
|
|
-INSERT INTO `subnets` (`id`, `subnet`, `ip_int_start`, `ip_int_stop`, `dhcp_start`, `dhcp_stop`, `dhcp_lease_time`, `gateway`, `office`, `hotspot`, `vpn`, `free`, `dhcp`, `static`, `dhcp_update_hostname`, `discovery`, `comment`) VALUES(11, '192.168.0.0/16', 3232235520, 3232301055, 0, 0, 480, 0, 0, 0, 0, 1, 0, 0, 0, 0, 'Не считать трафик');
|
|
|
-INSERT INTO `subnets` (`id`, `subnet`, `ip_int_start`, `ip_int_stop`, `dhcp_start`, `dhcp_stop`, `dhcp_lease_time`, `gateway`, `office`, `hotspot`, `vpn`, `free`, `dhcp`, `static`, `dhcp_update_hostname`, `discovery`, `comment`) VALUES(12, '10.0.0.0/8', 167772160, 184549375, 0, 0, 480, 0, 0, 0, 0, 0, 0, 0, 0, 0, 'Не считать трафик');
|
|
|
-INSERT INTO `subnets` (`id`, `subnet`, `ip_int_start`, `ip_int_stop`, `dhcp_start`, `dhcp_stop`, `dhcp_lease_time`, `gateway`, `office`, `hotspot`, `vpn`, `free`, `dhcp`, `static`, `dhcp_update_hostname`, `discovery`, `comment`) VALUES(13, '172.16.0.0/12', 2886729728, 2887778303, 0, 0, 480, 0, 0, 0, 0, 0, 0, 0, 0, 0, 'Не считать трафик');
|
|
|
-INSERT INTO `subnets` (`id`, `subnet`, `ip_int_start`, `ip_int_stop`, `dhcp_start`, `dhcp_stop`, `dhcp_lease_time`, `gateway`, `office`, `hotspot`, `vpn`, `free`, `dhcp`, `static`, `dhcp_update_hostname`, `discovery`, `comment`) VALUES(14, '192.168.40.0/24', 3232245760, 3232246015, 3232245762, 3232245960, 480, 3232245761, 1, 0, 0, 0, 1, 0, 0, 1, 'WiFI, Можаевская');
|
|
|
-INSERT INTO `subnets` (`id`, `subnet`, `ip_int_start`, `ip_int_stop`, `dhcp_start`, `dhcp_stop`, `dhcp_lease_time`, `gateway`, `office`, `hotspot`, `vpn`, `free`, `dhcp`, `static`, `dhcp_update_hostname`, `discovery`, `comment`) VALUES(15, '192.168.200.0/24', 3232286720, 3232286975, 3232286783, 3232286911, 480, 3232286721, 1, 0, 0, 0, 0, 0, 0, 1, 'Транспорт - оптика');
|
|
|
-INSERT INTO `subnets` (`id`, `subnet`, `ip_int_start`, `ip_int_stop`, `dhcp_start`, `dhcp_stop`, `dhcp_lease_time`, `gateway`, `office`, `hotspot`, `vpn`, `free`, `dhcp`, `static`, `dhcp_update_hostname`, `discovery`, `comment`) VALUES(16, '192.168.201.0/24', 3232286976, 3232287231, 3232287039, 3232287167, 480, 3232286977, 1, 0, 1, 0, 0, 0, 0, 0, 'Транспорт - туннели');
|
|
|
-INSERT INTO `subnets` (`id`, `subnet`, `ip_int_start`, `ip_int_stop`, `dhcp_start`, `dhcp_stop`, `dhcp_lease_time`, `gateway`, `office`, `hotspot`, `vpn`, `free`, `dhcp`, `static`, `dhcp_update_hostname`, `discovery`, `comment`) VALUES(17, '10.111.4.0/24', 175047680, 175047935, 175047743, 175047871, 480, 175047681, 1, 0, 0, 0, 0, 0, 0, 1, 'Мультиплексоры');
|
|
|
-INSERT INTO `subnets` (`id`, `subnet`, `ip_int_start`, `ip_int_stop`, `dhcp_start`, `dhcp_stop`, `dhcp_lease_time`, `gateway`, `office`, `hotspot`, `vpn`, `free`, `dhcp`, `static`, `dhcp_update_hostname`, `discovery`, `comment`) VALUES(18, '10.1.7.0/24', 167839488, 167839743, 167839551, 167839679, 480, 167839489, 1, 0, 1, 0, 0, 0, 0, 0, 'l2tp vpn');
|
|
|
-INSERT INTO `subnets` (`id`, `subnet`, `ip_int_start`, `ip_int_stop`, `dhcp_start`, `dhcp_stop`, `dhcp_lease_time`, `gateway`, `office`, `hotspot`, `vpn`, `free`, `dhcp`, `static`, `dhcp_update_hostname`, `discovery`, `comment`) VALUES(19, '10.1.3.0/24', 167838464, 167838719, 167838527, 167838655, 480, 167838465, 1, 0, 1, 0, 0, 0, 0, 0, 'gre vpn');
|
|
|
-INSERT INTO `subnets` (`id`, `subnet`, `ip_int_start`, `ip_int_stop`, `dhcp_start`, `dhcp_stop`, `dhcp_lease_time`, `gateway`, `office`, `hotspot`, `vpn`, `free`, `dhcp`, `static`, `dhcp_update_hostname`, `discovery`, `comment`) VALUES(20, '10.5.1.0/24', 168100096, 168100351, 168100159, 168100287, 480, 168100097, 1, 0, 1, 0, 0, 0, 0, 0, 'openvpn');
|
|
|
-INSERT INTO `subnets` (`id`, `subnet`, `ip_int_start`, `ip_int_stop`, `dhcp_start`, `dhcp_stop`, `dhcp_lease_time`, `gateway`, `office`, `hotspot`, `vpn`, `free`, `dhcp`, `static`, `dhcp_update_hostname`, `discovery`, `comment`) VALUES(21, '10.5.2.0/24', 168100352, 168100607, 168100415, 168100543, 480, 168100353, 1, 0, 1, 0, 0, 0, 0, 0, 'new openvpn');
|
|
|
-INSERT INTO `subnets` (`id`, `subnet`, `ip_int_start`, `ip_int_stop`, `dhcp_start`, `dhcp_stop`, `dhcp_lease_time`, `gateway`, `office`, `hotspot`, `vpn`, `free`, `dhcp`, `static`, `dhcp_update_hostname`, `discovery`, `comment`) VALUES(22, '192.168.42.0/24', 3232246272, 3232246527, 3232246472, 3232246526, 1440, 3232246273, 1, 0, 0, 0, 1, 0, 0, 1, 'Управление, Жуково');
|
|
|
-INSERT INTO `subnets` (`id`, `subnet`, `ip_int_start`, `ip_int_stop`, `dhcp_start`, `dhcp_stop`, `dhcp_lease_time`, `gateway`, `office`, `hotspot`, `vpn`, `free`, `dhcp`, `static`, `dhcp_update_hostname`, `discovery`, `comment`) VALUES(23, '192.168.50.0/24', 3232248320, 3232248575, 3232248330, 3232248574, 480, 3232248321, 1, 0, 0, 0, 1, 0, 0, 1, 'Гудков, Дом');
|
|
|
-INSERT INTO `subnets` (`id`, `subnet`, `ip_int_start`, `ip_int_stop`, `dhcp_start`, `dhcp_stop`, `dhcp_lease_time`, `gateway`, `office`, `hotspot`, `vpn`, `free`, `dhcp`, `static`, `dhcp_update_hostname`, `discovery`, `comment`) VALUES(24, '192.168.41.0/24', 3232246016, 3232246271, 3232246079, 3232246207, 480, 3232246017, 1, 0, 0, 0, 1, 0, 0, 1, 'WiFi, Дзержинского84');
|
|
|
-INSERT INTO `subnets` (`id`, `subnet`, `ip_int_start`, `ip_int_stop`, `dhcp_start`, `dhcp_stop`, `dhcp_lease_time`, `gateway`, `office`, `hotspot`, `vpn`, `free`, `dhcp`, `static`, `dhcp_update_hostname`, `discovery`, `comment`) VALUES(25, '192.168.15.0/24', 3232239360, 3232239615, 3232239423, 3232239551, 480, 3232239361, 1, 0, 0, 0, 1, 0, 0, 1, 'Жуково - оборудование');
|
|
|
-INSERT INTO `subnets` (`id`, `subnet`, `ip_int_start`, `ip_int_stop`, `dhcp_start`, `dhcp_stop`, `dhcp_lease_time`, `gateway`, `office`, `hotspot`, `vpn`, `free`, `dhcp`, `static`, `dhcp_update_hostname`, `discovery`, `comment`) VALUES(26, '192.168.45.0/24', 3232247040, 3232247295, 3232247103, 3232247231, 480, 3232247041, 1, 0, 0, 0, 1, 0, 0, 1, 'Ceph test cluster');
|
|
|
-INSERT INTO `subnets` (`id`, `subnet`, `ip_int_start`, `ip_int_stop`, `dhcp_start`, `dhcp_stop`, `dhcp_lease_time`, `gateway`, `office`, `hotspot`, `vpn`, `free`, `dhcp`, `static`, `dhcp_update_hostname`, `discovery`, `comment`) VALUES(27, '192.168.205.0/24', 3232288000, 3232288255, 3232288002, 3232288254, 480, 3232288001, 1, 0, 0, 0, 1, 0, 0, 1, 'Гости');
|
|
|
+INSERT INTO `subnets` (`id`, `subnet`, `ip_int_start`, `ip_int_stop`, `dhcp_start`, `dhcp_stop`, `dhcp_lease_time`, `gateway`, `office`, `hotspot`, `vpn`, `free`, `dhcp`, `static`, `dhcp_update_hostname`, `discovery`, `comment`) VALUES(1, '192.168.120.0/24', 3232266240, 3232266495, 3232266303, 3232266431, 480, 3232266241, 1, 0, 0, 0, 1, 0, 0, 1, 'Office network');
|
|
|
|
|
|
-- --------------------------------------------------------
|
|
|
|
|
|
@@ -707,11 +746,37 @@ CREATE TABLE `syslog` (
|
|
|
`id` int(11) UNSIGNED NOT NULL,
|
|
|
`timestamp` timestamp NOT NULL DEFAULT current_timestamp(),
|
|
|
`auth_id` int(11) NOT NULL DEFAULT 0,
|
|
|
- `customer` varchar(50) COLLATE utf8mb4_unicode_ci NOT NULL DEFAULT 'system',
|
|
|
- `message` text COLLATE utf8mb4_unicode_ci NOT NULL,
|
|
|
+ `customer` varchar(50) NOT NULL DEFAULT 'system',
|
|
|
+ `message` text NOT NULL,
|
|
|
`level` int(11) NOT NULL DEFAULT 1
|
|
|
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci;
|
|
|
|
|
|
+--
|
|
|
+-- Дамп данных таблицы `syslog`
|
|
|
+--
|
|
|
+
|
|
|
+INSERT INTO `syslog` (`id`, `timestamp`, `auth_id`, `customer`, `message`, `level`) VALUES(1, '2023-03-04 19:55:16', 0, 'admin', 'Добавлен параметр id: 19 name: arp discavery = 1', 2);
|
|
|
+INSERT INTO `syslog` (`id`, `timestamp`, `auth_id`, `customer`, `message`, `level`) VALUES(2, '2023-03-04 19:55:23', 0, 'admin', 'Добавлен параметр id: 35 name: connections history, days = 90', 2);
|
|
|
+INSERT INTO `syslog` (`id`, `timestamp`, `auth_id`, `customer`, `message`, `level`) VALUES(3, '2023-03-04 19:55:38', 0, 'admin', 'Изменён параметр id: 124 name: connections history, days = 120', 2);
|
|
|
+INSERT INTO `syslog` (`id`, `timestamp`, `auth_id`, `customer`, `message`, `level`) VALUES(4, '2023-03-04 19:55:44', 0, 'admin', 'Добавлен параметр id: 9 name: default snmp version = 2', 2);
|
|
|
+INSERT INTO `syslog` (`id`, `timestamp`, `auth_id`, `customer`, `message`, `level`) VALUES(5, '2023-03-04 19:55:52', 0, 'admin', 'Добавлен параметр id: 41 name: discavery network = /usr/local/scripts/fetch_new_arp.pl', 2);
|
|
|
+INSERT INTO `syslog` (`id`, `timestamp`, `auth_id`, `customer`, `message`, `level`) VALUES(6, '2023-03-04 19:56:03', 0, 'admin', 'Добавлен параметр id: 26 name: history detail traffic = 3', 2);
|
|
|
+INSERT INTO `syslog` (`id`, `timestamp`, `auth_id`, `customer`, `message`, `level`) VALUES(7, '2023-03-04 19:56:13', 0, 'admin', 'Добавлен параметр id: 27 name: history dhcp lease = 1', 2);
|
|
|
+INSERT INTO `syslog` (`id`, `timestamp`, `auth_id`, `customer`, `message`, `level`) VALUES(8, '2023-03-04 19:56:24', 0, 'admin', 'Изменён параметр id: 128 name: history dhcp lease = 10', 2);
|
|
|
+INSERT INTO `syslog` (`id`, `timestamp`, `auth_id`, `customer`, `message`, `level`) VALUES(9, '2023-03-04 19:56:32', 0, 'admin', 'Добавлен параметр id: 48 name: history syslog = 90', 2);
|
|
|
+INSERT INTO `syslog` (`id`, `timestamp`, `auth_id`, `customer`, `message`, `level`) VALUES(10, '2023-03-04 19:56:49', 0, 'admin', 'Добавлен параметр id: 49 name: history traffic stats = 365', 2);
|
|
|
+INSERT INTO `syslog` (`id`, `timestamp`, `auth_id`, `customer`, `message`, `level`) VALUES(11, '2023-03-04 19:57:10', 0, 'admin', 'Добавлен параметр id: 47 name: history worklog = 90', 2);
|
|
|
+INSERT INTO `syslog` (`id`, `timestamp`, `auth_id`, `customer`, `message`, `level`) VALUES(12, '2023-03-04 19:57:26', 0, 'admin', 'Изменён параметр id: 131 name: history worklog = 365', 2);
|
|
|
+INSERT INTO `syslog` (`id`, `timestamp`, `auth_id`, `customer`, `message`, `level`) VALUES(13, '2023-03-04 19:57:32', 0, 'admin', 'Добавлен параметр id: 53 name: log level = 2', 2);
|
|
|
+INSERT INTO `syslog` (`id`, `timestamp`, `auth_id`, `customer`, `message`, `level`) VALUES(14, '2023-03-04 19:57:40', 0, 'admin', 'Добавлен параметр id: 55 name: netflow_step = 10', 2);
|
|
|
+INSERT INTO `syslog` (`id`, `timestamp`, `auth_id`, `customer`, `message`, `level`) VALUES(15, '2023-03-04 19:58:09', 0, 'admin', 'Добавлен параметр id: 56 name: traffic_ipstat_history = 30', 2);
|
|
|
+INSERT INTO `syslog` (`id`, `timestamp`, `auth_id`, `customer`, `message`, `level`) VALUES(16, '2023-03-04 21:06:40', 0, 'admin', 'Create new subnet 192.168.0.0/24', 2);
|
|
|
+INSERT INTO `syslog` (`id`, `timestamp`, `auth_id`, `customer`, `message`, `level`) VALUES(17, '2023-03-04 21:08:04', 0, 'admin', 'Создан новый пользователь: Login => User1', 1);
|
|
|
+INSERT INTO `syslog` (`id`, `timestamp`, `auth_id`, `customer`, `message`, `level`) VALUES(18, '2023-03-04 21:08:10', 0, 'admin', 'Изменён пользователь id: 1 login: User1. \r\nПрименено: \r\n filter_group_id => cur: 1 old: 0,\r\n\r\n Не изменялось:\r\n login = User1,\r\n enabled = 1,\r\n ou_id = 3,\r\n filter_group_id = 0', 1);
|
|
|
+INSERT INTO `syslog` (`id`, `timestamp`, `auth_id`, `customer`, `message`, `level`) VALUES(19, '2023-03-04 21:08:19', 0, 'admin', 'Создаём новый ip-адрес \r\nip: 192.168.120.30\r\nmac: \r\n', 1);
|
|
|
+INSERT INTO `syslog` (`id`, `timestamp`, `auth_id`, `customer`, `message`, `level`) VALUES(20, '2023-03-04 21:08:19', 1, 'admin', 'Создан новый адрес доступа для login: User1: ip => 192.168.120.30, mac => ', 1);
|
|
|
+INSERT INTO `syslog` (`id`, `timestamp`, `auth_id`, `customer`, `message`, `level`) VALUES(21, '2023-03-04 21:08:27', 1, 'admin', 'Изменена запись для адреса 192.168.120.30! Список изменений: \r\n comments => cur: User1 old: ,\r\n nagios_status => cur: UP old: ,\r\n\r\n Не изменялось:\r\n ou_id = 3,\r\n ip = 192.168.120.30,\r\n ip_int = 3232266270,\r\n save_traf = 1,\r\n enabled = 1,\r\n dhcp = 1,\r\n filter_group_id = 1,\r\n comments = ,\r\n nagios_status = ', 1);
|
|
|
+
|
|
|
-- --------------------------------------------------------
|
|
|
|
|
|
--
|
|
|
@@ -740,7 +805,7 @@ CREATE TABLE `Traffic_detail` (
|
|
|
|
|
|
CREATE TABLE `Unknown_mac` (
|
|
|
`id` int(11) NOT NULL,
|
|
|
- `mac` varchar(12) COLLATE utf8mb4_unicode_ci DEFAULT NULL,
|
|
|
+ `mac` varchar(12) DEFAULT NULL,
|
|
|
`port_id` int(11) DEFAULT NULL,
|
|
|
`device_id` int(11) DEFAULT NULL,
|
|
|
`timestamp` timestamp NOT NULL DEFAULT current_timestamp() ON UPDATE current_timestamp()
|
|
|
@@ -756,38 +821,44 @@ CREATE TABLE `User_auth` (
|
|
|
`id` int(11) NOT NULL,
|
|
|
`user_id` int(11) NOT NULL DEFAULT 0,
|
|
|
`ou_id` int(11) DEFAULT NULL,
|
|
|
- `ip` varchar(18) COLLATE utf8mb4_unicode_ci NOT NULL DEFAULT '',
|
|
|
+ `ip` varchar(18) NOT NULL DEFAULT '',
|
|
|
`ip_int` int(10) UNSIGNED NOT NULL DEFAULT 0,
|
|
|
`save_traf` tinyint(1) NOT NULL DEFAULT 0,
|
|
|
`enabled` tinyint(1) NOT NULL DEFAULT 0,
|
|
|
`dhcp` tinyint(1) NOT NULL DEFAULT 1,
|
|
|
`filter_group_id` tinyint(1) NOT NULL DEFAULT 0,
|
|
|
`deleted` tinyint(4) NOT NULL DEFAULT 0,
|
|
|
- `comments` varchar(250) COLLATE utf8mb4_unicode_ci DEFAULT NULL,
|
|
|
- `dns_name` varchar(60) COLLATE utf8mb4_unicode_ci NOT NULL DEFAULT '',
|
|
|
- `WikiName` varchar(250) COLLATE utf8mb4_unicode_ci DEFAULT NULL,
|
|
|
- `dhcp_acl` text COLLATE utf8mb4_unicode_ci DEFAULT NULL,
|
|
|
+ `comments` varchar(250) DEFAULT NULL,
|
|
|
+ `dns_name` varchar(60) NOT NULL DEFAULT '',
|
|
|
+ `WikiName` varchar(250) DEFAULT NULL,
|
|
|
+ `dhcp_acl` text DEFAULT NULL,
|
|
|
`queue_id` int(11) NOT NULL DEFAULT 0,
|
|
|
- `mac` varchar(20) COLLATE utf8mb4_unicode_ci NOT NULL DEFAULT '',
|
|
|
- `dhcp_action` varchar(10) COLLATE utf8mb4_unicode_ci NOT NULL DEFAULT '',
|
|
|
+ `mac` varchar(20) NOT NULL DEFAULT '',
|
|
|
+ `dhcp_action` varchar(10) NOT NULL DEFAULT '',
|
|
|
`dhcp_time` datetime NOT NULL DEFAULT current_timestamp(),
|
|
|
- `dhcp_hostname` varchar(60) COLLATE utf8mb4_unicode_ci DEFAULT NULL,
|
|
|
+ `dhcp_hostname` varchar(60) DEFAULT NULL,
|
|
|
`last_found` datetime NOT NULL DEFAULT current_timestamp(),
|
|
|
`blocked` tinyint(1) NOT NULL DEFAULT 0,
|
|
|
`day_quota` int(11) NOT NULL DEFAULT 0,
|
|
|
`month_quota` int(11) NOT NULL DEFAULT 0,
|
|
|
`device_model_id` int(11) DEFAULT 87,
|
|
|
- `firmware` varchar(100) COLLATE utf8mb4_unicode_ci DEFAULT NULL,
|
|
|
+ `firmware` varchar(100) DEFAULT NULL,
|
|
|
`timestamp` timestamp NOT NULL DEFAULT current_timestamp(),
|
|
|
- `clientid` varchar(50) COLLATE utf8mb4_unicode_ci NOT NULL DEFAULT '',
|
|
|
+ `clientid` varchar(50) NOT NULL DEFAULT '',
|
|
|
`nagios` tinyint(1) NOT NULL DEFAULT 0,
|
|
|
- `nagios_status` varchar(10) COLLATE utf8mb4_unicode_ci NOT NULL DEFAULT '',
|
|
|
- `nagios_handler` varchar(50) COLLATE utf8mb4_unicode_ci NOT NULL DEFAULT '',
|
|
|
+ `nagios_status` varchar(10) NOT NULL DEFAULT '',
|
|
|
+ `nagios_handler` varchar(50) NOT NULL DEFAULT '',
|
|
|
`link_check` tinyint(1) NOT NULL DEFAULT 0,
|
|
|
`changed` tinyint(1) NOT NULL DEFAULT 0,
|
|
|
`changed_time` datetime NOT NULL DEFAULT current_timestamp()
|
|
|
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci;
|
|
|
|
|
|
+--
|
|
|
+-- Дамп данных таблицы `User_auth`
|
|
|
+--
|
|
|
+
|
|
|
+INSERT INTO `User_auth` (`id`, `user_id`, `ou_id`, `ip`, `ip_int`, `save_traf`, `enabled`, `dhcp`, `filter_group_id`, `deleted`, `comments`, `dns_name`, `WikiName`, `dhcp_acl`, `queue_id`, `mac`, `dhcp_action`, `dhcp_time`, `dhcp_hostname`, `last_found`, `blocked`, `day_quota`, `month_quota`, `device_model_id`, `firmware`, `timestamp`, `clientid`, `nagios`, `nagios_status`, `nagios_handler`, `link_check`, `changed`, `changed_time`) VALUES(1, 1, 3, '192.168.120.30', 3232266270, 1, 1, 1, 1, 0, 'User1', '', NULL, NULL, 0, '', '', '2023-03-05 00:08:19', NULL, '2023-03-05 00:08:19', 0, 0, 0, 87, NULL, '2023-03-04 21:08:19', '', 0, 'UP', '', 0, 1, '2023-03-05 00:08:27');
|
|
|
+
|
|
|
-- --------------------------------------------------------
|
|
|
|
|
|
--
|
|
|
@@ -797,8 +868,8 @@ CREATE TABLE `User_auth` (
|
|
|
CREATE TABLE `User_auth_alias` (
|
|
|
`id` int(11) NOT NULL,
|
|
|
`auth_id` int(11) NOT NULL,
|
|
|
- `alias` varchar(100) COLLATE utf8mb4_unicode_ci DEFAULT NULL,
|
|
|
- `description` varchar(100) COLLATE utf8mb4_unicode_ci DEFAULT NULL,
|
|
|
+ `alias` varchar(100) DEFAULT NULL,
|
|
|
+ `description` varchar(100) DEFAULT NULL,
|
|
|
`timestamp` timestamp NOT NULL DEFAULT current_timestamp()
|
|
|
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci;
|
|
|
|
|
|
@@ -811,8 +882,8 @@ CREATE TABLE `User_auth_alias` (
|
|
|
CREATE TABLE `User_list` (
|
|
|
`id` int(10) UNSIGNED NOT NULL,
|
|
|
`timestamp` timestamp NOT NULL DEFAULT current_timestamp(),
|
|
|
- `login` varchar(40) COLLATE utf8mb4_unicode_ci NOT NULL DEFAULT '',
|
|
|
- `fio` varchar(60) COLLATE utf8mb4_unicode_ci NOT NULL DEFAULT '',
|
|
|
+ `login` varchar(255) DEFAULT NULL,
|
|
|
+ `fio` varchar(255) DEFAULT NULL,
|
|
|
`enabled` tinyint(1) NOT NULL DEFAULT 1,
|
|
|
`blocked` tinyint(1) NOT NULL DEFAULT 0,
|
|
|
`deleted` tinyint(1) NOT NULL DEFAULT 0,
|
|
|
@@ -824,6 +895,12 @@ CREATE TABLE `User_list` (
|
|
|
`month_quota` int(11) NOT NULL DEFAULT 0
|
|
|
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci;
|
|
|
|
|
|
+--
|
|
|
+-- Дамп данных таблицы `User_list`
|
|
|
+--
|
|
|
+
|
|
|
+INSERT INTO `User_list` (`id`, `timestamp`, `login`, `fio`, `enabled`, `blocked`, `deleted`, `ou_id`, `device_id`, `filter_group_id`, `queue_id`, `day_quota`, `month_quota`) VALUES(1, '2023-03-04 21:08:04', 'User1', NULL, 1, 0, 0, 3, NULL, 1, 0, 0, 0);
|
|
|
+
|
|
|
-- --------------------------------------------------------
|
|
|
|
|
|
--
|
|
|
@@ -865,8 +942,8 @@ CREATE TABLE `User_stats_full` (
|
|
|
|
|
|
CREATE TABLE `variables` (
|
|
|
`id` int(11) NOT NULL,
|
|
|
- `name` varchar(30) COLLATE utf8mb4_unicode_ci NOT NULL,
|
|
|
- `value` varchar(255) COLLATE utf8mb4_unicode_ci DEFAULT NULL,
|
|
|
+ `name` varchar(30) NOT NULL,
|
|
|
+ `value` varchar(255) DEFAULT NULL,
|
|
|
`clear_time` timestamp NOT NULL DEFAULT current_timestamp(),
|
|
|
`created` timestamp NOT NULL DEFAULT current_timestamp()
|
|
|
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci;
|
|
|
@@ -879,7 +956,7 @@ CREATE TABLE `variables` (
|
|
|
|
|
|
CREATE TABLE `vendors` (
|
|
|
`id` int(11) NOT NULL,
|
|
|
- `name` varchar(40) COLLATE utf8mb4_unicode_ci NOT NULL
|
|
|
+ `name` varchar(40) NOT NULL
|
|
|
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci;
|
|
|
|
|
|
--
|
|
|
@@ -930,6 +1007,8 @@ INSERT INTO `vendors` (`id`, `name`) VALUES(55, 'AddPac');
|
|
|
INSERT INTO `vendors` (`id`, `name`) VALUES(56, 'Devline');
|
|
|
INSERT INTO `vendors` (`id`, `name`) VALUES(57, 'Canon');
|
|
|
INSERT INTO `vendors` (`id`, `name`) VALUES(58, 'Brother');
|
|
|
+INSERT INTO `vendors` (`id`, `name`) VALUES(59, 'Epson');
|
|
|
+INSERT INTO `vendors` (`id`, `name`) VALUES(60, 'IP-COM');
|
|
|
|
|
|
--
|
|
|
-- Индексы сохранённых таблиц
|
|
|
@@ -1053,12 +1132,16 @@ ALTER TABLE `mac_history`
|
|
|
ADD PRIMARY KEY (`id`),
|
|
|
ADD KEY `mac` (`mac`,`timestamp`),
|
|
|
ADD KEY `ip` (`ip`,`timestamp`),
|
|
|
- ADD KEY `timestamp` (`timestamp`,`mac`),
|
|
|
- ADD KEY `timestamp_2` (`timestamp`,`ip`);
|
|
|
-
|
|
|
+ ADD KEY `timestamp` (`timestamp`) USING BTREE,
|
|
|
+ ADD KEY `mac_2` (`mac`),
|
|
|
+ ADD KEY `ip_2` (`ip`);
|
|
|
|
|
|
-ALTER TABLE `mac_vendors` ADD PRIMARY KEY (`id`), ADD KEY `oui` (`oui`);
|
|
|
-ALTER TABLE `mac_vendors` MODIFY `id` int(11) NOT NULL AUTO_INCREMENT;
|
|
|
+--
|
|
|
+-- Индексы таблицы `mac_vendors`
|
|
|
+--
|
|
|
+ALTER TABLE `mac_vendors`
|
|
|
+ ADD PRIMARY KEY (`id`),
|
|
|
+ ADD KEY `oui` (`oui`);
|
|
|
|
|
|
--
|
|
|
-- Индексы таблицы `OU`
|
|
|
@@ -1094,7 +1177,10 @@ ALTER TABLE `subnets`
|
|
|
--
|
|
|
ALTER TABLE `syslog`
|
|
|
ADD PRIMARY KEY (`id`),
|
|
|
- ADD KEY `timestamp_2` (`timestamp`,`level`,`customer`) USING BTREE;
|
|
|
+ ADD KEY `timestamp` (`timestamp`) USING BTREE,
|
|
|
+ ADD KEY `level` (`level`),
|
|
|
+ ADD KEY `auth_id` (`auth_id`);
|
|
|
+ALTER TABLE `syslog` ADD FULLTEXT KEY `customer` (`customer`);
|
|
|
|
|
|
--
|
|
|
-- Индексы таблицы `Traffic_detail`
|
|
|
@@ -1182,7 +1268,7 @@ ALTER TABLE `building`
|
|
|
-- AUTO_INCREMENT для таблицы `config`
|
|
|
--
|
|
|
ALTER TABLE `config`
|
|
|
- MODIFY `id` int(11) NOT NULL AUTO_INCREMENT, AUTO_INCREMENT=119;
|
|
|
+ MODIFY `id` int(11) NOT NULL AUTO_INCREMENT, AUTO_INCREMENT=135;
|
|
|
|
|
|
--
|
|
|
-- AUTO_INCREMENT для таблицы `config_options`
|
|
|
@@ -1200,7 +1286,7 @@ ALTER TABLE `connections`
|
|
|
-- AUTO_INCREMENT для таблицы `Customers`
|
|
|
--
|
|
|
ALTER TABLE `Customers`
|
|
|
- MODIFY `id` int(11) NOT NULL AUTO_INCREMENT, AUTO_INCREMENT=10;
|
|
|
+ MODIFY `id` int(11) NOT NULL AUTO_INCREMENT, AUTO_INCREMENT=11;
|
|
|
|
|
|
--
|
|
|
-- AUTO_INCREMENT для таблицы `devices`
|
|
|
@@ -1248,13 +1334,13 @@ ALTER TABLE `dns_cache`
|
|
|
-- AUTO_INCREMENT для таблицы `Filter_list`
|
|
|
--
|
|
|
ALTER TABLE `Filter_list`
|
|
|
- MODIFY `id` int(11) NOT NULL AUTO_INCREMENT, AUTO_INCREMENT=105;
|
|
|
+ MODIFY `id` int(11) NOT NULL AUTO_INCREMENT, AUTO_INCREMENT=110;
|
|
|
|
|
|
--
|
|
|
-- AUTO_INCREMENT для таблицы `Group_filters`
|
|
|
--
|
|
|
ALTER TABLE `Group_filters`
|
|
|
- MODIFY `id` int(11) NOT NULL AUTO_INCREMENT, AUTO_INCREMENT=220;
|
|
|
+ MODIFY `id` int(11) NOT NULL AUTO_INCREMENT, AUTO_INCREMENT=227;
|
|
|
|
|
|
--
|
|
|
-- AUTO_INCREMENT для таблицы `Group_list`
|
|
|
@@ -1269,6 +1355,11 @@ ALTER TABLE `mac_history`
|
|
|
MODIFY `id` int(10) UNSIGNED NOT NULL AUTO_INCREMENT;
|
|
|
|
|
|
--
|
|
|
+-- AUTO_INCREMENT для таблицы `mac_vendors`
|
|
|
+--
|
|
|
+ALTER TABLE `mac_vendors`
|
|
|
+ MODIFY `id` int(11) NOT NULL AUTO_INCREMENT;
|
|
|
+
|
|
|
--
|
|
|
-- AUTO_INCREMENT для таблицы `OU`
|
|
|
--
|
|
|
@@ -1291,13 +1382,13 @@ ALTER TABLE `remote_syslog`
|
|
|
-- AUTO_INCREMENT для таблицы `subnets`
|
|
|
--
|
|
|
ALTER TABLE `subnets`
|
|
|
- MODIFY `id` int(11) NOT NULL AUTO_INCREMENT, AUTO_INCREMENT=28;
|
|
|
+ MODIFY `id` int(11) NOT NULL AUTO_INCREMENT, AUTO_INCREMENT=2;
|
|
|
|
|
|
--
|
|
|
-- AUTO_INCREMENT для таблицы `syslog`
|
|
|
--
|
|
|
ALTER TABLE `syslog`
|
|
|
- MODIFY `id` int(11) UNSIGNED NOT NULL AUTO_INCREMENT;
|
|
|
+ MODIFY `id` int(11) UNSIGNED NOT NULL AUTO_INCREMENT, AUTO_INCREMENT=22;
|
|
|
|
|
|
--
|
|
|
-- AUTO_INCREMENT для таблицы `Traffic_detail`
|
|
|
@@ -1315,7 +1406,7 @@ ALTER TABLE `Unknown_mac`
|
|
|
-- AUTO_INCREMENT для таблицы `User_auth`
|
|
|
--
|
|
|
ALTER TABLE `User_auth`
|
|
|
- MODIFY `id` int(11) NOT NULL AUTO_INCREMENT;
|
|
|
+ MODIFY `id` int(11) NOT NULL AUTO_INCREMENT, AUTO_INCREMENT=2;
|
|
|
|
|
|
--
|
|
|
-- AUTO_INCREMENT для таблицы `User_auth_alias`
|
|
|
@@ -1327,7 +1418,7 @@ ALTER TABLE `User_auth_alias`
|
|
|
-- AUTO_INCREMENT для таблицы `User_list`
|
|
|
--
|
|
|
ALTER TABLE `User_list`
|
|
|
- MODIFY `id` int(10) UNSIGNED NOT NULL AUTO_INCREMENT;
|
|
|
+ MODIFY `id` int(10) UNSIGNED NOT NULL AUTO_INCREMENT, AUTO_INCREMENT=2;
|
|
|
|
|
|
--
|
|
|
-- AUTO_INCREMENT для таблицы `User_stats`
|
|
|
@@ -1352,3 +1443,8 @@ ALTER TABLE `variables`
|
|
|
--
|
|
|
ALTER TABLE `vendors`
|
|
|
MODIFY `id` int(11) NOT NULL AUTO_INCREMENT, AUTO_INCREMENT=10023;
|
|
|
+COMMIT;
|
|
|
+
|
|
|
+/*!40101 SET CHARACTER_SET_CLIENT=@OLD_CHARACTER_SET_CLIENT */;
|
|
|
+/*!40101 SET CHARACTER_SET_RESULTS=@OLD_CHARACTER_SET_RESULTS */;
|
|
|
+/*!40101 SET COLLATION_CONNECTION=@OLD_COLLATION_CONNECTION */;
|