Pipe

Pipe, or the gateway of hell:

humla@pipe:~$ cat /etc/network/interfaces

  1. /etc/network/interfaces -- configuration file for ifup(8), ifdown(8)
  2. The loopback interface

auto lo iface lo inet loopback

  1. The first network card - this entry was created during the Debian installation
  2. uplink. aka internet

auto eth0 iface eth0 inet static address 10.0.0.12 broadcast 255.255.255.255 netmask 255.255.255.0 gateway 10.0.0.1

  1. the hausmaniacs

auto eth1 iface eth1 inet static address 10.10.10.1 broadcast 10.10.10.255 netmask 255.255.255.0 mtu 1496

  1. kontoret?

auto eth2 iface eth2 inet static address 10.10.2.1 broadcast 10.10.2.255 netmask 255.255.255.0

  1. humla network

auto eth3 iface eth3 inet static address 10.10.3.1 broadcast 10.10.3.255 netmask 255.255.255.0

  1. DMZ

auto eth4 iface eth4 inet static address 10.10.4.1 broadcast 10.10.4.255 netmask 255.255.255.0

  1. 42? ikke plugget inn

auto eth5 iface eth5 inet static address 10.10.42.1 broadcast 10.10.42.255 netmask 255.255.255.0

  1. ikke i bruk eth6

auto eth6 iface eth6 inet static address 10.10.6.1 broadcast 10.10.6.255 netmask 255.255.255.0

  1. vlan for dette rotete husnettet
  2. vi setter grusomhetens teater paa vlan eth1.7
  3. auto vlan7
  4. iface vlan7 inet static
  5. address 10.10.7.1
  6. broadcast 10.10.7.255
  7. netmask 255.255.255.0
  8. mtu 1496
  9. vlan_raw_device eth1

humla@pipe:~$ cat /etc/dnsmasq.conf

  1. Configuration file for dnsmasq.
  2. Format is one option per line, legal options are the same
  3. as the long options legal on the command line. See
  4. "/usr/sbin/dnsmasq --help" or "man 8 dnsmasq" for details.
  5. The following two options make you a better netizen, since they
  6. tell dnsmasq to filter out queries which the public DNS cannot
  7. answer, and which load the servers (especially the root servers)
  8. uneccessarily. If you have a dial-on-demand link they also stop
  9. these requests from bringing up the link uneccessarily.
  10. Never forward plain names (with a dot or domain part)

domain-needed

  1. Never forward addresses in the non-routed address spaces.

bogus-priv

  1. Uncomment this to filter useless windows-originated DNS requests
  2. which can trigger dial-on-demand links needlessly.
  3. Note that (amongst other things) this blocks all SRV requests,
  4. so don't use it if you use eg Kerberos.
  5. This option only affects forwarding, SRV records originating for
  6. dnsmasq (via srv-host= lines) are not suppressed by it.

filterwin2k

  1. Change this line if you want dns to get its upstream servers from
  2. somewhere other that /etc/resolv.conf

resolv-file=/etc/resolv.conf.dnsmasq

  1. By default, dnsmasq will send queries to any of the upstream
  2. servers it knows about and tries to favour servers to are known
  3. to be up. Uncommenting this forces dnsmasq to try each query
  4. with each server strictly in the order they appear in
  5. /etc/resolv.conf
  6. strict-order
  7. If you don't want dnsmasq to read /etc/resolv.conf or any other
  8. file, getting its servers for this file instead (see below), then
  9. uncomment this
  10. no-resolv
  11. If you don't want dnsmasq to poll /etc/resolv.conf or other resolv
  12. files for changes and re-read them then uncomment this.
  13. no-poll
  14. Add other name servers here, with domain specs if they are for
  15. non-public domains.
  16. server=/localnet/192.168.0.1
  17. Add local-only domains here, queries in these domains are answered
  18. from /etc/hosts or DHCP only.
  19. local=/localnet/
  20. Add domains which you want to force to an IP address here.
  21. The example below send any host in doubleclick.net to a local
  22. webserver.
  23. address=/doubleclick.net/127.0.0.1
  24. If you want dnsmasq to change uid and gid to something other
  25. than the default, edit the following lines.
  26. user=
  27. group=
  28. If you want dnsmasq to listen for requests only on specified interfaces
  29. (and the loopback) give the name of the interface (eg eth0) here.
  30. Repeat the line for more than one interface.
  31. interface=eth1
  32. interface=eth3
  33. interface=eth2
  34. Or you can specify which interface _not_ to listen on

except-interface=eth0

  1. Or which to listen on by address (remember to include 127.0.0.1 if
  2. you use this.)
  3. listen-address=10.10.10.1
  4. listen-address=10.10.10.1
  5. listen-address=10.10.2.1
  6. On systems which support it, dnsmasq binds the wildcard address,
  7. even when it is listening on only some interfaces. It then discards
  8. requests that it shouldn't reply to. This has the advantage of
  9. working even when interfaces come and go and change address. If you
  10. want dnsmasq to really bind only the interfaces it is listening on,
  11. uncomment this option. About the only time you may need this is when
  12. running another nameserver on the same machine.
  13. bind-interfaces
  14. If you don't want dnsmasq to read /etc/hosts, uncomment the
  15. following line.
  16. no-hosts
  17. or if you want it to read another file, as well as /etc/hosts, use
  18. this.
  19. addn-hosts=/etc/banner_add_hosts
  20. Set this (and domain: see below) if you want to have a domain
  21. automatically added to simple names in a hosts-file.

expand-hosts

  1. Set the domain for dnsmasq. this is optional, but if it is set, it
  2. does the following things.
  3. 1) Allows DHCP hosts to have fully qualified domain names, as long
  4. as the domain part matches this setting.
  5. 2) Sets the "domain" DHCP option thereby potentially setting the
  6. domain of all systems configured by DHCP
  7. 3) Provides the domain part for "expand-hosts"

domain=haus.mania

  1. Uncomment this to enable the integrated DHCP server, you need
  2. to supply the range of addresses available for lease and optionally
  3. a lease time. If you have more than one network, you will need to
  4. repeat this for each network on which you want to supply DHCP
  5. service.
  6. dhcp-range=192.168.0.50,192.168.0.150,12h
  7. the haus

dhcp-range=10.10.10.50,10.10.10.200,255.255.255.0,1h

  1. kontoret

dhcp-range=10.10.2.50,10.10.2.200,255.255.255.0,1h

  1. humla

dhcp-range=10.10.3.50,10.10.3.200,255.255.255.0,1h

  1. DMZ

dhcp-range=10.10.4.50,10.10.4.200,255.255.255.0,1h

  1. 42

dhcp-range=10.10.42.50,10.10.42.200,255.255.255.0,1h

  1. eth6 - ikke i bruk enda

dhcp-range=10.10.6.50,10.10.6.200,255.255.255.0,1h

  1. grusomhetens teater vlan7

dhcp-range=10.10.7.50,10.10.7.200,255.255.255.0,1h

  1. This is an example of a DHCP range where the netmask is given. This
  2. is needed for networks we reach the dnsmasq DHCP server via a relay
  3. agent. If you don't know what a DHCP relay agent is, you probably
  4. don't need to worry about this.
  5. dhcp-range=192.168.0.50,192.168.0.150,255.255.255.0,12h
  6. This is an example of a DHCP range with a network-id, so that
  7. some DHCP options may be set only for this network.
  8. dhcp-range=red,192.168.0.50,192.168.0.150
  9. Supply parameters for specified hosts using DHCP. There are lots
  10. of valid alternatives, so we will give examples of each. Note that
  11. IP addresses DO NOT have to be in the range given above, they just
  12. need to be on the same network. The order of the parameters in these
  13. do not matter, it's permissble to give name,adddress and MAC in any order
  14. Always allocate the host with ethernet address 11:22:33:44:55:66
  15. The IP address 192.168.0.60
  16. dhcp-host=11:22:33:44:55:66,192.168.0.60
  17. Always set the name of the host with hardware address
  18. 11:22:33:44:55:66 to be "fred"
  19. dhcp-host=11:22:33:44:55:66,fred
  20. Always give the host with ethernet address 11:22:33:44:55:66
  21. the name fred and IP address 192.168.0.60 and lease time 45 minutes
  22. dhcp-host=11:22:33:44:55:66,fred,192.168.0.60,45m

