Slash Boxes
NOTE: use Perl; is on undef hiatus. You can read content, but you can't post it. More info will be forthcoming forthcomingly.

All the Perl that's Practical to Extract and Report

The Fine Print: The following comments are owned by whoever posted them. We are not responsible for them in any way.
More | Login | Reply
Loading... please wait.
  • Have you considered keeping a timestamp for each entry and sorting the output by the time the entry was added to the list? That'd tend to keep things smaller if you've mostly got additions to the list, since the changes will all be clustered at the end of the file. (Deletions would mess this up some, but no worse than what you've got now, I expeect)
    • It's complicated by the fact that this dnsbl zone is a merge of multiple zones, with the IP address returned being a bitmask of the zones. Some have timed out entries, but others are pretty static, and for the merged one it would be almost impossible to do easily.

      I think a diff is going to be much easier to make work. We should be able to check the return code from patch() to see if it applied, and if not resort to rsync. And maybe rsync once a day anyway just to be sure.
      • Hmm. Another thought just occurred to me, which is a merge of our two ideas...

        Do the diff, but then go through the diff and do all the <'s first, removing those lines. Then just add all the >'s at the end.