TC is the linux tool used to manipulate the traffic control functionality in the kernel.

learn more… | top users | synonyms

4
votes
1answer
2k views

VLAN based rate limiting using tc

I have been trying to perform VLAN based rate limiting on an academic project I am working on. The project uses Openflow (with Beacon controller) and the network is emulated using Mininet. The network ...
0
votes
0answers
15 views

Gradual throttling total bandwidth

I have a server with a 30TB traffic allowance hosting (mostly) history images and would like to throttle one particular directory (the download image sizes) when necessary to avoid going over the ...
1
vote
1answer
6k views

Linux Traffic Control: qdisc mq

On my Linux system I see this: # ip link list .... 2: eth2: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc mq state UP mode DEFAULT qlen 1000 .... What's qdisc mq? In http://lartc.org/lartc....
0
votes
0answers
16 views

When add filter in tc have a “RTNETLINK answers: Invalid argument, We have an error talking to the kernel” error

Need help witch tc on debian 8. I add class rule like this "tc class add dev p514p1 parent 1:0 classid 1:0xA486 htb rate 20480Kbit ceil 102400Kbit quantum 2000 mtu 3000 burst 15k" and then add filter ...
4
votes
1answer
1k views

HTB.init / tc behind NAT

I have an Ubuntu 10 box that I'm trying to set up as a bandwidth-shaping router. The machine has one WAN interface, eth0 and two LAN interfaces, eth1 and eth2. NAT is configured using MASQUERADE as ...
1
vote
0answers
14 views

How to add latency and bandwidth-limit interface using tc?

I know I can add latency to an interface using this command: # tc qdisc add dev eth0 root netem delay 50ms In addition to latency, I want to limit the bandwidth of this interface to 100kbps. How ...
0
votes
0answers
7 views

Monitor network traffic by FireQOS class?

I'm using FireQOS (which is basically an abstraction on top of the Linux tc qdisc mechanism as well as iptables) to classify traffic into different bandwidth classes. I can watch the bandwidth per ...
1
vote
1answer
194 views

How to do traffic shaping (rate limiting) with TC per OpenVPN client

This question is related to another question with a great answer and script from @Oliver. The goal: I want to modify/extend the script provided in this answer to suit my requirements, which are as ...
1
vote
0answers
33 views

TC not classifying packets correctly based on iptables MARK

I have machineA that is connected to the internet via eth0. MachineB on the other hand is connected to machineA through a mesh and is connected to the internet via machineA. I am trying to give lower ...
-2
votes
2answers
80 views

Configure OpenVPN with many users [closed]

Similar to this question I am looking at connecting 1000's of concurrent users: OpenVPN performance: how many concurrent clients are possible? To save CPU cycles I would like to know if there is ...
-1
votes
2answers
43 views

OpenVPN Variables Passed via Script

Can someone explain and/or direct me to a summary of the variables that are available to be passed to OpenVPN upon a client connection? For example, what do the following $1, $2, $3, $4 values ...
0
votes
0answers
23 views

Add Filters to Users

I am running OpenVPN on Ubuntu 14.04 (dev tun) and I can't seem to get my learn-address script to run below I would like to run the learn-address script each time a user connects to OpenVPN that ...
0
votes
1answer
66 views

Bash Script Not Working

I hope this is an easy answer Problems: I placed the following bash script called learn-address.sh in the following folder: vi /etc/openvpn/netem/learn-address.sh Added the following (2) ...
2
votes
1answer
37 views

Bandwidth throttling linux to external subnets

I am looking to start up a new open-source mirror for my enterprise, but would also be interested in opening it up for external clients as well. However, for obvious reasons, I would like to limit ...
1
vote
2answers
148 views

How to setup a netem box

I'm trying to simulate different network condition based on factors such as latency, bandwidth and so on. I found that Netem is the best way to simulate different network condition. So my desired ...
1
vote
0answers
86 views

HTB scheduler unexpected behaviour, low priority traffic starving high priority traffic

I am working on assuring low delay for UDP traffic at the home gateway level. At this home gateway I have two types of traffic, TCP and UDP, and I assure differentiated treatment by using HTB. The ...
1
vote
0answers
102 views

linux tc qdisc pie (aqm) configuration with limited bandwidth

I would like to configure AQM PIE by using tc-qdisc, but at the same time I would like to limit the bandwidth to 1Mb/s. I have used similar configuration with fq_codel, i.e. I have limited the ...
2
votes
1answer
84 views

