Sphinxes0o0 / notes

Learning's notes and misc.
https://sphinxes0o0.github.io/notes/
2 stars 0 forks source link

[BSD][kernel]mbuf #14

Closed Sphinxes0o0 closed 6 months ago

Sphinxes0o0 commented 1 year ago

https://www.bsdcan.org/2004/papers/NetworkBufferAllocation.pdf

Sphinxes0o0 commented 1 year ago

https://github.com/freebsd/freebsd-src/blob/main/usr.bin/netstat/mbuf.c#L70

Sphinxes0o0 commented 1 year ago

https://github.com/freebsd/freebsd-src/blob/main/usr.bin/netstat/mbuf.c#L70

这个代码太新了不适合在QNX上面使用, qnx上面支持使用sysctl MIB的方式获取一些kern 的信息:

https://www.qnx.com/developers/docs/7.0.0/#com.qnx.doc.neutrino.lib_ref/topic/s/sysctl.html

进一步的阅读可以看这个: https://man.freebsd.org/cgi/man.cgi?sysctl(3)

TODO: 写一个像netstat -m 的小工具, 可以获取kern的mbuf信息, 同时监控一下使用

Sphinxes0o0 commented 1 year ago

https://www.qnx.com/developers/docs/7.0.0/index.html#com.qnx.doc.neutrino.utilities/topic/s/sysctl.html

Sphinxes0o0 commented 1 year ago

https://github.com/freebsd/freebsd-src/blob/main/usr.bin/netstat/mbuf.c#L70

这个代码太新了不适合在QNX上面使用, qnx上面支持使用sysctl MIB的方式获取一些kern 的信息:

https://www.qnx.com/developers/docs/7.0.0/#com.qnx.doc.neutrino.lib_ref/topic/s/sysctl.html

进一步的阅读可以看这个: https://man.freebsd.org/cgi/man.cgi?sysctl(3)

TODO: 写一个像netstat -m 的小工具, 可以获取kern的mbuf信息, 同时监控一下使用

还是要多看书 多学习

Sphinxes0o0 commented 6 months ago

看看FreeBSD 实现里面有没有这个mbuf 的资料吧