N900 USB router

(mention Nokia PC Suite as well)
(wikify and tidy)
Line 1: Line 1:
-
When the only internet link is the N900, how to connect a laptop to it and use it to connect to the net ? This is the oposite use case of http://wiki.maemo.org/N900_USB_networking.
+
When the only internet link is the [[Nokia N900|N900]], how to connect a laptop to it and use it to connect to the net? This is the opposite use case of [[N900 USB networking]].
 +
 
== On the N900 ==
== On the N900 ==
-
/etc/apt/sources.list
+
 
-
deb http://repository.maemo.org/extras-devel/ fremantle free
+
<ol>
-
apt-get install iptables
+
<li>[[Extras-devel#How to activate Extras-devel|Enable extras-devel]]</li>
-
http://wiki.maemo.org/Kernel_Power#I...el_from_extras
+
<li>Install [http://maemo.org/packages/view/iptables/ iptables] at a [[terminal]] with [[root access]]:<pre>apt-get install iptables</pre></li>
-
apt-get install kernel-power-settings
+
<li>Install [http://maemo.org/packages/view/kernel-power-settings/ kernel-power-settings] (see [[Kernel_Power#Installation_of_the_stable_kernel_from_extras|the detailed installation instructions]]):<pre>apt-get install kernel-power-settings</pre></li>
-
echo 1 > /proc/sys/net/ipv4/ip_forward
+
<li>Setup iptables to allow forwarding:
-
iptables -t nat -A POSTROUTING -o wlan0 -j MASQUERADE
+
<pre>
-
iptables -t nat -A POSTROUTING -o gprs0 -j MASQUERADE
+
echo 1 > /proc/sys/net/ipv4/ip_forward
-
cat /etc/network/interfaces
+
iptables -t nat -A POSTROUTING -o wlan0 -j MASQUERADE
-
iface usb0 inet static
+
iptables -t nat -A POSTROUTING -o gprs0 -j MASQUERADE
-
address 192.168.3.15
+
</pre></li>
-
netmask 255.255.255.0
+
<li>Check the IP address for USB networking:<pre>cat /etc/network/interfaces</pre>
-
ifup usb0
+
<pre>
 +
iface usb0 inet static
 +
address 192.168.3.15
 +
netmask 255.255.255.0
 +
ifup usb0
 +
</pre>
 +
</li>
 +
</ol>
 +
 
== On the laptop ==
== On the laptop ==
 +
 +
Use the IP address for USB networking from [[#On the N900|the N900]] and configure the USB network device to use it as the default gateway:
 +
  sudo ifconfig usb1 192.168.3.14
  sudo ifconfig usb1 192.168.3.14
  sudo route add default gw 192.168.3.15
  sudo route add default gw 192.168.3.15
 +
== For Non-Power Users On Windows ==
-
= For Non-Power Users On Windows =
+
The [http://www.nokiausa.com/get-support-and-software/software/nokia-pc-suites/compatibility-and-download Nokia PC Suite] also provides this functionality for Windows users. Once it is set up, click on the green globe icon to get started - or you can just run "OneTouchAccess" from the PC Suite program files directory (<code>C:\Program Files\Nokia\Nokia PC Suite 7\</code> by default on Windows XP)
-
 
+
-
The [http://www.nokiausa.com/get-support-and-software/software/nokia-pc-suites/compatibility-and-download Nokia PC Suite] also provides this functionality for Windows users. Once it's set up, click on the green globe icon to get started - or you can just run "OneTouchAccess" from the PC Suite program files directory (C:\Program Files\Nokia\Nokia PC Suite 7\ by default on Windows XP)
+

Revision as of 02:38, 29 June 2010

When the only internet link is the N900, how to connect a laptop to it and use it to connect to the net? This is the opposite use case of N900 USB networking.

On the N900

  1. Enable extras-devel
  2. Install iptables at a terminal with root access:
    apt-get install iptables
  3. Install kernel-power-settings (see the detailed installation instructions):
    apt-get install kernel-power-settings
  4. Setup iptables to allow forwarding:
    echo 1 > /proc/sys/net/ipv4/ip_forward
    iptables -t nat -A POSTROUTING -o wlan0 -j MASQUERADE
    iptables -t nat -A POSTROUTING -o gprs0 -j MASQUERADE
    
  5. Check the IP address for USB networking:
    cat /etc/network/interfaces
    iface usb0 inet static
    address 192.168.3.15
    netmask 255.255.255.0
    ifup usb0
    

On the laptop

Use the IP address for USB networking from the N900 and configure the USB network device to use it as the default gateway:

sudo ifconfig usb1 192.168.3.14
sudo route add default gw 192.168.3.15

For Non-Power Users On Windows

The Nokia PC Suite also provides this functionality for Windows users. Once it is set up, click on the green globe icon to get started - or you can just run "OneTouchAccess" from the PC Suite program files directory (C:\Program Files\Nokia\Nokia PC Suite 7\ by default on Windows XP)