diff --git a/conf.d/net b/conf.d/net index d7dbd60..f119b17 100644 --- a/conf.d/net +++ b/conf.d/net @@ -2,9 +2,11 @@ # scripts in /etc/init.d. To create a more complete configuration, # please review /usr/share/doc/openrc/net.example and save your configuration # in /etc/conf.d/net (this file :]!). -config_eth1="192.168.4.5 netmask 255.255.255.0 brd 192.168.4.255" -routes_eth1="default via 192.168.4.1" - +config_eth1="192.168.0.5 netmask 255.255.255.0 brd 192.168.0.255" +routes_eth1="default via 192.168.0.1" +#routes_eth0="default via 192.168.0.1 +#10.0.0.0/8 via 192.168.0.1 +#::/0" # The network scripts are now part of net-misc/netifrc # In order to avoid sys-apps/openrc-0.12.4 from removing this file, this comment was diff --git a/dhcpcd.conf b/dhcpcd.conf new file mode 100644 index 0000000..96eaf52 --- /dev/null +++ b/dhcpcd.conf @@ -0,0 +1,35 @@ +# A sample configuration for dhcpcd. +# See dhcpcd.conf(5) for details. + +# Inform the DHCP server of our hostname for DDNS. +hostname + +# Use the hardware address of the interface for the Client ID. +#clientid +# or +# Use the same DUID + IAID as set in DHCPv6 for DHCPv4 ClientID as per RFC4361. +duid + +# Persist interface configuration when dhcpcd exits. +persistent + +# Rapid commit support. +# Safe to enable by default because it requires the equivalent option set +# on the server to actually work. +option rapid_commit + +# A list of options to request from the DHCP server. +option domain_name_servers, domain_name, domain_search, host_name +option classless_static_routes +# Most distributions have NTP support. +option ntp_servers +# Respect the network MTU. +# Some interface drivers reset when changing the MTU so disabled by default. +#option interface_mtu + +# A ServerID is required by RFC2131. +require dhcp_server_identifier + +# A hook script is provided to lookup the hostname if not set by the DHCP +# server, but it should not be run by default. +nohook lookup-hostname diff --git a/dhcpcd.duid b/dhcpcd.duid new file mode 100644 index 0000000..e53bbfd --- /dev/null +++ b/dhcpcd.duid @@ -0,0 +1 @@ +00:01:00:01:1c:9b:fa:d3:94:de:80:6b:dd:cc diff --git a/init.d/dhcpcd b/init.d/dhcpcd new file mode 100755 index 0000000..d88b061 --- /dev/null +++ b/init.d/dhcpcd @@ -0,0 +1,17 @@ +#!/sbin/runscript +# Copyright 2007-2008 Roy Marples +# All rights reserved. Released under the 2-clause BSD license. + +command=/sbin/dhcpcd +pidfile=/var/run/dhcpcd.pid +command_args=-q +name="DHCP Client Daemon" + +depend() +{ + provide net + need localmount + use logger network + after bootmisc modules + before dns +} diff --git a/resolv.conf b/resolv.conf index 4114c57..ed8a017 100644 --- a/resolv.conf +++ b/resolv.conf @@ -1 +1,4 @@ -nameserver 192.168.4.1 +# Generated by dhcpcd +# /etc/resolv.conf.head can replace this line +# /etc/resolv.conf.tail can replace this line +nameserver 192.168.0.1