<?xml version='1.0' encoding='UTF-8'?><?xml-stylesheet href="http://www.blogger.com/styles/atom.css" type="text/css"?><feed xmlns='http://www.w3.org/2005/Atom' xmlns:openSearch='http://a9.com/-/spec/opensearchrss/1.0/' xmlns:georss='http://www.georss.org/georss' xmlns:gd='http://schemas.google.com/g/2005' xmlns:thr='http://purl.org/syndication/thread/1.0'><id>tag:blogger.com,1999:blog-7193226236525813745</id><updated>2011-11-27T15:34:18.048-08:00</updated><category term='datacenter'/><category term='track'/><category term='router'/><category term='cisco'/><category term='exim'/><category term='hsrp'/><category term='bgp'/><category term='failover'/><category term='dynamips'/><category term='tap0'/><category term='standby'/><category term='domainkeys'/><category term='dynagen'/><category term='internet'/><category term='ip2ip'/><category term='NIO_gen_eth0'/><category term='network'/><category term='freebsd'/><category term='ospf'/><category term='bridge0'/><category term='route'/><category term='rtr'/><category term='switch'/><category term='ip sla'/><title type='text'>bitwise</title><subtitle type='html'></subtitle><link rel='http://schemas.google.com/g/2005#feed' type='application/atom+xml' href='http://dancaescu.blogspot.com/feeds/posts/default'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/7193226236525813745/posts/default?max-results=100'/><link rel='alternate' type='text/html' href='http://dancaescu.blogspot.com/'/><link rel='hub' href='http://pubsubhubbub.appspot.com/'/><author><name>Dan Caescu</name><uri>http://www.blogger.com/profile/10188122621218786514</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><generator version='7.00' uri='http://www.blogger.com'>Blogger</generator><openSearch:totalResults>8</openSearch:totalResults><openSearch:startIndex>1</openSearch:startIndex><openSearch:itemsPerPage>100</openSearch:itemsPerPage><entry><id>tag:blogger.com,1999:blog-7193226236525813745.post-7999289292979225283</id><published>2009-12-07T15:05:00.000-08:00</published><updated>2009-12-07T15:32:36.756-08:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='cisco'/><category scheme='http://www.blogger.com/atom/ns#' term='failover'/><category scheme='http://www.blogger.com/atom/ns#' term='standby'/><category scheme='http://www.blogger.com/atom/ns#' term='bgp'/><category scheme='http://www.blogger.com/atom/ns#' term='ospf'/><category scheme='http://www.blogger.com/atom/ns#' term='hsrp'/><title type='text'>A nice way to do failover with bgp, ospf and hsrp</title><content type='html'>My setup is as follows:&lt;br /&gt;&lt;br /&gt;Two 3550 switches, each connected to a different provider via BGP. I would like to have redundancy between the two switches/providers. Here's what I did:&lt;br /&gt;&lt;br /&gt;1. Routing: &lt;br /&gt;   a) Each switch should have a route preference 190 towards the other switch. While BGP is up, we will have a default route [preference 20] towards the corresponding provider. If BGP is down, route will switch to the 190 preference route we just added. So we will go out via our second L3 switch.&lt;br /&gt;   b) Each router will be connected in both switches. I was thinking first to use bridge irb, but it looks more natural to use ospf. So I setup two IP ranges (172.16.1.0/24 [sw1] and 172.16.2.0/24 [sw2] ) to use with OSPF. Lets take for example one of the routers, a 2651XM. Fa0/0 is connected to port fa0/2 in SW1 and Fa0/1 is connected to port fa0/2 in SW2.  &lt;br /&gt;&lt;br /&gt;Below, an example config (we will discuss this below the sample config)&lt;br /&gt;[sw1]&lt;br /&gt;&lt;br /&gt;interface FastEthernet0/2&lt;br /&gt; description to R01, fa0/0 &lt;br /&gt; switchport trunk encapsulation dot1q&lt;br /&gt; switchport mode trunk&lt;br /&gt;&lt;br /&gt;router ospf 1&lt;br /&gt; network 172.16.1.0 0.0.0.255 area 0&lt;br /&gt; network 172.16.2.0 0.0.0.255 area 0&lt;br /&gt; network 129.x.x.0 0.0.0.255 area0&lt;br /&gt; default-information originate always&lt;br /&gt;&lt;br /&gt;interface vlan 100&lt;br /&gt; ip address 129.x.x.11 netmask 255.255.255.0&lt;br /&gt; standby 100 ip 129.x.x.1&lt;br /&gt; standby 100 priority 255&lt;br /&gt; standby 100 preempt&lt;br /&gt;&lt;br /&gt;ip route 0.0.0.0 0.0.0.0 129.x.x.12 190&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;[sw2]&lt;br /&gt;&lt;br /&gt;interface FastEthernet0/2&lt;br /&gt; description to R01, fa0/1&lt;br /&gt; switchport trunk encapsulation dot1q&lt;br /&gt; switchport mode trunk&lt;br /&gt;&lt;br /&gt;router ospf 1&lt;br /&gt; network 172.16.1.0 0.0.0.255 area 0&lt;br /&gt; network 172.16.2.0 0.0.0.255 area 0&lt;br /&gt; network 129.x.x.0 0.0.0.255 area0&lt;br /&gt; default-information originate always&lt;br /&gt;&lt;br /&gt;interface vlan 100&lt;br /&gt; ip address 129.x.x.12 netmask 255.255.255.0&lt;br /&gt; standby 100 ip 129.x.x.1&lt;br /&gt; standby 100 priority 101&lt;br /&gt; standby 100 preempt&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;ip route 0.0.0.0 0.0.0.0 129.x.x.11 190&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;[r01]&lt;br /&gt;&lt;br /&gt;interface FastEthernet0/0&lt;br /&gt; description to SW1, fa0/2&lt;br /&gt; no ip address&lt;br /&gt;&lt;br /&gt;interface FastEthernet0/0.1&lt;br /&gt; encapsulation dot1q 101&lt;br /&gt; ip address 172.16.1.3 255.255.255.0&lt;br /&gt;&lt;br /&gt;interface FastEthernet0/1&lt;br /&gt; description to SW2, fa0/2&lt;br /&gt; no ip address&lt;br /&gt;&lt;br /&gt;interface FastEthernet0/1.1&lt;br /&gt; encapsulation dot1q 102&lt;br /&gt; ip address 172.16.2.3 255.255.255.0&lt;br /&gt;&lt;br /&gt;interface Loopback0&lt;br /&gt; ip address 129.x.x.54 255.255.255.255&lt;br /&gt; ip ospf 1 area 0&lt;br /&gt;&lt;br /&gt;router ospf 1&lt;br /&gt; log-adjacency-changes&lt;br /&gt; network 129.x.x.54 0.0.0.0 area 0&lt;br /&gt; network 172.16.1.0 0.0.0.255 area 0 &lt;br /&gt;&lt;br /&gt;ip route 0.0.0.0 0.0.0.0 129.x.x.1&lt;br /&gt;&lt;br /&gt;Now, how does this work?&lt;br /&gt;&lt;br /&gt;- each router has a default route towards the other, preference 190 . As said above, when BGP fails on any of the switches, traffic goes out via the other switch.&lt;br /&gt;- if both bgp sessions fail then.... well, thats just bad luck :)&lt;br /&gt;&lt;br /&gt;How will my packets select a certain ISP?&lt;br /&gt;&lt;br /&gt;- its gonna be due to HSRP protocol (hot standby router protocol). Notice on the second switch the 'standby 100 priority 101' statement. Default is 100, but I put it to 101 to make the config more self explanatory. The first switch has priority 255, which means in the HSRP group, the first switch will always be elected as default gateway.&lt;br /&gt;&lt;br /&gt;What if HSRP fails? &lt;br /&gt;&lt;br /&gt;- hsrp won't fail. If one of the switches fails, the switch still up will take the role as default gateway. (and use that switches bgp connection).&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;Other things: OSPF will always let know the switches on which interface they can find the  129.x.x.54 IP address. Check this out:&lt;br /&gt;&lt;br /&gt;&lt;------------------------------------------------------------&gt;&lt;br /&gt;sw2# sh ip route ospf&lt;br /&gt;  129.x.x.0/24 is variably subnetted, 11 subnets, 5 masks&lt;br /&gt;O     129.x.x.54/32 [110/2] via 172.16.1.3, 3d01h, Vlan101&lt;br /&gt;                    [110/2] via 172.16.2.3, 3d01h, Vlan102&lt;br /&gt;&lt;------------------------------------------------------------&gt;&lt;br /&gt;&lt;br /&gt;What else can I do?&lt;br /&gt;&lt;br /&gt;- have each provider connect in each switch. In my config I could only afford provider A in switch 1 and provider B in switch 2. If you will be able to setup provider A &amp; B in switch 1 and provider A &amp; B in switch 2 as well, then this is going to be 100% redundant.&lt;br /&gt;&lt;br /&gt;Any ideas, comments?&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/7193226236525813745-7999289292979225283?l=dancaescu.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://dancaescu.blogspot.com/feeds/7999289292979225283/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=7193226236525813745&amp;postID=7999289292979225283' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/7193226236525813745/posts/default/7999289292979225283'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/7193226236525813745/posts/default/7999289292979225283'/><link rel='alternate' type='text/html' href='http://dancaescu.blogspot.com/2009/12/nice-way-to-do-failover-with-bgp-ospf.html' title='A nice way to do failover with bgp, ospf and hsrp'/><author><name>Dan Caescu</name><uri>http://www.blogger.com/profile/10188122621218786514</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-7193226236525813745.post-5239802792294144762</id><published>2009-05-04T16:50:00.001-07:00</published><updated>2009-05-04T18:29:05.465-07:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='NIO_gen_eth0'/><category scheme='http://www.blogger.com/atom/ns#' term='ip2ip'/><category scheme='http://www.blogger.com/atom/ns#' term='freebsd'/><category scheme='http://www.blogger.com/atom/ns#' term='tap0'/><category scheme='http://www.blogger.com/atom/ns#' term='dynagen'/><category scheme='http://www.blogger.com/atom/ns#' term='bridge0'/><category scheme='http://www.blogger.com/atom/ns#' term='dynamips'/><title type='text'>Dynamips / Dynagen on FreeBSD, connect to tap0</title><content type='html'>A real world example:&lt;br /&gt;&lt;br /&gt;I needed to send calls directly to a router but didn't want to mess with production routers.&lt;br /&gt;I had a FreeBSD box running so I decided to install dynamips and dynagen and put a IP2IP image on it.&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;How to do it:&lt;br /&gt;&lt;br /&gt;1. fetch the image that you need from one of your routers (or from cisco's website).&lt;br /&gt;2. install from /usr/ports dynagen and dynamips.&lt;br /&gt;3. check out my config file and adapt to your needs:&lt;br /&gt;&lt;br /&gt;[localhost]&lt;br /&gt;&lt;br /&gt;[[3745]]&lt;br /&gt;image = c3745......[cut here]&lt;br /&gt;ram = 300&lt;br /&gt;rom = 64&lt;br /&gt;nvram = 300&lt;br /&gt;mmap = true&lt;br /&gt;cnfg = None&lt;br /&gt;confreg = 0x2102&lt;br /&gt;&lt;br /&gt;[[ROUTER IP2IP]]&lt;br /&gt;model = 3745&lt;br /&gt;console = 2000&lt;br /&gt;f0/0 = NIO_gen_eth:tap0&lt;br /&gt;&lt;br /&gt;then save and do as written below:&lt;br /&gt;&lt;br /&gt;kldload if_tap &lt;br /&gt;touch /dev/tap0 &lt;br /&gt;ifconfig tap0 up &lt;br /&gt;&lt;br /&gt;kldload if_bridge &lt;br /&gt;ifconfig bridge0 create&lt;br /&gt;ifconfig bridge0 addm eth0 addm fxp0&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;ifconfig bridge0:&lt;br /&gt;&lt;br /&gt;bridge0: flags=8843&lt;UP,BROADCAST,RUNNING,SIMPLEX,MULTICAST&gt; metric 0 mtu 1500&lt;br /&gt;        ether 26:0a:67:8d:3e:3c&lt;br /&gt;        id 00:00:00:00:00:00 priority 32768 hellotime 2 fwddelay 15&lt;br /&gt;        maxage 20 holdcnt 6 proto rstp maxaddr 100 timeout 1200&lt;br /&gt;        root id 00:00:00:00:00:00 priority 32768 ifcost 0 port 0&lt;br /&gt;        member: eth0 flags=143&lt;LEARNING,DISCOVER,AUTOEDGE,AUTOPTP&gt;&lt;br /&gt;        member: fxp0 flags=143&lt;LEARNING,DISCOVER,AUTOEDGE,AUTOPTP&gt;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;Now I am able to reach the internet from my virtual router.&lt;br /&gt;&lt;br /&gt;dynamips -H localhost &amp;&lt;br /&gt;dynagen ip2ip.cfg &amp;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;[root@cluster2 /home/dan/simulator]# dynagen ip2ip.cfg&lt;br /&gt;Reading configuration file...&lt;br /&gt;&lt;br /&gt;Shutdown in progress...&lt;br /&gt;Shutdown completed.&lt;br /&gt;*** Warning:  Starting IP2IP with no idle-pc value&lt;br /&gt;CPU0: carved JIT exec zone of 64 Mb into 2048 pages of 32 Kb.&lt;br /&gt;C3745 instance 'IP2IP' (id 0):&lt;br /&gt;  VM Status  : 0&lt;br /&gt;  RAM size   : 300 Mb&lt;br /&gt;  NVRAM size : 300 Kb&lt;br /&gt;  IOS image  : c3745-adventerprisek9_ivs-mz.124-25.bin&lt;br /&gt;&lt;br /&gt;Loading ELF file 'c3745-adventerprisek9_ivs-mz.124-25.bin'...&lt;br /&gt;ELF entry point: 0x80008000&lt;br /&gt;&lt;br /&gt;C3745 'IP2IP': starting simulation (CPU0 PC=0xffffffffbfc00000), JIT enabled.&lt;br /&gt;Network successfully loaded&lt;br /&gt;&lt;br /&gt;Dynagen management console for Dynamips and Pemuwrapper 0.11.0&lt;br /&gt;Copyright (c) 2005-2007 Greg Anuzelli, contributions Pavel Skovajsa&lt;br /&gt;&lt;br /&gt;=&gt;&lt;br /&gt;=&gt;&lt;br /&gt;=&gt;&lt;br /&gt;[2]+  Stopped                 dynagen ip2ip.cfg&lt;br /&gt;[root@cluster2 /home/dan/simulator]# telnet localhost 2000&lt;br /&gt;Trying localhost...&lt;br /&gt;Connected to localhost.&lt;br /&gt;Escape character is '^]'.&lt;br /&gt;Connected to Dynamips VM "IP2IP" (ID 0, type c3745) - Console port&lt;br /&gt;&lt;br /&gt;############################################################################################################## [OK]&lt;br /&gt;&lt;br /&gt;If you don't manage to connect to the internet like that, you could as well select the main interface:&lt;br /&gt;&lt;br /&gt;f0/0 = NIO_gen_eth:fxp0&lt;br /&gt;&lt;br /&gt;You should assign an ip address from the same range to f0/0. Worked for me.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/7193226236525813745-5239802792294144762?l=dancaescu.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://dancaescu.blogspot.com/feeds/5239802792294144762/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=7193226236525813745&amp;postID=5239802792294144762' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/7193226236525813745/posts/default/5239802792294144762'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/7193226236525813745/posts/default/5239802792294144762'/><link rel='alternate' type='text/html' href='http://dancaescu.blogspot.com/2009/05/dynamips-dynagen-on-freebsd-connect-to.html' title='Dynamips / Dynagen on FreeBSD, connect to tap0'/><author><name>Dan Caescu</name><uri>http://www.blogger.com/profile/10188122621218786514</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-7193226236525813745.post-1680261858496344181</id><published>2008-07-24T15:58:00.000-07:00</published><updated>2008-07-24T16:02:06.167-07:00</updated><title type='text'>Google Mail on multiple devices with pop3/imap</title><content type='html'>Quick tip: instead of using username@gmail.com , use recent:username@gmail.com and you 'll be able to get all your messages on more than one device. Google Mail seems to 'mark' messages as read when you download them with POP3 (as the standard says it should), but does it in a funny way, so that you cannot download your messages with another computer/pda/etc later on (because they are marked as read, isn't it?). Well, on courier and other pop3/imap servers I was able to do it with no problems from 10 devices if i wanted to.   So you can use recent:username@gmail.com and it'll work.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/7193226236525813745-1680261858496344181?l=dancaescu.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://dancaescu.blogspot.com/feeds/1680261858496344181/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=7193226236525813745&amp;postID=1680261858496344181' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/7193226236525813745/posts/default/1680261858496344181'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/7193226236525813745/posts/default/1680261858496344181'/><link rel='alternate' type='text/html' href='http://dancaescu.blogspot.com/2008/07/google-mail-on-multiple-devices-with.html' title='Google Mail on multiple devices with pop3/imap'/><author><name>Dan Caescu</name><uri>http://www.blogger.com/profile/10188122621218786514</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-7193226236525813745.post-2334442047362887425</id><published>2007-11-05T15:57:00.000-08:00</published><updated>2007-11-05T16:12:41.305-08:00</updated><title type='text'>two different approaches on the same problem</title><content type='html'>Let's presume your isp had the following config on your its side:&lt;br /&gt;&lt;br /&gt;interface FastEthernet0/8&lt;br /&gt;description Link to Dan - 1M&lt;br /&gt;switchport access vlan 634&lt;br /&gt;switchport trunk encapsulation dot1q&lt;br /&gt;switchport trunk native vlan 635&lt;br /&gt;switchport trunk allowed vlan 2,635&lt;br /&gt;switchport mode trunk&lt;br /&gt;no cdp enable&lt;br /&gt;spanning-tree portfast&lt;br /&gt;spanning-tree bpdufilter enable&lt;br /&gt;spanning-tree bpduguard enable&lt;br /&gt;spanning-tree guard none&lt;br /&gt;service-policy input dan-1024&lt;br /&gt;&lt;br /&gt;Why is it trunk? Because in between this switch and myself there is a radio bridge which is currently using vlan2 (for monitoring purpose). All of the sudden this config stops working after an IOS upgrade (says my ISP). (I was accessing vlan 635 on my side : switchport access vlan 634).&lt;br /&gt;&lt;br /&gt;Since it was unlikely for my ISP to solve the problem (i don't know exactly what was wrong, they did not know either), here's the two approaches i found for this:&lt;br /&gt;&lt;br /&gt;I had a 1800router with a NM8-ESW card&lt;br /&gt;&lt;br /&gt;1. moved the cable from the radio unit to the NM-8ESW interface, put one of the fast&lt;br /&gt;interfaces (fe0/0/1) to trunk mode, created vlan 634 (corresponding to&lt;br /&gt;my vlan in the isp network), and after this changed the source&lt;br /&gt;interface for tunnel1 from fast0/1 to vlan634 (which i configured with&lt;br /&gt;ip address x.y.z.6/30). Was working, but had to try the next thing as well (see 2.)&lt;br /&gt;&lt;br /&gt;2. put the cable from the radio unit back to fast0/1 , created a subinterface&lt;br /&gt;on this (fast0/1.1) , assigned x.y.z.6/30 and encapsulation dot1q&lt;br /&gt;634. Working again. Moved tunnel source to fa0/1.1 &lt;br /&gt;&lt;br /&gt;My relevant config:&lt;br /&gt;&lt;br /&gt;ip sla monitor 1&lt;br /&gt; type echo protocol ipIcmpEcho z.g.h.3&lt;br /&gt; frequency 5&lt;br /&gt;ip sla monitor schedule 1 life forever start-time now&lt;br /&gt;ip sla monitor 2&lt;br /&gt; type echo protocol ipIcmpEcho h.k.l.2&lt;br /&gt; frequency 5&lt;br /&gt;ip sla monitor schedule 2 life forever start-time now&lt;br /&gt;&lt;br /&gt;track 123 rtr 2 reachability&lt;br /&gt;&lt;br /&gt;!&lt;br /&gt;interface Tunnel1&lt;br /&gt; description gre pri tunnel&lt;br /&gt; bandwidth 1024&lt;br /&gt; ip unnumbered Loopback0&lt;br /&gt; ip hold-time eigrp 31 60&lt;br /&gt; ip tcp adjust-mss 1300&lt;br /&gt; delay 40000&lt;br /&gt; keepalive 33 3&lt;br /&gt; tunnel source FastEthernet0/1.1&lt;br /&gt; tunnel destination z.g.h.3&lt;br /&gt;&lt;br /&gt;interface FastEthernet0/1.1&lt;br /&gt; description radio connection x.y.z.6 to isp&lt;br /&gt; bandwidth 1024&lt;br /&gt; ip address x.y.z.6 255.255.255.252&lt;br /&gt; encapsulation dot1q 634&lt;br /&gt;&lt;br /&gt;the other tunnel doesnt matter, my other link was working fine.&lt;br /&gt;&lt;br /&gt;Why I posted this? Because I need some advice. The last version is the version I'm using now, but I would like a second opinion on the two versions I've posted. Or maybe some other solution. Thanks in advance.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/7193226236525813745-2334442047362887425?l=dancaescu.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://dancaescu.blogspot.com/feeds/2334442047362887425/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=7193226236525813745&amp;postID=2334442047362887425' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/7193226236525813745/posts/default/2334442047362887425'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/7193226236525813745/posts/default/2334442047362887425'/><link rel='alternate' type='text/html' href='http://dancaescu.blogspot.com/2007/11/two-different-approaches-on-same.html' title='two different approaches on the same problem'/><author><name>Dan Caescu</name><uri>http://www.blogger.com/profile/10188122621218786514</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-7193226236525813745.post-2344718387054517118</id><published>2007-11-05T15:45:00.000-08:00</published><updated>2007-11-05T15:49:27.977-08:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='cisco'/><category scheme='http://www.blogger.com/atom/ns#' term='network'/><category scheme='http://www.blogger.com/atom/ns#' term='router'/><category scheme='http://www.blogger.com/atom/ns#' term='datacenter'/><category scheme='http://www.blogger.com/atom/ns#' term='switch'/><category scheme='http://www.blogger.com/atom/ns#' term='hsrp'/><title type='text'>This summer's (minor) network upgrade.</title><content type='html'>So, on Friday we started working on extending the data center. What we've done? Well, in order to accommodate the FPSO we really had to work a lot. Started at 20:00 on Friday and finished next day at 12:00. So about 16 hours. First thing done was cleaning the cabinets (ie throwing all the old cables and laying down new ones). Now what's so cool about this is that it will make life a hell lot easier since... well, i will later post a picture with the old cabinets so you'll get the big idea why now it's easier. Next, since the fiber leads were not in place yet (in the new trunking), we had to find some other leads and put them on top of the cabinets. Not a very elegant solution, but it worked. Next, since we Distribution and Access were collapsed into two Cisco 6509 switches doing HSRP. Since we had to accommodate lot of servers for the FPSO, we decided that the 6509s should be placed in the WAN part. So two stacks of 4x 3750 switches were set in place of this 6509s and .... well, to make a long story short , we switched from L2 to L3. Everything seems more organized right now, some parts have become more redundant (we had HSRP only on 6509 switches, now this moved to WAN part and everything became more redundant since everything has 2 or 3 fibers connecting here. Not to mention the new cabinets which each have 2 ups's , and since each router has two power supplies , each router is connected to two different upses. ) Tunnels are now terminating on a 3800 router (they were terminating into a 1800), and soon we'll change the raw internet router (now a 3620 which is barely over the minimum of what we need. not to say that with NBAR on place it used to choke before enabling NBAR on remote routers as well). Moved everything from Vlan1 to Vlan50 (at least for management purpose), made vlan400 for .187.0/24 class (Connecting the oil rigs ,remote locations and so on). Also Rami was kind enough to do some more overtime (I guess the guy spent about 24 hours here), and also upgraded the Call Manager so now it doesn't take like 15 seconds for each login/logoff.&lt;br /&gt;&lt;br /&gt;The major network upgrade is not written (but took place). Kept me for almost 37 hours awake. Will post this at a later time.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/7193226236525813745-2344718387054517118?l=dancaescu.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://dancaescu.blogspot.com/feeds/2344718387054517118/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=7193226236525813745&amp;postID=2344718387054517118' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/7193226236525813745/posts/default/2344718387054517118'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/7193226236525813745/posts/default/2344718387054517118'/><link rel='alternate' type='text/html' href='http://dancaescu.blogspot.com/2007/11/this-summers-network-upgrade.html' title='This summer&apos;s (minor) network upgrade.'/><author><name>Dan Caescu</name><uri>http://www.blogger.com/profile/10188122621218786514</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-7193226236525813745.post-4131279409735750661</id><published>2007-09-15T10:51:00.000-07:00</published><updated>2007-09-15T10:54:22.224-07:00</updated><title type='text'>idirect upgrade howto</title><content type='html'>I run into this a couple of days ago. I had to upgrade a idirect router (upload a new options file), but i did not had the password for iSite anymore. Here's how i did it:&lt;br /&gt;&lt;br /&gt;1. Reload the idirect router.&lt;br /&gt;2. Connect to the router with a cisco console cable&lt;br /&gt;3. Login with username root and password iDirect (defaults)&lt;br /&gt;4. ps ax ; and kill all the falcon processes.&lt;br /&gt;5. # cd /etc/idirect/falcon/&lt;br /&gt;# ls&lt;br /&gt;&lt;br /&gt;   falcon.opt      falcon.opt.old&lt;br /&gt;&lt;br /&gt;   #&lt;br /&gt;6. # mv falcon.opt falcon.opt.old&lt;br /&gt;7. set your computer's ip address to be whatever the router connected to the idirect&lt;br /&gt;modem/router was.&lt;br /&gt;8. start a webserver on your computer&lt;br /&gt;9. on falcon router : wget http://your-computers-ip-address/name-of-new-conf-file.opt&lt;br /&gt;10.reload falcon router&lt;br /&gt;&lt;br /&gt;that's it. Too simple, but worth writing for the future.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/7193226236525813745-4131279409735750661?l=dancaescu.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://dancaescu.blogspot.com/feeds/4131279409735750661/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=7193226236525813745&amp;postID=4131279409735750661' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/7193226236525813745/posts/default/4131279409735750661'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/7193226236525813745/posts/default/4131279409735750661'/><link rel='alternate' type='text/html' href='http://dancaescu.blogspot.com/2007/09/idirect-upgrade-howto.html' title='idirect upgrade howto'/><author><name>Dan Caescu</name><uri>http://www.blogger.com/profile/10188122621218786514</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-7193226236525813745.post-1216767715740538870</id><published>2007-09-15T08:42:00.000-07:00</published><updated>2007-09-15T09:12:37.379-07:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='cisco'/><category scheme='http://www.blogger.com/atom/ns#' term='route'/><category scheme='http://www.blogger.com/atom/ns#' term='ip sla'/><category scheme='http://www.blogger.com/atom/ns#' term='rtr'/><category scheme='http://www.blogger.com/atom/ns#' term='internet'/><category scheme='http://www.blogger.com/atom/ns#' term='track'/><title type='text'>How about multiple internet connections?</title><content type='html'>Lets presume that one of your customers is buying two internet connections. One is from you, the other one is from the competition. Since he is not buying alot of bandwidth, he won't have much options regarding the usage of bgp, or some other routing protocol to switch between providers when one of his links is down. Here's a quick solution:&lt;br /&gt;&lt;br /&gt;PS: this was a cisco 851&lt;br /&gt;&lt;br /&gt;no service pad&lt;br /&gt;service timestamps debug uptime&lt;br /&gt;service timestamps log uptime&lt;br /&gt;service password-encryption&lt;br /&gt;!&lt;br /&gt;hostname example-customer&lt;br /&gt;!&lt;br /&gt;boot-start-marker&lt;br /&gt;boot-end-marker&lt;br /&gt;!&lt;br /&gt;logging buffered 65535 debugging&lt;br /&gt;!&lt;br /&gt;aaa new-model&lt;br /&gt;!&lt;br /&gt;!&lt;br /&gt;aaa authentication password-prompt password:&lt;br /&gt;aaa authentication username-prompt Username:&lt;br /&gt;aaa authentication login default local&lt;br /&gt;aaa authorization exec default local&lt;br /&gt;!&lt;br /&gt;aaa session-id common&lt;br /&gt;!&lt;br /&gt;resource policy&lt;br /&gt;!&lt;br /&gt;clock timezone GMT+1 1&lt;br /&gt;ip subnet-zero&lt;br /&gt;no ip source-route&lt;br /&gt;ip cef&lt;br /&gt;!&lt;br /&gt;!&lt;br /&gt;no ip dhcp use vrf connected&lt;br /&gt;!&lt;br /&gt;ip dhcp pool example-customer&lt;br /&gt;   network 192.168.2.0 255.255.255.0&lt;br /&gt;   default-router 192.168.2.1&lt;br /&gt;   dns-server &lt;your-dns-servers&gt;&lt;br /&gt;   domain-name example-customer.com&lt;br /&gt;   lease 2&lt;br /&gt;!&lt;br /&gt;!&lt;br /&gt;ip tcp path-mtu-discovery&lt;br /&gt;no ip bootp server&lt;br /&gt;ip domain name example-customer.com&lt;br /&gt;ip name-server &lt;your-dns-server1&gt;&lt;br /&gt;ip name-server &lt;your-dns-server2&gt;&lt;br /&gt;ip sla 1&lt;br /&gt; icmp-echo &lt;your&gt; source-ip &lt;your&gt;&lt;br /&gt; request-data-size 500&lt;br /&gt; threshold 2000&lt;br /&gt; tag providers-rtr&lt;br /&gt; frequency 45&lt;br /&gt;ip sla schedule 1 start-time now&lt;br /&gt;ip sla 2&lt;br /&gt; icmp-echo &lt;your&gt; source-ip &lt;your&gt;&lt;br /&gt; request-data-size 500&lt;br /&gt; threshold 3000&lt;br /&gt; tag providers-rtr&lt;br /&gt; frequency 45&lt;br /&gt;ip sla schedule 2 start-time now&lt;br /&gt;!&lt;br /&gt;!&lt;br /&gt;!&lt;br /&gt;!&lt;br /&gt;!&lt;br /&gt;!&lt;br /&gt;track 1 rtr 1&lt;br /&gt;!&lt;br /&gt;track 2 rtr 2&lt;br /&gt;!&lt;br /&gt;!&lt;br /&gt;!&lt;br /&gt;!&lt;br /&gt;!&lt;br /&gt;interface FastEthernet0&lt;br /&gt; description Link to Provider1&lt;br /&gt; switchport access vlan 2&lt;br /&gt; spanning-tree portfast&lt;br /&gt;!&lt;br /&gt;interface FastEthernet1&lt;br /&gt; description Link to Provider2&lt;br /&gt; switchport access vlan 3&lt;br /&gt; spanning-tree portfast&lt;br /&gt;!&lt;br /&gt;interface FastEthernet2&lt;br /&gt;!&lt;br /&gt;interface FastEthernet3&lt;br /&gt;!&lt;br /&gt;interface FastEthernet4&lt;br /&gt; description Local LAN&lt;br /&gt; ip address 192.168.2.1 255.255.255.0&lt;br /&gt; ip nat inside&lt;br /&gt; ip virtual-reassembly&lt;br /&gt; duplex auto&lt;br /&gt; speed auto&lt;br /&gt;!&lt;br /&gt;interface Vlan1&lt;br /&gt; no ip address&lt;br /&gt;!&lt;br /&gt;interface Vlan2&lt;br /&gt; description Link to Provider1&lt;br /&gt; ip address &lt;provider1&gt; 255.255.255.248&lt;br /&gt; ip nat outside&lt;br /&gt; ip virtual-reassembly&lt;br /&gt;!&lt;br /&gt;interface Vlan3&lt;br /&gt; description Link to Provider2&lt;br /&gt; ip address &lt;provider2&gt; 255.255.255.248&lt;br /&gt; ip nat outside&lt;br /&gt; ip virtual-reassembly&lt;br /&gt;!&lt;br /&gt;ip classless&lt;br /&gt;ip route 0.0.0.0 0.0.0.0 &lt;your&gt; track 1&lt;br /&gt;ip route 0.0.0.0 0.0.0.0 &lt;your&gt; 10 track 2&lt;br /&gt;!&lt;br /&gt;no ip http server&lt;br /&gt;no ip http secure-server&lt;br /&gt;ip nat pool provider1 &lt;start&gt; &lt;end&gt; prefix-length 29&lt;br /&gt;ip nat pool provider2 &lt;start&gt; &lt;end&gt; prefix-length 29&lt;br /&gt;ip nat inside source route-map nat-provider1-out pool provider1 overload&lt;br /&gt;ip nat inside source route-map nat-provider2-out pool provider2 overload&lt;br /&gt;!&lt;br /&gt;access-list 10 permit 192.168.0.0 0.0.0.255&lt;br /&gt;access-list 11 permit &lt;provider1&gt;&lt;br /&gt;access-list 12 permit &lt;provider2&gt;&lt;br /&gt;access-list 20 permit 192.168.2.0 0.0.0.255&lt;br /&gt;&lt;access-list&gt;&lt;br /&gt;no cdp run&lt;br /&gt;!&lt;br /&gt;route-map nat-provider1-out permit 10&lt;br /&gt; match ip next-hop 12&lt;br /&gt;!&lt;br /&gt;route-map nat-provider2-out permit 10&lt;br /&gt; match ip next-hop 11&lt;br /&gt;!&lt;br /&gt;!&lt;br /&gt;control-plane&lt;br /&gt;!&lt;br /&gt;banner motd ^C&lt;br /&gt;welcome dude.&lt;br /&gt;^C&lt;br /&gt;!&lt;br /&gt;line con 0&lt;br /&gt; exec-timeout 30 0&lt;br /&gt; no modem enable&lt;br /&gt;line aux 0&lt;br /&gt;line vty 0 4&lt;br /&gt; access-class 160 in&lt;br /&gt; exec-timeout 30 0&lt;br /&gt; transport input telnet ssh&lt;br /&gt; transport output telnet ssh&lt;br /&gt;!&lt;br /&gt;scheduler max-task-time 5000&lt;br /&gt;end&lt;br /&gt;&lt;br /&gt;I took out some parts of the config and changed it a bit from what it looks like on the router, but it should work without problems.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/7193226236525813745-1216767715740538870?l=dancaescu.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://dancaescu.blogspot.com/feeds/1216767715740538870/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=7193226236525813745&amp;postID=1216767715740538870' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/7193226236525813745/posts/default/1216767715740538870'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/7193226236525813745/posts/default/1216767715740538870'/><link rel='alternate' type='text/html' href='http://dancaescu.blogspot.com/2007/09/how-about-multiple-internet-connections.html' title='How about multiple internet connections?'/><author><name>Dan Caescu</name><uri>http://www.blogger.com/profile/10188122621218786514</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-7193226236525813745.post-4075907542790042974</id><published>2007-09-15T08:32:00.000-07:00</published><updated>2007-09-15T08:41:18.159-07:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='freebsd'/><category scheme='http://www.blogger.com/atom/ns#' term='exim'/><category scheme='http://www.blogger.com/atom/ns#' term='domainkeys'/><title type='text'>Exim + DomainKeys Howto.</title><content type='html'>I ran into this problem a couple of months ago: all the mail one of my customers was sending ended up in bulk folder in Yahoo, Hotmail and other big free mail providers. While I was aware this will not solve the problem entirely, due to the fact that they open blindly any attachment in any email they receive (and thus get viruses which start sending emails/spam the next minute), I thought that I should also implement DomainKeys, since I was doing alot of maintenance work (like updating clamav, spamassasin and so on and so forth).&lt;br /&gt;&lt;br /&gt;It took me a couple of days to finally get it working the right way due to different factors (dns, not being able to find a very comprehensive documentation, etc).&lt;br /&gt;&lt;br /&gt;Here is what I came up with:&lt;br /&gt;&lt;br /&gt;&lt;p class="line862"&gt;This is a quick tutorial on how to enable domainkeys (&lt;a class="http" href="http://domainkeys.sourceforge.net/"&gt;http://domainkeys.sourceforge.net/&lt;/a&gt;) on Exim on a FreeBSD server. &lt;span class="anchor" id="line-107"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-108"&gt;&lt;/span&gt;&lt;/p&gt;&lt;p class="line874"&gt;First, if you have not installed yet Exim, you have to install it. &lt;span class="anchor" id="line-109"&gt;&lt;/span&gt;If you have installed it already, you have to recompile it. &lt;span class="anchor" id="line-110"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-111"&gt;&lt;/span&gt;&lt;/p&gt;&lt;p class="line874"&gt;The way to do it: &lt;span class="anchor" id="line-112"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-113"&gt;&lt;/span&gt;&lt;/p&gt;&lt;p class="line867"&gt;&lt;span class="anchor" id="line-114"&gt;&lt;/span&gt;&lt;/p&gt;&lt;pre&gt;cd /usr/ports/mail/exim&lt;br /&gt;&lt;span class="anchor" id="line-115"&gt;&lt;/span&gt;ee Makefile    (or use joe / vi /whatever you like)&lt;br /&gt;&lt;span class="anchor" id="line-116"&gt;&lt;/span&gt;&lt;/pre&gt;&lt;span class="anchor" id="line-117"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-118"&gt;&lt;/span&gt;&lt;p class="line874"&gt;Search for the following lines: &lt;span class="anchor" id="line-119"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-120"&gt;&lt;/span&gt;&lt;/p&gt;&lt;pre&gt;# Enable DomainKeys support&lt;br /&gt;&lt;span class="anchor" id="line-121"&gt;&lt;/span&gt;#WITH_DOMAINKEYS=       yes&lt;br /&gt;&lt;span class="anchor" id="line-122"&gt;&lt;/span&gt;&lt;/pre&gt;&lt;span class="anchor" id="line-123"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-124"&gt;&lt;/span&gt;&lt;p class="line874"&gt;..and uncomment the "#WITH_DOMAINKEYS=          yes". &lt;span class="anchor" id="line-125"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-126"&gt;&lt;/span&gt;&lt;/p&gt;&lt;p class="line874"&gt;Now you will have: &lt;span class="anchor" id="line-127"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-128"&gt;&lt;/span&gt;&lt;/p&gt;&lt;p class="line867"&gt;&lt;span class="anchor" id="line-129"&gt;&lt;/span&gt;&lt;/p&gt;&lt;pre&gt;# Enable DomainKeys support&lt;br /&gt;&lt;span class="anchor" id="line-130"&gt;&lt;/span&gt;WITH_DOMAINKEYS=       yes&lt;br /&gt;&lt;span class="anchor" id="line-131"&gt;&lt;/span&gt;&lt;/pre&gt;&lt;span class="anchor" id="line-132"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-133"&gt;&lt;/span&gt;&lt;p class="line874"&gt;Save and exit the text editor. &lt;span class="anchor" id="line-134"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-135"&gt;&lt;/span&gt;&lt;/p&gt;&lt;p class="line874"&gt;Do the following: &lt;span class="anchor" id="line-136"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-137"&gt;&lt;/span&gt;&lt;/p&gt;&lt;p class="line867"&gt;&lt;span class="anchor" id="line-138"&gt;&lt;/span&gt;&lt;/p&gt;&lt;pre&gt;make clean&lt;br /&gt;&lt;span class="anchor" id="line-139"&gt;&lt;/span&gt;make rmconfig&lt;br /&gt;&lt;span class="anchor" id="line-140"&gt;&lt;/span&gt;make&lt;br /&gt;&lt;span class="anchor" id="line-141"&gt;&lt;/span&gt;make FORCE_PKG_REGISTER=1 install  &lt;-- if you already have exim installed. &lt;span class="anchor" id="line-142"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span class="anchor" id="line-143"&gt;&lt;/span&gt;make install                       &lt;-- if you don't have yet exim installed. &lt;span class="anchor" id="line-144"&gt;&lt;/span&gt;&lt;/pre&gt;&lt;span class="anchor" id="line-145"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-146"&gt;&lt;/span&gt;&lt;p class="line862"&gt;Copy &amp;amp; paste in your console: &lt;span class="anchor" id="line-147"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-148"&gt;&lt;/span&gt;&lt;/p&gt;&lt;p class="line867"&gt;&lt;span class="anchor" id="line-149"&gt;&lt;/span&gt;&lt;/p&gt;&lt;pre&gt;cd /usr/local/etc/exim&lt;br /&gt;&lt;span class="anchor" id="line-150"&gt;&lt;/span&gt;mkdir dk&lt;br /&gt;&lt;span class="anchor" id="line-151"&gt;&lt;/span&gt;cd dk&lt;br /&gt;&lt;span class="anchor" id="line-152"&gt;&lt;/span&gt;openssl genrsa -out rsa.private 768&lt;br /&gt;&lt;span class="anchor" id="line-153"&gt;&lt;/span&gt;openssl rsa -in rsa.private -out rsa.public -pubout -outform PEM&lt;br /&gt;&lt;span class="anchor" id="line-154"&gt;&lt;/span&gt;cat rsa.public&lt;br /&gt;&lt;span class="anchor" id="line-155"&gt;&lt;/span&gt;&lt;/pre&gt;&lt;span class="anchor" id="line-156"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-157"&gt;&lt;/span&gt;&lt;p class="line874"&gt;After all this you will have a result which will look something like that: &lt;span class="anchor" id="line-158"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-159"&gt;&lt;/span&gt;&lt;/p&gt;&lt;p class="line867"&gt;&lt;span class="anchor" id="line-160"&gt;&lt;/span&gt;&lt;/p&gt;&lt;pre&gt;-----BEGIN PUBLIC KEY-----&lt;br /&gt;&lt;span class="anchor" id="line-161"&gt;&lt;/span&gt;MHwwDQYJKoZIhvcNAQEBBQADawAwaAJhAKJ2lzDLZ8XlVambQfMXn3LRGKOD5o6l&lt;br /&gt;&lt;span class="anchor" id="line-162"&gt;&lt;/span&gt;MIgulclWjZwP56LRqdg5ZX15bhc/GsvW8xW/R5Sh1NnkJNyL/cqY1a+GzzL47t7E&lt;br /&gt;&lt;span class="anchor" id="line-163"&gt;&lt;/span&gt;XzVc+nRLWT1kwTvFNGIoAUsFUq+J6+OprwIDAQAB&lt;br /&gt;&lt;span class="anchor" id="line-164"&gt;&lt;/span&gt;-----END PUBLIC KEY-----&lt;br /&gt;&lt;span class="anchor" id="line-165"&gt;&lt;/span&gt;&lt;/pre&gt;&lt;span class="anchor" id="line-166"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-167"&gt;&lt;/span&gt;&lt;p class="line874"&gt;Save whats between ---BEGIN PUBLIC KEY--- and ---END PUBLIC KEY--- for later use. &lt;span class="anchor" id="line-168"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-169"&gt;&lt;/span&gt;&lt;/p&gt;&lt;p class="line874"&gt;Edit with your favorite text editor /usr/local/etc/exim/configure &lt;span class="anchor" id="line-170"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-171"&gt;&lt;/span&gt;&lt;/p&gt;&lt;p class="line874"&gt;find the line which starts with "remote_smtp:" . This should be under the "begin transports" section of the file. &lt;span class="anchor" id="line-172"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-173"&gt;&lt;/span&gt;&lt;/p&gt;&lt;p class="line874"&gt;It looks like that: &lt;span class="anchor" id="line-174"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-175"&gt;&lt;/span&gt;&lt;/p&gt;&lt;p class="line867"&gt;&lt;span class="anchor" id="line-176"&gt;&lt;/span&gt;&lt;/p&gt;&lt;pre&gt;remote_smtp:&lt;br /&gt;&lt;span class="anchor" id="line-177"&gt;&lt;/span&gt;  driver = smtp&lt;br /&gt;&lt;span class="anchor" id="line-178"&gt;&lt;/span&gt;&lt;/pre&gt;&lt;span class="anchor" id="line-179"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-180"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-181"&gt;&lt;/span&gt;&lt;p class="line874"&gt;Edit there and make it look like that: &lt;span class="anchor" id="line-182"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-183"&gt;&lt;/span&gt;&lt;/p&gt;&lt;p class="line867"&gt;&lt;span class="anchor" id="line-184"&gt;&lt;/span&gt;&lt;/p&gt;&lt;pre&gt;remote_smtp:&lt;br /&gt;&lt;span class="anchor" id="line-185"&gt;&lt;/span&gt;  driver = smtp&lt;br /&gt;&lt;span class="anchor" id="line-186"&gt;&lt;/span&gt;  dk_selector = myselector    # you will need this later when you will alter your dns config&lt;br /&gt;&lt;span class="anchor" id="line-187"&gt;&lt;/span&gt;  dk_private_key = /usr/local/etc/exim/dk/rsa.private&lt;br /&gt;&lt;span class="anchor" id="line-188"&gt;&lt;/span&gt;  dk_canon = nofws&lt;br /&gt;&lt;span class="anchor" id="line-189"&gt;&lt;/span&gt;&lt;/pre&gt;&lt;span class="anchor" id="line-190"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-191"&gt;&lt;/span&gt;&lt;p class="line874"&gt;Save the file, exit and start/restart exim : &lt;span class="anchor" id="line-192"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-193"&gt;&lt;/span&gt;&lt;/p&gt;&lt;p class="line867"&gt;&lt;span class="anchor" id="line-194"&gt;&lt;/span&gt;&lt;/p&gt;&lt;pre&gt;sh /usr/local/etc/rc.d/exim.sh restart&lt;br /&gt;&lt;span class="anchor" id="line-195"&gt;&lt;/span&gt;&lt;/pre&gt;&lt;span class="anchor" id="line-196"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-197"&gt;&lt;/span&gt;&lt;p class="line874"&gt;Login to the server that serves as DNS server for the domain name for which you are configuring this domainkey thing. &lt;span class="anchor" id="line-198"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-199"&gt;&lt;/span&gt;&lt;/p&gt;&lt;p class="line874"&gt;Go to /etc/namedb/ &lt;span class="anchor" id="line-200"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-201"&gt;&lt;/span&gt;&lt;/p&gt;&lt;p class="line874"&gt;Find the file corresponding to your domain (look for it in named.conf and you will find the path to it). &lt;span class="anchor" id="line-202"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-203"&gt;&lt;/span&gt;&lt;/p&gt;&lt;p class="line874"&gt;Let's presume is /etc/namedb/pri/com/yourdomain.com. &lt;span class="anchor" id="line-204"&gt;&lt;/span&gt;Edit this file, and just after/below the IN MX statement, add the following things: &lt;span class="anchor" id="line-205"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-206"&gt;&lt;/span&gt;&lt;/p&gt;&lt;p class="line867"&gt;&lt;span class="anchor" id="line-207"&gt;&lt;/span&gt;&lt;/p&gt;&lt;pre&gt;_domainkey.yourdomain.com.       IN      TXT     "t=y; o=-"&lt;br /&gt;&lt;span class="anchor" id="line-208"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span class="anchor" id="line-209"&gt;&lt;/span&gt;myselector._domainkey.yourdomain.com.  IN      TXT     "k=rsa; t=y; p=MHwwDQYJKoZIhvcNAQEBBQADawAwaAJhAKJ2lzDLZ8XlVambQfMXn3LRGKOD5o6lMIgulclWjZwP56LRqdg5ZX15bhc/GsvW8xW/R5Sh1NnkJNyL/cqY1a+GzzL47t7EXzVc+nRLWT1kwTvFNGIoAUsFUq+J6+OprwIDAQAB"&lt;br /&gt;&lt;span class="anchor" id="line-210"&gt;&lt;/span&gt;&lt;/pre&gt;&lt;span class="anchor" id="line-211"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-212"&gt;&lt;/span&gt;&lt;p class="line874"&gt;Alter the serial (for example, if today is 28-aug-2007, make your serial look like 2007082800 or 2007082801, etc), save the file and reload named. &lt;span class="anchor" id="line-213"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-214"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-215"&gt;&lt;/span&gt;&lt;/p&gt;&lt;p class="line874"&gt;if your domain is something like customer.yourdomain.com, then the records will look like that: &lt;span class="anchor" id="line-216"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-217"&gt;&lt;/span&gt;&lt;/p&gt;&lt;p class="line867"&gt;&lt;span class="anchor" id="line-218"&gt;&lt;/span&gt;&lt;/p&gt;&lt;pre&gt;_domainkey.customer.yourdomain.com.       IN      TXT     "t=y; o=-"&lt;br /&gt;&lt;span class="anchor" id="line-219"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span class="anchor" id="line-220"&gt;&lt;/span&gt;myselector._domainkey.customer.yourdomain.com.  IN      TXT     "k=rsa; t=y; p=MHwwDQYJKoZIhvcNAQEBBQADawAwaAJhAKJ2lzDLZ8XlVambQfMXn3LRGKOD5o6lMIgulclWjZwP56LRqdg5ZX15bhc/GsvW8xW/R5Sh1NnkJNyL/cqY1a+GzzL47t7EXzVc+nRLWT1kwTvFNGIoAUsFUq+J6+OprwIDAQAB"&lt;br /&gt;&lt;span class="anchor" id="line-221"&gt;&lt;/span&gt;&lt;/pre&gt;&lt;span class="anchor" id="line-222"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-223"&gt;&lt;/span&gt;&lt;p class="line874"&gt;Remember to also modify /etc/namedb/named.conf: &lt;span class="anchor" id="line-224"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-225"&gt;&lt;/span&gt;&lt;/p&gt;&lt;p class="line874"&gt;Add the following to your options { ... } section of named.conf &lt;span class="anchor" id="line-226"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-227"&gt;&lt;/span&gt;&lt;/p&gt;&lt;pre&gt;        check-names master ignore;&lt;br /&gt;&lt;span class="anchor" id="line-228"&gt;&lt;/span&gt;&lt;/pre&gt;&lt;span class="anchor" id="line-229"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-230"&gt;&lt;/span&gt;&lt;p class="line874"&gt;This will allow you to use _ (underscore). &lt;span class="anchor" id="line-231"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-232"&gt;&lt;/span&gt;&lt;/p&gt;&lt;p class="line874"&gt;You will have to edit and add that "check-names master ignore;" thing if you get the following error in your logs: &lt;span class="anchor" id="line-233"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-234"&gt;&lt;/span&gt;&lt;/p&gt;&lt;p class="line867"&gt;&lt;span class="anchor" id="line-235"&gt;&lt;/span&gt;&lt;/p&gt;&lt;pre&gt;Aug 28 15:02:33 noc1 named[83277]: pri/com/yourdomain.com:15: myselector._domainkey.yourdomain.com: bad owner name (check-names)&lt;br /&gt;&lt;span class="anchor" id="line-236"&gt;&lt;/span&gt;Aug 28 15:02:33 noc1 named[83277]: zone yourdomain.com/IN: loading master file pri/com/yourdomain.com: bad owner name (check-names)&lt;br /&gt;&lt;span class="anchor" id="line-237"&gt;&lt;/span&gt;&lt;/pre&gt;&lt;span class="anchor" id="line-238"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-239"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-240"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-241"&gt;&lt;/span&gt;&lt;p class="line874"&gt;The long string after ....."k=rsa; t=y; p= is your public key which i said you should keep for later use. &lt;span class="anchor" id="line-242"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-243"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-244"&gt;&lt;/span&gt;&lt;/p&gt;&lt;p class="line874"&gt;To test send an e-mail to dk at dk.crynwr.com . You will receive about 5 messages back from different addresses with test results. &lt;span class="anchor" id="line-245"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-246"&gt;&lt;/span&gt;&lt;/p&gt;&lt;p class="line874"&gt;If any of them says test passed you should be ok. &lt;span class="anchor" id="line-247"&gt;&lt;/span&gt;Send an e-mail to a yahoo.com e-mail address and check the headers.They should look like this: &lt;span class="anchor" id="line-248"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-249"&gt;&lt;/span&gt;&lt;/p&gt;&lt;p class="line867"&gt;&lt;span class="anchor" id="line-250"&gt;&lt;/span&gt;&lt;/p&gt;&lt;pre&gt;From Dan Caescu Tue Aug 28 06:20:08 2007&lt;br /&gt;&lt;span class="anchor" id="line-251"&gt;&lt;/span&gt;Return-Path: &lt;test@yourdomain.com&gt;&lt;br /&gt;&lt;span class="anchor" id="line-252"&gt;&lt;/span&gt;Authentication-Results: mta233.mail.mud.yahoo.com  from=yourdomain.com; domainkeys=pass (ok)&lt;br /&gt;&lt;span class="anchor" id="line-253"&gt;&lt;/span&gt;Received: from x.x.x.x  (EHLO relay.yourdomain.com) (x.x.x.y)&lt;br /&gt;&lt;span class="anchor" id="line-254"&gt;&lt;/span&gt;  by mta233.mail.mud.yahoo.com with SMTP; Tue, 28 Aug 2007 08:16:56 -0700&lt;br /&gt;&lt;span class="anchor" id="line-255"&gt;&lt;/span&gt;DomainKey-Signature: a=rsa-sha1; q=dns; c=nofws; s=myselector; d=yourdomain.com;&lt;br /&gt;&lt;span class="anchor" id="line-256"&gt;&lt;/span&gt;&lt;/test@yourdomain.com&gt;&lt;/pre&gt;&lt;span class="anchor" id="line-257"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-258"&gt;&lt;/span&gt;&lt;p class="line874"&gt;That should be all. &lt;span class="anchor" id="line-259"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-260"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-261"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-262"&gt;&lt;/span&gt;&lt;/p&gt;Good luck!&lt;br /&gt;&lt;br /&gt;PS: I also posted this here: &lt;a href="http://wiki.exim.org/DomainKeys"&gt;http://wiki.exim.org/DomainKeys&lt;/a&gt; You will also find there some other useful documentation.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/7193226236525813745-4075907542790042974?l=dancaescu.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://dancaescu.blogspot.com/feeds/4075907542790042974/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=7193226236525813745&amp;postID=4075907542790042974' title='2 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/7193226236525813745/posts/default/4075907542790042974'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/7193226236525813745/posts/default/4075907542790042974'/><link rel='alternate' type='text/html' href='http://dancaescu.blogspot.com/2007/09/exim-domainkeys-howto.html' title='Exim + DomainKeys Howto.'/><author><name>Dan Caescu</name><uri>http://www.blogger.com/profile/10188122621218786514</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>2</thr:total></entry></feed>
