manuales:servidor_squid
Diferencias
Muestra las diferencias entre dos versiones de la página.
| Ambos lados, revisión anteriorRevisión previaPróxima revisión | Revisión previa | ||
| manuales:servidor_squid [2011/04/15 17:29] – cayu | manuales:servidor_squid [2012/04/16 15:39] (actual) – [Permisos] cayu | ||
|---|---|---|---|
| Línea 70: | Línea 70: | ||
| === Comandos === | === Comandos === | ||
| - | ^^ Comando ^ Descripción | + | ^ Comando ^ Descripción ^ |
| |GET|Solicita el recurso ubicado en la URL especificada| | |GET|Solicita el recurso ubicado en la URL especificada| | ||
| |HEAD|Solicita el encabezado del recurso ubicado en la URL especificada| | |HEAD|Solicita el encabezado del recurso ubicado en la URL especificada| | ||
| Línea 79: | Línea 79: | ||
| === Encabezados === | === Encabezados === | ||
| - | ^^ Nombre del encabezado ^ Descripción | + | ^ Nombre del encabezado ^ Descripción ^ |
| |Accept|Tipo de contenido aceptado por el navegador| | |Accept|Tipo de contenido aceptado por el navegador| | ||
| |Accept-Charset|Juego de caracteres que el navegador espera| | |Accept-Charset|Juego de caracteres que el navegador espera| | ||
| Línea 109: | Línea 109: | ||
| === Códigos de respuesta === | === Códigos de respuesta === | ||
| - | ^^ Código ^ Mensaje ^ Descripción | + | ^ Código ^ Mensaje ^ Descripción ^ |
| |200|OK|La solicitud se llevó a cabo de manera correcta| | |200|OK|La solicitud se llevó a cabo de manera correcta| | ||
| |201|CREATED|Sigue a un comando POST e indica el éxito, la parte restante del cuerpo indica la dirección URL donde se ubicará el documento creado recientemente| | |201|CREATED|Sigue a un comando POST e indica el éxito, la parte restante del cuerpo indica la dirección URL donde se ubicará el documento creado recientemente| | ||
| Línea 482: | Línea 482: | ||
| * **cachemgr.conf** - Es el archivo de configuración principal del **Cache manager** | * **cachemgr.conf** - Es el archivo de configuración principal del **Cache manager** | ||
| + | |||
| + | == Archivos de LOG == | ||
| + | |||
| + | * **/ | ||
| + | * En este archivo se registran todos los pedidos HTTP, siendo sus campos : | ||
| + | * timestamp de la recepción de la petición | ||
| + | * Tiempo transcurrido entre la petición y la recepción | ||
| + | * Dirección IP del cliente | ||
| + | * Código de resultado HTTP | ||
| + | * Cantidad de bytes entregados al cliente | ||
| + | * Método HTTP utilizado - GET, POST, CONNECT | ||
| + | * URL solicitada | ||
| + | * Si hay autenticación, | ||
| + | * Desde donde se resolvió la petición, DIRECT o desde un PARENT proxy | ||
| + | * Tipo de contenido mime | ||
| + | * **/ | ||
| + | * Mensajes informativos o de error sobre el cache interno de Squid | ||
| + | * **/ | ||
| + | * Información de los objetos que pasaron por el cache | ||
| + | * **/ | ||
| + | * Información general del proceso squidGuard | ||
| + | * **/ | ||
| + | * Información del filtrado de reglas de squidGuard | ||
| ===== Controles de acceso ===== | ===== Controles de acceso ===== | ||
| Línea 540: | Línea 563: | ||
| ==== Autenticacion ==== | ==== Autenticacion ==== | ||
| + | Squid puede utilizar diferentes métodos de validación de usuarios, los mismo pueden ser independientes de Squid y se llamados por un helper. | ||
| + | |||
| + | |||
| + | |||
| + | Básicamente el helper nos devolvera **OK** ó **ERR** en base a la información que le hayamos proporcionado | ||
| + | |||
| + | === LDAP === | ||
| + | |||
| + | Ejemplo de configuración para un LDAP común | ||
| + | < | ||
| + | auth_param basic program / | ||
| + | |||
| + | auth_param basic children 5 | ||
| + | auth_param basic realm Web-Proxy | ||
| + | auth_param basic credentialsttl 1 minute | ||
| + | |||
| + | acl ldap-auth proxy_auth REQUIRED | ||
| + | |||
| + | http_access allow ldap-auth | ||
| + | http_access allow localhost | ||
| + | http_access deny all | ||
| + | </ | ||
| + | |||
| + | === ActiveDirectory W2003 - LDAP === | ||
| + | |||
| + | < | ||
| + | auth_param basic program / | ||
| + | </ | ||
| ==== Permisos ==== | ==== Permisos ==== | ||
| Línea 684: | Línea 735: | ||
| </ | </ | ||
| + | **Clases de Delay Pools** | ||
| - | ===== Referencias ===== | + | * Clase 1 : Limita el ancho de banda total para todos los que sean afectados por el delay pool |
| + | * Clase 2 : Limita el ancho de banda total y por cada usuario | ||
| + | * Clase 3 : Limita en total, por usuario y por red | ||
| - | http:// | ||
| - | http:// | ||
| - | http:// | ||
| + | |||
| + | |||
| + | |||
| + | |||
| + | |||
| + | |||
| + | |||
| + | |||
| + | |||
| + | === Filtrado === | ||
| + | |||
| + | Dentro del archivo **/ | ||
| + | |||
| + | < | ||
| + | redirect_program / | ||
| + | redirect_children 6 | ||
| + | </ | ||
| + | |||
| + | |||
| + | == Configuración de SquidGuard == | ||
| + | |||
| + | **/ | ||
| + | < | ||
| + | dbhome / | ||
| + | logdir / | ||
| + | |||
| + | destination bl_homerepair { | ||
| + | urllist blacklists/ | ||
| + | domainlist blacklists/ | ||
| + | logfile squidguard.log | ||
| + | } | ||
| + | |||
| + | destination bl_gardening { | ||
| + | urllist blacklists/ | ||
| + | domainlist blacklists/ | ||
| + | logfile squidguard.log | ||
| + | } | ||
| + | |||
| + | destination bl_culinary { | ||
| + | domainlist blacklists/ | ||
| + | logfile squidguard.log | ||
| + | } | ||
| + | |||
| + | destination bl_porn { | ||
| + | urllist blacklists/ | ||
| + | domainlist blacklists/ | ||
| + | expressionlist blacklists/ | ||
| + | logfile squidguard.log | ||
| + | } | ||
| + | |||
| + | destination bl_ringtones { | ||
| + | domainlist blacklists/ | ||
| + | logfile squidguard.log | ||
| + | } | ||
| + | |||
| + | destination bl_whitelist { | ||
| + | urllist blacklists/ | ||
| + | domainlist blacklists/ | ||
| + | logfile squidguard.log | ||
| + | } | ||
| + | |||
| + | destination bl_weapons { | ||
| + | urllist blacklists/ | ||
| + | domainlist blacklists/ | ||
| + | logfile squidguard.log | ||
| + | } | ||
| + | |||
| + | destination bl_kidstimewasting { | ||
| + | urllist blacklists/ | ||
| + | domainlist blacklists/ | ||
| + | logfile squidguard.log | ||
| + | } | ||
| + | |||
| + | destination bl_spyware { | ||
| + | domainlist blacklists/ | ||
| + | logfile squidguard.log | ||
| + | } | ||
| + | |||
| + | destination bl_audio-video { | ||
| + | urllist blacklists/ | ||
| + | domainlist blacklists/ | ||
| + | logfile squidguard.log | ||
| + | } | ||
| + | |||
| + | destination bl_webmail { | ||
| + | urllist blacklists/ | ||
| + | domainlist blacklists/ | ||
| + | logfile squidguard.log | ||
| + | } | ||
| + | |||
| + | destination bl_financial { | ||
| + | domainlist blacklists/ | ||
| + | logfile squidguard.log | ||
| + | } | ||
| + | |||
| + | destination bl_weather { | ||
| + | urllist blacklists/ | ||
| + | domainlist blacklists/ | ||
| + | logfile squidguard.log | ||
| + | } | ||
| + | |||
| + | destination bl_childcare { | ||
| + | urllist blacklists/ | ||
| + | domainlist blacklists/ | ||
| + | logfile squidguard.log | ||
| + | } | ||
| + | |||
| + | destination bl_virusinfected { | ||
| + | urllist blacklists/ | ||
| + | domainlist blacklists/ | ||
| + | logfile squidguard.log | ||
| + | } | ||
| + | |||
| + | destination bl_chat { | ||
| + | urllist blacklists/ | ||
| + | domainlist blacklists/ | ||
| + | logfile squidguard.log | ||
| + | } | ||
| + | |||
| + | destination bl_desktopsillies { | ||
| + | urllist blacklists/ | ||
| + | domainlist blacklists/ | ||
| + | logfile squidguard.log | ||
| + | } | ||
| + | |||
| + | destination bl_searchengines { | ||
| + | domainlist blacklists/ | ||
| + | logfile squidguard.log | ||
| + | } | ||
| + | |||
| + | destination bl_naturism { | ||
| + | urllist blacklists/ | ||
| + | domainlist blacklists/ | ||
| + | logfile squidguard.log | ||
| + | } | ||
| + | |||
| + | destination bl_aggressive { | ||
| + | urllist blacklists/ | ||
| + | domainlist blacklists/ | ||
| + | logfile squidguard.log | ||
| + | } | ||
| + | |||
| + | destination bl_clothing { | ||
| + | domainlist blacklists/ | ||
| + | logfile squidguard.log | ||
| + | } | ||
| + | |||
| + | destination bl_ecommerce { | ||
| + | urllist blacklists/ | ||
| + | domainlist blacklists/ | ||
| + | logfile squidguard.log | ||
| + | } | ||
| + | |||
| + | destination bl_marketingware { | ||
| + | domainlist blacklists/ | ||
| + | logfile squidguard.log | ||
| + | } | ||
| + | |||
| + | destination bl_astrology { | ||
| + | domainlist blacklists/ | ||
| + | logfile squidguard.log | ||
| + | } | ||
| + | |||
| + | destination bl_jobsearch { | ||
| + | urllist blacklists/ | ||
| + | domainlist blacklists/ | ||
| + | logfile squidguard.log | ||
| + | } | ||
| + | |||
| + | destination bl_gambling { | ||
| + | urllist blacklists/ | ||
| + | domainlist blacklists/ | ||
| + | logfile squidguard.log | ||
| + | } | ||
| + | |||
| + | destination bl_updatesites { | ||
| + | urllist blacklists/ | ||
| + | domainlist blacklists/ | ||
| + | logfile squidguard.log | ||
| + | } | ||
| + | |||
| + | destination bl_ads { | ||
| + | urllist blacklists/ | ||
| + | domainlist blacklists/ | ||
| + | expressionlist blacklists/ | ||
| + | logfile squidguard.log | ||
| + | } | ||
| + | |||
| + | destination bl_entertainment { | ||
| + | urllist blacklists/ | ||
| + | domainlist blacklists/ | ||
| + | logfile squidguard.log | ||
| + | } | ||
| + | |||
| + | destination bl_cleaning { | ||
| + | domainlist blacklists/ | ||
| + | logfile squidguard.log | ||
| + | } | ||
| + | |||
| + | destination bl_artnudes { | ||
| + | urllist blacklists/ | ||
| + | domainlist blacklists/ | ||
| + | logfile squidguard.log | ||
| + | } | ||
| + | |||
| + | destination bl_vacation { | ||
| + | urllist blacklists/ | ||
| + | domainlist blacklists/ | ||
| + | logfile squidguard.log | ||
| + | } | ||
| + | |||
| + | destination bl_sports { | ||
| + | urllist blacklists/ | ||
| + | domainlist blacklists/ | ||
| + | logfile squidguard.log | ||
| + | } | ||
| + | |||
| + | destination bl_blog { | ||
| + | urllist blacklists/ | ||
| + | domainlist blacklists/ | ||
| + | logfile squidguard.log | ||
| + | } | ||
| + | |||
| + | destination bl_religion { | ||
| + | urllist blacklists/ | ||
| + | domainlist blacklists/ | ||
| + | logfile squidguard.log | ||
| + | } | ||
| + | |||
| + | destination bl_mixed_adult { | ||
| + | domainlist blacklists/ | ||
| + | logfile squidguard.log | ||
| + | } | ||
| + | |||
| + | destination bl_frencheducation { | ||
| + | urllist blacklists/ | ||
| + | domainlist blacklists/ | ||
| + | logfile squidguard.log | ||
| + | } | ||
| + | |||
| + | destination bl_pets { | ||
| + | urllist blacklists/ | ||
| + | domainlist blacklists/ | ||
| + | logfile squidguard.log | ||
| + | } | ||
| + | |||
| + | destination bl_mobile-phone { | ||
| + | domainlist blacklists/ | ||
| + | logfile squidguard.log | ||
| + | } | ||
| + | |||
| + | destination bl_mail { | ||
| + | urllist blacklists/ | ||
| + | domainlist blacklists/ | ||
| + | logfile squidguard.log | ||
| + | } | ||
| + | |||
| + | destination bl_dating { | ||
| + | urllist blacklists/ | ||
| + | domainlist blacklists/ | ||
| + | logfile squidguard.log | ||
| + | } | ||
| + | |||
| + | destination bl_guns { | ||
| + | urllist blacklists/ | ||
| + | domainlist blacklists/ | ||
| + | logfile squidguard.log | ||
| + | } | ||
| + | |||
| + | destination bl_verisign { | ||
| + | domainlist blacklists/ | ||
| + | logfile squidguard.log | ||
| + | } | ||
| + | |||
| + | destination bl_cellphones { | ||
| + | domainlist blacklists/ | ||
| + | logfile squidguard.log | ||
| + | } | ||
| + | |||
| + | destination bl_beerliquorinfo { | ||
| + | domainlist blacklists/ | ||
| + | logfile squidguard.log | ||
| + | } | ||
| + | |||
| + | destination bl_onlinepayment { | ||
| + | domainlist blacklists/ | ||
| + | logfile squidguard.log | ||
| + | } | ||
| + | |||
| + | destination bl_government { | ||
| + | urllist blacklists/ | ||
| + | domainlist blacklists/ | ||
| + | logfile squidguard.log | ||
| + | } | ||
| + | |||
| + | destination bl_drugs { | ||
| + | urllist blacklists/ | ||
| + | domainlist blacklists/ | ||
| + | logfile squidguard.log | ||
| + | } | ||
| + | |||
| + | destination bl_beerliquorsale { | ||
| + | domainlist blacklists/ | ||
| + | logfile squidguard.log | ||
| + | } | ||
| + | |||
| + | destination bl_hygiene { | ||
| + | domainlist blacklists/ | ||
| + | logfile squidguard.log | ||
| + | } | ||
| + | |||
| + | destination bl_onlineauctions { | ||
| + | urllist blacklists/ | ||
| + | domainlist blacklists/ | ||
| + | logfile squidguard.log | ||
| + | } | ||
| + | |||
| + | destination bl_warez { | ||
| + | urllist blacklists/ | ||
| + | domainlist blacklists/ | ||
| + | logfile squidguard.log | ||
| + | } | ||
| + | |||
| + | destination bl_dialers { | ||
| + | urllist blacklists/ | ||
| + | domainlist blacklists/ | ||
| + | logfile squidguard.log | ||
| + | } | ||
| + | |||
| + | destination bl_antispyware { | ||
| + | urllist blacklists/ | ||
| + | domainlist blacklists/ | ||
| + | logfile squidguard.log | ||
| + | } | ||
| + | |||
| + | destination bl_adult { | ||
| + | urllist blacklists/ | ||
| + | domainlist blacklists/ | ||
| + | logfile squidguard.log | ||
| + | } | ||
| + | |||
| + | destination bl_instantmessaging { | ||
| + | urllist blacklists/ | ||
| + | domainlist blacklists/ | ||
| + | logfile squidguard.log | ||
| + | } | ||
| + | |||
| + | destination bl_news { | ||
| + | urllist blacklists/ | ||
| + | domainlist blacklists/ | ||
| + | logfile squidguard.log | ||
| + | } | ||
| + | |||
| + | destination bl_socialnetworking { | ||
| + | urllist blacklists/ | ||
| + | domainlist blacklists/ | ||
| + | logfile squidguard.log | ||
| + | } | ||
| + | |||
| + | destination bl_jewelry { | ||
| + | domainlist blacklists/ | ||
| + | logfile squidguard.log | ||
| + | } | ||
| + | |||
| + | destination bl_filehosting { | ||
| + | domainlist blacklists/ | ||
| + | logfile squidguard.log | ||
| + | } | ||
| + | |||
| + | destination bl_reaffected { | ||
| + | domainlist blacklists/ | ||
| + | logfile squidguard.log | ||
| + | } | ||
| + | |||
| + | destination bl_phishing { | ||
| + | urllist blacklists/ | ||
| + | domainlist blacklists/ | ||
| + | logfile squidguard.log | ||
| + | } | ||
| + | |||
| + | destination bl_medical { | ||
| + | urllist blacklists/ | ||
| + | domainlist blacklists/ | ||
| + | logfile squidguard.log | ||
| + | } | ||
| + | |||
| + | destination bl_violence { | ||
| + | urllist blacklists/ | ||
| + | domainlist blacklists/ | ||
| + | logfile squidguard.log | ||
| + | } | ||
| + | |||
| + | destination bl_personalfinance { | ||
| + | urllist blacklists/ | ||
| + | domainlist blacklists/ | ||
| + | logfile squidguard.log | ||
| + | } | ||
| + | |||
| + | destination bl_sportnews { | ||
| + | urllist blacklists/ | ||
| + | domainlist blacklists/ | ||
| + | logfile squidguard.log | ||
| + | } | ||
| + | |||
| + | destination bl_banking { | ||
| + | urllist blacklists/ | ||
| + | domainlist blacklists/ | ||
| + | logfile squidguard.log | ||
| + | } | ||
| + | |||
| + | destination bl_sexuality { | ||
| + | urllist blacklists/ | ||
| + | domainlist blacklists/ | ||
| + | logfile squidguard.log | ||
| + | } | ||
| + | |||
| + | destination bl_games { | ||
| + | urllist blacklists/ | ||
| + | domainlist blacklists/ | ||
| + | logfile squidguard.log | ||
| + | } | ||
| + | |||
| + | destination bl_sect { | ||
| + | domainlist blacklists/ | ||
| + | logfile squidguard.log | ||
| + | } | ||
| + | |||
| + | destination bl_onlinegames { | ||
| + | urllist blacklists/ | ||
| + | domainlist blacklists/ | ||
| + | logfile squidguard.log | ||
| + | } | ||
| + | |||
| + | destination bl_hacking { | ||
| + | urllist blacklists/ | ||
| + | domainlist blacklists/ | ||
| + | logfile squidguard.log | ||
| + | } | ||
| + | |||
| + | destination bl_shopping { | ||
| + | domainlist blacklists/ | ||
| + | logfile squidguard.log | ||
| + | } | ||
| + | |||
| + | destination bl_radio { | ||
| + | urllist blacklists/ | ||
| + | domainlist blacklists/ | ||
| + | logfile squidguard.log | ||
| + | } | ||
| + | |||
| + | destination bl_proxy { | ||
| + | urllist blacklists/ | ||
| + | domainlist blacklists/ | ||
| + | logfile squidguard.log | ||
| + | } | ||
| + | |||
| + | |||
| + | |||
| + | destination excepciones { | ||
| + | expressionlist excepciones.destexprlist | ||
| + | urllist excepciones.desturllist | ||
| + | domainlist excepciones.destdomainlist | ||
| + | logfile squidguard.log | ||
| + | } | ||
| + | |||
| + | destination Restricciones_a_mano { | ||
| + | urllist Restricciones_a_mano.desturllist | ||
| + | domainlist Restricciones_a_mano.destdomainlist | ||
| + | expressionlist Restricciones_a_mano.destexprlist | ||
| + | logfile squidguard.log | ||
| + | } | ||
| + | |||
| + | src admin { | ||
| + | ip | ||
| + | } | ||
| + | | ||
| + | |||
| + | acl { | ||
| + | default { | ||
| + | pass excepciones !denegados_a_mano !bl_audio-video !bl_proxy !bl_warez !bl_porn !bl_filehosting !bl_adult | ||
| + | redirect http:// | ||
| + | } | ||
| + | } | ||
| + | </ | ||
| + | |||
| + | En el apartado **redirect** indicamos al squidGuard que nos muestre un contenido especial cuando intentamos acceder a ubicaciones filtradas. Cuando vemos **%u** nos referimos a la variable de url, y podemos obtenerla por medio de los datos GET | ||
| + | |||
| + | Otras variables que podemos exportar por GET son : | ||
| + | * **%a** La dirección IP del cliente | ||
| + | * **%i** El nombre de usuario del cliente | ||
| + | * **%n** Dominio al que se intento acceder | ||
| + | * **%p** Variable that holds the REQUEST_URI, | ||
| + | * **%s** Variable that holds the matched source group (client group) or " | ||
| + | * **%t** Variable that holds the matched destination group (target group) or " | ||
| + | * **%u** Variable that holds the requested URL. | ||
| + | |||
| + | |||
| + | |||
| + | == Blacklist == | ||
| + | |||
| + | |||
| + | Listado de sitios prohibidos organizados por categorias. A continuacion describimos cada unas de las mismas: | ||
| + | |||
| + | ^Categoria^Descripcion^ | ||
| + | |ads | ||
| + | |adult | ||
| + | |aggressive | ||
| + | |antispyware | ||
| + | |artnudes | ||
| + | |astrology | ||
| + | |audio-video | ||
| + | |banking | ||
| + | |beerliquorinfo | ||
| + | |beerliquorsale | ||
| + | |Blog | ||
| + | |cellphones | ||
| + | |chat | ||
| + | |childcare | ||
| + | |cleaning | ||
| + | |clothing | ||
| + | |culnary | ||
| + | |dating | ||
| + | |desktopsillies | ||
| + | |dialers | ||
| + | |drugs | ||
| + | |ecommerce | ||
| + | |entertainment | ||
| + | |filehosting | ||
| + | |frencheducation | ||
| + | |gambling | ||
| + | |games | ||
| + | |gardening | ||
| + | |government | ||
| + | |guns | ||
| + | |hacking | ||
| + | |homerepair | ||
| + | |hygiene | ||
| + | |instantmessaging | ||
| + | |jewelry | ||
| + | |jobsearch | ||
| + | |kidstimewasting | ||
| + | |mail | ||
| + | |marketingware | ||
| + | |medical | ||
| + | |mixed_adult | ||
| + | |naturism | ||
| + | |news | ||
| + | |onlineauctions | ||
| + | |onlinegames | ||
| + | |onlinepayment | ||
| + | |personalfinance | ||
| + | |pets | ||
| + | |phishing | ||
| + | |porn | ||
| + | |proxy | ||
| + | |radio | ||
| + | |religion | ||
| + | |ringtones | ||
| + | |searchengines | ||
| + | |sect | ||
| + | |sexuality | ||
| + | |shopping | ||
| + | |socialnetworking | ||
| + | |sportnews | ||
| + | |sports | ||
| + | |spyware | ||
| + | |updatesites | ||
| + | |vacation | ||
| + | |violence | ||
| + | |virusinfected | ||
| + | |warez | ||
| + | |weather | ||
| + | |weapons | ||
| + | |webmail | ||
| + | |whitelist | ||
| + | |||
| + | === Referencias === | ||
| + | |||
| + | ^URL^Descripción^ | ||
| + | |http:// | ||
| + | |http:// | ||
| + | |http:// | ||
| + | |http:// | ||
| + | |||
| + | ===== Balanceo de Carga y Alta Disponibilidad ===== | ||
| + | |||
| + | ==== LVS (Linux Virtual Server) + Heartbeat ==== | ||
| + | |||
| + | ==== Red Hat Cluster Suite ==== | ||
| + | |||
| + | Supongamos que tenemos dos servidores proxy 10.1.2.103 y 10.1.2.105 y ambos atienden por una ip virtual 10.1.2.106 | ||
| + | |||
| + | === LVS === | ||
| + | |||
| + | Configuracion de la utilidad IPVS de Linux Virtual Server | ||
| + | |||
| + | |||
| + | == / | ||
| + | |||
| + | |||
| + | < | ||
| + | -A -t 10.1.2.106: | ||
| + | -a -t 10.1.2.106: | ||
| + | -a -t 10.1.2.106: | ||
| + | </ | ||
| + | |||
| + | |||
| + | == ipvsadm -L == | ||
| + | |||
| + | < | ||
| + | IP Virtual Server version 1.2.1 (size=4096) | ||
| + | Prot LocalAddress: | ||
| + | -> RemoteAddress: | ||
| + | TCP lvs-proxy.cayu.com.ar: | ||
| + | -> proxy2.cayu.com.ar: | ||
| + | -> proxy1.cayu.com.ar: | ||
| + | </ | ||
| + | |||
| + | El sistema balancea por medio del algoritmo wlc. | ||
| + | |||
| + | === Piranha === | ||
| + | |||
| + | Piranha es un producto de clustering de Red Hat, incluye el demonio de control de LVS de Red Hat, y una herramienta de configuracion web del cluster. | ||
| + | |||
| + | La herramienta de monitoreo de piranha tiene dos caracteristicas principales : | ||
| + | |||
| + | |||
| + | * Soporte integrado de Heartbeat. | ||
| + | * Chequeo de disponibilidad de servicios en los servidores. | ||
| + | |||
| + | |||
| + | La herramienta de monitoreo de piranha usa el proceso heartbeat por medio de mensajes UDP entre los nodos balanceados y un servicio que se encarga de monitorear que ciertos procesos esten corriendo. | ||
| + | |||
| + | Configuracion de Piranha en el servidor primario | ||
| + | |||
| + | == / | ||
| + | |||
| + | |||
| + | <code java> | ||
| + | serial_no = 69 | ||
| + | primary = 10.1.2.103 | ||
| + | service = lvs | ||
| + | backup_active = 1 | ||
| + | backup = 10.1.2.105 | ||
| + | heartbeat = 1 | ||
| + | heartbeat_port = 539 | ||
| + | keepalive = 4 | ||
| + | deadtime = 18 | ||
| + | network = direct | ||
| + | debug_level = NONE | ||
| + | monitor_links = 0 | ||
| + | virtual proxy { | ||
| + | | ||
| + | | ||
| + | | ||
| + | port = 8080 | ||
| + | pmask = 255.255.255.0 | ||
| + | send = "GET cache_object:// | ||
| + | | ||
| + | | ||
| + | | ||
| + | | ||
| + | | ||
| + | | ||
| + | | ||
| + | | ||
| + | | ||
| + | | ||
| + | | ||
| + | } | ||
| + | | ||
| + | | ||
| + | | ||
| + | | ||
| + | } | ||
| + | } | ||
| + | </ | ||
| + | |||
| + | Configuracion de Piranha en el servidor secundario | ||
| + | |||
| + | == / | ||
| + | |||
| + | |||
| + | <code java> | ||
| + | serial_no = 55 | ||
| + | primary = 10.1.2.103 | ||
| + | service = lvs | ||
| + | backup_active = 1 | ||
| + | backup = 10.1.2.105 | ||
| + | heartbeat = 1 | ||
| + | heartbeat_port = 539 | ||
| + | keepalive = 4 | ||
| + | deadtime = 18 | ||
| + | network = direct | ||
| + | debug_level = NONE | ||
| + | monitor_links = 0 | ||
| + | virtual proxy { | ||
| + | | ||
| + | | ||
| + | | ||
| + | port = 8080 | ||
| + | pmask = 255.255.255.0 | ||
| + | send = "GET cache_object:// | ||
| + | | ||
| + | | ||
| + | | ||
| + | | ||
| + | | ||
| + | | ||
| + | | ||
| + | | ||
| + | | ||
| + | | ||
| + | } | ||
| + | | ||
| + | | ||
| + | | ||
| + | | ||
| + | } | ||
| + | } | ||
| + | </ | ||
| + | |||
| + | |||
| + | |||
| + | |||
| + | Se agrego la configuracion para la interface virtual lo:0 / | ||
| + | < | ||
| + | DEVICE=lo:0 | ||
| + | IPADDR=10.1.2.106 | ||
| + | NETMASK=255.255.255.255 | ||
| + | # | ||
| + | # If you're having problems with gated making 127.0.0.0/8 a martian, | ||
| + | # you can change this to something else (255.255.255.255, | ||
| + | # | ||
| + | ONBOOT=yes | ||
| + | NAME=lvsIP | ||
| + | </ | ||
| + | |||
| + | |||
| + | |||
| + | ===== Errores comúnes ===== | ||
| + | |||
| + | Si nuestro Squid no responde y encontramos mensaje como este en nuestro // | ||
| + | |||
| + | < | ||
| + | 2011/05/31 02:13:19| WARNING! Your cache is running out of filedescriptors | ||
| + | </ | ||
| + | |||
| + | Dentro de nuestro archivo **/ | ||
| + | |||
| + | < | ||
| + | * - nofile 8192 | ||
| + | </ | ||
| + | |||
| + | |||
| + | Y en nuestro **squid.conf** | ||
| + | |||
| + | < | ||
| + | max_filedesc 8192 | ||
| + | </ | ||
| + | |||
| + | Otras opciones de configuración de Squid que nos pueden ayudar con cierto manejo de sockets o recursos son: | ||
| + | |||
| + | < | ||
| + | pconn_timeout 30 seconds | ||
| + | server_persistent_connections off | ||
| + | </ | ||
| + | |||
| + | ===== Referencias ===== | ||
| + | |||
| + | http:// | ||
| + | http:// | ||
| + | http:// | ||
| + | http:// | ||
| http:// | http:// | ||
| --- // | --- // | ||
manuales/servidor_squid.1302888596.txt.gz · Última modificación: 2011/04/15 17:29 por cayu
