Dear Monks,
I have a log file which records system usage on a server. I have a session start time and an end time. I would like to know how many concurrent users are accessing the system. Here is what I have done so far. I have created a new field for the duration of the session. Any transaction that does not last more than one second (i.e. 00:00:00) is ignored. I converted my dates from ISO format (yyyy-mm-dd hh:mm:ss to epoch time and am hoping to create a data structure to iterate over each enumeration in order to establish an intersection/concurrence. Logically, it seems like such a daunting task. So I wanted to discuss this case with the pros to find out how you all would address this problem. I am thinking of what would be the best way to implement this. For instance, most users would be connected for less than a couple of hours. So there is no reason to analyze data from the stack that is irrelevant! Any ideas or advise to guide this poor, lost monk? Thanks a lot.

In reply to How to Iterate to Identify Concurrent Users by Anonymous Monk

Title:
Use:  <p> text here (a paragraph) </p>
and:  <code> code here </code>
to format your post, it's "PerlMonks-approved HTML":



  • Posts are HTML formatted. Put <p> </p> tags around your paragraphs. Put <code> </code> tags around your code and data!
  • Titles consisting of a single word are discouraged, and in most cases are disallowed outright.
  • Read Where should I post X? if you're not absolutely sure you're posting in the right place.
  • Please read these before you post! —
  • Posts may use any of the Perl Monks Approved HTML tags:
    a, abbr, b, big, blockquote, br, caption, center, col, colgroup, dd, del, details, div, dl, dt, em, font, h1, h2, h3, h4, h5, h6, hr, i, ins, li, ol, p, pre, readmore, small, span, spoiler, strike, strong, sub, summary, sup, table, tbody, td, tfoot, th, thead, tr, tt, u, ul, wbr
  • You may need to use entities for some characters, as follows. (Exception: Within code tags, you can put the characters literally.)
            For:     Use:
    & &amp;
    < &lt;
    > &gt;
    [ &#91;
    ] &#93;
  • Link using PerlMonks shortcuts! What shortcuts can I use for linking?
  • See Writeup Formatting Tips and other pages linked from there for more info.