January 27th, 2003, 01:16 PM
It is not going to be a static list at all. It will be updated and changed during almost every access. I am storing IPs that hit my websites. Almost every IP that hits it will be unique and must be added into the list. Considerations towards finding an already existed copy of the same IP have to be taken, as I do not want to add the same IP twice.
January 27th, 2003, 01:19 PM
This doesn't give me high hopes! A program of such simple complexity that I am speaking of must be able to be compile and distributed to other flavors of Unix and have it work?
I will definitely do this. Good advice all around.
January 27th, 2003, 01:30 PM
i think you underestimate the complexity it takes to make such a program. especially without a database.
in this case, to save CPU power and harddisk access times, you probably would want to setup even two servers, one webserver and one database server.
January 27th, 2003, 01:47 PM
My database is going to be so simple though. Plus I have coded things exactly like this before in Perl and stored all the data in a flatfile as text. I just want to do the same thing except store it in binary perhaps as a linked list. It is just reading and writing to a disc. How incompatible can that get?
This is something I want to sell to other webhosters and webmasters, so I can not have any extravagant solutions like this. :(
January 27th, 2003, 02:01 PM
again, 12 hits per second is not simple.
for the compatibility issues: ever read about file locking? know the different behaviour of linux and windows? do you know that PERL does not support locking on one of these OSs (i canīt remember which one it was)
the problem is not what your program does. it is what like 20-50 instances of your program running at the same time will do and what different OSs will do to your program...
letīs end this part of the discussion. i say itīs complex, you say itīs easy. so just implement it and weīll see who is right :rolleyes:
January 27th, 2003, 02:03 PM
just as a side note which may or may not be useful:
i'm reading about randomness, in particular poisson curve/distribution stuff and the main first thing you get from this is that if something avarages at 12 per second that does not mean that typically each second you get 12. things come in bursts. 'an avarage of 12 per second' can easily make you think you'll usually get 12 per second and it won't fluctuate too much above or below 12 per second, when this is not actually the case in reality at all, so an avarage number ratio can easily give the wrong impression.
January 27th, 2003, 02:10 PM
Very true, balance. You might get 50 all in one second sometimes. I know that they traffic on my server sometimes is twice as high during peak hours as it is in low hours, so that means that 12/second goes to 24/second on average for those peak hours. Add that to the randomness you are talking about, then 50 in one second is easily attainable when dealing with 1,000,000 hits/day.