Like I said, there shouldn’t be any real impact on your bandwidth in the scenario you described; a trickle at most.
What you’ll want to do to confirm it is to install a bandwidth monitoring program. Then you can view your bandwidth usage and see any spikes—or low/no usage as the case may be.
(Then you can show your roommates the graphs and rub their noses in it.) :-D
Don't do it with Squid : you need control for everything, not just for HTTP on port 80.
The answer requires iptables with the '--quota' option, which implements network quotas by decrementing a byte counter with each packet. The argument of "--quota" is a value in bytes.
There shall be one chain for each user. First rule of the chain counts down a 13 GB quota for packets from 192.168.0.2
and accepts the packet if it is below quota:
iptables -A INPUT -p tcp -s 192.168.0.2 -m quota --quota 13958643712 -j ACCEPT
Second rule of the chain classify over-quota packets in a tc class of your choice :
iptables -A INPUT -p tcp -j CLASSIFY --set-class 1:12
Then it's all classic traffic shaping : http://tldp.org/HOWTO/Traffic-Control-HOWTO/
Of course, you need to use static IP allocation or make sure that DHCP allocates addresses fixed by device's MAC address - and you need to block all addresses but the identified ones of the devices belonging to one of the three users.
By the way, you mention that "when 2 people browse the internet they should get 1 Mbps each, and when 3 people access, they should get 2Mbps divided by 3" but you can do better than that when you set up your traffic classes hierarchy: your requirement should rather be "when two people browse the internet they should not get less that 1 Mbps each, and when three people access, they should get not get less that 2 Mbps divided by 3" so that each can get more if the other people use less than their guaranteed throughput... And tc lets you do that !
Since your router is supported by openwrt and dd-wrt, you have all the tools you need !
Best Answer
Ideally you want to do this on the router with QoS. There are several open source firmwares that do this very well (see Tomato or DD-WRT).
It doesn't look like your router supports those firmwares but that it does provide some level of QoS (see section 4.7.2 of the manual). Do some searching on configuring QoS for youtube and see if you can apply those rules with in your router settings.