Page 1 of 2 12 LastLast
Results 1 to 15 of 84

Thread: HOWTO: MLDonkey as Download Manager for WL-700g [draft v.0.1]

Hybrid View

Previous Post Previous Post   Next Post Next Post
  1. #1

    HOWTO: MLDonkey as Download Manager for WL-700g

    MLDonkey - Multi-platform, multi-protocol client. It's include support for FTP, HTTP, ed2k and BitTorrent protocols and it's a best replacement for standard ASUS Download Manager.

    Foreplay:
    1. kfurge custom firmware must be installed on your WL-700g box (with rc.local file uploaded and optware packages installed).
    2. The ksoftirqd CPU eating patch must be applied via rc.local (To ensure the patch is working try to execute /opt/bin/top at the WL-700 shell, "Load average" value have to be less then 1.00).
    3. bzip2 package must be installed on your WL-700 box (/opt/bin/ipkg install bzip2).


    Installation (based on russian thread):
    1. First of all, you have to disable standard ASUS Download Manager. Via "Web Manager" of your WL-700 box, go to Configuration -> Advanced Setting -> Applications and set "Enable Download Master?" and "Enable Download Daemon?" to "No".
    2. telnet (or putty) to your WL-700 box and do the next commands:
      Code:
      cd /opt/bin
      wget http://oleg.wl500g.info/bin/mlnet.lite.gz
      gunzip mlnet.lite.gz
      chmod +x mlnet.lite
    3. Next, you have to make run-script for MLDonkey, let's name it /opt/etc/init.d/mlnet. (/opt/bin/vi /opt/etc/init.d/mlnet then press <I> and type next content):
      Code:
      #!/bin/sh
      
      set backuphome=$HOME
      set backuptmp=$TMPDIR
      export HOME=/shares/MYVOLUME1/MYSHARE1/
      export TMPDIR=/shares/MYVOLUME1/MYSHARE1/.mldonkey/temp
      rm -f /shares/MYVOLUME1/MYSHARE1/.mldonkey/*.tmp
      /opt/bin/mlnet.lite -allowed_ips '127.0.0.1/8 192.168.1.0/24' &
      export HOME=$backuphome
      export TMPDIR=$backuptmp
      (to save file press <ESC> <CTRL>+<:> <X> <ENTER>)
    4. Installation complete, now it's time to try run MLDonkey for the first time, type "/opt/etc/init.d/mlnet" in shell, you should see something like that:
      Code:
      # 2007/07/18 23:55:47 [cO] Starting MLDonkey 2.8.5 ...
      2007/07/18 23:55:47 [cO] Language EN, locale ASCII, ulimit for open files 1024
      2007/07/18 23:55:47 [cO] MLDonkey is working in /shares/MYVOLUME1/MYSHARE1/.mldonkey
      2007/07/18 23:55:47 [cO] creating new MLDonkey base directory in /shares/MYVOLUME1/MYSHARE1/.mldonkey
      2007/07/18 23:55:47 [cO] loaded language resource file
      2007/07/18 23:55:47 [DNS] Resolving [(none)] ...
      2007/07/18 23:55:47 [DNS] Resolving [www.mldonkey.org] ...
      Setting option allowed_ips
      2007/07/18 23:55:47 [cO] Logging in /shares/MYVOLUME1/MYSHARE1/.mldonkey/mlnet.log
      2007/07/18 23:55:50 [dMain] Core started
      It's OK, the "/.mldonkey" hidden directory was created successfully and we can move to the next step.
    5. Add run-string of MLDonkey to your rc.local file (via "vi" editor like step 3):
      Code:
      /opt/etc/init.d/mlnet
    6. Now it's time to reboot your WL-700 box. If it's OK after rebooting, you'll get the
      Code:
      192.168.1.1 at 4000 port for telnet acess to your MLDonkey
      192.168.1.1 at 4001 port for GUI control to your MLDonkey
      192.168.1.1 at 4080 port for web access to your MLDonkey
      So you can control your MLDonkey via web-interface http://192.168.1.1:4080/.


    Setting up the MLDonkey GUI
    1. We will use the sancho to control MLDonkey. Download it and install.
    2. At the first run "Host setup manager wizard" will pop up. Click "Next" on "preference file" step. Leave blank "core spawned from" on "Core settings" step and move to next one. Specify your WL-700 IP (ex.: 192.168.1.1) on next step and click "Add as new entry", then select your entry (192.168.1.1:4001) and click "Make current selection the default". Select old default entry (127.0.0.1:4001) and delete it clicking "Delete entry". It's done, press "Connect" to connect to your WL-700 MLDonkey and run sancho main window.
    3. The next important step is to set your bandwidth settings correctly. Press right mouse button on sancho tray icon and go to menu "Bandwidth settings -> Bandwidth settings", the "Bandwidth" dialogue wil pop up. Set the values of your bandwidth (max_hard_download_rate and max_hard_upload_rate) for "High bandwidth" preset, about half of it for medium preset and about 1/3 of capacity for low preset. Now you can easy switch the bandwidth used by MLDonkey.
    4. Little more tricks: go to Tools -> Preferences -> sancho:Main and check options "On close: minimize to systray", "On minimize: minimize to systray" and "On start: minimize to systray". In "Sanch:Windows regestry" section of preferences window check "Register association" for ed2k:// protocol, scroll down this tab and click "Update Windows registry". On next tab "File Extensions" select "Register association" for bittorrent (.torrent) and click "Update Windows registry". On more thing your better to do is to move sancho shortcut from desktop to Start->Autorun.


    Thats all, now you have fully-functional, stable, fast and multi-protocol download manager on you WL-700 box.

    Any comments?
    Last edited by mawr; 19-07-2007 at 13:55.

  2. #2
    Great tutorial! Much better than the built-in download manager :-)

    For some reason though, i can't execute the mlnet startscript, but when i execute the commands manually, mldonkey starts up without a problem :-)

    I do have 1 major problem though - i cant get the port forwarding for mldonkey right.

    I have configured mldonkey to use port 46680 (by using Sancho, "BT-client_port"), and then forwarded port 46680 to 127.0.0.1 (which should be the router itself), but that is not working :-(.

    I have also tryed to forward port 46680 to 192.168.1.1 without sucess. I have been using the webinterface for this, but i can remember something about some "iptables" commands back when i was messing around with a debian server, maybe that is what i need to do?

    Any suggestions? :-)

    And once again, thank you for this great tutorial!

  3. #3
    Ah, i figured it out by using the famous search function :-)

    The problem is that the ports need to be in the "INPUT" chain in iptables, not FORWARD.

    You can add these by running this command (This will of course open port 3400, you can just replace that with whatever port you have configured mldonkey for, allthough it is a good idea to change it from the original port, as it is not allowed to use this port on many trackers, and many ISP's are slowing down trafic on that port)

    iptables -I INPUT 7 -p tcp --dport 3400-j ACCEPT

    You can add this line to rc.local to make it permanent.

    Still not getting more than about 50kb/s.

    Should i specify max_hard_download_rate as kbit or kb/s?
    Last edited by Henrikh; 06-08-2007 at 14:02.

  4. #4
    Hi,

    Can someone confirm if MLDonkey can support encryption for torrent downloads?

    My ISP does throttling so its impossible to use torrents without encryption turned on to bypass them...

    thanks!

  5. #5
    I haven't seen any option for enabling encryption or anything like that in the bittorrent options. I dont know how bittorrent encryption works, but i'm afraid it would be rather hard for the small 266mhz MIPS processor to handle such a task.

  6. #6

    Bit torrent help

    Hello, i tired downloading MLdmonkey but i am having some problems,
    [Bhavdip@(none) bin]$wget http://oleg.wl500g.info/bin/mlnet.lite.gz
    --21:57:28-- http://oleg.wl500g.info/bin/mlnet.lite.gz
    => `mlnet.lite.gz'
    Resolving oleg.wl500g.info... 158.250.11.254, 212.192.248.17
    Connecting to oleg.wl500g.info|158.250.11.254|:80... connected.
    HTTP request sent, awaiting response... 200 OK
    Length: 786,362 (768K) [application/x-gzip]
    mlnet.lite.gz: Permission denied

    Cannot write to `mlnet.lite.gz' (No such file or directory).
    I don't know why i keep getting permission denied? I am logged in via shell.

  7. #7
    Quote Originally Posted by Henrikh View Post
    Ah, i figured it out by using the famous search function :-)

    The problem is that the ports need to be in the "INPUT" chain in iptables, not FORWARD.

    You can add these by running this command (This will of course open port 3400, you can just replace that with whatever port you have configured mldonkey for, allthough it is a good idea to change it from the original port, as it is not allowed to use this port on many trackers, and many ISP's are slowing down trafic on that port)

    iptables -I INPUT 7 -p tcp --dport 3400-j ACCEPT

    You can add this line to rc.local to make it permanent.

    Still not getting more than about 50kb/s.

    Should i specify max_hard_download_rate as kbit or kb/s?
    Found solution:
    iptables -I FORWARD -p tcp --dport 6882 -j ACCEPT
    iptables -t nat -I PREROUTING -i eth1 -p tcp --dport 6882 -j DNAT --to-destination 192.168.1.1
    You should add this to the mlnet init script. This one works well on my wl500gp, speed is around 120-140kb/s instead of 50-55kb/s.

    Note: yous might need to change 'eth1' to ppp0 or something like that. (Network Interface of the ISP/WAN)
    Source: http://mldonkey.sourceforge.net/WhatFirewallPortsToOpen

    One question: I understand this is a 'lite' version of mldonkey, but I want DC. Who knows how to enable it? (Without recomplieing)

  8. #8
    Quote Originally Posted by viktike View Post
    Found solution:


    You should add this to the mlnet init script. This one works well on my wl500gp, speed is around 120-140kb/s instead of 50-55kb/s.

    Note: yous might need to change 'eth1' to ppp0 or something like that. (Network Interface of the ISP/WAN)
    Source: http://mldonkey.sourceforge.net/WhatFirewallPortsToOpen

    One question: I understand this is a 'lite' version of mldonkey, but I want DC. Who knows how to enable it? (Without recomplieing)
    Well by just adding the port to the input chain did it for me (I checked with a port scanner, and the trackers also reported me as "connectable" :-). The slow speed was due to a bug in the old 2.8.5 mlnet version, with mlnet 2.9.1 i get way better performance. I have reached speeds approaching 500kb/s, but i limit the speed, else the CPU is completely overloaded, and thereby increasing the respond-time for other services significantly.

    I guess you can't just enable DC++ support without recompiling, as far as i understand the code that should handle the DC++ protocol is not included in the compilation to minimize space usage.
    Last edited by Henrikh; 11-01-2008 at 16:59.

  9. #9
    Guys,

    I'm adding MLDonkey to my upcoming firmware image. Are there any other ports besides the BT ports (6882-6899) that I should open through the firewall to make ML Donkey more usable?

    - K.C.
    Last edited by kfurge; 20-01-2008 at 03:06. Reason: Fix ports

  10. #10

    Limit upload speed of MlDonkey

    After some struggling, I managed to get mldonkey working. Greet tutorial, thanks. Finally I will be able to download edonkey files, without leaving on my pc.

    Does anyone know a way to limit the upload speed of Mldonkey without affecting the download speed? In Belgium, there are still no internet providers that give you an unlimited amount of data upload. Therefore, I have to limit this speed because if I consume to much they put me on small band (56k).

    Any ideas are welcome.

    Thanks,

    Bart

  11. #11

    Unhappy MLDonkey

    # /opt/etc/init.d/mlnet
    /opt/etc/init.d/mlnet: cannot execute
    -Using Telnet

    [Bhavdip@(none) bin]$sudo /opt/etc/init.d/mlnet
    sudo: /opt/etc/init.d/mlnet: command not found
    [Bhavdip@(none) bin]$
    -Shell using "sudo"

    [Bhavdip@(none) bin]$/opt/etc/init.d/mlnet
    -bash: /opt/etc/init.d/mlnet: Permission denied
    -Shell without using sudo.

    I have followed the instructions and i do not understand what is causing MLDonkey not to start up. Thank you all for your help.

  12. #12
    Quote Originally Posted by Fullback View Post
    # /opt/etc/init.d/mlnet
    /opt/etc/init.d/mlnet: cannot execute
    -Using Telnet

    [Bhavdip@(none) bin]$sudo /opt/etc/init.d/mlnet
    sudo: /opt/etc/init.d/mlnet: command not found
    [Bhavdip@(none) bin]$
    -Shell using "sudo"

    [Bhavdip@(none) bin]$/opt/etc/init.d/mlnet
    -bash: /opt/etc/init.d/mlnet: Permission denied
    -Shell without using sudo.

    I have followed the instructions and i do not understand what is causing MLDonkey not to start up. Thank you all for your help.
    Are you sure you have made the file executable? You can make it executable with:
    chmod +x /opt/etc/init.d/mlnet

    Does anyone know how to compile MLDonkey? Im am not experienced enough with UNIX to do this, they have fixed problems with torrents being slow in the newest version of MLDonkey (2.9).
    Last edited by Henrikh; 14-08-2007 at 13:26.

  13. #13

    Cant close mlnet

    If i vi mlnet and add the text from step 2.2 on
    http://wl700g.homelinux.net/drupal/?q=node/137
    this wont work:
    (to save file press <ESC> <CTRL>+<:> <X> <ENTER>)
    I doesnt save
    but if i do ZZ
    i get the error
    Write error: No such file or directory
    Im so close!
    Woffesl

  14. #14
    Join Date
    Aug 2007
    Location
    Austria
    Posts
    52

    Thumbs up successful installation

    Quote Originally Posted by mawr View Post
    ...Thats all, now you have fully-functional, stable, fast and multi-protocol download manager on you WL-700 box.

    Any comments?
    Hi mawr !

    thanks for your detailed description, i followed your instructions and mldonkey is running fine on my WL700g router now

    comment: additionally to your instructions i had to install zlib too
    Code:
    ipkg install zlib bzip2 -force-overwrite

    thanks and brgds,

    --
    tiwag

  15. #15

    editing rc.local

    Ive followed your discription how to instal ML donkey. But i still have a few questions.
    Where is my rc.local, cant see it in explorer anymore, but i knw its there somewhere?
    How to edit rc.local, im not very experienced with telnet and putty and only copy and paste your commands in putty. Can you please give me 1 step by step example how to edit rc local.
    You also decriped the command
    (to save file press <ESC> <CTRL>+<:> <X> <ENTER>)
    to close and save a file. But it doesnt happen with me. What to do exactly, how to do this.
    Is there a list of standard commands i use in putty. Dont know how to navigate. Things like the dir and edit command in dos.
    Hope to hear soon.
    I think im close to satisfaction with my wl

Page 1 of 2 12 LastLast

Similar Threads

  1. Photo Album & Download Manager
    By antoschka in forum WL-700g Firmware Discussion
    Replies: 2
    Last Post: 18-06-2007, 22:52
  2. HowTo install a lightweight blog server
    By Tamadite in forum WL-500g/WL-500gx Tutorials
    Replies: 0
    Last Post: 03-12-2006, 02:46
  3. Download Manager
    By Erwin in forum Dutch Discussion - Nederlands
    Replies: 1
    Last Post: 18-10-2006, 20:35

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •