Page 1 of 3 123 LastLast
Results 1 to 10 of 28

Thread: Help on changing the torrent client port

  1. #1
    Join Date
    Nov 2010
    Posts
    7

    Default Help on changing the torrent client port

    Hello,

    I just got a box office media player. I have a problem with the speed of the torrent client. I created a port forwarding on my router to the PBO on port 6881. However the upload speed on the web pages still show 0. I suspect the ISP may block traffic on 6881. Can some please let me know how I can change the default port of the torrent client?

    Thanks

  2. #2
    Join Date
    Dec 2009
    Location
    Canada (ON)
    Posts
    2,036

    Default

    How to do this is different depending on which firmware you are using. For any firmware that are based on the yaffs filesystems ( Basically any firmware that are compatible with Bootcode 16 (BC16) look here: http://www.patriotmemory.com/forums/showthread.php?t=4421

    Also take note that at some point in the firmware the BTtorrent script was change from btpd to bt.script so again without your firmware number it's hard to know for sure but it would be called one of those 2 names. There is also another file called btpd but this one is a binary file.

    If you have one of the newer firmware that are only compatible with bootcode 18 and above then things are a little more complicated since the filesystem used by those firmware is read-only. You will need to copy your BTtorrent script somewhere writable like /usr/local/etc/ edit it as indicated in the link then overmount it to the original BT script. Again the actual location of the original script depends on your firmware. The overmount will have to be called from the /usr/local/etc/rcS file so that it is done on reboot.

    If you have no experience in linux and have no clue where to start from the info I provided just let me know which firmware you have and I will write a step by step procedure for you.
    Last edited by snappy46; 01-23-2012 at 12:25 PM.

  3. #3
    Join Date
    Nov 2010
    Posts
    7

    Default

    Thanks Snappy. The firmware version is P05. Greatly appreciated your help.

    Henry

  4. #4
    Join Date
    Dec 2009
    Location
    Canada (ON)
    Posts
    2,036

    Default

    Quote Originally Posted by newuser1 View Post
    Thanks Snappy. The firmware version is P05. Greatly appreciated your help.

    Henry
    Not sure from you statement if you got this done successfully or still need a step by step procedure. Anyhow let me know if you do.

  5. #5
    Join Date
    Nov 2010
    Posts
    7

    Default

    Snappy. Sorry for the confusion. I still need the step by step. Thanks

  6. #6
    Join Date
    Dec 2009
    Location
    Canada (ON)
    Posts
    2,036

    Default

    Quote Originally Posted by newuser1 View Post
    Snappy. Sorry for the confusion. I still need the step by step. Thanks
    Sorry for the delay I have been busy with other stuff.

    If you have P05 then your firmware is using squashfs which is only read only but it still can be done it just requires a few more steps.

    1) Telnet to your PBO (window users I believe use putty to do this and I think that telnet is available on win7 but it needs to be enable. So you need to enter your PBO_IP in telnet. When asked for a login type in root and just enter when prompted for a password.

    2) You need to copy your bt.script somewhere that is not read only. The usr/local/etc is a good place for that so enter:

    Code:
    # cp /usr/local/bin/package/script/bt.script /usr/local/etc
    3) now you need to edit your /usr/local/etc/rcS file so that the file you just copy to /usr/local/etc/ (bt.script) be used on boot up instead of the original bt.script which you can not edit. So I would just used the editor vi available on the PBO. Just google vi editor for a list of command. So enter:

    Code:
    # vi /usr/local/etc/rcS
    You are now in the vi editor. Go to the end of the file and insert that line:

    mount --bind /usr/local/etc/bt.script /usr/local/bin/package/script/bt.script &

    In vi to insert just press "i" to save and exit press [ESC] and then ":wq!" without the quotes. If you ran into problem just press [ESC] and the "q!" to exit without saving.

    Once you have saved the rcS file reboot your PBO.

    After the reboot if you did everything I mentioned your /usr/local/bin/package/script/bt.script will now be editable. Again will we used vi to do the editing; so enter:

    Code:
    # vi /usr/local/bin/package/script/bt.script
    In this script use the arrow keys to navigate and look for the following lines:

    #start running btpd
    export HOME=$bthome
    $btpdbin

    This is near the end in the btpd_start() function. Now just add at the end of the $btpdbin -p 51777 --max-peers 60. So now it should look like this:

    #start running btpd
    export HOME=$bthome
    $btpdbin -p 51777 --max-peers 60

    Now reboot the PBO once more and now the bt torrent should run with the new parameters port 51777 or whatever port you want just change that number and it will also be more stable with a max-peers of 60. That being said the bt torrent on the PBO with this firmware and above is quite a bit flaky has been known to shutdown so just keep an eye on your download. For what it is worth the bt torrent on ARCBO 4318 is a lot lot lot more stable. I also recommend you do your download to the internal drive if you have one since download to external USB drive to not resume automatically after a reboot.

    Good luck.

  7. #7
    Join Date
    Nov 2010
    Posts
    4

    Default

    Sorry for my English, I did not use it long.
    Is possible to change the length of seed (upload) to no limit or longer than 48h?
    Last edited by barto0o; 11-18-2010 at 12:42 PM.

  8. #8
    Join Date
    Dec 2009
    Location
    Canada (ON)
    Posts
    2,036

    Default

    Quote Originally Posted by barto0o View Post
    Sorry for my English, I did not use it long.
    Is possible to change the length of seed to no limit or longer than 48h?
    I am not aware of any way to do this using any of the options available (see list below). I am not sure how the seed time is set using the web interface. Maybe they have another script running to keep track of how long a certain torrent has been seeding and stop it when the time has been reached ??????

    All other script that I've seen using btpd uses a cron (scheduler) to run btpd and make sure it is still running then check for Download/Upload ratio, watch directory to see if any new torrent has been added and then carry on to be call up again from the cron (scheduler) 2 minutes later and do the same thing again and again and well again. I believe kind of the same things happen here (except for the part that make sure it is still running) using the PBO main application DvdPlayer. All I know for sure is that btpd script (bt.script) is called from the DvdPlayer app hence it controls what's going on with btpd.

    If you are interested here's an example of a script written to run btpd. We could always use that ourself I suppose but I am not sure if cron is available on the PBO:

    http://www.nslu2-linux.org/wiki/Optware/Btpd


    Here's the list of btpd command line options:

    OPTIONS
    --bw-in n Limit incoming BitTorrent traffic to n kB/s.

    Default is 0 which means unlimited.

    --bw-out n
    Limit outgoing BitTorrent traffic to n kB/s.

    Default is 0 which means unlimited.

    -d dir The directory in which to run btpd. Default is ’$HOME/.btpd’.

    --logfile file
    Where to put the logfile. By default it’s put in the btpd
    dir.

    --max-peers n
    Limit the amount of peers to n.

    --max-uploads n
    Controls the number of simultaneous uploads.

    The possible values are:

    n < -1 : Choose n >= 2 based on --bw-out (default).

    n = -1 : Upload to every interested peer.

    n = 0 : Dont’t upload to anyone.

    n > 0 : Upload to at most n peers simultaneously.

    --no-daemon
    Keep the btpd process in the foregorund and log to
    std{out,err}.

    This options is intended for debugging purposes.

    -p n --port n
    Listen on port n. Default is 6881.

    --prealloc n
    Preallocate disk space in chunks of n kB. Default is 2048.
    Note that n will be rounded up to the closest multiple of the
    torrent piece size. If n is zero no preallocation will be
    done.

    --help Show summary of options.

    Sorry I can not be of anymore help regarding your request.

    Cheers !!!!

  9. #9
    Join Date
    Nov 2010
    Posts
    4

    Default

    Ok thanks, maybe someone will be able to change it for unlimited time.
    I'm not the best in the linux environment, I myself will not be able to change that.

  10. #10
    Join Date
    Nov 2010
    Posts
    4

    Default

    One more question, why bt client does not see my HDD?
    connect to its IP address and the PBO does not see HDD


    I see the drive after running PBO
    but when I come in torrents or after restart
    HDD disappears

    (sorry for my english;-)
    Last edited by barto0o; 11-18-2010 at 05:32 PM.

Posting Permissions

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