dhcp-host=00:50:8D:F7:FC:EA,chilipepper,10.10.10.101,1h dhcp-host=08:00:11:11:A8:6F,humlaprinter,10.10.3.24,1h

  1. dhcp-host=08:00:69:13:09:5a,flimmer,10.10.3.6,1h

dhcp-host=00:01:02:FA:79:3B,borris,10.10.3.12,1h dhcp-host=00:A0:24:4D:EF:C0,300kr,10.10.3.146,1h dhcp-host=00:06:5B:A7:91:19,bender,10.10.3.13,1h dhcp-host= 00:02:B3:0A:0D:30,vulcano,10.10.3.86,1h dhcp-host=00:B0:D0:B9:C1:17,antenna,10.10.3.247,1h

  1. dhcp-host=00:06:5B:A7:91:19,kylieminogue,10.10.3.132,1h

dhcp-host=00:D0:B7:28:16:C7,spartacus,10.10.3.109,1h dhcp-host=00:D0:B7:14:EA:8B,indastria,10.10.3.162,1h dhcp-host=00:02:B3:8F:77:90,shiny,10.10.10.179,1h dhcp-host=00:D0:B7:15:FC:97,machiavelli,10.10.3.188,1h dhcp-host=00:11:D8:8D:A6:32,jam,10.10.3.199,1h dhcp-host=00:0c:6e:c8:f2:34,yagi,10.10.3.138,1h dhcp-host=00:06:5B:13:30:18,brannbil,10.10.3.120,1h

  1. Give the machine which says it's name is "bert" IP address
  2. 192.168.0.70 and an infinite lease
  3. dhcp-host=bert,192.168.0.70,infinite
  4. Always give the host with client identifier 01:02:02:04
  5. the IP address 192.168.0.60
  6. dhcp-host=id:01:02:02:04,192.168.0.60
  7. Always give the host with client identifier "marjorie"
  8. the IP address 192.168.0.60
  9. dhcp-host=id:marjorie,192.168.0.60
  10. Enable the address given for "judge" in /etc/hosts
  11. to be given to a machine presenting the name "judge" when
  12. it asks for a DHCP lease.
  13. dhcp-host=judge
  14. Never offer DHCP service to a machine whose ethernet
  15. address is 11:22:33:44:55:66
  16. dhcp-host=11:22:33:44:55:66,ignore
  17. Ignore any client-id presented by the machine with ethernet
  18. address 11:22:33:44:55:66. This is useful to prevent a machine
  19. being treated differently when running under different OS's or
  20. between PXE boot and OS boot.
  21. dhcp-host=11:22:33:44:55:66,id:*
  22. Send extra options which are tagged as "red" to
  23. the machine with ethernet address 11:22:33:44:55:66
  24. dhcp-host=11:22:33:44:55:66,net:red
  25. Send extra options which are tagged as "red" to
  26. any machine with ethernet address starting 11:22:33:
  27. dhcp-host=11:22:33:*:*:*,net:red
  28. Send extra options which are tagged as "red" to any machine whose
  29. DHCP vendorclass string includes the substring "Linux"
  30. dhcp-vendorclass=red,Linux
  31. Send extra options which are tagged as "red" to any machine one
  32. of whose DHCP userclass strings includes the substring "accounts"
  33. dhcp-userclass=red,accounts
  34. If this line is uncommented, dnsmasq will read /etc/ethers and act
  35. on the ethernet-address/IP pairs found there just as if they had
  36. been given as --dhcp-host options. Useful if you keep
  37. MAC-address/host mappings there for other purposes.
  38. read-ethers
  39. Send options to hosts which ask for a DHCP lease.
  40. See RFC 2132 for details of available options.
  41. Note that all the common settings, such as netmask and
  42. broadcast address, DNS server and default route, are given
  43. sane defaults by dnsmasq. You very likely will not need any
  44. any dhcp-options. If you use Windows clients and Samba, there
  45. are some options which are recommended, they are detailed at the
  46. end of this section.
  47. For reference, the common options are:
  48. subnet mask - 1
  49. default router - 3
  50. DNS server - 6
  51. broadcast address - 28
  52. Set the NTP time server addresses to 192.168.0.4 and 10.10.0.5
  53. dhcp-option=42,192.168.0.4,10.10.0.5
  54. dhcp-option=3,10.10.10.1
  55. Set the NTP time server address to be the same machine as
  56. is running dnsmasq

