ALT Linux Community general discussions
 help / color / mirror / Atom feed
* [mdk-re] ipchains & accounting
@ 2001-09-03 19:05 rrrrr
  2001-09-04  9:17 ` Alexandre Redko
  0 siblings, 1 reply; 2+ messages in thread
From: rrrrr @ 2001-09-03 19:05 UTC (permalink / raw)
  To: mandrake-russian

Ктонибудь занимался этим вопросом или кто как считает трафик по выделенке.

Михаил




^ permalink raw reply	[flat|nested] 2+ messages in thread

* Re: [mdk-re] ipchains & accounting
  2001-09-03 19:05 [mdk-re] ipchains & accounting rrrrr
@ 2001-09-04  9:17 ` Alexandre Redko
  0 siblings, 0 replies; 2+ messages in thread
From: Alexandre Redko @ 2001-09-04  9:17 UTC (permalink / raw)
  To: mandrake-russian

Добрый день!

> кто как считает трафик по выделенке.

У нас такая штука (подарок провайдера):

/etc/rc.d/rc.account
--------------------------
#!/bin/sh

# Add new users under this line in address order!!!

/sbin/ipchains -N acct_in
/sbin/ipchains -N acct_out
/sbin/ipchains -N acct_bth

/sbin/ipchains -I input -j acct_in
/sbin/ipchains -I output -j acct_out
/sbin/ipchains -I input -j acct_bth
/sbin/ipchains -I output -j acct_bth

/sbin/ipchains -F acct_in
/sbin/ipchains -F acct_out
/sbin/ipchains -F acct_bth

/sbin/ipchains -A acct_in -i eth1
/sbin/ipchains -A acct_out -i eth1
/sbin/ipchains -A acct_bth -i eth1

# user1
/sbin/ipchains -A acct_in -s 10.0.0.2/32
/sbin/ipchains -A acct_out -d 10.0.0.2/32

# user2
/sbin/ipchains -A acct_in -s 10.0.0.3/32
/sbin/ipchains -A acct_out -d 10.0.0.3/32
......
----------------------------

Потом то, что пишут эти правила каждые 5 минут обсчитывается скриптом на
перле и пишется в файлы - общий трафик и поюзерно

Regards to All
Alexandr Redko
LU # 178842
ICQ # 75828152




^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2001-09-04  9:17 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2001-09-03 19:05 [mdk-re] ipchains & accounting rrrrr
2001-09-04  9:17 ` Alexandre Redko

ALT Linux Community general discussions

This inbox may be cloned and mirrored by anyone:

	git clone --mirror http://lore.altlinux.org/community/0 community/git/0.git

	# If you have public-inbox 1.1+ installed, you may
	# initialize and index your mirror using the following commands:
	public-inbox-init -V2 community community/ http://lore.altlinux.org/community \
		mandrake-russian@linuxteam.iplabs.ru community@lists.altlinux.org community@lists.altlinux.ru community@lists.altlinux.com
	public-inbox-index community

Example config snippet for mirrors.
Newsgroup available over NNTP:
	nntp://lore.altlinux.org/org.altlinux.lists.community


AGPL code for this site: git clone https://public-inbox.org/public-inbox.git