I'm working on a school project in which I try to simulate the network phenomenon of Buffer Bloating. This essentially is latency as a consequence of buffers in routers getting larger and larger in time because of the cheap prices of memory.
Now, to start on this project, I have already done some research on the linux "tc"-command and how to use it, but I fail to see how to set the right configuration for my needs. The situation is as follows; I have 3 computers. PC1 is connected to PC2, and PC2 is connected to PC3. In this configuration, PC2 is acting as the router in which a large buffer is used. Traffic is send from PC1 to PC3 over PC2. Now, my intention is to limit the bandwidth PC2 can use to send the incoming data from PC1 to PC3.
I was planning on doing this by setting a large buffer on PC2 with a delay on fetching the packets from the buffer to simulate a slower link. This should cause the large buffer to fill up and introduce latencies.
Now, I want to ask this community on ideas on how to configure this by using the "tc"-command, or maybe other tools that are suitable for the job. Or if you have other ideas on how to simulate buffer bloating, those are welcome too.
Thanks for your patience.