Al final tuve que crear Cipher.repo como repositorio interno de CentOS

Hasta la mitad de la semana pasada, en Cipher la cosa estuvo muy tranquila, seguiamos actualizando nuestra pequeña granja de servidores CentOS (porque ni debian ni ubuntu pienso utilizar nunca) y estábamos en los temas de los updates y upgrades de la versiones de CentOS 4.4 a CentOS 5.

CentOS logo

Entonces vinieron los problemas, no me acuerdo que dia, el 15 o 16 de Mayo la línea se pego “al techo”, no se podia usar nada en lo que se refiere el internet, estaba la red bien plantada. No era facil darse cuenta a “ojo de buen cubero”, porque veias que los servidores estaban que descargaban un monton de cosas. Por mi cabeza me paso que habia tomado mis servers y ahi se me ponia la cosa “color hormiga”.

Ya cuando tomamos posesión de la situación, nos dimos cuenta de que se habian venido 2 grandes descargas:

  • Actualización de CentOS 4.4 a 4.5 (servidores aun sin upgrade a 5) con todo lo que eso trae en lo que se refiere a descargas.
  • Actualizaciones del CentOS 5, en donde se incluia el kernel-2.6.18-8.1.4.el5 con sources, headers y devel, bastante pesado diria yo para las podres lineas dedicadas que tenemos.

Como aqui no usamos Speedy ni similares, sino lineas dedicadas con IPs publicos, el ancho de banda es crítico. La cosa se tornó desesperante ya que nuestros clientes no podian ingresar a sus servicios de la forma convencional, dada la congestión interna que existia.

“A grandes problemas, grandes soluciones” reza el dicho, entonces lo que se me ocurrió como paleativo a los problemas, fue copiar las carpetas de los CentOS ya actualizados en /var/cache/yum que es donde se guardan las actualizaciones y copiarselas a las otras que aun no habian terminado de actualizar, para que las máquinas eviten estar descargando cosas de la red. Funcionó en algo, pero tambien lo tuvimos que hacer para las desktops que son CentOS tambien.

Era un caos absoluto en el tema de ancho de banda. Es que aquí nosotros si usamos Linux tanto en desktops como en servidores, no como ciertos “vecinitos de 2 pisos mas abajo” que dicen que son full Linux, pero todos sus desktops son Window$ XP.

Entonces, el lunes que la cosa seguia congestionada, no me acordaba en donde habia leido que uno se podia hacer su repositorio privado de CentOS, para evitar problemas de ancho de banda en redes grandes. Me fui a San Google y me puse a investigar un rato acerca de hacer repositorios privados.

El truco es muy sencillo, por medio de rsync lo que haces es sincronizar directorios (en las noches al inicio) para que contengan la misma información de los repositorios oficiales. Con esto obtienes la data y de ahi creas los archivos metadata para que el YUM los pueda entender por medio de la utilidad createrepo. En mi caso sincronicé los repositorios oficiales de CentOS base y updates y el de rpmforge.

Y de ahi hice la creación de los siguientes archivos a colocar como unicos (poniendo los demas en otras carpetas) en /etc/yum.repos.d/

/etc/yum.repos.d/Cipher-CentOS.repo

[base]
name=Cipher CentOS-$releasever – Base
baseurl=http://centos.cipher.com.pe/centos/$releasever/os/$basearch/
enabled=1

[updates]
name=Cipher CentOS-$releasever – Updates
baseurl=http://centos.cipher.com.pe/centos/$releasever/updates/$basearch
enabled=1

/etc/yum.repos.d/Cipher-rpmforge.repo

[rpmforge]
name = Cipher Red Hat Enterprise $releasever – RPMforge.net – dag
baseurl = http://centos.cipher.com.pe/dag/redhat/el5/en/$basearch/dag/
enabled = 1

Y listo…!!!

Con esto las maquinas se actualizan de forma automática, lo unico que hacen es ver que las actualizaciones esten descargadas y de inmediato se ponen a actualizar. Por ahi tengo otros repositorios activos como atrpms.net pero eso ya lo traigo del mismo internet porque no son actualizaciones críticas.

Espero que les ayude a conservar ancho de banda.

Alex Celi

