Vediamo se riesco a Tetherare a rovescio col Next da Ubuntu Natty Narwal 64Bit!
Prima di collegare il Next, verifico che la rete di Ubuntu sia attiva (chiaramente se navigo è attiva ma voglio essere sicuro nei dettagli) così:
codice:
root@NattyBox:~# ifconfig
eth0 Link encap:Ethernet HWaddr 08:00:27:c6:ce:d3
indirizzo inet:192.168.56.119 Bcast:192.168.56.255 Maschera:255.255.255.0
indirizzo inet6: fe80::a00:27ff:fec6:ced3/64 Scope:Link
UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1
RX packets:12 errors:0 dropped:0 overruns:0 frame:0
TX packets:47 errors:0 dropped:0 overruns:0 carrier:0
collisioni:0 txqueuelen:1000
Byte RX:1228 (1.2 KB) Byte TX:8422 (8.4 KB)
...
root@NattyBox:~#
...così:
codice:
root@NattyBox:~# route
Tabella di routing IP del kernel
Destination Gateway Genmask Flags Metric Ref Use Iface
192.168.56.0 * 255.255.255.0 U 1 0 0 eth0
link-local * 255.255.0.0 U 1000 0 0 eth0
default 192.168.56.1 0.0.0.0 UG 0 0 0 eth0
root@NattyBox:~#
...così:
codice:
root@NattyBox:~# ping -c 1 192.168.56.1
PING 192.168.56.1 (192.168.56.1) 56(84) bytes of data.
64 bytes from 192.168.56.1: icmp_req=1 ttl=64 time=0.165 ms
--- 192.168.56.1 ping statistics ---
1 packets transmitted, 1 received, 0% packet loss, time 0ms
rtt min/avg/max/mdev = 0.165/0.165/0.165/0.000 ms
root@NattyBox:~#
così:
codice:
root@NattyBox:~# nslookup www.google.it
Server: 193.70.152.25
Address: 193.70.152.25#53
Non-authoritative answer:
www.google.it canonical name = www.google.com.
www.google.com canonical name = www.l.google.com.
Name: www.l.google.com
Address: 173.194.35.49
Name: www.l.google.com
Address: 173.194.35.50
Name: www.l.google.com
Address: 173.194.35.51
Name: www.l.google.com
Address: 173.194.35.52
Name: www.l.google.com
Address: 173.194.35.48
root@NattyBox:~#
...e così:
codice:
root@NattyBox:~# traceroute www.google.it
traceroute to www.google.it (74.125.232.115), 30 hops max, 60 byte packets
1 192.168.56.1 (192.168.56.1) 0.157 ms 0.092 ms 0.092 ms
2 10.0.0.1 (10.0.0.1) 621.014 ms 740.552 ms 740.598 ms
3 151.6.46.210 (151.6.46.210) 750.168 ms 750.573 ms 759.936 ms
4 ... (...) 759.816 ms 769.697 ms 769.596 ms
5 ... (...) 779.815 ms 779.708 ms 780.100 ms
6 ... (...) 781.018 ms 266.049 ms 325.778 ms
7 66.249.94.235 (66.249.94.235) 395.419 ms 626.293 ms 626.569 ms
8 72.14.232.63 (72.14.232.63) 655.598 ms 735.526 ms 745.527 ms
9 mil01s07-in-f19.1e100.net (74.125.232.115) 735.284 ms 735.542 ms 745.528 ms
root@NattyBox:~#
N.B. Ho messo dei puntini rossi - qua e là - per questioni di GEO-Privacy e... potrebbe essere necessario installare il pacchetto traceroute per eseguire l'ultimo comando
Cosa ho fatto?
- ho verificato la presenza dell'interfaccia di rete (ifconfig)
- come sono gestite le mie richieste in uscita (route)
- se riesco ad uscire dalla porta di casa di Ubuntu (ping)... rimanendo sulla soglia...
- se riesco a tradurre i nomi dei siti nel loro vero indirizzo internet (nslookup)
- se riesco ad arrivarci e tornare indietro (traceroute)
...sembra che la rete funzioni correttamente (lato Ubuntu)... adesso collego il Next (COME SEMPRE) e verifico dal Visualizzatore dei registri di sistema (file syslog) che sia tutto a posto:
codice:
Dec 27 19:02:37 NattyBox kernel: [ 1427.800115] usb 1-1: new high speed USB device using ehci_hcd and address 2
Dec 27 19:02:37 NattyBox kernel: [ 1428.083197] usbcore: registered new interface driver uas
Dec 27 19:02:37 NattyBox kernel: [ 1428.094218] cdc_acm 1-1:1.0: This device cannot do calls on its own. It is not a modem.
Dec 27 19:02:37 NattyBox kernel: [ 1428.094284] cdc_acm 1-1:1.0: ttyACM0: USB ACM device
Dec 27 19:02:37 NattyBox kernel: [ 1428.106677] usbcore: registered new interface driver cdc_acm
Dec 27 19:02:37 NattyBox kernel: [ 1428.106681] cdc_acm: v0.26:USB Abstract Control Model driver for USB modems and ISDN adapters
Dec 27 19:02:37 NattyBox kernel: [ 1428.117222] Initializing USB Mass Storage driver...
Dec 27 19:02:37 NattyBox kernel: [ 1428.118022] scsi3 : usb-storage 1-1:1.3
Dec 27 19:02:37 NattyBox kernel: [ 1428.119433] usbcore: registered new interface driver usb-storage
Dec 27 19:02:37 NattyBox kernel: [ 1428.119437] USB Mass Storage support registered.
Dec 27 19:02:37 NattyBox modem-manager[661]: <info> (ttyACM0) opening serial port...
Dec 27 19:02:38 NattyBox modem-manager[661]: <info> (ttyACM0) closing serial port...
Dec 27 19:02:38 NattyBox modem-manager[661]: <info> (ttyACM0) serial port closed
Dec 27 19:02:38 NattyBox modem-manager[661]: <info> (ttyACM0) opening serial port...
Dec 27 19:02:38 NattyBox modem-manager[661]: <info> (Generic): GSM modem /sys/devices/pci0000:00/0000:00:1f.5/usb1/1-1 claimed port ttyACM0
Dec 27 19:02:38 NattyBox kernel: [ 1429.133250] scsi 3:0:0:0: Direct-Access SAMSUNG GT-S5570 Card 0100 PQ: 0 ANSI: 2
Dec 27 19:02:38 NattyBox kernel: [ 1429.141830] sd 3:0:0:0: Attached scsi generic sg3 type 0
Dec 27 19:02:38 NattyBox kernel: [ 1429.174095] sd 3:0:0:0: [sdb] Attached SCSI removable disk
...ovviamente il mio Next è rooted e busyboxed... altrimenti mi fermo qui...
N.B. A questo punto è RACCOMANDATISSIMO installare su Next l'emulatore di terminale... fra poco sarà l'unica opzione disponibile...
...al momento ho il Wifi disattivato ma il Next è online per conto suo sulla rete 3G...
lo verifico (da adb shell!) così:
codice:
# busybox ifconfig
...
pdp0 Link encap:Point-to-Point Protocol
inet addr:201.202.203.204 P-t-P:201.202.203.204 Mask:255.255.255.0
UP POINTOPOINT RUNNING NOARP MULTICAST MTU:1350 Metric:1
RX packets:8353 errors:0 dropped:0 overruns:0 frame:0
TX packets:8570 errors:0 dropped:0 overruns:0 carrier:0
collisions:0 txqueuelen:1000
RX bytes:6105165 (5.8 MiB) TX bytes:1236210 (1.1 MiB)
#
ATTENZIONE: Io non ho installato busybox fino in fondo ma solo in parte, quindi tutti i miei comandi busyboxati avranno sempre il prefisso busybox...
...in caso di installazione completa (busybox install) è sufficiente digitare il comando dopo il prefisso...
N.B. Per motivi di geo-privacy ho cambiato ancora l'indirizzo attuale della mia connessione...
...così:
codice:
# busybox route
Kernel IP routing table
Destination Gateway Genmask Flags Metric Ref Use Iface
201.202.203.204 * 255.255.255.255 UH 0 0 0 pdp0
193.70.152.25 * 255.255.255.255 UH 0 0 0 pdp0
212.52.97.25 * 255.255.255.255 UH 0 0 0 pdp0
201.203.203.0 * 255.255.255.0 U 0 0 0 pdp0
default 201.202.203.1 0.0.0.0 UG 0 0 0 pdp0
#
...e così:
codice:
# busybox ping -c 1 201.203.203.204
PING 201.203.203.204 (201.203.203.204): 56 data bytes
64 bytes from 201.203.203.204: seq=0 ttl=64 time=1.637 ms
--- 201.203.203.204 ping statistics ---
1 packets transmitted, 1 packets received, 0% packet loss
round-trip min/avg/max = 1.637/1.637/1.637 ms
#
può bastare...
Adesso facciamoli comunicare!
Mi metto davanti al visualizzatore dei file di registro (file syslog) e sul Next dal menu Impostazioni -> Wireless e Rete -> Tethering o Router Wifi attivo il Tethering USB...
...WOW...
codice:
...
...
Dec 27 19:27:54 NattyBox NetworkManager[646]: <info> (usb0): DHCPv4 state changed preinit -> bound
Dec 27 19:27:54 NattyBox NetworkManager[646]: <info> Activation (usb0) Stage 4 of 5 (IP4 Configure Get) scheduled...
Dec 27 19:27:54 NattyBox NetworkManager[646]: <info> Activation (usb0) Stage 4 of 5 (IP4 Configure Get) started...
Dec 27 19:27:54 NattyBox NetworkManager[646]: <info> address 192.168.42.148
Dec 27 19:27:54 NattyBox NetworkManager[646]: <info> prefix 24 (255.255.255.0)
Dec 27 19:27:54 NattyBox NetworkManager[646]: <info> gateway 192.168.42.129
Dec 27 19:27:54 NattyBox NetworkManager[646]: <info> hostname 'NattyBox'
Dec 27 19:27:54 NattyBox NetworkManager[646]: <info> nameserver '192.168.42.129'
...
...
Non solo ha scritto un sacco di Logs, ma mi ha anche attivato una nuova interfaccia di rete chiamata semplicemente
auto USB
Tutto qua?
Lo verificheremo nel prossimo Post...
eh eh... please wait...
P.S. Come ricordato alcuni post sopra, ringraziamenti a Stepph per la configurazione e i test sul Next!