dhcp-option=42,0.0.0.0

  1. Set the NIS domain name to "welly"
  2. dhcp-option=40,welly
  3. Set the default time-to-live to 50
  4. dhcp-option=23,10
  5. Set the "all subnets are local" flag
  6. dhcp-option=27,1
  7. Send the etherboot magic flag and then etherboot options (a string).
  8. dhcp-option=128,e4:45:74:68:00:00
  9. dhcp-option=129,NIC=eepro100
  10. Specify an option which will only be sent to the "red" network
  11. (see dhcp-range for the declaration of the "red" network)
  12. dhcp-option=red,42,192.168.1.1
  13. The following DHCP options set up dnsmasq in the same way as is specified
  14. for the ISC dhcpcd in
  15. http://www.samba.org/samba/ftp/docs/textdocs/DHCP-Server-Configuration.txt
  16. adapted for a typical dnsmasq installation where the host running
  17. dnsmasq is also the host running samba.
  18. you may want to uncomment them if you use Windows clients and Samba.
  19. dhcp-option=19,0 # option ip-forwarding off
  20. dhcp-option=44,0.0.0.0 # set netbios-over-TCP/IP nameserver(s) aka WINS server(s)
  21. dhcp-option=45,0.0.0.0 # netbios datagram distribution server
  22. dhcp-option=46,8 # netbios node type
  23. dhcp-option=47 # empty netbios scope.
  24. Send RFC-3397 DNS domain search DHCP option. WARNING: Your DHCP client
  25. probably doesn't support this......
  26. dhcp-option=119,eng.apple.com,marketing.apple.com
  27. Send encapsulated vendor-class specific options. The vendor-class
  28. is sent as DHCP option 60, and all the options marked with the
  29. vendor class are send encapsulated in DHCP option 43. The meaning of
  30. the options is defined by the vendor-class. This example sets the
  31. mtftp address to 0.0.0.0 for PXEClients
  32. dhcp-option=vendor:PXEClient,1,0.0.0.0
  33. Set the boot filename and tftpd server name and address
  34. for BOOTP. You will only need this is you want to
  35. boot machines over the network.
  36. dhcp-boot=/var/ftpd/pxelinux.0,boothost,192.168.0.3
  37. Set the limit on DHCP leases, the default is 150
  38. dhcp-lease-max=150
  39. The DHCP server needs somewhere on disk to keep its lease database.
  40. This defaults to a sane location, but if you want to change it, use
  41. the line below.
  42. dhcp-leasefile=/var/lib/misc/dnsmasq.leases
  43. Set the DHCP server to authoritative mode. In this mode it will barge in
  44. and take over the lease for any client which broadcasts on the network,
  45. whether it has a record of the lease or not. This avoids long timeouts
  46. when a machine wakes up on a new network. DO NOT enable this if there's
  47. the slighest chance that you might end up accidentally configuring a DHCP
  48. server for your campus/company accidentally. The ISC server uses the same
  49. the same option, and this URL provides more information:
  50. http://www.isc.org/index.pl?/sw/dhcp/authoritative.php

