Welcome Guest ( Log In | Register )

58 Pages V   1 2 3 > » 

การดึง contact จาก ผู้ให้บริการเวบเมล (yahoo, hotmail, gmail,...)

Posted by Patrickz, Jan 22 2010, 10:26 AM

การ import contact จากบริการเวบเมลนั้น มี 2 วิธี

1. ผ่าน API ของผู้ให้บริการ
วิธีนี้ โดยทั่วไปจะกระโดดไปยังหน้าเวบของผู้ให้บริการ เพื่อให้ user ยอมรับการเข้าถึงข้อมูลส่วนตัว (กรณีนี้คือ contact) จากนั้นจะกระโดดกลับมานี้หน้าเวบเดิม เพื่อดำเนินการต่อไป
มีผู้ให้บริการเพียงไม่กี่ราย ที่มี API ให้ใช้
Live/MSN/Hotmail: Contacts API
Google GMail: Google Contacts Data
Yahoo: Yahoo! Address Book API
LinkedIn: APIs
Facebook: cause apps

2.web grabber
ใช้วิธีเปิด socket หรือพูดง่ายๆ ว่าใช้โปรแกรมจำลองเป็น web browser เข้าไปดึง contact list ออกมา
วิธีนี้จะช้ากว่าการใช้ API โดยตรง และวิธีนี้ีมีความเสี่ยงสูงที่ scripts จะทำงานไม่สำเร็จ เนื่องจากหากผู้ให้บริการเปลี่ยนแปลงรูปแบบเวบ หรือขั้นตอนกระบวนการทำงาน ก็จะทำให้ scripts ทำงานผิดพลาด
ข้อดีคือสะดวกสบาย user เพียงแค่ใส่ username และ password (ไม่ต้องกระโดดไปที่หน้าเวบของผู้ให้บริการ) แต่กรณีนี้ user ต้องมีความเชื่อใจเวบไซค์



scripts อื่นๆ
php contacts importer (yahoo, gmail, hotmail, aol, myscape), $100 USD
Contact Grabber (Yahoo, Gmail, Hotmail, AOL, Lycos), GPL
Import hotmail adresses , LGPL/BSD
PHP Import Gmail, Yahoo, Hotmail, AOL Addresses 2.0.0
Email login and download Contacts List (yahoo, hotmail, gmail, orkut)
contactmines (start from $19.95) มีทั้ง PHP, .NET
improsys contact importer $240


Octazen Contacts Importer (>$160 USD)
torrentialwebdev.com - Contact List Retrieval
Class: Contacts importer

ส่วนใหญ่ Open source ที่ทดลองเล่นมา (ตาม list ข้างบน) ใช้งานจริงไม่ได้ update ล่าสุดก็ปี 2008 ซึ่งผู้ให้บริการก็เปลี่ยน pattern หรือ process การทำงานไปหมดแล้ว

สุดท้ายมาเจอ openinviter ใช้งานได้จริง และ support ผู้ให้บริการดังต่อไปนี้

Pochta, Clevergo, GMail, Netaddress, Canoe, Care2, O2, Web.de, Rambler, Doramail, FastMail, OperaMail, KataMail, Aussiemail, Mail.in, IndiaTimes, Kids, Sapo.pt, Mynet.com, Yahoo!, Mail2World, Bordermail, Abv, GMX.net, Meta, India, YouTube, Gawab, Mail.com, Yandex, Nz11, Zapakmail, Techemail, Atlas, Wp.pt, Inbox.com, Azet, Freemail, Popstarmail, Walla, Virgilio, Grafitti, MSN, Interia, Terra, Mail.ru, AOL, Lycos, Evite, Inet, Apropo, Hushmail, Rediff, LinkedIn, Bigstring, Live/Hotmail, 5Fm, Libero, Uk2 or social portals like Cyworld, MySpace, Badoo, Plazes, Livejournal, Vimeo, Mydogspace, Tagged, Last.fm, Hyves, Xing, Mevio, Bookcrossing, Motortopia, Brazencareerist, Ning, Xanga, Flickr, Konnects, Twitter, Koolro, Faces, Skyrock, Bebo, NetLog, Mycatspace, Kincafe, Flixster, Eons, Friendfeed, Plurk, Meinvz, Hi5, Xuqa, Vkontakte, Perfspot, Flingr, Plaxo, Multiply, Lovento, Orkut, Famiva, Friendster, Fdcareer, Facebook.

