[Maria-developers] SO_REUSEPORT and mariadb
hi guys, i was reading the SO_REUSEPORT of kernel 3.9, and i didn't found it in mariadb maybe we could use it? here are the SO_REUSEPORT topics: https://lwn.net/Articles/542629/ http://linux.dell.com/files/presentations/Linux_Plumbers_Conf_2010/Scaling_t... here the important parts: ------------------ 1)The first of the traditional approaches is to have a single listener thread that accepts all incoming connections and then passes these off to other threads for processing. The problem with this approach is that the listening thread can become a bottleneck in extreme cases. In early discussions<http://thread.gmane.org/gmane.linux.network/102140/focus=102150> on SO_REUSEPORT, Tom noted that he was dealing with applications that accepted 40,000 connections per second. Given that sort of number, it's unsurprising to learn that Tom works at Google. 2)The second of the traditional approaches used by multithreaded servers operating on a single port is to have all of the threads (or processes) perform an accept() call on a single listening socket in a simple event loop of the form: while (1) { new_fd = accept(...); process_connection(new_fd); } ------------------ i didn -- Roberto Spadim
ops.. i didn't tested yet, but instead of: setup socket bind accept "fork" execute we will have something like: "fork" setup socket bind aceep execute the problem is one process (other mysql process not the current one) running the same port that's a nice thing (when changing mysql version) but it's a problem too (two different versions of mysql running on the same port) well i will try some tests and with time i will report again, any news are wellcome too =]
participants (1)
-
Roberto Spadim