question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Change or append/create rules

See original GitHub issue

I use tcconfig on multiple hosts where I execute commands via Ansible, therefore, I do not store state. I would like to be able to override rules (on per network basis) without affecting the other rules and, if the rules do not exist, I would like to append (--add) them in the current list of traffic shaping rules. This could be done either by introducing a new option or changing the logic of --change option.

Thanks.

Issue Analytics

  • State:closed
  • Created 6 years ago
  • Comments:8 (8 by maintainers)

github_iconTop GitHub Comments

1reaction
thombashicommented, Oct 17, 2017

@dastergon Sorry to bother you. I believe the problem fixed at tcconfig 0.16.1. Could you try this version?

# tcdel -d ens33 -a
# tcset --direction outgoing --dst-network 192.168.122.202 --delay 12milliseconds --rate 1Gbps --device ens33 --change
# tcset --direction incoming --dst-network 192.168.122.202 --delay 12milliseconds --device ens33 --rate 1Gbps --change
# tcset --direction outgoing --dst-network 192.168.122.203 --delay 12milliseconds --rate 1Gbps --device ens33 --change
# tcset --direction incoming --dst-network 192.168.122.203 --delay 12milliseconds --device ens33 --rate 1Gbps --change
# tcshow -d ens33
{
    "ens33": {
        "outgoing": {
            "dst-network=192.168.122.202/32, protocol=ip": {
                "filter_id": "800::800",
                "delay": "12.0ms",
                "rate": "1G"
            },
            "dst-network=192.168.122.203/32, protocol=ip": {
                "filter_id": "800::801",
                "delay": "12.0ms",
                "rate": "1G"
            }
        },
        "incoming": {
            "dst-network=192.168.122.202/32, protocol=ip": {
                "filter_id": "800::800",
                "delay": "12.0ms",
                "rate": "1G"
            },
            "dst-network=192.168.122.203/32, protocol=ip": {
                "filter_id": "800::801",
                "delay": "12.0ms",
                "rate": "1G"
            }
        }
    }
}
1reaction
thombashicommented, Oct 2, 2017

@dastergon Thank you for your confirmation. It sure seems to be one of the common usages. I would implement the feature in the next release.

Read more comments on GitHub >

github_iconTop Results From Across the Web

CubeRuleAppend - IBM
CubeRuleAppend appends a single line of rule text to a TM1® cube rule. ... a new rule will be created, containing only the...
Read more >
Mail flow rule actions in Exchange Server - Microsoft Learn
When you create or modify the rule in the Exchange Management Shell, use the ApplyHtmlDisclaimerTextLocation parameter with the value Append ...
Read more >
How to Append Disclaimer to Outgoing Emails in Exchange
There we can see wide range of options and previously created rules (if any). Now Click on the '+' Icon, and select “Create...
Read more >
how to make a rule to add (append) data to a longtext field
I can make an action to overwrite data for a field, but am struggling to work out how to append data to an...
Read more >
Add append/prepend common (pass)word rules #4134 - GitHub
Add append /prepend common (pass)word rules #4134 ... e.g. to what we have in password.lst - then create the prepend/append rules with those...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found