{"id":741,"date":"2012-11-04T22:15:09","date_gmt":"2012-11-04T21:15:09","guid":{"rendered":"http:\/\/diablo.craem.net\/wordpress\/?p=741"},"modified":"2012-11-04T22:15:09","modified_gmt":"2012-11-04T21:15:09","slug":"concatenar-rutas-estaticas-en-dhcp3-con-debian","status":"publish","type":"post","link":"https:\/\/diablo.craem.net\/?p=741","title":{"rendered":"Concatenar rutas est\u00e1ticas en dhcp3 con Debian"},"content":{"rendered":"<p>Otra entrada que es un apunte.<br \/>\nHoy me ha tocado a\u00f1adir en mi dhcp, 2 rutas est\u00e1ticas, una de clase A y otra de clase C. Esto, lo hab\u00ed\u00ada hecho hace tiempo con los dhcp de windows, pero con Linux no estaba tan claro.<br \/>\nSiguiendo los est\u00e1ndares, veo que las rutas est\u00e1ticas con clase se basan en la rfc 3442, de lectura obligada:<br \/>\nhttps:\/\/tools.ietf.org\/html\/rfc3442<br \/>\nY nos dice que a\u00f1adir varias, tiene que ser de la forma:<br \/>\n<code><br \/>\nClassless Route Option Format<br \/>\n   The code for this option is 121, and its minimum length is 5 bytes.<br \/>\n   This option can contain one or more static routes, each of which<br \/>\n   consists of a destination descriptor and the IP address of the router<br \/>\n   that should be used to reach that destination.<br \/>\n    Code Len Destination 1    Router 1<br \/>\n   +-----+---+----+-----+----+----+----+----+----+<br \/>\n   | 121 | n | d1 | ... | dN | r1 | r2 | r3 | r4 |<br \/>\n   +-----+---+----+-----+----+----+----+----+----+<br \/>\n    Destination 2       Router 2<br \/>\n   +----+-----+----+----+----+----+----+<br \/>\n   | d1 | ... | dN | r1 | r2 | r3 | r4 |<br \/>\n   +----+-----+----+----+----+----+----+<br \/>\n   In the above example, two static routes are specified.<br \/>\n<\/code><br \/>\nEn mi caso, quiero a\u00f1adir las siguientes rutas:<br \/>\n10.0.0.0 \/ 8 gateway: 192.168.2.251<br \/>\n192.168.5.0 \/ 24 gateway: 192.168.2.251<br \/>\nEditamos el fichero \/etc\/dhcp3\/dhcpd.conf y en mi caso, lo dejo tal que:<br \/>\n<code><br \/>\n# option definitions common to all supported networks\u00e2\u20ac\u00a6<br \/>\noption rfc3442-classless-static-routes 24, 192, 168, 5, 192, 168, 2, 251, 8, 10, 192, 168, 2, 251;<br \/>\n<\/code><br \/>\nPara la red 192.168.5.0\/24: 24, 192, 168, 5, 192, 168, 2, 251<br \/>\n                             |<br \/>\n                             |->red \/ 24<br \/>\nPara la red 10.0.0.0\/8    : 8, 10, 192, 168, 2, 251<br \/>\n                             |<br \/>\n                             |&#8211;> red \/ 8<br \/>\nEnjoy your dhcp.<\/p>\n","protected":false},"excerpt":{"rendered":"<p>Otra entrada que es un apunte. Hoy me ha tocado a\u00f1adir en mi dhcp, 2 rutas est\u00e1ticas, una de clase A y otra de clase C. Esto, lo hab\u00ed\u00ada hecho hace tiempo con los dhcp de windows, pero con Linux no estaba tan claro. Siguiendo los est\u00e1ndares, veo que las rutas est\u00e1ticas con clase se [&hellip;]<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[5],"tags":[58,63,162],"class_list":["post-741","post","type-post","status-publish","format-standard","hentry","category-linux","tag-debian","tag-dhcp3","tag-rfc3442"],"_links":{"self":[{"href":"https:\/\/diablo.craem.net\/index.php?rest_route=\/wp\/v2\/posts\/741","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/diablo.craem.net\/index.php?rest_route=\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/diablo.craem.net\/index.php?rest_route=\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/diablo.craem.net\/index.php?rest_route=\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/diablo.craem.net\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=741"}],"version-history":[{"count":0,"href":"https:\/\/diablo.craem.net\/index.php?rest_route=\/wp\/v2\/posts\/741\/revisions"}],"wp:attachment":[{"href":"https:\/\/diablo.craem.net\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=741"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/diablo.craem.net\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=741"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/diablo.craem.net\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=741"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}