Archive for the 'TV series' Category

My Greasemonkey script for TVsubtitles

I’m often going to TVsubtitles to download subtitles for TV shows episodes. But the original page doesn’t provide an optimized flow: for example, on the home page there are two sections called “Latest subtitles” and “Most downloaded subtitles”, but they don’t link to the subtitle files. Instead they link to intermediate nagging pages where you then can download the subtitles.

For example, today it appears like this:

tvsub00

Without Greasemonkey script

the Weeds 5×01 doesn’t link to the subtitle file, but links actually to an intermediate page:

tvsub01

Intermediate (and useless) download page

To remediate this and get direct download links, I’ve made the following Greasemonkey script:

// ==UserScript==
// @name           tvsubtitles.net
// @namespace      tvsubtitles.net
// @description    tvsubtitles.net
// @include        http://www.tvsubtitles.net/*
// ==/UserScript==

// http://www.tvsubtitles.net/subtitle-63109.html (/subtitle-) -->
// http://www.tvsubtitles.net/download-63109.html (/download-)

var allLinks, thisLink;

xpath = '//a[contains(@href, "subtitle-")]';

allLinks = document.evaluate(xpath,document,
    null,
    XPathResult.UNORDERED_NODE_SNAPSHOT_TYPE,
    null);

for (var i = 0; i < allLinks.snapshotLength; i++) {
	thisLink = allLinks.snapshotItem(i);
	thisLink.href = thisLink.href.replace(/subtitle-/,  "download-");

	if( thisLink.title != "" ) {
	   thisLink.firstChild.textContent = thisLink.firstChild.textContent + " (" + thisLink.title + ")";
	}
}

With that script, the link to the intermediate page is replaced by a link to the subtitle file, and some information about the release corresponding to that sub file is also added:

tvsub02

Using my Greasemonkey script

UPDATE: I’ve just seen that there are 2 similar existing scripts on userscripts.org. At least mine is the only one that add the Release info to the links ;-).

showRSS — all your tv shows, one feed, their torrent

tvrss.net is down… maybe it’s just temporary… I hope so.

In the meantime, to feed your uTorrent with the latest episodes of your favorite TV Shows, you can switch to showRSS (free registration required):

showRSS — all your tv shows, one feed, their torrent.

Programa uTorrent para bajar tus series favoritas

Como ya explicaba con anterioridad, tengo en casa un pequeño servidor (PII 350MHz 256MB Ram) bajo Linux en el cual corre uTorrent sobre Wine. Me encanta uTorrent por su facilidad a la hora de configurarlo para bajar cualquier cosa, por ejemplo los ultimos capitulos de tus series americanas favoritas en VO, sin tener que estar siempre pendiente de buscar en los multiples buscadores de torrents si han salido o no los capitulos.

Con uTorrent, es muy facil configurarlo mediante el uso de feeds RSS, en los que se publican links a los torrents. Los feeds se actualizan automaticamente con los ultimos capitulos de series, uTorrents los lee periodicamente: ya esta! Cuando sale un capitulo nuevo, uTorrent simplemente lo baja!

A veces exieten varios torrents para un mismo capitulo. Para no bajarlo varias veces, uTorrent tiene una funcionalidad llamada “Smart Episode Filter”.

Por ultimo, desde la version 1.8 (recomendada), es capaz, de bajar los PROPER / REPACK (versiones corregidas de los capitulos), cuando salgan (no los considera como torrents duplicados). Eso es genial, porque antes, si baja un cap. y despues salia un REPACK, igual no te enterabas y acababas viendo un capitulo con defectos.

Pues nada, ahi va el tema:

  • El tutorial sobre como configurar uTorrent con feeds RSS, pensaba hacerlo yo, pero hoy he descubierto este, de EZTV (leer easy-TV), que esta muy bien hecho, ademas tambien vale para Azureus.
  • Yo uso como fuente de RSS esta web: TvRSS, donde creo que hay un feed para todas y cada una de las series existentes (no se cuantas hay, pero es una pasada)