(ยังไม่รวม plugins ที่เชื่อมกับ CMS/Forum อย่าง Vwebmail, joovili, Dating Pro, PhpBB, Wordpress, phpFoX, Boonex Dolphin, JamRoom, Drupal, RoundCube, Buddy Zone, SimpleMachines Forum (SMF), PHPMELODY, symfony, jamit job, Atmail5, Social Engine, Joomla1.0, myBB, PunBB, phpizabi, nowFire, vBulletin, Joomla อีก)

ดู list เต็ม ได้ที่หน้า openinviter status


การตรวจสอบอีเมล (Validate email address)

Posted by Patrickz, Jan 18 2010, 10:04 AM

การตรวจสอบอีเมล Address
มีขั้นตอนดังนี้

1. email address format
เอกสารข้อกำหนดของอีเมลมีหลายรุ่น เช่น RFC 822 (1982), RFC 2822 (2001), RFC 5322 (2008) ดังนั้นรูปแบบอีเมลหนึ่ง จึงอาจไม่เข้าเงื่อนไขตามเอกสารข้อกำหนดบางชุดก็ได้ ดังนั้นจึงควรยึดถือตาม RFC 2822 เป็นอย่างต่ำ

รูปแบบอีกเมล local-part@hostname.com ประกอบไปด้วย 2 ส่วน คั่นด้วยเครื่องหมาย @
ส่วนแรก (อยู่หน้าเครื่องหมาย @) เรียกว่า local-part มีความยาวไม่เกิน 64 ตัวอักษร
ส่วนหลัง (อยู่หลังเครื่องหมาย @) เรียกว่า hostname มีความยาวไม่เกิน 255 ตัวอักษร
รูปแบบอีเมลประกอบไปด้วย:

  • ตัวอักษร a-z, A-Z
  • ตัวเลข 0-9
  • อักขระ ! # {:content:} % & ' * + - / = ? ^ _ ` { | } ~
  • อักขระ . ต้องไม่ใช่ตัวแรก หรือตัวสุดท้าย และต้องไม่ใช้ติดกัน
  • domain name ต้องไม่เกิน 255 ตัวอักษร

ตัวอย่าง Regular Expression สำหรับ email address อย่างง่าย : /^[A-Z0-9._%+-]+@[A-Z0-9.-]+\.[A-Z]{2,4}$/i

CODE
<?php
                       $pattern = "/^[A-Z0-9._%+-]+@[A-Z0-9.-]+\.[A-Z]{2,4}$/i";
                       $email = 'myemail@gmail.com';
                      
                       if (preg_match($pattern, $email)) {
                           echo "A match was found.";
                       } else {
                           echo "A match was not found.";
                       }
                       ?>



2. DNS validate

คือขั้นตอนการเข้าไปดู MX record ของ Domain นั้นๆ เพื่อตรวจสอบดูว่า domain นั้นสามารถรับอีเมลได้หรือไ่ม่
หากไม่เจอ MX Record ก็หมายความว่า อีเมลนั้นไม่มีตัวตน เนื่องจาก domain นั้นๆ ไม่สามารถรับอีเมลได้

การตรวจสอบ MX Record นั้น สามารถทำได้โดยการติดต่อไปยัง DNS ด้วยคำสั่ง dig, nslookup
ตัวอย่างคำสั่ง $dig MX gmail.com
CODE
; <<>> DiG 9.2.4 <<>> MX gmail.com
          ;; global options:  printcmd
          ;; Got answer:
          ;; ->>HEADER<<- opcode: QUERY, status: NOERROR, id: 7644
          ;; flags: qr rd ra; QUERY: 1, ANSWER: 5, AUTHORITY: 0, ADDITIONAL: 0
                  
          ;; QUESTION SECTION:
          ;gmail.com.                     IN      MX
                  
          ;; ANSWER SECTION:
                  gmail.com.              2700    IN      MX      5 gmail-smtp-in.l.google.com.
                  gmail.com.              2700    IN      MX      20 alt2.gmail-smtp-in.l.google.com.
                  gmail.com.              2700    IN      MX      30 alt3.gmail-smtp-in.l.google.com.
                  gmail.com.              2700    IN      MX      40 alt4.gmail-smtp-in.l.google.com.
                  gmail.com.              2700    IN      MX      10 alt1.gmail-smtp-in.l.google.com.

