How to tether your Nokia N95s Internet connection to your laptop via Bluetooth in Linux如何繫繩諾基亞N95s您的Internet連接到您的膝上型電腦通過藍牙在Linux

by Ken Murray on October 27, 2008 肯穆雷 2008年十月27日

Linux操作系統Symbian的

Sometimes you end up somewhere with your laptop where you just can’t find any open WiFi.有時候,你到的地方你的筆記本電腦在那裡你就不能找到任何公開的WiFi 。 Luckily you have a Nokia N95 and a Bluetooth adapter.幸運的你有諾基亞N95和藍牙適配器。 I’m going to show you how to tether your N95 to your laptop via Bluetooth the quick and dirty command line way, as well as the prettier GUI way.我要告訴您如何繫繩您的N95型到您的膝上型電腦通過藍牙快速和骯髒的命令行方式,以及漂亮的GUI方式。 In these examples I am running Fedora 9 and Gnome.在這些例子我運行的Fedora 9日和Gnome 。

Warning: You probably only want to do this if you have a decent data plan. 警告:您可能只想要做到這一點如果您有一個體面的數據計劃。 Using 3G data can result in a very large bill!利用3G數據可能會導致一個非常大的法案!

  1. The first thing you need to do is make sure your N95 is paired with your laptop.首先,你需要做的就是確保您的N95採用搭配您的筆記本電腦。 This is far easier than I expected.這是容易得多比我預想的。 As long as you have the gnome-bluetooth package installed, it’s as simple as initiating the pairing from your phone and entering the same passkey on both the phone and the computer when prompted.只要你有警句,藍牙軟件包進行安裝,它就是這麼簡單開始配對從您的電話,然後輸入相同的密碼都在電話和計算機提示時。 You also need to have the ppp package and the wvdial package installed.您還需要有購買力平價包和wvdial軟件包進行安裝。 If you don’t, you can simply run, as root in a terminal window, yum install ppp wvdial (or use whatever package manager comes w/ your Linux distro).如果您沒有,您只需運行,根在終端窗口百勝安裝購買力平價wvdial (或使用軟件包管理器無論是水/你的Linux發行) 。
  2. Now that both devices are paired, open a terminal window and run hcitool scan to discover your phones Bluetooth MAC address.現在,這兩個裝置配對,打開一個終端窗口和運行hcitool掃描發現您的手機藍牙MAC地址。 This section applies to both the command line and GUI parts of this tutorial.本節既適用於命令行和圖形用戶界面部分的教程。

    [user@radon ~]$ hcitool scan [用戶@氡〜 ] $ hcitool掃描
    Scanning …掃描...
    00:22:66:9F:83:37 N95 00:22:66:9傳真: 83:37 N95型

  3. Next we use sdptool to find out the channel for the Dial-Up Networking service.下一步我們使用sdptool找出渠道撥號網絡服務。

    [user@radon ~]$ sdptool browse 00:22:66:9F:83:37 [用戶@氡〜 ] $ sdptool瀏覽00:22:66:9傳真: 83:37
    Browsing 00:22:66:9F:83:37 …瀏覽00:22:66:9傳真: 83:37 ...
    Service Name: Dial-Up Networking服務名稱:撥號網絡
    Service RecHandle: 0×1004a服務RecHandle : 0 × 1004a
    Service Class ID List:服務類ID列表:
    “Dialup Networking” (0×1103) “撥號網絡” ( 0 × 1103 )
    Protocol Descriptor List:議定書描述名單:
    “L2CAP” (0×0100) “ L2CAP ” ( 0 × 0100 )
    “RFCOMM” (0×0003) “ RFCOMM ” ( 0 × 0003 )
    Channel: 2 通道: 2
    Language Base Attr List:語言基礎屬性清單:
    code_ISO639: 0×454e code_ISO639 : 0 × 454e
    encoding: 0×6a編碼: 0 × 6a的
    base_offset: 0×100 base_offset : 0 × 100
    Profile Descriptor List:簡介描述名單:
    “Dialup Networking” (0×1103) “撥號網絡” ( 0 × 1103 )
    Version: 0×0100版本: 0 × 0100

  4. There will probably be a few screens of output.有可能將一些屏幕輸出。 I have only included the relevant part in the above example.我只包括相關部分在上面的例子。 Note that the Dial-Up Networking service is on channel 2 .請注意,撥號網絡服務的渠道2 。
  5. Using your favorite text editor, as root, edit /etc/bluetooth/rfcomm.conf and make it look like the following, substituting your phones MAC address and channel number.用您最喜愛的文本編輯器,如根,編輯/ etc /藍牙/ rfcomm.conf並使它看起來像下面,取代您的手機MAC地址和頻道號碼。
  6. #
    # RFCOMM configuration file. # RFCOMM配置文件。
    #

    rfcomm0 { rfcomm0 (
    bind yes;綁定是;
    device 00:22:66:9F:83:37;設備00:22:66:9傳真: 83:37 ;
    channel 2;通道2 ;
    }

  7. Save your rfcomm.conf and exit your text editor.保存您的rfcomm.conf和退出您的文字編輯器。
  8. As root, restart the bluetooth service:根,重新啟動藍牙服務:

    [root@radon ~]# service Bluetooth restart [根@氡〜 ] #藍牙服務啟動
    Stopping Bluetooth services: [ OK ]停車藍牙服務: [確定]
    Starting Bluetooth services: [ OK ]啟動藍牙服務: [確定]

  9. We have now created a Bluetooth serial port at /dev/rfcomm0 that will be persistent through reboots.我們現在已經建立了一個藍牙串行端口在/ dev/rfcomm0 ,將持續通過重新啟動。 This is the port you will use as a “modem” during the rest of the configuration.這是港口您將使用的“調製解調器”期間,其餘的配置。

Now we move on to the quick and dirty command line setup.現在,我們進入快速和骯髒的命令行安裝。 Feel free to skip to the GUI setup below if you aren’t very comfortable with the command line.隨時跳到下面的GUI安裝如果您不是很舒服的命令行。

Command Line Method 命令行的方法
GUI Method 桂方法


Command Line Method 命令行的方法

  1. Edit /etc/wvdial.conf and make it look like this:編輯/ etc / wvdial.conf並使它看起來就像這樣:
  2. Modem = /dev/rfcomm0調製解調器= / dev/rfcomm0
    Baud = 460800波特率= 460800
    SetVolume = 0 SetVolume = 0
    Dial Command = ATDT撥號命令= ATDT
    Init1 = ATZ Init1 = ATZ
    Init3 = ATM0 Init3 = ATM0
    FlowControl = CRTSCTS FlowControl = CRTSCTS

    [Dialer Bluetooth] [撥號藍牙]
    Username = user用戶名=用戶
    Password = pass密碼=通行證
    Phone = *99***1#電話= * 99 *** 1 #
    Stupid Mode = 1愚蠢的模式= 1
    Init1 = ATZ Init1 = ATZ
    Inherits = Modem0繼承= Modem0

  3. I’m using Rogers Wireless in Canada and the above is the minimum configuration that works for me.我使用的Rogers無線公司在加拿大和上面的最低配置,為我的作品。 Literally Username = user and Password = pass.毫不誇張=用戶帳號和密碼=通行證。 You may need to make changes to the Username, Password, and Phone lines.您可能需要更改使用者名稱,密碼和電話線。 Contact your wireless provider for the correct details.聯繫您的無線服務提供商正確的細節。
  4. I also had to create a script called /etc/ppp/ip-up.local to make the automatic DNS configuration work.我還創建一個腳本所謂的/ etc / ppp中/ IP的up.local使自動DNS配置工作。 Here’s my ip-up.local:這是我的IP up.local :
  5. #!/bin/bash # ! /斌/慶祝
    #

    PATH=/sbin:/usr/sbin:/bin:/usr/bin路徑= / sbin :是/ usr / sbin : /斌:是/ usr /斌
    export PATH出口路徑
    echo “# created by pppd” > /etc/resolv.conf迴聲“ #創建參見pppd ” “的/ etc / resolv.conf的
    echo “nameserver ${DNS1}” >> /etc/resolv.conf迴聲“域名$ ( DNS1 ) ” “ ”的/ etc / resolv.conf的
    echo “nameserver ${DNS2}” >> /etc/resolv.conf迴聲“域名$ ( DNS2 ) ” “ ”的/ etc / resolv.conf的
    chmod go+r /etc/resolv.conf屬性去+的R /等/ resolv.conf的

    Don’t forget to chmod 755 /etc/ppp/ip-up.local不要忘記屬性755的/ etc / ppp中/ IP的up.local

  6. Unfortunately I have not been able to connect as a normal user in this configuration so you’ll have to connect as root.不幸的是,我一直無法連接作為一個普通用戶在此配置,讓您有連接的根源。

    [root@radon ~]# wvdial Bluetooth [根@氡〜 ] # wvdial藍牙
    –> WvDial: Internet dialer version 1.60 -> “ W vDial:互聯網撥號1 .60版本
    –> Cannot get information for serial port. -> “無法獲取信息的串行端口。
    –> Initializing modem. -> “初始化調製解調器。
    –> Sending: ATZ -> “發送: A TZ
    ATZ
    OK俄克拉何馬州

    –> Sending: ATM0 -> “發送: A TM0
    ATM0
    OK俄克拉何馬州
    –> Modem initialized. -> “調製解調器初始化。
    –> Sending: ATDT*99***1# -> “發送: A TDT* 9 9* **1 #
    –> Waiting for carrier. -> “等待承運人。
    ATDT*99***1# ATDT * 99 *** 1 #
    CONNECT連接
    ~[7f]}#@!}!} } }2}#}$@#}!}$}%\}”}&} }*} } g}%~ 〜 [ 7樓]}#@!}!} ) ) 2 }#}$@#}!}$}% \ }"}&} ) * ) )克) % 〜
    –> Carrier detected. -> “載波檢測。 Starting PPP immediately.按購買力平價立即開始。
    –> Starting pppd at Sun Oct 19 16:48:56 2008 -> “啟動參見p ppd在S un1 0月1 9日1 6時4 8分5 6秒2 008年
    –> Pid of pppd: 8028 -> “的P ID參見p ppd: 8 028
    –> Using interface ppp0 -> “使用界面p pp0
    –> local IP address 172.28.53.106 -> “本地I P地址1 72.28.53.106
    –> remote IP address 10.6.6.6 -> “遠程I P地址1 0.6.6.6
    –> primary DNS address 207.181.101.4 -> “主D NS地址2 07.181.101.4
    –> secondary DNS address 207.181.101.5 -> “次要D NS地址2 07.181.101.5

  7. I removed the lines containing unprintable characters, but otherwise you should see something very similar to above.餘行刪除含有芹菜字符,否則您應該看到的東西非常相似以上。 Note that wvdial stays in the foreground.請注意, wvdial留在前台。 This is so you can disconnect by simply pressing Ctrl-C.這是您可以通過簡單地斷開迫切按Ctrl - C 。
  8. You can verify that you are online by switching to a new terminal window and running ifconfig.您可以驗證您是在線切換到一個新的終端窗口和運行ifconfig 。

    [root@radon ~]# ifconfig [根@氡〜 ] # ifconfig
    lo Link encap:Local Loopback羅連封裝:本地環回
    inet addr:127.0.0.1 Mask:255.0.0.0 Inet電子地址: 127.0.0.1面膜: 255.0.0.0
    inet6 addr: ::1/128 Scope:Host inet6地址: : : 128分之1範圍:主機
    UP LOOPBACK RUNNING MTU:16436 Metric:1向上迴路運行的MTU : 16436公制: 1
    RX packets:12767 errors:0 dropped:0 overruns:0 frame:0接收的數據包: 12767錯誤: 0下跌: 0超支: 0畫面: 0
    TX packets:12767 errors:0 dropped:0 overruns:0 carrier:0德克薩斯州的數據包: 12767錯誤: 0下跌: 0超支: 0承運人: 0
    collisions:0 txqueuelen:0碰撞: 0 txqueuelen : 0
    RX bytes:714652 (697.9 KiB) TX bytes:714652 (697.9 KiB)接收字節: 714652 ( 697.9 KiB )德克薩斯州字節: 714652 ( 697.9 KiB )

    ppp0 Link encap:Point-to-Point Protocol ppp0鏈路封裝:點對點協議
    inet addr:172.28.53.106 PtP:10.6.6.6 Mask:255.255.255.255 Inet電子地址: 172.28.53.106和平之路: 10.6.6.6掩碼: 255.255.255.255
    UP POINTOPOINT RUNNING NOARP MULTICAST MTU:1500 Metric:1 POINTOPOINT向上運行NOARP組播的MTU : 1500公制: 1
    RX packets:4 errors:0 dropped:0 overruns:0 frame:0接收的數據包: 4錯誤: 0下跌: 0超支: 0畫面: 0
    TX packets:5 errors:0 dropped:0 overruns:0 carrier:0德克薩斯州包: 5錯誤: 0下跌: 0超支: 0承運人: 0
    collisions:0 txqueuelen:3碰撞: 0 txqueuelen : 3
    RX bytes:64 (64.0 b) TX bytes:94 (94.0 b)接收字節: 64 ( 64.0二)德克薩斯州字節: 94 ( 94.0二)

    [root@radon ~]# ping simplehelp.net [根@氡〜 ] #平simplehelp.net
    PING simplehelp.net (74.52.95.42) 56(84) bytes of data.平simplehelp.net ( 74.52.95.42 ) 56 ( 84 )字節的數據。
    64 bytes from 2a.5f.344a.static.theplanet.com (74.52.95.42): icmp_seq=1 ttl=46 time=110 ms 64字節從2a.5f.344a.static.theplanet.com ( 74.52.95.42 ) : icmp_seq = 1的TTL = 46時間= 110毫秒
    64 bytes from 2a.5f.344a.static.theplanet.com (74.52.95.42): icmp_seq=2 ttl=46 time=102 ms 64字節從2a.5f.344a.static.theplanet.com ( 74.52.95.42 ) : icmp_seq = 2的TTL = 46時間= 102毫秒
    64 bytes from 2a.5f.344a.static.theplanet.com (74.52.95.42): icmp_seq=3 ttl=46 time=164 ms 64字節從2a.5f.344a.static.theplanet.com ( 74.52.95.42 ) : icmp_seq = 3的TTL = 46時間= 164毫秒
    64 bytes from 2a.5f.344a.static.theplanet.com (74.52.95.42): icmp_seq=4 ttl=46 time=130 ms 64字節從2a.5f.344a.static.theplanet.com ( 74.52.95.42 ) : icmp_seq = 4的TTL = 46時間= 130毫秒
    64 bytes from 2a.5f.344a.static.theplanet.com (74.52.95.42): icmp_seq=5 ttl=46 time=149 ms 64字節從2a.5f.344a.static.theplanet.com ( 74.52.95.42 ) : icmp_seq = 5的TTL = 46時間= 149毫秒
    ^C ^ ç
    — simplehelp.net ping statistics — -s implehelp.net平統計數字-
    5 packets transmitted, 5 received, 0% packet loss, time 4513ms第5包轉發, 5收到, 0 %丟包,時間4513ms
    rtt min/avg/max/mdev = 102.061/131.349/164.376/23.190 ms內河碼頭民/平均/最大/ mdev = 102.061/131.349/164.376/23.190毫秒

  9. Once you are finished online, don’t forget to switch back to the terminal where you ran wvdial and press Ctrl-C.一旦您完成在線,不要忘記切換回終端,您跑wvdial和按Ctrl - C上升。

    ^CCaught signal 2: Attempting to exit gracefully… ^ CCaught信號2 :嘗試退出優雅...
    –> Terminating on signal 15 -> “終止信號1 5
    –> Connect time 5.8 minutes. -> “連接時間5 .8分鐘。
    –> Disconnecting at Sun Oct 19 16:54:48 2008 -> “斷開S un公司1 0月1 9日1 6時五十四分4 8秒2 008年


