MLDonkey Forum Index
Homepage •  Bugs •  Tasks •  Patches •  SF.net Project Page •  ChangeLog •  German forum •  Links •  Wiki •  Downloads
 
 FAQFAQ   SearchSearch   MemberlistMemberlist   UsergroupsUsergroups   RegisterRegister 
 ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 
 
latest guarding.p2p and ipfilter.dat
Goto page 1, 2, 3, 4, 5, 6, 7, 8, 9  Next
 
Post new topic   Reply to topic    MLDonkey Forum Index -> General Discussion
View previous topic :: View next topic  
Author Message
MadMac
user


Joined: 03 Jun 2004
Posts: 110
Location: Singapore

PostPosted: Sat Jun 26, 2004 8:41 am    Post subject: latest guarding.p2p and ipfilter.dat Reply with quote

I've just created an up-to-date comprehensive guarding.p2p file with Blocklist Manager. If someone is interested, it's available for download at http://www.openmedia.info/p23.html.

Cheers,
Mac


Last edited by MadMac on Sun Aug 08, 2004 6:19 am; edited 1 time in total
Back to top
View user's profile Send private message
pango
Sage


Joined: 31 Oct 2002
Posts: 2436

PostPosted: Sat Jun 26, 2004 1:46 pm    Post subject: Reply with quote

Restarting the core isn't necessary.
mldonkey_command "set ip_blocking guarding.p2p" or something similar should be enough.
Back to top
View user's profile Send private message
MadMac
user


Joined: 03 Jun 2004
Posts: 110
Location: Singapore

PostPosted: Sat Jun 26, 2004 2:58 pm    Post subject: Reply with quote

Additional remark, if you restart with this huge list the PC may hang for some minutes with high CPU load until it has all data loaded. For my old K6-3 380MHz it takes about 6 minutes.

Please don't kill the process as I did. At the next start it set all the ini's back to default and I lost my non-default port settings resulting in download problems.

Cheers,
Mac
Back to top
View user's profile Send private message
spiralvoice
Sage


Joined: 06 Jan 2003
Posts: 3772
Location: Germany

PostPosted: Sat Jun 26, 2004 5:04 pm    Post subject: Reply with quote

Known problem: http://savannah.nongnu.org/bugs/index.php?func=detailitem&item_id=8002
_________________
Link overview and precompiled cores here: http://mldonkey.sourceforge.net/DownloadLinks
Back to top
View user's profile Send private message
pango
Sage


Joined: 31 Oct 2002
Posts: 2436

PostPosted: Sun Jun 27, 2004 9:00 pm    Post subject: Reply with quote

I think I've spotted the problem. ins recursively calls add_range, instead of calling itself. That breaks tree balancing, and worse cases (like loading already sorted lists) gets much worse...
Code:

Index: src/utils/net/ip_set.ml
===================================================================
--- src/utils/net/ip_set.ml     (revision 34)
+++ src/utils/net/ip_set.ml     (working copy)
@@ -28,9 +28,9 @@
       BL_Empty -> BL_Range (true, BL_Empty, br, BL_Empty)
     | BL_Range (red, left, br2, right) ->
        if Ip.compare br.blocking_end br2.blocking_begin < 0 then
-         fixup (BL_Range (red, (add_range left br), br2, right))
+         fixup (BL_Range (red, (ins left br), br2, right))
        else if Ip.compare br.blocking_begin br2.blocking_end > 0 then
