The OpenNET Project / Index page

[ новости /+++ | форум | теги | ]



Индекс форумов
Составление сообщения

Исходное сообщение
"проблемы с загрузкой dhcpd"
Отправлено asphinx, 30-Окт-17 11:51 
Добрый день всем!

Работаю в одной конторе недавно (уже писал об этом). Есть в конторе наследственный линух: Linux localhost 3.14.29-gentoo #3 SMP Wed Feb 11 10:08:14 2015 x86_64 Intel(R) Xeon(R) CPU E5-2609 v2 @ 2.50GHz GenuineIntel GNU/Linux

Пытаюсь оптимизировать конфигурацию его и сети, настроил dhcpd: dhcpd --version
isc-dhcpd-4.3.1 Gentoo-r0, всё нормально работает.

# ifconfig
rem1: flags=4163<UP,BROADCAST,RUNNING,MULTICAST>  mtu 1500
        ether 9a:c0:20:74:db:6a  txqueuelen 500  (Ethernet)
        RX packets 270695  bytes 29077800 (27.7 MiB)
        RX errors 0  dropped 1367  overruns 0  frame 0
        TX packets 382646  bytes 46954412 (44.7 MiB)
        TX errors 0  dropped 0 overruns 0  carrier 0  collisions 0

rem2: flags=4163<UP,BROADCAST,RUNNING,MULTICAST>  mtu 1500
        ether 92:ba:ae:71:e5:72  txqueuelen 500  (Ethernet)
        RX packets 220282  bytes 24231385 (23.1 MiB)
        RX errors 0  dropped 1367  overruns 0  frame 0
        TX packets 448297  bytes 91635620 (87.3 MiB)
        TX errors 0  dropped 0 overruns 0  carrier 0  collisions 0

br1: flags=4163<UP,BROADCAST,RUNNING,MULTICAST>  mtu 1500
        inet 192.168.0.254  netmask 255.255.255.0  broadcast 192.168.0.255
        ether 0c:c4:7a:01:82:a0  txqueuelen 0  (Ethernet)
        RX packets 4468537  bytes 666410333 (635.5 MiB)
        RX errors 0  dropped 35  overruns 0  frame 0
        TX packets 5571670  bytes 8758544605 (8.1 GiB)
        TX errors 0  dropped 0 overruns 0  carrier 0  collisions 0

br1:1: flags=4163<UP,BROADCAST,RUNNING,MULTICAST>  mtu 1500
        inet 10.40.10.254  netmask 255.255.255.0  broadcast 10.40.10.255
        ether 0c:c4:7a:01:82:a0  txqueuelen 0  (Ethernet)

br1:2: flags=4163<UP,BROADCAST,RUNNING,MULTICAST>  mtu 1500
        inet 192.168.1.253  netmask 255.255.255.0  broadcast 192.168.1.255
        ether 0c:c4:7a:01:82:a0  txqueuelen 0  (Ethernet)

eno1: flags=4163<UP,BROADCAST,RUNNING,MULTICAST>  mtu 1500
        inet 192.168.0.253  netmask 255.255.255.0  broadcast 192.168.0.255
        ether 0c:c4:7a:01:82:a0  txqueuelen 1000  (Ethernet)
        RX packets 4528644  bytes 748104231 (713.4 MiB)
        RX errors 0  dropped 2734  overruns 0  frame 0
        TX packets 7719522  bytes 8834434819 (8.2 GiB)
        TX errors 0  dropped 0 overruns 0  carrier 0  collisions 0
        device memory 0xdf920000-df93ffff

eno3: flags=4163<UP,BROADCAST,RUNNING,MULTICAST>  mtu 1500
        inet xx.xxx.xx.xx  netmask 255.255.255.252  broadcast xx.xxx.xx.xx
        ether 0c:c4:7a:01:82:a2  txqueuelen 1000  (Ethernet)
        RX packets 7303820  bytes 8553293698 (7.9 GiB)
        RX errors 0  dropped 0  overruns 0  frame 0
        TX packets 4531300  bytes 772785614 (736.9 MiB)
        TX errors 0  dropped 0 overruns 0  carrier 0  collisions 0
        device memory 0xfbe20000-fbe3ffff

lo: flags=73<UP,LOOPBACK,RUNNING>  mtu 65536
        inet 127.0.0.1  netmask 255.0.0.0
        loop  txqueuelen 0  (Local Loopback)
        RX packets 9902  bytes 2781009 (2.6 MiB)
        RX errors 0  dropped 0  overruns 0  frame 0
        TX packets 9902  bytes 2781009 (2.6 MiB)
        TX errors 0  dropped 0 overruns 0  carrier 0  collisions 0