Como truco, tambien decir que me he registrado un perfil en Mininova: lo que aporta esto es que te dan un link privado a un RSS (hum, interesante!) de los ultimos torrents que hayas marcado como “bookmark” (con la estrellita) en Mininova! Esto es genial! Por ejemplo, si un dia busco algo en Mininova (una ISO, un mp3,…) y quiero bajarlo, no necesito bajarme el torrent, y abrirlo en mi uTorrent: simplement lo marco como bookmark en Mininova y voila! Pasado 20 minutos mi uTorrent refresca mi feed de bookmarks de Mininova y descubre que he añadido un torrent nuevo, y lo baja! Y todo remotamente, puedes estar en el trabajo, en casa de un amigo, en un cybercafe o en la playa (hum, con conexion wifi FON por ejemplo) ;-) y aun asi tu uTorrent sigue bajando lo que le digas!

Simplemente me encanta uTorrent y los RSS!

µTorrent en Linux (III): Tuning TCP/IP

En este nuevo post de mi serie sobre µTorrent en Linux, hablaré de los parametros de kernel que he modificado en mi maquina para intentar optimizar el tema de conexiones.

La verdad es que he cojido estos parametros de algun manual sobre como tunear un servidor para tener un buen rendimiento cuando asume muchas conexiones, lo cual deberia servir en nuestro caso.

Estas lineas se introducen en el fichero /etc/sysctl.conf y para cargarlas usamos el comando: sysctl -p. Ahi van los parametros, con comentarios:

# Enable fast recycling of TIME-WAIT sockets status

net.ipv4.tcp_tw_recycle=1

# tcp_fin_timeout is the time to hold a socket in state
# FIN-WAIT-2 when the socket is closed at the server.

net.ipv4.tcp_fin_timeout=30

# One of the problems found in servers with many simultaneous TCP
# connections is the large number of connections that are open but unused.
# TCP has a keepalive function that probes these connections and
# drops them after tcp_keepalive_time

net.ipv4.tcp_keepalive_time=1800

# max OS send buffer size (wmem) and receive buffer size (rmem)
# for queues on all protocols (8388608=8MB)

net.core.wmem_max=8388608
net.core.rmem_max=8388608

# In addition, you should also use the following commands for send and receive
# buffers. They specify three values: minimum size, initial size, and maximum
# size. The third value must be the same as or less than the value of
# wmem_max and rmem_max.

net.ipv4.tcp_rmem = 4096 87380 8388608
net.ipv4.tcp_wmem = 4096 87380 8388608

# When the server is heavily loaded or has many clients with bad connections
# with high latency, it can result in an increase in half-open connections.
# This is very common for Web servers, especially when there are many dial-up
# users. These half-open connections are stored in the backlog connections
# queue. You should set this value to at least 4096 (the default is 1024).

net.ipv4.tcp_max_syn_backlog=4096

# don't cache ssthresh from previous connection
net.ipv4.tcp_no_metrics_save = 1

Lo cierto es que no tengo datos para comparar si va mejor asi, pero el caso es que a mi me va de fabula!

µTorrent en Linux (II): Gestión del ancho de banda

Siguiendo con la serie de posts sobre como montar un servidor de bittorent en Linux, hablaré esta vez del tema del ancho de banda.

En efecto, Bittorent es un protocolo muy goloso: en pocas palabras, se suele comer todo el ancho de banda disponible (si le dejas).

Para bajar rapido, eso puede ser genial! Pero si queremos poder hacer algo mas, como navegar por ejemplo, conviene restringir un poco el Bittorrent.

En mi caso, uso el “scheduler” de µTorrent para lograrlo:
* Durante la noche (de 01:00 a 07:00 entre semana, y de 01:00 a 10:00 el fin de semana), cuando no me importa poder navegar o no (porque duermo!), lo dejo en “Full Speed”, es decir que no restrinjo. Si µTorrent tiene algo encolado para bajar/subir, podra disfrutar de todo el ancho de banda disponible.
* El resto del dia, limito el uTorrent a 90kB/s en bajada y 15kB/s en subida, asi no se come todo el ancho de banda.
* Cuando no se esta bajando nada, no suele consumirse casi nada de ancho de banda (logicamente).

utorrent bandwidth scheduler



Close
Powered by ShareThis