-         fixup (BL_Range (red, left, br2, (add_range right br)))
+         fixup (BL_Range (red, left, br2, (ins right br)))
        else (* ok, comments aren't preserved. Beat me. *)
              (* left and right aren't simplified either *)
          let newr = {


Loading of guardian_full.p2p, testing of 10000 random IPs:
Before:
Code:

[run 1 times]: 750 WALL (295.46 usr +  3.43 sys = 298.89 CPU) @  0.00/s (n=1)
           (warning: too few iterations for a reliable count)
Blocked: 5451
[run 10 times]: 1103 WALL (417.94 usr +  4.09 sys = 422.03 CPU) @  0.02/s (n=10)

After:
Code:

IP blacklist: 12912 ranges loaded
[run 1 times]:  4 WALL ( 1.81 usr +  0.06 sys =  1.87 CPU) @  0.53/s (n=1)
           (warning: too few iterations for a reliable count)
Blocked: 5451
[run 10 times]:  1 WALL ( 0.45 usr +  0.01 sys =  0.46 CPU) @ 21.74/s (n=10)

With guardian_full.p2p, which is large and already sorted, loading is now over 100 times faster, and checking almost 1000 times faster...
Back to top
View user's profile Send private message
pango
Sage


Joined: 31 Oct 2002
Posts: 2436

PostPosted: Sun Jun 27, 2004 9:36 pm    Post subject: Reply with quote

MadMac wrote:
Please don't kill the process as I did. At the next start it set all the ini's back to default and I lost my non-default port settings resulting in download problems.


I think the easiest way to fix that is to add a flag whether initialization has been completed or not, and only update *.ini on exit if it's on:
Code:

Index: src/daemon/driver/driverInteractive.ml
===================================================================
--- src/daemon/driver/driverInteractive.ml      (revision 34)
+++ src/daemon/driver/driverInteractive.ml      (working copy)
@@ -178,16 +178,22 @@
       value onclick
   end
   
+let initialization_completed = ref false
+
 let save_config () =
   (try Unix32.flush () with e ->
         Printf2.lprintf "Exception %s while flushing\n" (Printexc2.to_string e)
   );
-  Options.save_with_help downloads_ini;
-  CommonComplexOptions.save ();
-  networks_iter_all (fun r ->
-      List.iter (fun opfile ->
-          Options.save_with_help opfile         
-      ) r.network_config_file);
+  if !initialization_completed then (
+    Options.save_with_help downloads_ini;
+    CommonComplexOptions.save ();
+    networks_iter_all (fun r ->
+        List.iter (fun opfile ->
+            Options.save_with_help opfile         
+        ) r.network_config_file);
+  ) else (
+    Printf2.lprintf "Initialization not completed, bypassing state saving\n"
+  );
   ()
     
 let age_to_day date =
Index: src/daemon/driver/driverMain.ml
===================================================================
--- src/daemon/driver/driverMain.ml     (revision 34)
+++ src/daemon/driver/driverMain.ml     (working copy)
@@ -490,6 +490,7 @@
     end;
   
   if !!create_mlsubmit then save_mlsubmit_reg ();
+  DriverInteractive.initialization_completed := true;
   DriverInteractive.save_config ();
   
   Unix32.max_cache_size := MlUnix.max_filedescs


That should also fix bug #8117.
Back to top
View user's profile Send private message
spiralvoice
Sage


Joined: 06 Jan 2003
Posts: 3772
Location: Germany

PostPosted: Sun Jun 27, 2004 9:50 pm    Post subject: Reply with quote

pango wrote:
With guardian_full.p2p, which is large and already sorted, loading is now over 100 times faster

WOW!
before: 1m50s, now approx. 3 seconds: IP blacklist: 10544 ranges loaded
And I thought I had to buy a new CPU Very Happy

[EDIT]Patchpack 2-5-16p is online - with this and other patches
Until CVS 2-5-22 comes out I will only release patchpacks for CVS 2-5-16[/EDIT]
_________________
Link overview and precompiled cores here: http://mldonkey.sourceforge.net/DownloadLinks
Back to top
View user's profile Send private message
pango
Sage


Joined: 31 Oct 2002
Posts: 2436

PostPosted: Sun Jun 27, 2004 11:39 pm    Post subject: Reply with quote

Btw ip_set_avl_tree was a misnomer, since it's a red-black tree... Silly me...
Back to top
View user's profile Send private message
MadMac
user


Joined: 03 Jun 2004
Posts: 110
Location: Singapore

PostPosted: Mon Jun 28, 2004 11:00 am    Post subject: Reply with quote

Cool Cool. Have to try it on my slow box. Spiralvoice, does the 16p include this change already? I'm a bit confused now because you put already a 16q in your list Question

p.s.....ooops, seh's gerade im deutschen Forum Razz
Back to top
View user's profile Send private message
spiralvoice
Sage


Joined: 06 Jan 2003
Posts: 3772
Location: Germany

PostPosted: Mon Jun 28, 2004 4:39 pm    Post subject: Reply with quote

One thing to add: CPU usage went down from 35% to 26% with the new core Very Happy
_________________
Link overview and precompiled cores here: http://mldonkey.sourceforge.net/DownloadLinks
Back to top
View user's profile Send private message
MadMac
user


Joined: 03 Jun 2004
Posts: 110
Location: Singapore

PostPosted: Wed Jul 21, 2004 3:01 pm    Post subject: Reply with quote

Updated. New data, zip format, new automatic download script.

Enjoy!
Mac
http://www.openmedia.info
Back to top
View user's profile Send private message
spiralvoice
Sage


Joined: 06 Jan 2003
Posts: 3772
Location: Germany

PostPosted: Wed Jul 21, 2004 10:54 pm    Post subject: Reply with quote

Hi,

I just saw a client downloading data, so far no surprise. But it had an IP which is in the blocklist, block_list shows 2 hits for this IP area, how is this possible? The file concerned is a completed file residing in a directory with priority 4, core is 2-5-16t. The client is trusted MLDonkey using Overnet protocol.

Does IP blocking only work for eDonkey + BT network?
[EDIT]I donīt know if itīs the right place but I think donkeyClient.read_first_message overnet is lacking the check for blacklisted IPīs[/EDIT]
_________________
Link overview and precompiled cores here: http://mldonkey.sourceforge.net/DownloadLinks
Back to top
View user's profile Send private message
MadMac
user


Joined: 03 Jun 2004
Posts: 110
Location: Singapore

PostPosted: Sun Jul 25, 2004 4:15 am    Post subject: Reply with quote

Filter lists updated. In additon there are now 2 new versions of ipfilter.dat available for use with eMule & Co.

Cheers,
Mac
Back to top
View user's profile Send private message
atordo
user


Joined: 02 Apr 2003
Posts: 237
Location: Spain

PostPosted: Mon Jul 26, 2004 12:13 am    Post subject: Reply with quote

MadMac, could you elaborate more on differences between guarding.p2p and guarding_full.p2p? I've seen that almost half of the full version is filled with "ghostofterror proxy". What is that? I'm just trying to decide if the download time and CPU cicles worth the pain.

Pango, I applied both patches (by hand, some lines do not match) to 2.5.21g and seem to work as expected.

Thanks to both.
Back to top
View user's profile Send private message
MadMac
user


Joined: 03 Jun 2004
Posts: 110
Location: Singapore

PostPosted: Mon Jul 26, 2004 12:44 am    Post subject: Reply with quote

@atordo

The details are explained at the website in the ipfilter part. This applies to guarding.p2p as well. Please take a look here: http://www.openmedia.info/p27.html
As I wrote before I would recommend the normal guarding.p2p for a standalone MLdonkey. May not be that safe but should be sufficient, especially if you run it under Linux/*nix (who cares about Spyware & Trojans Twisted Evil)...

If you like to create your own more specific lists you should take a look at http://www.bluetack.co.uk and look for Blocklist Manager. This tool can manage many lists from different sources and is very flexible.

Cheers,
Mac
Back to top
View user's profile Send private message
Display posts from previous:   
Post new topic   Reply to topic    MLDonkey Forum Index -> General Discussion All times are GMT
Goto page 1, 2, 3, 4, 5, 6, 7, 8, 9  Next
Page 1 of 9

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum


Sourceforge.net Logo