# grep -v ^# /etc/conf.d/dhcpd|grep -v ^$
DHCPD_IFACE="br1"

Но вот возникли неожиданные сложности при настройке автозапуска:
rc-update |grep dhcp
                dhcpd |      default

dhcpd не стартует, ругается, что нет br1, ладно идём в /etc/local.d/local.start, делаем, как делал предшественник, так:

/usr/sbin/eoip

/sbin/brctl addbr br1
/sbin/brctl addif br1 rem1
/sbin/brctl addif br1 rem2
/sbin/brctl addif br1 eno1
/bin/ifconfig br1 up
/bin/ifconfig br1 192.168.0.254/24
/bin/ifconfig eno1 192.168.0.253/24

/sbin/service dhcpd start

/bin/ifconfig br1:1 10.40.10.254/24
/bin/ifconfig br1:2 192.168.1.253/24

Всё равно, при падении питания dhcpd не стартовал. В логе следующее:
Oct 29 12:22:08 localhost dhcpd: Copyright 2004-2014 Internet Systems Consortium
.
Oct 29 12:22:08 localhost dhcpd: All rights reserved.
Oct 29 12:22:08 localhost dhcpd: For info, please visit https://www.isc.org/soft
ware/dhcp/
Oct 29 12:22:08 localhost dhcpd: Config file: /etc/dhcp/dhcpd.conf
Oct 29 12:22:08 localhost dhcpd: Database file: /var/lib/dhcp/dhcpd.leases
Oct 29 12:22:08 localhost dhcpd: PID file: /var/run/dhcp/dhcpd.pid
Oct 29 12:22:08 localhost dhcpd: WARNING: Host declarations are global.  They are not limited to the scope you declared them in.
Oct 29 12:22:08 localhost dhcpd: Wrote 0 deleted host decls to leases file.
Oct 29 12:22:08 localhost dhcpd: Wrote 0 new dynamic host decls to leases file.
Oct 29 12:22:08 localhost dhcpd: Wrote 42 leases to leases file.
Oct 29 12:22:08 localhost dhcpd:
Oct 29 12:22:08 localhost dhcpd: No subnet declaration for br1 (no IPv4 addresses).
Oct 29 12:22:08 localhost dhcpd: ** Ignoring requests on br1.  If this is not what
Oct 29 12:22:08 localhost dhcpd:    you want, please write a subnet declaration
Oct 29 12:22:08 localhost dhcpd:    in your dhcpd.conf file for the network segment
Oct 29 12:22:08 localhost dhcpd:    to which interface br1 is attached. **
Oct 29 12:22:08 localhost dhcpd:
Oct 29 12:22:08 localhost dhcpd: Not configured to listen on any interfaces!
Oct 29 12:22:08 localhost dhcpd:
Oct 29 12:22:08 localhost dhcpd: If you think you have received this message due to a bug rather
Oct 29 12:22:08 localhost dhcpd: than a configuration issue please read the section on submitting
Oct 29 12:22:08 localhost dhcpd: bugs on either our web page at www.isc.org or in the README file
Oct 29 12:22:08 localhost dhcpd: before submitting a bug.  These pages explain the proper
Oct 29 12:22:08 localhost dhcpd: process and the information we find helpful for debugging..
Oct 29 12:22:08 localhost dhcpd:
Oct 29 12:22:08 localhost dhcpd: exiting.
Oct 29 12:22:08 localhost /etc/init.d/dhcpd[2795]: start-stop-daemon: failed to start `/usr/sbin/dhcpd'
Oct 29 12:22:08 localhost /etc/init.d/dhcpd[2774]: ERROR: dhcpd failed to start
Oct 29 12:22:14 localhost dhcpd: Copyright 2004-2014 Internet Systems Consortium.
Oct 29 12:22:14 localhost dhcpd: All rights reserved.
Oct 29 12:22:14 localhost dhcpd: For info, please visit https://www.isc.org/software/dhcp/
Oct 29 12:22:14 localhost dhcpd: Config file: /etc/dhcp/dhcpd.conf
Oct 29 12:22:14 localhost dhcpd: Database file: /var/lib/dhcp/dhcpd.leases
Oct 29 12:22:14 localhost dhcpd: PID file: /var/run/dhcp/dhcpd.pid
Oct 29 12:22:14 localhost dhcpd: WARNING: Host declarations are global.  They are not limited to the scope you declared them in.
Oct 29 12:22:14 localhost dhcpd: Wrote 0 deleted host decls to leases file.
Oct 29 12:22:14 localhost dhcpd: Wrote 0 new dynamic host decls to leases file.
Oct 29 12:22:14 localhost dhcpd: Wrote 42 leases to leases file.
Oct 29 12:22:14 localhost dhcpd:
Oct 29 12:22:14 localhost dhcpd: No subnet declaration for br1 (no IPv4 addresses).
Oct 29 12:22:14 localhost dhcpd: ** Ignoring requests on br1.  If this is not what
Oct 29 12:22:14 localhost dhcpd:    you want, please write a subnet declaration
Oct 29 12:22:14 localhost dhcpd:    in your dhcpd.conf file for the network segment
Oct 29 12:22:14 localhost dhcpd:    to which interface br1 is attached. **
Oct 29 12:22:14 localhost dhcpd:
Oct 29 12:22:14 localhost dhcpd: Not configured to listen on any interfaces!
Oct 29 12:22:14 localhost dhcpd:
Oct 29 12:22:14 localhost dhcpd: If you think you have received this message due to a bug rather
Oct 29 12:22:14 localhost dhcpd: than a configuration issue please read the section on submitting
Oct 29 12:22:14 localhost dhcpd: bugs on either our web page at www.isc.org or in the README file
Oct 29 12:22:14 localhost dhcpd: before submitting a bug.  These pages explain the proper
Oct 29 12:22:14 localhost dhcpd: process and the information we find helpful for debugging..
Oct 29 12:22:14 localhost dhcpd:
Oct 29 12:22:14 localhost dhcpd: exiting.
Oct 29 12:22:14 localhost /etc/init.d/dhcpd[3121]: start-stop-daemon: failed to start `/usr/sbin/dhcpd'
Oct 29 12:22:14 localhost /etc/init.d/dhcpd[3102]: ERROR: dhcpd failed to start

