Eu organizarei uma LAN party na próxima semana, onde criaremos uma LAN isolada, sem conexão com a internet. Como não desejo configurar IPs estáticos em uns 8 computadores, pensei em configurar um servidor DHCP no meu computador. Eu achei que existe o dhcp3-server
.
O problema provavelmente é que o servidor DHCP será executado o tempo todo, causando problemas quando eu estiver em outra rede. Como posso configurá-lo para que eu ligue na LAN party?
Eu uso o Kubuntu com o KDE, se isso faz alguma diferença.
Ok, eu tenho o servidor dhcp instalado, mas ele não inicia. Anexei a saída de alguns comandos, arquivos de configuração
/etc/dhcp/dhcpd.conf
ddns-update-style none;
option domain-name "example.org";
option domain-name-servers ns1.example.org, ns2.example.org;
default-lease-time 600;
max-lease-time 7200;
log-facility local7;
subnet 192.168.100.0 netmask 255.255.255.0 {
range 192.168.100.100 192.168.100.200;
}
/ etc / default / isc-dhcp-server
INTERFACES="eth0"
ifconfig
eth0 Link encap:Ethernet HWaddr f0:de:f1:de:a2:90
UP BROADCAST MULTICAST MTU:1500 Metric:1
RX packets:0 errors:0 dropped:0 overruns:0 frame:0
TX packets:0 errors:0 dropped:0 overruns:0 carrier:0
collisions:0 txqueuelen:1000
RX bytes:0 (0.0 B) TX bytes:0 (0.0 B)
Interrupt:20 Memory:f2500000-f2520000
lo Link encap:Local Loopback
inet addr:127.0.0.1 Mask:255.0.0.0
inet6 addr: ::1/128 Scope:Host
UP LOOPBACK RUNNING MTU:16436 Metric:1
RX packets:2830 errors:0 dropped:0 overruns:0 frame:0
TX packets:2830 errors:0 dropped:0 overruns:0 carrier:0
collisions:0 txqueuelen:0
RX bytes:405626 (405.6 KB) TX bytes:405626 (405.6 KB)
wlan0 Link encap:Ethernet HWaddr 10:0b:a9:bf:e8:fc
inet addr:131.220.201.217 Bcast:131.220.207.255 Mask:255.255.248.0
inet6 addr: fe80::120b:a9ff:febf:e8fc/64 Scope:Link
UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1
RX packets:43878 errors:0 dropped:0 overruns:0 frame:0
TX packets:27630 errors:0 dropped:0 overruns:0 carrier:0
collisions:0 txqueuelen:1000
RX bytes:52123963 (52.1 MB) TX bytes:2967812 (2.9 MB)
route -n
Kernel IP routing table
Destination Gateway Genmask Flags Metric Ref Use Iface
0.0.0.0 131.220.207.254 0.0.0.0 UG 0 0 0 wlan0
131.220.200.0 0.0.0.0 255.255.248.0 U 2 0 0 wlan0
169.254.0.0 0.0.0.0 255.255.0.0 U 1000 0 0 wlan0
serviço isc-dhcp-server status
isc-dhcp-server stop/waiting
dhcpd
Internet Systems Consortium DHCP Server 4.1-ESV-R4
Copyright 2004-2011 Internet Systems Consortium.
All rights reserved.
For info, please visit https://www.isc.org/software/dhcp/
Wrote 0 leases to leases file.
No subnet declaration for wlan0 (131.220.201.217).
** Ignoring requests on wlan0. If this is not what
you want, please write a subnet declaration
in your dhcpd.conf file for the network segment
to which interface wlan0 is attached. **
Not configured to listen on any interfaces!
dhcpd eth0
Internet Systems Consortium DHCP Server 4.1-ESV-R4
Copyright 2004-2011 Internet Systems Consortium.
All rights reserved.
For info, please visit https://www.isc.org/software/dhcp/
Wrote 0 leases to leases file.
No subnet declaration for eth0 (no IPv4 addresses).
** Ignoring requests on eth0. If this is not what
you want, please write a subnet declaration
in your dhcpd.conf file for the network segment
to which interface eth0 is attached. **
Not configured to listen on any interfaces!