GUI Method 桂方法

Now, if all that command line stuff scares you, here’s how to make it work using Gnome’s GUI:現在,如果所有的命令行的東西嚇跑你,這裡如何使它工作使用Gnome公司的圖形用戶界面:

  1. Click System -> Administration -> Network點擊系統 -> “管理- >”網絡
  2. You will be asked to enter your root password.您將被要求輸入您的root密碼。 Enter it and click OK .輸入然後單擊確定。
  3. Now you can see a list of installed network devices.現在,你可以看到一個安裝的網絡設備。 Click on the Hardware tab.點擊硬件選項卡。

  4. click to enlarge點擊放大

  5. Now click the New button, select Modem , and click OK .現在點擊新建按鈕,選擇調製解調器,然後單擊確定。
  6. Change the Modem Device to /dev/rfcomm0.變化的現代裝置 / dev/rfcomm0 。 If /dev/rfcomm0 is not available in the list, just type it in. Click OK .如果/ dev/rfcomm0不提供的名單,只需鍵入它進來單擊確定。
  7. Now click the Devices tab.現在單擊設備選項卡。

  8. click to enlarge點擊放大


    click to enlarge點擊放大

  9. Click the New button, select Modem connection, and click Forward . 單擊新建按鈕,選擇調製解調器連接 ,然後按一下前進

  10. click to enlarge點擊放大

  11. All I needed to do to make my Rogers Wireless connection work was enter *99***1# as the Phone Number, user as the Login Name, and pass as the Password.我需要做使我的羅傑斯無線上網的工作進入* 99 *** 1 #的電話號碼用戶的登錄名, 通過作為密碼。 I also chose to name this connection Bluetooth.我也選擇了這方面的名字藍牙。 Click Forward .按一下前進

  12. click to enlarge點擊放大

  13. I left these options at their defaults.我離開這些選項在默認。 Click Forward .按一下前進

  14. click to enlarge點擊放大

  15. We’ve finished creating the connection.我們已經完成建立連接。 Click Apply . 單擊應用。

  16. click to enlarge點擊放大

  17. Click the X in the top right corner to close this window.點擊 X右上角關閉此窗口。

  18. click to enlarge點擊放大

  19. Click Yes to save the changes. 單擊是保存更改。
  20. Click OK . 單擊確定。 No, we won’t need to restart the computer.不,我們將不再需要重新啟動計算機。

  21. click to enlarge點擊放大

  22. So, let’s use our newly created connection.所以,讓我們使用我們新創建的連接。 Click System -> Administration -> Network Device Control .點擊系統 -> “管理- >”網絡設備控制。
  23. Select the Bluetooth connection you just created and click Activate .選擇藍牙連接您剛剛創建並點擊激活

  24. click to enlarge點擊放大

  25. Notice how the Bluetooth connection has changed from Inactive to Active .通知如何藍牙連接已經從無效主動

  26. click to enlarge點擊放大

  27. Open Firefox and visit http://www.simplehelp.net.打開Firefox ,並參觀http://www.simplehelp.net 。

  28. click to enlarge點擊放大

  29. When you are finished online, go back to the Network Device Control window, select the Active Bluetooth connection and click Deactivate .當您完成在線,請返回網絡設備控制窗口中,選擇主動藍牙連接 ,然後點擊停用

  30. click to enlarge點擊放大

  31. Verify that the Bluetooth connection is indeed Inactive, then close the Network Device Control window.確認藍牙連接確實是無效,然後關閉網絡設備控制窗口。

  32. click to enlarge點擊放大

  33. Some of you may be wondering why I chose not to use Network Manager.你們有些人可能不知道我為什麼選擇不使用網絡管理員。 It’s quite simply due to the fact that mobile broadband support in Network Manager is in it’s infancy and I found it to be virtually unusable.這是很簡單原因是,移動寬帶支持網絡管理器是在它的初創階段,我發現這是幾乎無法使用。 Once Network Manager’s mobile broadband support becomes better, I’ll rewrite this tutorial based on it.一旦網絡管理員的移動寬帶支持變得更好,我會重寫本教程的基礎上它。
