OpenTSDB / tcollector

Data collection framework for OpenTSDB
http://opentsdb.net
GNU Lesser General Public License v3.0
513 stars 359 forks source link

Too many close() syscall when collecting data #417

Open jimmyxian opened 5 years ago

jimmyxian commented 5 years ago

In my environment, about 1000000 close() syscalls produced by my own collector every 10 seconds. Almost takes 300ms when doing close FDs. After analysis, I find the following reasons.

Also, after review the history patch, I find the patch which setclose_fds from False to True. https://github.com/OpenTSDB/tcollector/commit/7b5659db0dfbc3915cf16f90e3fbf92e1deec1da#diff-50bd42e8d38bbdf7c24f69ae5e25165f @tsuna

Any good idea to solve to this?

vasiliyk commented 6 months ago

Xian, could you reconfirm that you can still reproduce the bug?