จะเห็นว่า domain gmail.com มี mail server รองรับ 5 domain (แต่ล่ะ domain อาจจะมี server วิ่งอยู่กี่ร้อยกี่พันตัว ก็มิอาจรู้ได้)
อีกตัวอย่างจากบริการจาก mxtoolbox.com เพื่อดู MX Record ของ gmail.com

สำหรับ ภาษา PHP มี function getmxrr() ให้ใช้อยู่แล้ว smile.gif

3. SMTP (Callback_verification, VRFY)
ตอนนี้เราทราบแล้วว่า อีเมล์ถูกรูปแบบ และ domain ก็รับอีเมลได้ แต่ยังไม่รู้ว่าที่อยู่อีเมลนั้นมีอยู่จริงหรือไม่ ดังนั้นสิ่งที่ต้องตรวจสอบต่อไปคือ
การถาม mail server ว่า มี mailbox (อีเมล) นี้มีอยู่จริงหรือเปล่า

การติดต่อทำได้โดยการเปิด socket ติดต่อไปยัง SMTP ซึ่งโดยปกติ จะเป็น port 25
เรื่องนี้เกี่ยวข้องกับ protocal ตรงๆ จึงไม่ขออธิบาย แต่สรุปว่าโดยทั่วไป มี 2 คำสั่ง

- vrfy (verify) ใช้ถาม mail server ว่ามี mailbox หรือไม่ ทำงานได้เร็วกว่าคำสั่ง rcpt(จะอธิบายต่อไป) แต่อาจใช้ไม่ได้ เนื่องจากอาจมีนโยบายด้านความปลอดภัย

ตัวอย่าง
QUOTE
SMTP client: VRFY mike
SMTP server: 250 mike@abc.com

แสดงว่า mike@abc.com มีอยู่จริง

แล้วถ้าไปดึง mailing-list ล่ะ
QUOTE
SMTP client: VRFY users-hackers
SMTP server: 250-carol@abc.com
250-greg@abc.com
250-marsha@abc.com
250 peter@abc.com

เริ่มน่ากลัวล่ะ...เหตุผลที่คำสั่งนี้มักใช้ไม่ได้ biggrin.gif

- rcpt เป็นคำสั่งกำหนด mailbox ที่จะส่งเมล (แ่ต่เราจะไม่ส่งจริง แค่ถามเฉยๆ) ลองดูตัวอย่างจาก บทความ How to check if an email address exists without sending an email?

QUOTE
COMMAND:
telnet mail.reddit.com 25

COMMAND:
helo hi
RESPONSE:
250 mail.reddit.com

COMMAND:
mail from: youremail@gmail.com
RESPONSE:
250 2.1.0 Ok

COMMAND:
rcpt to: mailbox.does.not.exist@reddit.com
RESPONSE:
550 5.1.1 <mailbox.does.not.exist@reddit.com>: Recipient address rejected: User unknown in local recipient table


COMMAND:
quit
RESPONSE:
221 2.0.0 Bye


ดังนั้น หาก mailbox นี้มีอยู่จริง mail server จะคืนค่า 250 กลับมาให้

คุณ Gabe ได้เขียน SMTP_validateEmail class (PHP) แจกจ่าย ผมยังไม่ได้ลอง (ถ้าลองแล้วไม่ work จะ update และแก้ไขให้)


สรุป
1. email address format - ตรวจสอบรูปแบบอีเมล
2. DNS validate - ถาม domain ว่ารับเมลได้ไหม
3. SMTP (Callback_verification, VRFY) ถาม mail server ว่า มี email address นี้อยู่จริงหรือไม่