dhcp-authoritative

  1. Set the cachesize here.
  2. cache-size=150
  3. If you want to disable negative caching, uncomment this.
  4. no-negcache
  5. Normally responses which come form /etc/hosts and the DHCP lease
  6. file have Time-To-Live set as zero, which conventionally means
  7. do not cache further. If you are happy to trade lower load on the
  8. server for potentially stale date, you can set a time-to-live (in
  9. seconds) here.
  10. local-ttl=
  11. If you want dnsmasq to detect attempts by Verisign to send queries
  12. to unregistered .com and .net hosts to its sitefinder service and
  13. have dnsmasq instead return the correct NXDOMAIN response, uncomment
  14. this line. You can add similar lines to do the same for other
  15. registries which have implemented wildcard A records.
  16. bogus-nxdomain=64.94.110.11
  17. If you want to fix up DNS results from upstream servers, use the
  18. alias option. This only works for IPv4.
  19. This alias makes a result of 1.2.3.4 appear as 5.6.7.8
  20. alias=1.2.3.4,5.6.7.8
  21. and this maps 1.2.3.x to 5.6.7.x
  22. alias=1.2.3.0,5.6.7.0,255.255.255.0
  23. Change these lines if you want dnsmasq to serve MX records.
  24. Return an MX record named "maildomain.com" with target
  25. servermachine.com and preference 50
  26. mx-host=maildomain.com,servermachine.com,50
  27. Set the default target for MX records created using the localmx option.
  28. mx-target=servermachine.com
  29. Return an MX record pointing to the mx-target for all local
  30. machines.
  31. localmx
  32. Return an MX record pointing to itself for all local machines.
  33. selfmx
  34. Change the following lines if you want dnsmasq to serve SRV
  35. records. These are useful if you want to serve ldap requests for
  36. Active Directory and other windows-originated DNS requests.
  37. See RFC 2782.
  38. You may add multiple srv-host lines.
  39. The fields are <name>,<target>,<port>,<priority>,<weight>
  40. If the domain part if missing from the name (so that is just has the
  41. service and protocol sections) then the domain given by the domain=
  42. config option is used. (Note that expand-hosts does not need to be
  43. set for this to work.)
  44. A SRV record sending LDAP for the example.com domain to
  45. ldapserver.example.com port 289
  46. srv-host=_ldap._tcp.example.com,ldapserver.example.com,389
  47. A SRV record sending LDAP for the example.com domain to
  48. ldapserver.example.com port 289 (using domain=)
  49. domain=example.com
  50. srv-host=_ldap._tcp,ldapserver.example.com,389
  51. Two SRV records for LDAP, each with different priorities
  52. srv-host=_ldap._tcp.example.com,ldapserver.example.com,389,1
  53. srv-host=_ldap._tcp.example.com,ldapserver.example.com,389,2
  54. A SRV record indicating that there is no LDAP server for the domain
  55. example.com
  56. srv-host=_ldap._tcp.example.com
  57. Change the following lines to enable dnsmasq to serve TXT records.
  58. These are used for things like SPF and zeroconf. (Note that the
  59. domain-name expansion done for SRV records _does_not
  60. occur for TXT records.)
  61. Example SPF.
  62. txt-record=example.com,v=spf1 a -all
  63. Example zeroconf
  64. txt-record=_http._tcp.example.com,name=value,paper=A4
  65. For debugging purposes, log each DNS query as it passes through
  66. dnsmasq.
  67. log-queries
  68. Include a another lot of configuration options.
  69. conf-file=/etc/dnsmasq.more.conf
  70. dhcp-option=3,10.10.10.1

dhcp-boot=/pxelinux.0,boothost,10.10.10.1

  1. dhcp-boot=/sgi-boot.img,10.10.10.1,10.10.10.1
  2. dhcp-boot=/flimmer-boot.img,10.10.10.1,10.10.10.1
  3. dhcp-boot=08:00:69:0e:7d:77,/sgi-boot.img,10.10.10.1,10.10.10.1

Events RSS Events

Previous Events

Navigation

Internt

Help