Projet

Général

Profil

Révision e55e233b

IDe55e233b225163d845c452f4cb2da11632a43045
Parent 84866ca6
Enfant e384c4b6

Ajouté par XciD il y a presque 12 ans

Update rtom_mem

Add category for people who have multiple sessions

Voir les différences:

plugins/rtorrent/rtom_mem
26 26
#	socket		rTorrent's rpc socket (scgi_local)	- using scgi_local	- needed, when "src" is set to "socket"
27 27
#	ip		rTorrent's ip address			- using scgi_port	- needed, when "src" is NOT set to "socket"
28 28
#	port		rTorrent's scgi port (scgi_port)	- using scgi_port	- needed, when "src" is NOT set to "socket"
29
#
29
#	category        Change graph category
30 30
#
31 31
# Configuration example
32 32
#
......
34 34
#	user username
35 35
#	env.src socket
36 36
#	env.socket /home/user/torrent/.socket/rpc.socket
37
#	env.category Category	
37 38
#
38 39
#	[rtom_mem]
39 40
#	env.ip 127.0.0.1
......
48 49
}
49 50

  
50 51
if ( $ARGV[0] and $ARGV[0] eq "config" ) {
52
	my $category = $ENV{"category"} || "";
51 53
	print "graph_title rTorrent memory usage\n";
52 54
	print "graph_args --base 1024 --lower-limit 0\n";
53 55
	print "graph_vlabel Bytes\n";
54
	print "graph_category rTorrent\n";
56
	print "graph_category rTorrent ".${category}."\n";
55 57
	print "mem.label Memory usage\n";
56 58
	print "mem.info Memory osage of rTorrent\n";
57 59
	print "mem.type GAUGE\n";

Formats disponibles : Unified diff