Links


standard banner size

Posted by Patrickz, Dec 22 2009, 03:23 PM

Rectangular and pop-up ads
Large rectangle 336 x 280
Medium rectangle 300 x 250
Square pop-up 250 x 250
Vertical rectangle 240 x 400
Rectangle 180 x 150
3:1 Rectangle 300 x 100
Pop-under 720 x 300


Banner and button ads
Leaderboard 728 x 90
Full banner / Impact banner 468 x 60
Half banner 234 x 60
Button 1 120 x 90
Button 2 120 x 60
Micro bar 88 x 31
Micro button 80 x 15
Vertical banner 120 x 240
Square button 125 x 125


"Skyscraper" ads
Thin Skyscraper 120 x 600
Standard skyscraper 160 x 600
Half-page 300 x 600


ลองเล่น Facebook API

Posted by Patrickz, Nov 1 2009, 09:54 AM

ไม่ค่อยมีใครเขียนblog เกี่ยวกับการพัฒนาโปรแกรมบน Facebook เลย ที่เห็นก็มี เริ่มต้นกับการเขียน Facebook Application สำหรับผู้เริ่มต้น (PHP) แค่นั้นเอง

Resource


ตัวอย่างจาก "Quick Creation Guide"
ใช้ PHP คู่กับ facebook php lib
CODE
<html>
<body bgcolor="#EFEFEF">
<?php
       // Copyright 2007 Facebook Corp.  All Rights Reserved.
       //
       // Application: CustomBlock
       // File: 'index.php'
       //   This is a sample skeleton for your application.
       //
      
       require_once 'facebook.php';
      
       $appapikey = '2341a3d3dbdd56027ff68ac20d88ea21';
       $appsecret = '453e2f1c901fc7363271c9f52338043f';
       $facebook = new Facebook($appapikey, $appsecret);
       $user_id = $facebook->require_login();
      
       // Greet the currently logged-in user!
       echo "<p>Hello, <fb:name uid=\"$user_id\" useyou=\"false\" />!</p>";
      
       // Print out at most 25 of the logged-in user's friends,
       // using the friends.get API method
       echo "<p>Friends:";
       $friends = $facebook->api_client->friends_get();
       $friends = array_slice($friends, 0, 25);
       foreach ($friends as $friend) {
         echo "<br>$friend";
       }
       echo "</p>";
</body>
</html>




opensource modeling tools list

Posted by Patrickz, Oct 29 2009, 10:40 AM


LXDE: Lightweight X11 Desktop Environment

Posted by Patrickz, Oct 24 2009, 02:39 PM



Lightweight X11 Desktop Environment (LXDE)เป็น Desktop Manage บน Linux
มันคือโครงการที่ใช้ Openbox + GTK ชื่อก็บอกอยู่แล้วว่าต้องกิน resource น้อยกว่า GNome และ KDE แน่ๆ



ที่น่าสนใจคือ distro ต่างๆ โดยเฉพาะ Ubuntu, Fedora, Suse, Mint เริ่มให้ความสนใจ ทั้งนี้อาจเพราะกระแส netbook ที่กำลังมา ใครมีเครื่อง spec เก่าๆ ก็น่าสนใจ

คู่แข่งของ LXDE เห็นจะเป็น Xfce ที่เหลืออาจป็นแค่ดาวประดับฟ้า รอวันเกิด(หรือดับ?) รายชื่อ Desktop Environment ดูได้ที่ http://www.freedesktop.org/wiki/Desktops

Links
wikipedia:Comparison of X Window System desktop environments
wikipedia:LXDE
wikipedia:Xfce


nohup: สั่งโปรแกรมทำงานต่อ

Posted by Patrickz, Oct 23 2009, 12:04 PM

ไม่ได้ใช้คำสั่งนี้นานๆ ลืมได้เหมือนกัน ทั้งที่เป็นคำสั่งง่ายๆ เลยเขียน blog นี้ลงโทษตัวเองที่ลืม
เคยไหม เวลาเข้า ssh แล้วต้องรัน scripts ซึ่งต้องใช้เวลานานๆ แต่เน็ตดันหลุด (และมักจะหลุดตอนมีเหตุสำคัญ...)

