Socket handling system + start working on monitor records + count_line script (pretty useless)