Related Posts: 相關文章:
  • How to share the GPS in your N95 with your laptop via Bluetooth in Linux如何分享全球定位系統在您的N95型與你的筆記本電腦通過藍牙在Linux
  • How to tether your Nokia N95s Internet connection to your laptop via USB in Linux如何繫繩諾基亞N95s您的Internet連接到您的膝上型電腦通過USB在Linux
  • How to turn your N95 into a wireless access point如何把你的N95型成一個無線接入點
  • Use Adeona to help recover a lost or stolen laptop使用Adeona ,以幫助恢復丟失或被盜的筆記本電腦
  • Technology and Lifestyle技術和生活方式
  • Get Simple Help tutorials just like this one in your email inbox every day - for free!獲取簡單的幫助教程就這樣一個在您的電子郵件收件匣每一天-是免費的! Just enter your email address below:只要輸入您的電子郵件地址如下:

    You can always opt out of this email subscription at any time.您可以隨時退出這個郵件訂閱在任何時候。


    Bookmark and Share 書籤和共享

    { 0 comments… 0評論... add one now現在添加一個 }

    Leave a Comment發表您的評論

    You can use these HTML tags and attributes: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <strike> <strong> 您可以使用這些HTML標記和屬性: href="" title="">的<a <abbr title=""> <acronym title="">的<b> <blockquote cite=""> <cite>的<code> <del datetime="">的<em> <i> <q cite=""> <strike>的<strong>