Linux มีคำสั่ง run command เป็นแบบ background process ดังนี้

$command &

ถ้าหากเรา remote ด้วย SSH, Telnet แล้วใช้คำสั่งนี้ เวลาเราออกจาก ssh/telnet ไม่ว่าจะเน็ตหลุดหรือไม่ตั้งใจก็ตาม
คำสั่งที่ทำงานอยู่จะถูก kill process ไปด้วย

ดังนั้น Linux จึงมีคำสั่ง nohup ใช้งานดังนี้

$nohup command &

note:

  • HUP ย่อมาจาก hangup (signal)
  • no hup คือ การไม่ส่ง hangup signal ไปยัง kernel
  • ไม่จำเป็นต้องใช้ nohup กับ wget เนื่องจาก wget มี wget -b อยู่แล้ว
Links
keyword: Linux, long, background, process


ลองใช้ thttpd

Posted by Patrickz, Oct 22 2009, 10:44 PM

พอดี Backup server โดยใช้ partimage backup เป็น image โดยบูทผ่าน Finnix
ก็ backup ได้ไม่มีปัญหา แต่กำลังนึกตอนนี้จะเอา image มาเก็บไว้นี้สิ จะส่งมาที่เครื่องที่บ้านก็เป็น ADSL (ช้าอีก)
ก็ต้องใช้วิธี download มา ถ้าใช้แผ่น Finnix ก็จะมีสองวิธี

ssh
1. ใช้คำสั่ง passwd เพื่อกำหนด password ของ root ก่อน
2. สั่ง /etc/init.d/ssh หรือ service ssh ก็ได้
ไฟล์ที่ download มีขนาดค่อนข้างใหญ่ ผลคือนรกชัดๆ ช้ามาก

thttpd
thttpd เป็น OSS จาก ACME Laboratories เป็น webserver แบบ single-threaded ขนาดเล็ก ไม่กินทรัพยากร แถมยังมีความสามารถ bandwidth throttling ด้วย

จริงๆ แล้ว thttpd ยังเหมาะกับเวบขนาดเล็ก หรือบริการเฉพาะ เช่นระบบดู Traffic, Bandwidth เป็นต้น และโดยเฉพาะเหมาะในการเอาไปใช้ในอุปกรณ์ embedded hardware และ router (เข้าใจว่าก็ใช้กันใน router อยู่แล้ว)

thttpd -dd /mnt/hdc

โอเค แค่อยากบันทึกเอาไว้ว่า ผมได้ลองใช้ thttpd แล้ว


Interest Developer Forum

Posted by Patrickz, Oct 22 2009, 10:08 AM

Developer Forum ที่น่าสนใจ

  • Microsoft (MSDN)
  • Sony Ericsson (Developer World)
  • Sun (Java ME)
  • RIM (BlackBerry Developer Programs)
  • Qualcomm (BREW developer network)
  • Google (Google Code and Android)
  • Facebook (Developer Garages)
  • Yahoo! (Yahoo! Developer Network)
  • Adobe (Flash Lite)
  • Apple (Apple Developer Connection)
  • Motorola (MOTODEV)
  • Samsung mobile Developer's Club
  • Palm Developer Network
  • Symbian Foundation Developer Network
  • NN4D (Navteq Network for Developers)


Torrent client on Linux

Posted by Patrickz, Oct 18 2009, 04:41 PM

พอดีมี cloud ใช้อยู่โหนดหนึ่ง แทบไม่ได้ใช้อะไรเลย ทิ้งเอาไว้หลายเดือนแล้ว เลยเอามาทำอะไรสักหน่อย
และก็กำหนดโหลด torrent ด้วย เลยใช้ bandwidth ให้เต็มที่เลยดีกว่า biggrin.gif

โจทย์มีอยู่ว่า

  • ไม่กิน resource
  • เป็น CLI (Command line interface)
  • ติดตั้งง่าย
โปรแกรม Torrent ต่างๆ ทั้งบน Windows และ Linux นั้น ส่วนใหญ่เป็น GUI และไม่ค่อยมี CLI mode ให้ใช้
จึงมีโปรแกรมอยู่ไม่กี่ตัว และเพื่อความสะดวก ก็หา webui มาใช้


