can-utils
can-utils copied to clipboard
Cansniffer freezing for about 5 seconds when filtering ID's using bitmask after runtime
i've recently noticed that cansniffer is freezing for a few seconds after adding or removing frames using a bitmask. (+500700) or (-1237FF), etc.
Hey @mitchdetailed,
can you give me details:
- Which kernel version are you using?
- Which can-utils version are you using?
- What are the steps to reproduce the issue on the command line?
regards, Marc
Hm @mitchdetailed - this issue is open for a while now.
Can you tell us the can-utils version, Marc was asking for? Did you get the can-utils via Debian/Ubuntu package (which is unfortunately pretty outdated) or did you build it on your own from this repository?
just the common package using sudo apt-get. i can confirm that it still is an issue when using masks. youtube video link will be supplied shortly
On Wed, May 4, 2022, 1:17 PM Oliver Hartkopp @.***> wrote:
Hm @mitchdetailed https://github.com/mitchdetailed - this issue is open for a while now.
Can you tell us the can-utils version, Marc was asking for? Did you get the can-utils via Debian/Ubuntu package (which is unfortunately pretty outdated) or did you build it on your own from this repository?
— Reply to this email directly, view it on GitHub https://github.com/linux-can/can-utils/issues/306#issuecomment-1117605559, or unsubscribe https://github.com/notifications/unsubscribe-auth/AI62NLWSLVSXCYKCWLT7YADVIKWLNANCNFSM5AKBKMDQ . You are receiving this because you were mentioned.Message ID: @.***>
https://youtu.be/rJkoJQktLWs
On Wed, May 18, 2022 at 12:55 PM Mitch Minton @.***> wrote:
just the common package using sudo apt-get. i can confirm that it still is an issue when using masks. youtube video link will be supplied shortly
On Wed, May 4, 2022, 1:17 PM Oliver Hartkopp @.***> wrote:
Hm @mitchdetailed https://github.com/mitchdetailed - this issue is open for a while now.
Can you tell us the can-utils version, Marc was asking for? Did you get the can-utils via Debian/Ubuntu package (which is unfortunately pretty outdated) or did you build it on your own from this repository?
— Reply to this email directly, view it on GitHub https://github.com/linux-can/can-utils/issues/306#issuecomment-1117605559, or unsubscribe https://github.com/notifications/unsubscribe-auth/AI62NLWSLVSXCYKCWLT7YADVIKWLNANCNFSM5AKBKMDQ . You are receiving this because you were mentioned.Message ID: @.***>
-- Minton Performance 615-977-9787
Thanks for the video! Never seen such behavior!
So still the questions from Marc stay open:
What is you Linux kernel version? (output of uname -a
)
What is your can-utils version? (output of dpkg -l can-utils
)
Hi @mitchdetailed ,
I think I found the problem.
Since this commit https://github.com/torvalds/linux/commit/d5f9023fa61ee8b94f37a93f08e94b136cf1e463 the removal of CAN_BCM jobs is delayed to remove some data structures in a safe way. I've never seen this effect but with the use of the 'old' BCM-based cansniffer
(which is now only available here https://github.com/linux-can/can-tests/blob/master/bcm/cansniffer.c) the delay of removing 2048 BCM jobs can be shown easily.
So this safety fix of the BCM obviously needs to be revisited in terms of performance :-/
To fix the problem for you:
- remove the out-dated can-utils package from your system with
apt remove --purge can-utils
- clone the latest can-utils from this repository
git clone https://github.com/linux-can/can-utils.git
-
cd can-utils
-
make
-
sudo make install
The new cansniffer
does not use the CAN_BCM but the CAN_RAW sockets (and supports 29bit CAN IDs).
in case nobody has told you today, you're awesome Oliver!
On Thu, May 19, 2022, 2:54 PM Oliver Hartkopp @.***> wrote:
Hi @mitchdetailed https://github.com/mitchdetailed ,
I think I found the problem.
Since this commit @.*** https://github.com/torvalds/linux/commit/d5f9023fa61ee8b94f37a93f08e94b136cf1e463 the removal of CAN_BCM jobs is delayed to remove some data structures in a safe way. I've never seen this effect but with the use of the 'old' BCM-based cansniffer which is now only available here https://github.com/linux-can/can-tests/blob/master/bcm/cansniffer.c the delay of removing 2048 BCM jobs can be shown easily.
So this safety fix of the BCM obviously needs to be revisited in term of performance :-/
To fix the problem for you:
- remove the out-dated can-utils package from your system with apt remove --purge can-utils
- clone the latest can-utils from this repository git clone https://github.com/linux-can/can-utils.git
- cd can-utils
- make
- sudo make install
The new cansniffer does not use the CAN_BCM but the CAN_RAW sockets (and supports 29bit CAN IDs).
— Reply to this email directly, view it on GitHub https://github.com/linux-can/can-utils/issues/306#issuecomment-1132137918, or unsubscribe https://github.com/notifications/unsubscribe-auth/AI62NLRQFNRA572RY5LRL3DVK2L6VANCNFSM5AKBKMDQ . You are receiving this because you were mentioned.Message ID: @.***>
in case nobody has told you today, you're awesome Oliver!
Thanks Mitch!
But as you can see, improvement can only happen when people like you use that stuff and provide valuable bug reports (including your eye-opening video!). So I can give that 'thank you' back to Tennessee !!