731 Responses to “Al final tuve que crear Cipher.repo como repositorio interno de CentOS”

  1. This was really awesome to read. Thanks for sharing it. You made a long-term reader and I’ll be back to view more. Thank you for sharing.

  2. High Risk Merchant Account Provider

  3. I do trust all of the ideas you’ve presented for your post. They are very convincing and will definitely work. Still, the posts are too short for newbies. May you please lengthen them a bit from subsequent time? Thank you for the post.

  4. Good web site! I truly love how it is simple on my eyes and the data are well written. I am wondering how I might be notified when a new post has been made. I’ve subscribed to your RSS feed which must do the trick! Have a great day!

  5. fuck says:

    What a stuff of un-ambiguity and preserveness of valuable experience regarding unexpected emotions.|

  6. I’m a massive fan of this blog. I’ll return to see more sometime soon. Thank you for making it.

  7. May I simply just say what a comfort to discover someone that truly understands what they’re discussing over the internet. You certainly understand how to bring an issue to light and make it important. More people have to check this out and understand this side of your story. I was surprised that you’re not more popular since you surely have the gift.

  8. Greetings from Colorado! I’m bored to death at work so I decided to check out your site on my iphone during lunch break. I really like the knowledge you provide here and can’t wait to take a look when I get home. I’m surprised at how fast your blog loaded on my mobile .. I’m not even using WIFI, just 3G .. Anyways, great blog!|

  9. Hello, I log on to your blog like every week. Your writing style is witty, keep it up!|

  10. Can I simply just say what a relief to discover an individual who truly knows what they are talking about over the internet. You definitely understand how to bring an issue to light and make it important. More people need to check this out and understand this side of the story. I was surprised that you aren’t more popular since you most certainly possess the gift.

  11. This piece of writing will help the internet people for setting up new weblog or even a weblog from start to end.|

  12. I was able to find good information from your content.

  13. I would like to thank you for the efforts you’ve put in writing this blog. I’m hoping to see the same high-grade content by you in the future as well. In fact, your creative writing abilities has motivated me to get my very own website now 😉

  14. This is the right site for everyone who would like to understand this topic. You understand a whole lot its almost hard to argue with you (not that I personally will need to…HaHa). You definitely put a brand new spin on a subject that’s been written about for years. Excellent stuff, just great!

  15. Way cool! Some very valid points! I appreciate you writing this article and also the rest of the website is really good.

  16. Hello would you mind sharing which blog platform you’re using? I’m looking to start my own blog soon but I’m having a tough time selecting between BlogEngine/Wordpress/B2evolution and Drupal. The reason I ask is because your design seems different then most blogs and I’m looking for something completely unique. P.S Apologies for being off-topic but I had to ask!

  17. Hi there would you mind stating which blog platform you’re working with? I’m going to start my own blog soon but I’m having a hard time making a decision between BlogEngine/Wordpress/B2evolution and Drupal. The reason I ask is because your design and style seems different then most blogs and I’m looking for something unique. P.S Sorry for being off-topic but I had to ask!

  18. 부산출장 says:

    I love reading a post that can make people think. Also, thanks for allowing me to comment!

  19. Hi there! This post couldn’t be written any better! Reading this post reminds me of my previous room mate! He always kept chatting about this. I will forward this write-up to him. Pretty sure he will have a good read. Thank you for sharing!|

  20. filologo says:

    Hello i am kavin, its my first occasion to commenting anyplace, when i read this article i thought i could also create comment due to this brilliant paragraph.|

  21. This is the perfect blog for anybody who would like to understand this topic. You realize so much its almost hard to argue with you (not that I really would want to…HaHa). You certainly put a new spin on a subject that has been written about for ages. Wonderful stuff, just great!

  22. Yes! Finally something about keyword1.|

  23. Ward Walsh says:

    As I web site possessor I believe the content material here is rattling excellent , appreciate it for your efforts. You should keep it up forever! Good Luck.

  24. You’re so interesting! I don’t believe I’ve truly read through anything like that before. So wonderful to find another person with unique thoughts on this subject. Seriously.. many thanks for starting this up. This website is one thing that is needed on the internet, someone with a little originality!

Leave a Reply