bandwidth larger than tc htb ceil in 10-Gigabit network

In classid 88:201, I set ceil 200mibps, but in fact data can be send at 218 Mibps. Any one have any ideas what I'm doing wrong? Cheers! tc qdisc add dev eth0 root handle 88: htb default 202 tc ...
0
votes
2answers
29 views

Traffic control - bulk downloads with scp makes sshd to lag

My goal is to limit bandwidth per system user with tc, IMQ interfaces and iptables. Right now i have problem with bulk downloads (i.e. scp) that is creating lag on interactive programs such as ssh ...
1
vote
1answer
23 views

traffic shaping using ifb redirect

I would like to use ifb to perform some shaping for multiple virtual interfaces. However, I am not sure how to tell the ifb interface to egress to a dedicated egress interface Right now vnet0 -> ...
5
votes
1answer
8k views

Using tc to delay packets to only a single IP address

I am new to using tc and netem. I want to delay packets being sent to a specific IP address. However, the commands below cause all packets on the system to be delayed, instead of just to the IP ...
0
votes
0answers
31 views

ubuntu 14.04 LTS issue with tc filter command

Friends, I am using HTB queues in an output port, and my filter condition uses both destination MAC address and VLAN ID. I am having problems to make this filter work together. I have tried almost ...
0
votes
0answers
158 views

tc add delay by specific port

Am trying to simulate WAN latency between an application server and an Oracle database server. The database server itself runs several instances, one of which is my applications 'local' instance, ...
0
votes
2answers
112 views

youtube through google chrome can not be identified by ndpi-netfilter

I have ndpi-netfilter installed on ubuntu and i need to shape the youtube traffic to 100kbps using tc module. I cassify all youtube traffic to a one class through the iptables and apply tc class to ...
1
vote
1answer
43 views

tc filters not working with DRR

I am trying to control the outgoing traffic from two VMs with the DRR qdisc. This is the hierarchy I want to have: root | qdisc drr ...
0
votes
1answer
195 views

linux tc: unstable rate using tbf qdisc

This is the first time I am experimenting with tc. What I am trying to achieve is to limit the download rate that passes through a Virtual Machine that acts as gateway. The VM has two Ethernet ...
1
vote
2answers
95 views

Percentual dynamic bandwidth control with tc

Does anyone know if tc (iproute2) can be used to percentually divide the currently available bandwidth? We're on a GPRS connection on which the available bandwidth changes frequently. What I want to ...
0
votes
1answer
87 views

Add latency and random packet drops excluding SSH packets

I want to add some random delay/drop to all packets excluding SSH packets. I can do that to all packets this way: tc qdisc change dev $NIC root netem delay 100ms 10ms 25% tc qdisc change dev $NIC ...
1
vote
1answer
345 views

How can I do traffic shaping in Linux by IP for both way communication?

Well, I've already gone through How can I do traffic shaping in Linux by IP? on serverfault & what I'm trying to achieve is pretty much same. Internet--------Linux Router----Switch-----Clients ...
0
votes
1answer
672 views

RTNETLINK answers: File exists when using netem with tc

So I simply get this error when I enter this command in my master VM: sudo tc qdisc add dev eth0 root netem delay 97ms RTNETLINK answers: File exists Any idea how that could be fixed? I am ...
0
votes
1answer
504 views

Is there a way to limit bandwidth per ip using HTB + a CIDR range in Linux?

I can create rules to limit a entire subnet or to limit individual ip addresses with tc and htb. I am looking to use CIDR ranges to keep things somewhat elegant. The machines in question are all ...
1
vote
1answer
106 views

QoS Traffic Shaping based on packet loss and latency for VPN

I am currently having the following situation: I am using a VPN (OpenVPN) over a rather unstable internet connection. This means the maximum bandwidth varies between 100kbs and 1mbit. Whenever the ...
7
votes
3answers
9k views

Resetting a queue discipline back to the default pfifo_fast one?

I'm trying to temporarily set a rate-limited queue discipline and then remove it a bit later: # /sbin/tc qdisc add dev eth1 root tbf rate 600kbit latency 50ms burst 1540 # /sbin/tc qdisc del dev eth1 ...
1
vote
0answers
34 views

iptables mark is not persisting after MASQUERADING [closed]

iptables -i eth0 -t mangle -I PREROUTING 1 -m mac --mac-source $mac -j MARK --set-mark 88 echo "1" > /proc/sys/net/ipv4/ip_forward iptables -A FORWARD -i wlan0 -o eth0 -m state --state ...
0
votes
1answer
182 views