rTorrent - a Lightwieght Torrent Client
rTorrent ใช้คู่กับ libtorrent เป็น CLI ไม่กิน resource




WebUI

มีให้เลือกใช้อยู่หลายตัว
  • wTorrent นิยมสุด
  • rTWi งั้นๆ
  • rtgui ใช้ได้ หล่อด้วย
ทั้งหมดเขียนด้วย PHP







นอกจากนอกจาก rTorrent ก็ยังมี torrentflux แต่ดูเหมือนว่า torrentflux กิน resource มากกว่า ทั้งยังใช้ MySQL อีกด้วย

ดังนั้น Solutions ตอนนี้จึงเป็น rTorrent + wTorrent ตามประชานิยม การติดตั้งไม่ยาก ต้องการ libsigc++ และ libcurl จากนั้นค่อยติดตั้ง rTorrent
แต่วิธีการค่อนข้างยุ่งยาก เพราะต้อง compile source code เอง จึงแนะนำว่าลองหา binary ที่ compile แล้วดีกว่า (RPM)


ติดตั้ง rTorrent
สำหรับ CentOS 5.4, RHEL 5.4 ง่ายหน่อย ติดตั้งได้ดังนี้

CODE
wget http://dag.wieers.com/rpm/packages/libtorrent/libtorrent-0.12.0-1.el5.rf.i386.rpm
   wget http://dag.wieers.com/rpm/packages/libsigc++20/libsigc++20-2.0.17-1.el5.rf.i386.rpm
    wget http://dag.wieers.com/rpm/packages/rtorrent/rtorrent-0.8.0-1.el5.rf.i386.rpm
   rpm -i libsigc++20-2.0.17-1.el5.rf.i386.rpm
    rpm -i libtorrent-0.12.0-1.el5.rf.i386.rpm
   rpm -i rtorrent-0.8.0-1.el5.rf.i386.rpm


RPM Package ของ centos, redhat, rhel และ fedora อื่นๆ ลองหาดูได้จาก http://dries.ulyssis.org/rpm/, http://www.rpmfind.net/
ส่วน Ubuntu ติดตั้งด้วย sudo apt-get install rtorrent

ยังขาดไฟล์ .rtorrent.rc อยู่ ไปเอาได้ที่ http://libtorrent.rakshasa.no/browser/trun...t.rc?rev=latest หน้าตาไฟล์จะเป็นอย่างนี้

