Буду освобождать канал по расписанию и по нагрузке (по присутствию пользователя на винде).
Первая задача расписана 
тут: 
/usr/local/bin/transmission-remote -d 0 -u 8 --auth admin:password
/usr/local/bin/transmission-remote -D -u 50 --auth admin:password 
1. Transmission будет только отдавать на скорости в 8 кбайт/сек.
2. Вся входящая полоса будет отдана на загрузку, а отдача будет 
вестись на скорости в 50 кбайт/сек.
Вторая задача, но для Х, расписана 
тут: 
#!/bin/bash
IDLEMAX=120000 #время бездействия, после которого снимается ограничение (мс)
TIMEOUT=4
HOST=localhost
PORT=9099
IDLENOW=-1
while true; do
  IDLENOW=$(xprintidle)
  if << $IDLENOW -gt $IDLEMAX >>
    then if << $TURTLE == true >>
          then
            TURTLE=false
            echo -e "\nTurtle mode OFF"
            transmission-remote $HOST:$PORT -AS
            notify-send "Transmission" "Ограничение скорости снято" -i transmission &
         fi
    elif << $TURTLE != true >>
          then
            TURTLE=true
            echo -e "\nTurtle mode ON"
            transmission-remote $HOST:$PORT -as
            notify-send "Transmission" "Установлено ограничение скорости" -i transmission &
  fi
  sleep $TIMEOUT
done
 
Сейчас пойду искать альтернативу 
xprintidle  для Win
А ещё в комментах пишут, что ораничивать есть смысл колич. пиров:
transmission-remote -pr 4 
Продолжение: 
Управление загрузкой торрентов  
Ну и в 
догонку  все ключи transmission-remote
 
Usage: transmission-remote [host] [options]
       transmission-remote [port] [options]
       transmission-remote [host:port] [options]
See the man page for detailed explanations and many examples.
Options:
  -h   --help                                        Display this help page and exit
  -a   --add                                         Add torrent files by filename or URL
  -as  --alt-speed                                   Use the alternate Limits
  -AS  --no-alt-speed                                Don't use the alternate Limits
  -asd --alt-speed-downlimit                  max alternate download speed (in KB/s)
  -asu --alt-speed-uplimit                    max alternate upload speed (in KB/s)
  -asc --alt-speed-scheduler                         Use the scheduled on/off times
  -ASC --no-alt-speed-scheduler                      Don't use the scheduled on/off times
       --alt-speed-time-begin                  Time to start using the alt speed limits (in hhmm)
       --alt-speed-time-end                    Time to stop using the alt speed limits (in hhmm)
       --alt-speed-days                        Numbers for any/all days of the week - eg. "1-7"
  -b   --debug                                       Print debugging information
  -d   --downlimit                            Set the maximum global download speed in KB/s
  -D   --no-downlimit                                Don't limit the global download speed
  -er  --encryption-required                         Encrypt all peer connections
  -ep  --encryption-preferred                        Prefer encrypted peer connections
  -et  --encryption-tolerated                        Prefer unencrypted peer connections
  -f   --files                                       List the current torrent(s)' files
  -g   --get                                  Mark files for download
  -G   --no-get                               Mark files for not downloading
  -i   --info                                        Show the current torrent(s)' details
  -j   --syabas-settings                             Show the session's settings
  -k   --syabas-print-list                           List all torrents and print detailed information for NMT
  -si  --session-info                                Show the session's details
  -st  --session-stats                               Show the session's statistics
  -l   --list                                        List all torrents
       --move                                  Move current torrent's data to a new folder
       --find                                  Tell Transmission where to find a torrent's data
  -m   --portmap                                     Enable portmapping via NAT-PMP or UPnP
  -M   --no-portmap                                  Disable portmapping
  -n   --auth                     Set authentication info
  -N   --netrc                             Set authentication info from a .netrc file
  -o   --dht                                         Enable distributed hash tables (DHT)
  -O   --no-dht                                      Disable distributed hash tables (DHT)
  -p   --port                                  Port for incoming peers (Default: 51413)
  -P   --random-port                                 Random port for incomping peers
  -ph  --priority-high                        Set the files' priorities as high
  -pn  --priority-normal                      Set the files' priorities as normal
  -pl  --priority-low                         Set the files' priorities as low
  -r   --remove                                      Remove the current torrent(s)
  -pr  --peers                                  Set the current torrent(s)' maximum number of peers each
  -gpr --global-peers                           Set the global maximum number of peers
       --remove-and-delete                           Remove the current torrent(s) and delete local data
  -sr  --seedratio              ratio                Let the current torrent(s) seed until a specific ratio
  -srd --seedratio-default                           Let the current torrent(s) use the global seedratio settings
  -SR  --no-seedratio                                Let the current torrent(s) seed regardless of ratio
  -gsr --global-seedratio       ratio                All torrents, unless overridden by a per-torrent setting, should seed until a specific ratio
  -GSR --no-global-seedratio                         All torrents, unless overridden by a per-torrent setting, should seed regardless of ratio
  -s   --start                                       Start the current torrent(s)
  -S   --stop                                        Stop the current torrent(s)
  -t   --torrent                            Set the current torrent(s)
  -u   --uplimit                              Set the maximum global upload speed in KB/s
  -U   --no-uplimit                                  Don't limit the global upload speed
  -v   --verify                                      Verify the current torrent(s)
  -V   --version                                     Show version number and exit
  -w   --download-dir                          Set the default download folder
  -x   --pex                                         Enable peer exchange (PEX)
  -X   --no-pex                                      Disable peer exchange (PEX)
  -pi  --peer-info                                   List the current torrent(s)' peers                      
На данный момент доступна уже вторая версия:WIDLE v.0.0.2 (Static library) на Yandex.Disk  
Подробней читать по соответствующему тегу WIDLE  
 
Комментариев нет:
Отправить комментарий