А это я его "пнул" вручную с консоли: service start dhcpd:

Oct 29 12:28:52 localhost dhcpd: Copyright 2004-2014 Internet Systems Consortium.
Oct 29 12:28:52 localhost dhcpd: All rights reserved.
Oct 29 12:28:52 localhost dhcpd: For info, please visit https://www.isc.org/software/dhcp/
Oct 29 12:28:52 localhost dhcpd: Config file: /etc/dhcp/dhcpd.conf
Oct 29 12:28:52 localhost dhcpd: Database file: /var/lib/dhcp/dhcpd.leases
Oct 29 12:28:52 localhost dhcpd: PID file: /var/run/dhcp/dhcpd.pid
Oct 29 12:28:52 localhost dhcpd: WARNING: Host declarations are global.  They are not limited to the scope you declared them in.
Oct 29 12:28:52 localhost dhcpd: Wrote 0 deleted host decls to leases file.
Oct 29 12:28:52 localhost dhcpd: Wrote 0 new dynamic host decls to leases file.
Oct 29 12:28:52 localhost dhcpd: Wrote 42 leases to leases file.
Oct 29 12:28:52 localhost dhcpd: Multiple interfaces match the same subnet: br1 eno1
Oct 29 12:28:52 localhost dhcpd: Multiple interfaces match the same shared network: br1 eno1
Oct 29 12:28:52 localhost dhcpd: Server starting service.

Как видите, всё взлетело нормально. :( Чего ему не хватает для нормального старта? Ладно - первый раз, возможно, ещё не поднялся бридж, но второй-то раз он стартует точно после поднятия интерфейса...

И ещё одно - первые 6 строк в логе при старте dhcpd пишутся нормально, а потом (начиная с " WARNING: Host declarations are global." - все строки в логе, касающиеся dhcpd тупо дублируются. :( Кто-нибудь с таким сталкивался?

 

Ваше сообщение
Имя*:
EMail:
Для отправки новых сообщений в текущей нити на email укажите знак ! перед адресом, например, !user@host.ru (!! - не показывать email).
Более тонкая настройка отправки ответов производится в профиле зарегистрированного участника форума.
Заголовок*:
Сообщение*:
  Введите код, изображенный на картинке: КОД
 
При общении не допускается: неуважительное отношение к собеседнику, хамство, унизительное обращение, ненормативная лексика, переход на личности, агрессивное поведение, обесценивание собеседника, провоцирование флейма голословными и заведомо ложными заявлениями. Не отвечайте на сообщения, явно нарушающие правила - удаляются не только сами нарушения, но и все ответы на них. Лог модерирования.



Партнёры:
PostgresPro
Inferno Solutions
Hosting by Hoster.ru
Хостинг:

Закладки на сайте
Проследить за страницей
Created 1996-2024 by Maxim Chirkov
Добавить, Поддержать, Вебмастеру