Limit input on a given port with tc filter and u32 match

I'm trying to rate-limit all incoming traffic on ports 8128-8191. I've read everything I found, checked everything ten times, it still doesn't work. The commands: tc qdisc del dev eth0 root tc ...
2
votes
0answers
33 views

Traffic shaping linux shell users on a per-user basis

I have a debian 7 server with a number of shell users and I would like to limit upload and download rate on all interfaces (eth0, gre1, sit1) on a per user basis so each user has his own 75KB/s upload ...
1
vote
2answers
436 views

Linux: limit specific port rate by combining tc with iptables does not work as expected

The script blow tries to limit the incoming rate of the port 2000, when using iptables to mark the INPUT packets does not work, but OUTPUT works fine. I use nc -kl 2000 on machine 10.0.1.54 and iperf ...
0
votes
0answers
75 views

What is means in tc “Unparsable filter ID ”2:“”

I wrote a shell script for limit upload speed by tc and cgroup. #!/bin/bash -x mkdir -p /cgroup/imagecenter mount -t cgroup -o net_cls image_net /cgroup/imagecenter/ mkdir -p /cgroup/imagecenter/...
3
votes
2answers
621 views

Linux qos: tc DRR qdisc does not work

There is tc queue discipline DRR(Dificite Round Robin) . It has same capabilities, as HTB, but instead of using buckets, filled with tokens, it just assignes every queue some Dificit Counter. On ...
0
votes
0answers
56 views

TC - delete exact filter

Im't trying to automate traffic shaping on some system n one interface, using next script. This script adds classes and filters by one per class, width command like: tc filter add dev eth0 parent 1: ...
0
votes
1answer
166 views

RTNETLINK answers: Invalid argument while specifying packet loss by tc command

I am trying to specify packet loss by tc command on interface (port) 1 of switch part of network I have created using mininet : sudo tc qdisc change dev s1-eth1 root netem loss 0.1% but gettring ...
1
vote
0answers
195 views

Linux traffic shaping for multiple clients with tc [closed]

I need to divide bandwidth between several clients connected through IPSEC. I found this article: https://jve.linuxwall.info/blog/index.php?post/2010/10/16/How-can-I-do-traffic-shaping-in-Linux-by-...
0
votes
0answers
126 views

Bandwidth Policing on Linux gateway - not QoS

I have a linux server providing NAT to a large subnet (/16) using iptables to-destination + multiple external ip's to survive port exhaustion. I've looked at using tc / htb such as here Limiting ...
0
votes
0answers
304 views

Traffic Control in OpenStack Neutron with either TC or OpenVSwitch

As far as I know, QoS in OpenStack Neutron is still under development and not production-ready (I could be wrong on this point though, shout at me if so...), but we are required to implement traffic ...
2
votes
1answer
863 views

Limiting bandwidth on Ubuntu Linux

I am in the situation where I have to simulate a P2P-environment (for my masters thesis in computer science). To do that I am using Docker with Ubuntu to create a bunch of virtual machines that is ...
0
votes
1answer
429 views

How to limit outgoing traffic per IP Address using Linux TC

I want to limit outgoing traffic per IP address. For example I have a network interface eth0, having 1Gbps of bandwidth. I want to limit the whole network interface to 1Mbps each destination IP ...
1
vote
0answers
25 views

How do I cap each individual tcp stream, to a fixed maximum rate?

I've read but not in depth all the various traffic shaping docs and seen the long question on HSFC scheduling Does anyone really understand how HFSC scheduling in Linux/BSD works? looked at the ...
3
votes
3answers
275 views

Advanced dynamic routing with external program

I need to build a system in which i am able to route packets based on a number of parameters, such as port/protocol etc, which are somehow "normal", but also on other aspects, such as queue length, ...
0
votes
1answer
155 views

Using tc to delay packets to all IP address except for a single IP address

I'm familiar with this post here: Using tc to delay packets to only a single IP address Which will delay outbound packets to a single IP address. I want to do the opposite, which is to delay all ...
0
votes
1answer
73 views

Linux Traffic Shaping: ceil rate never reached

My application run on port 8080. I have this iptables command: iptables -A OUTPUT -t mangle -p tcp --sport 8080 -j MARK --set-mark 10 I have also theses TC rules: tc qdisc add dev eth0 root handle ...