CODE
# This is an example resource file for rTorrent. Copy to
     # ~/.rtorrent.rc and enable/modify the options as needed. Remember to
     # uncomment the options you wish to enable.
    
     # Maximum and minimum number of peers to connect to per torrent.
     #min_peers = 40
     #max_peers = 100
    
     # Same as above but for seeding completed torrents (-1 = same as downloading)
     #min_peers_seed = 10
     #max_peers_seed = 50
    
     # Maximum number of simultanious uploads per torrent.
     #max_uploads = 15
    
     # Global upload and download rate in KiB. "0" for unlimited.
     #download_rate = 0
     #upload_rate = 0
    
     # Default directory to save the downloaded torrents.
     #directory = ./
    
     # Default session directory. Make sure you don't run multiple instance
     # of rtorrent using the same session directory. Perhaps using a
     # relative path?
     #session = ./session
    
     # Watch a directory for new torrents, and stop those that have been
     # deleted.
     #schedule = watch_directory,5,5,load_start=./watch/*.torrent
     #schedule = untied_directory,5,5,stop_untied=
    
     # Close torrents when diskspace is low.
     #schedule = low_diskspace,5,60,close_low_diskspace=100M
    
     # Stop torrents when reaching upload ratio in percent,
     # when also reaching total upload in bytes, or when
     # reaching final upload ratio in percent.
     # example: stop at ratio 2.0 with at least 200 MB uploaded, or else ratio 20.0
     #schedule = ratio,60,60,"stop_on_ratio=200,200M,2000"
    
     # The ip address reported to the tracker.
     #ip = 127.0.0.1
     #ip = rakshasa.no
    
     # The ip address the listening socket and outgoing connections is
     # bound to.
     #bind = 127.0.0.1
     #bind = rakshasa.no
    
     # Port range to use for listening.
     #port_range = 6890-6999
    
     # Start opening ports at a random position within the port range.
     #port_random = no
    
     # Check hash for finished torrents. Might be usefull until the bug is
     # fixed that causes lack of diskspace not to be properly reported.
     #check_hash = no
    
     # Set whetever the client should try to connect to UDP trackers.
     #use_udp_trackers = yes
    
     # Alternative calls to bind and ip that should handle dynamic ip's.
     #schedule = ip_tick,0,1800,ip=rakshasa
     #schedule = bind_tick,0,1800,bind=rakshasa
    
     # Encryption options, set to none (default) or any combination of the following:
     # allow_incoming, try_outgoing, require, require_RC4, enable_retry, prefer_plaintext
     #
     # The example value allows incoming encrypted connections, starts unencrypted
     # outgoing connections but retries with encryption if they fail, preferring
     # plaintext to RC4 encryption after the encrypted handshake
     #
     # encryption = allow_incoming,enable_retry,prefer_plaintext
    
     # Enable DHT support for trackerless torrents or when all trackers are down.
     # May be set to "disable" (completely disable DHT), "off" (do not start DHT),
     # "auto" (start and stop DHT as needed), or "on" (start DHT immediately).
     # The default is "off". For DHT to work, a session directory must be defined.
     #
     # dht = auto
    
     # UDP port to use for DHT.
     #
     # dht_port = 6881
    
     # Enable peer exchange (for torrents not marked private)
     #
     # peer_exchange = yes
    
     #
     # Do not modify the following parameters unless you know what you're doing.
     #
    
     # Hash read-ahead controls how many MB to request the kernel to read
     # ahead. If the value is too low the disk may not be fully utilized,
     # while if too high the kernel might not be able to keep the read
     # pages in memory thus end up trashing.
     #hash_read_ahead = 10
    
     # Interval between attempts to check the hash, in milliseconds.
     #hash_interval = 100
    
     # Number of attempts to check the hash while using the mincore status,
     # before forcing. Overworked systems might need lower values to get a
     # decent hash checking rate.
     #hash_max_tries = 10


ไฟล์นี้ rtorrent จะไปหาที่ home directory ของ user ดังนั้นในกรณีถ้าใ้ช้ root ไฟล์จะเก็บที่ /root/.rtorrent.rc
ถ้า rtorrent หาไม่เจอ จะขึ้นข้อผิดพลาด Could not read resource file: ~/.rtorrent.rc

จบการติดตั้งล่ะ

ทดลองใช้งาน

install เสร็จแล้วลองดูซิว่า rTorrent ติดตั้งไว้ที่ไหนด้วย where is rtorrent และลองใช้ด้วยคำนั่ง rtorrent
การใช้งานเบื้องต้น อ่านได้ที่ rTorrent User Guide หรือคำสั่ง man rtorrent

ก็ลองด้วยการเรียกโปรแกรมด้วยคำสั่ง rtorrent กดปุ่ม backspace เพื่อใส่ url ของ torrent file (ผมใช้ http://www.mininova.org/tor/2978765 - romantic piano favorites)



เลือกไปที่ไฟล์ ด้วยการกดขึ้นและลง เลือกเพื่อดู detail ด้วยการกด ขวา


ที่หน้าจอนี้ยังสามารถ kick, ban peer ใจดำ ได้ biggrin.gif มือใหม่ อาจงง interface หน่อย แต่เข้าใจได้ไม่ยาก อ่าน rTorrent User Guide ล่ะกัน

ที่จริง ถึงตอนนี้ผมค่อนข้างพอใจนะ เพียงพอแก่ความต้องการแล้ว ไม่เห็นต้องใช้ webui เลย :/
ไว้ลง wTorrent จะมาเขียนต่อ


Links


58 Pages V   1 2 3 > »   

« March 2010 »

SMTWTFS
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31

Search My Blog







test

test