Get the domain NS glue record using dig
2011-08-29 by xpheas
First check the root servers for the tld (in my case .net)
Pick one and send a query to the rootserver:
The ADDITIONAL SECTION contains the glue records
BASH-Code:
| $ dig net NS +short e.gtld-servers.net. c.gtld-servers.net. h.gtld-servers.net. j.gtld-servers.net. l.gtld-servers.net. i.gtld-servers.net. d.gtld-servers.net. g.gtld-servers.net. a.gtld-servers.net. m.gtld-servers.net. f.gtld-servers.net. k.gtld-servers.net. b.gtld-servers.net. |
Pick one and send a query to the rootserver:
BASH-Code:
| $ dig @b.gtld-servers.net tipido.net NS ;; ADDITIONAL SECTION: ns1.tipido.com. 172800 IN A 46.4.71.122 ns2.tipido.com. 172800 IN A 84.23.79.58 |
The ADDITIONAL SECTION contains the glue records
Squid: http_port to outgoing_address
2011-08-15 by xpheas
My Squid server has 4 public IP-adresses and 4 private adresses. Each private address should map to a public one.
First add the private ones:
Now define the ACL's
And finally define the outgoing addresses:
First add the private ones:
BASH-Code:
| http_port 192.168.1.1:3128 http_port 192.168.1.2:3128 http_port 192.168.1.3:3128 http_port 192.168.1.4:3128 |
Now define the ACL's
BASH-Code:
| acl src_01 myip 192.168.1.1 acl src_02 myip 192.168.1.2 acl src_03 myip 192.168.1.3 acl src_04 myip 192.168.1.4 |
And finally define the outgoing addresses:
BASH-Code:
| tcp_outgoing_address 93.xx.xx.52 src_01 tcp_outgoing_address 93.xx.xx.53 src_02 tcp_outgoing_address 93.xx.xx.54 src_03 tcp_outgoing_address 93.xx.xx.55 src_04 |