Linux - Networking This forum is for any issue related to networks or networking.
Routing, network cards, OSI, etc. Anything is fair game. |
Notices |
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
Are you new to LinuxQuestions.org? Visit the following links:
Site Howto |
Site FAQ |
Sitemap |
Register Now
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
|
 |
03-12-2013, 10:25 AM
|
#1
|
Member
Registered: Jun 2010
Distribution: Debian, Ubuntu, Win
Posts: 143
Rep:
|
Where to find error messages for tc?
Hi All,
I'm having a strange situation where it appears that some 'tc class' replace/add commands being run by a script are not actually taking place; and when the script later wants to remove these classes, it dies because the classes don't exist.
The strangest thing is that if I run the commands manually, there's no error and as far as I can tell, it happens at random.
Is there somewhere I can see errors that may be logged by tc? The script is not reporting any error when it tries to add the class; tc simply replies with an empty response; indicating success.
Any thoughts welcome.
Thanks
Anubis.
|
|
|
03-12-2013, 12:12 PM
|
#2
|
LQ Guru
Registered: Nov 2010
Location: Colorado
Distribution: OpenSUSE, CentOS
Posts: 5,573
|
Have you tried checking the exit status of tc with "$?" ?
No response doesn't necessarily mean it was successful.
|
|
|
03-17-2013, 10:17 PM
|
#3
|
Member
Registered: Jun 2010
Distribution: Debian, Ubuntu, Win
Posts: 143
Original Poster
Rep:
|
Hi Suicidaleggroll,
Thanks for the reply; upon deeper investigation this seems to be a 'hiccup' in tc.
Looking back through the processing logs, the first attempt which returns the 'RTNETLINK answers: No such file or directory' exits leaving the rest of my script triggers in place; at a later time a few minutes later the attempts to process the removal again and this time it goes through successfully!
So, the issue seems to be some kind of read error when processing the deletion of the tc records.
I am using a locking mechanism on all my scripts to ensure that only one script is modifying tc at any one time, so I don't think it should be an overwriting problem, but I'm not sure what else could be causing this issue?
I did try what you suggested to check $?, but this returns 0 on each tc rule insertion.
Thanks
Anubis.
|
|
|
03-17-2013, 10:59 PM
|
#4
|
Member
Registered: Jun 2010
Distribution: Debian, Ubuntu, Win
Posts: 143
Original Poster
Rep:
|
Hi Suicidaleggroll,
Thanks very much for your help; upon even further investigation and the fortunate luck of catching an issue as it happens, I've located the problem to a locking issue whereby another process was able to utilize the same class identifier when it shouldn't have.
Many thanks for your assistance.
Anubis.
|
|
|
All times are GMT -5. The time now is 03:40 AM.
|
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.
|
Latest Threads
LQ News
|
|