transmission support almost ready
authorp2p p2p-next-02 <p2p@p2p-next-02.grid.pub.ro>
Tue, 3 May 2011 08:55:16 +0000 (11:55 +0300)
committerp2p p2p-next-02 <p2p@p2p-next-02.grid.pub.ro>
Tue, 3 May 2011 08:55:16 +0000 (11:55 +0300)
ControlScripts/client_script_mappings
ControlScripts/clients/transmission/detect_complete_transmission.sh
ControlScripts/clients/transmission/parse_transmission.sh
ControlScripts/clients/transmission/start_transmission_leecher.sh
ControlScripts/clients/transmission/start_transmission_seeder.sh
ControlScripts/clients/transmission/stop_transmission.sh
ControlScripts/globalconfig
TestSpecs/gen/transmission_test_01.csv [new file with mode: 0644]

index ffd19ec..95edac4 100644 (file)
@@ -38,6 +38,14 @@ start_client()
                        clients/hrk/start_hrk_leecher_limit.sh ${download_limit} ${upload_limit} ${connection_limit} &
                        return $!
                        ;;
+               "transmission_seeder")
+                       clients/transmission/start_transmission_seeder.sh &
+                       return $!
+                       ;;
+               "transmission_leecher")
+                       clients/transmission/start_transmission_leecher.sh &
+                       return $!
+                       ;;
                "tribler_seeder")
                        clients/tribler/start_tribler_seeder.sh &
                        return $!
@@ -90,6 +98,9 @@ stop_client()
                "hrktorrent_seeder" | "hrktorrent_leecher" | "hrktorrent_seeder_limit" | "hrktorrent_leecher_limit")
                        clients/hrk/stop_hrk.sh
                        ;;
+               "transmission_seeder" | "transmission_leecher")
+                       clients/transmission/stop_transmission.sh 
+                       ;;
                "tribler_seeder")
                        clients/tribler/stop_tribler.sh
                        ;;
@@ -130,6 +141,9 @@ detect_complete_client()
                "hrktorrent_seeder" | "hrktorrent_leecher" | "hrktorrent_seeder_limit" | "hrktorrent_leecher_limit")
                        clients/hrk/detect_complete_hrk.sh ${log_file}
                        ;;
+               "transmission_seeder" | "transmission_leecher")
+                       clients/transmission/detect_complete_transmission.sh ${log_file}
+                       ;;
                "tribler_seeder")
                        clients/tribler/detect_complete_tribler_seeder.sh ${log_file}
                        ;;
@@ -169,6 +183,9 @@ parse_client_log()
                        DEBUG echo "hello hrktorrent_seeder"
                        clients/hrk/parse_hrk.sh ${log_folder} ${log_file}
                        ;;
+               "transmission_seeder" | "transmission_leecher")
+                       clients/swift/parse_swift.sh ${log_folder} ${log_file}
+                       ;;
                "tribler_seeder")
                        clients/tribler/parse_tribler.sh ${log_folder} ${log_file}
                        ;;
index 19e36a7..b94d98c 100755 (executable)
@@ -24,7 +24,7 @@ LOG_FILE=$1
 
 while true; do
        # check for complete transfer
-       if cat $LOG_FILE | grep "Torrent finished" &> /dev/null; then
+       if cat $LOG_FILE | grep 'State changed from "Incomplete" to "Complete"' &> /dev/null; then
                echo "Torrent transfer finished"
                exit 0
        fi
@@ -35,9 +35,9 @@ while true; do
        fi
 
        # check stat client is alive
-       if ! pgrep "hrktorrent" &> /dev/null; then
+       if ! pgrep -f "transmission-cli" &> /dev/null; then
                if ! pgrep -f "schedule_client.sh" &> /dev/null; then
-                       echo "No hrktorrent and no schedule_client.sh process"
+                       echo "No transmission-cli and no schedule_client.sh process"
                        exit 0
                fi
        fi
index c25eb24..39d25ed 100755 (executable)
@@ -9,7 +9,7 @@
 #  * the name of a log file in that folder
 #
 # Sample run:
-#  ./parse_hrk.sh ../../../Results/samples/ p2p-next-01-101.log
+#  ./parse_transmission.sh ../../../Results/samples/ p2p-next-01-101.log
 
 if [ ! $# -eq 2 ]; then
        echo "usage: $0 log-folder log-file"
index f725452..205682f 100755 (executable)
@@ -27,8 +27,11 @@ else
        source ../ClientWorkingFolders/TmpLogs/node_config
 fi
 
+rm ~/.config/tramsmission/resume/*
+rm ~/.config/tramsmission/torrents/*
+
 cd $WORKING_FOLDER_REL_PATH/Regular/
 
-LD_LIBRARY_PATH=$HRK_ABS_PATH/../libtorrent-rasterbar/lib $HRK_ABS_PATH/hrktorrent --nodht ../TorrentsAndData/$TORRENT_FILE
+$TRANSMISSION_ABS_PATH/transmission-cli ../TorrentsAndData/$TORRENT_FILE -w .
 
 rm -rf *
index 0e81927..cc7129b 100755 (executable)
@@ -27,6 +27,9 @@ else
        source ../ClientWorkingFolders/TmpLogs/node_config
 fi
 
+rm ~/.config/tramsmission/resume/*
+rm ~/.config/tramsmission/torrents/*
+
 cd $WORKING_FOLDER_REL_PATH/TorrentsAndData/
 
-LD_LIBRARY_PATH=$HRK_ABS_PATH/../libtorrent-rasterbar/lib $HRK_ABS_PATH/hrktorrent --nodht --nohashcheck $TORRENT_FILE
+$TRANSMISSION_ABS_PATH/transmission-cli $TORRENT_FILE -w .
index b0f31f7..dbc76b3 100755 (executable)
@@ -11,4 +11,4 @@ if [ ! $# -eq 0 ]; then
        exit 1
 fi
 
-pkill -KILL -f hrktorrent
+pkill -KILL -f transmission-cli
index df992f2..c281317 100644 (file)
@@ -31,6 +31,9 @@ HRK_ABS_PATH="/home/p2p/p2p-clients/hrktorrent/hrktorrent"
 # hrktorrent with logging support
 HRK_LOG_ABS_PATH="/home/p2p/p2p-clients/hrktorrent-logging/hrktorrent"
 
+# TRANSMISSION_PATH
+TRANSMISSION_ABS_PATH="/home/p2p/p2p-clients/transmission/cli"
+
 # XBTUT_PATH
 XBTUT_ABS_PATH="/home/p2p/export/unified-tracker/trunk/xbt/Tracker" 
 
diff --git a/TestSpecs/gen/transmission_test_01.csv b/TestSpecs/gen/transmission_test_01.csv
new file mode 100644 (file)
index 0000000..beabd0a
--- /dev/null
@@ -0,0 +1,2 @@
+1,1,1,2,Nelimitat,1 Mbit/s,1 Mbit/s,64M,TODO
+2,1,3,4,Nelimitat,8 Mbit/s,8 Mbit/s,64M,TODO