LinuxSir.cn,穿越时空的Linuxsir!

 找回密码
 注册
搜索
热搜: shell linux mysql
查看: 1953|回复: 10

Red Hat Linux7.3下 USB ADSL MODEM 怎么上网?

[复制链接]
发表于 2002-8-8 21:52:21 | 显示全部楼层 |阅读模式
我的MODEM 是Alcatel Speed Touch USB的。没有 For Linux的驱动,怎么上ADSL?
网上说不用驱动?我是这样做的:
> adsl-setup 回车
user name : whkz
Ethnet... : eth0
demand value: no
DNS... :202.103.24.68
Second DNS:202.103.0.117
Firewall.... :0

这样配置后,我敲:
> adsl-start
有错啊。是不是在网卡那儿错了?因为USB MODEM 是不要网卡的啊,但是它偏偏要选一项!
发表于 2002-8-8 22:16:52 | 显示全部楼层
USB要驱动才能工作.....
到alcatel的网站上找驱动。。。

http://www.speedtouchdsl.com/support.htm
 楼主| 发表于 2002-8-8 22:24:43 | 显示全部楼层
我刚才看了一下以往的贴子,不少人用这个猫呢,都搞定了?
我又到 sourceforge 去找了一下关于 这个猫的东东,居然让我找到一个RPM的驱动和一个关于 connected 的东东,都是2002年5月以后的。我去LINUX下试试再来。
祝我好运吧?!:)
发表于 2002-8-8 22:27:24 | 显示全部楼层
哈。。到目前为止,没有一个弟兄搞定。。。。可能也有搞定的,但没有消息。。。神龙见头不到尾,但愿兄弟把这个问题搞定。。。
发表于 2002-8-9 00:17:03 | 显示全部楼层

思路

应该让那USB先驱动起来,具体方法找一下linuxeden里有
发表于 2002-8-9 00:33:32 | 显示全部楼层
把那个文章帖过来.请多多少少兄弟帮个...多谢...
 楼主| 发表于 2002-8-9 10:08:16 | 显示全部楼层
晕,还是没有搞定,驱动似乎没有问题,那个speedtouchconnect 运行时有问题,法文看不懂!
今晚回家继续搞,现在在公司没有办法试
 楼主| 发表于 2002-8-18 15:14:39 | 显示全部楼层
Installation/Configuration :
This is a two step job:

Kernel configuration
Pppd Configuration
Kernel Configuration
To allow Benoit's drivers to work, your kernel has to have a few options enabled. Configure it with your everyday options and carefully add the following ones:


USB support
Your kernel obviously has to support USB to run Alcatel Speedtouch.

Depending on your USB controller (chipset on motherboard/pci card), you'll have to choose between two modules: UHCI or OHCI
Without explaining the whole thing, these are two USB incompatible standards.
This is why you have to know which chipset is yours.


To determine which to use :
# lspci -v | grep USB


You should obtain something like :

usb-ohci : CMD technologies Inc|USB0670B
usb-uhci : USB Controller: Intel Corporation 82371AB PIIX4 USB (rev 01) (prog-if 00 [UHCI])

If your chipset uses OHCI standard, you'll have to pick usb-ohci (surprising !).
If, on the contrary, it uses UHCI standard you'll have to choose between usb-uhci or uhci. They should work both, but in case you have problems setting usb support with a module, pick the other one, and pray !

Options to allow usb support :

<M>/<*> Support for USB (CONFIG_USB)
<*> Preliminary USB device filesystem (CONFIG_USB_DEVICEFS)
<M> UHCI (Intel PIIX4, VIA, ...) support (CONFIG_USB_UHCI)
<M> UHCI Alternate Driver (JE) support (CONFIG_USB_UHCI_ALT)
<M> OHCI (Compaq, iMacs, OPTi, SiS, ALi, ...) support (CONFIG_USB_OHCI)
PPP support
You'll need ppp support in your kernel. If needed compile these parts:

<M> PPP (point-to-point protocol) support (CONFIG_PPP)
<M> PPP support for sync tty ports (CONFIG_PPP_SYNC_TTY)
HDLC support
This part is more sensible. If you want to allow proper reconnection, you'll have to patch this module.
Take it easy, you'll find the patch in the drivers' tarball and the command line to run is simple :
# cd /usr/src/linux
# patch -p1 --dry-run < /path/to/drivers/n_hdlc.c.diff  (watchout: two - before dry-run ! )
If you don't get error message, type the real command to currently patch the kernel sources
#patch -p1 < /path/to/drivers/n_hdlc.c.diff

NB: Kernels >= 2.4.18 include our n_hdlc patch so you have not to apply the patch anymore

You can continue, now :

Character devices --->
  • Non-standard serial port support
    <M> HDLC line discipline support
  • Unix98 PTY support
    Installing the drivers
    This installation is straightforward uncompress the drivers'tarball by typing :
    # tar xvzf speedtouch-xxx.tar.gz
    cd into the new directory and type :
    # ./configure && make

    If everything ran fine su root and finish the install by typing :
    # make install

    Greetings, the drivers should now be installed

    NB: check your path if you can't run modem_run, as it is copied in /usr/local/sbin

    Creation of the PPP devices
    Cd into your /dev directory :
    # cd /dev

    Check ppp devices existence doing :
    # ls *ppp*

    If the ls command gives you an output go to the next step, else create all ppp devices typing :
    # ./MAKEDEV ppp

    Pppd configuration
    Check your pppd version by typing :
    # pppd --version.
    Drivers are tested with pppd 2.4.0 and 2.4.1. They also run fine with older versions, per example pppd 2.3.11 shiped with the Potato Debian GNU/Linux.

    #######################
    ##### 我是从这里开始对照配置的 #####
    #######################
    To configure pppd, you'll have to edit 4 files.

    1st file :
    You should have an /etc/ppp/options file, edit it and keep these 4 lines in it (comment all extra lines with a #)

    ------------------ /etc/ppp/options Beginning -------------
    noauth
    usepeerdns
    lock
    noipdefault
    ------------------ /etc/ppp/options End ------------------

    2nd file
    Create /etc/ppp/peers/adsl :
    # mkdir /etc/ppp/peers
    # touch /etc/ppp/peers/adsl

    Copy and paste what follows (without the "---" ;) )

    -------------------/etc/ppp/peers/adsl Beginning------------
    #
    # This file could be rename but its place is under /etc/ppp/peers
    # To connect to Internet using this configuration file
    # pppd call adsl, where "adsl" stands for the name of this file
    #

    debug
    kdebug 1
    noipdefault
    defaultroute
    pty "/usr/local/sbin/pppoa3 -m 1 -c -vpi 0 -vci 32"
    sync
    user "your_login_here"
    noauth
    noaccomp
    nopcomp
    noccp
    novj
    holdoff 4
    persist
    maxfail 25
    usepeerdns
    ------------------/etc/ppp/peers/adsl EOF------------------

    If for an unknown reason pppoa3 failed, you can still try the old pppoa2 daemon. You should change the pty "/usr/local/sbin/pppoa3 -m 1 -c -vpi 0 -vci 32" line by pty "/usr/local/sbin/pppoa2 -vpi 0 -vci 32"
    For more details about pppoa2/3, type "man pppoa3, man pppoa2".

    Don't forget to adapt the vpi and vci values in the line :
    pty "/usr/local/sbin/pppoa2 -vpi 0 -vci 32"



    3rd file :
    2 protocols can be used by providers to identify their users: CHAP or PAP.
    Depending on your provider, edit /etc/ppp/chap-secrets or /etc/ppp/pap-secrets.


    These fields look like this :

    -------------------/etc/ppp/chap-secrets Begining--------------
    # client server secret IP addresses
    "your_login_here" "*" "your_password_here" "*"
    -------------------/etc/ppp/chap-secrets End-------------------

    If you don't know what protocol is used by your provider, you can fill in both files, it won't hurt.

    4th file :
    Edit /etc/modules.conf (or /etc/conf.modules if your system is a bit old) and add the following lines :

    alias char-major-108  ppp_generic
    alias /dev/ppp ppp_generic
    alias tty-ldisc-3 ppp_async
    alias tty-ldisc-13 n_hdlc
    alias tty-ldisc-14 ppp_synctty
    alias ppp-compress-21 bsd_comp
    alias ppp-compress-24 ppp_deflate
    alias ppp-compress-26 ppp_deflate

    Some entries are useless, but once again they won't hurt !


    --------------------------------------------------------------------------------

    Launching the connection
    You'll have to :
    Load modem's microcode
    Start pppd

    NB: to launch the connection, it is almost mandatory to be logged as root.
    Verifications
    Check if all modules are loaded (if you didn't compile them directly into the kernel) :
    # modprobe ppp_generic
    # modprobe ppp_synctty
    # modprobe n_hdlc
    Then, check that usbdevfs is mounted :
    # modprobe usbcore
    # mount none /proc/bus/usb -t usbdevfs
    # modprobe usb-uhci or usb-ohci or uhci

    Load the firmware
    To load the microcode into the modem, simply type :
    # modem_run -m -f /path/to/mgmt.o
    or
    # modem_run -m -f /path/to/alcaudsl.sys
    Launch pppd
    Type (and pray) :
    # pppd call adsl
    Wait for a few seconds (20) and check if the link is up by typing :
    # ifconfig ppp0

    ##################################
    #####一直到这里,基本上是OK。我不知道到这里是不是就完了。可我在KDE下用Kppp拔号却说找不到 /dev/usb 设备。???????怎么回事?#####
    ##################################
  • 发表于 2002-8-18 18:08:12 | 显示全部楼层
    Alcatel Speedtouch ADSL USB: installazione modo libero

    Di Serge Tchesmeli, aggiornato da Jice
    Installazione sotto Linux del modem ADSL Alcatel Speedtouch USB



    Introduzione:

    Questo articolo descrive l’installazione dei drivers Opensource del modem ADSL Alcatel Speedtouch USB.

    In un altro articolo presente su Léa, abbiamo descritto come installare e configurare questo modem, ma il metodo è molto complicato ( bisogna patchare il kernel, ricompilarlo, compilare applicazioni esterne necessarie e configurare il tutto è complesso); in più il risultato è mediocre (blocco sistematico o un riavvio), e soprattutto questo metodo è basato sui drivers proprietari rilasciati da Alcatel che non sono liberi del tutto, poco stabili e poco sovente aggiornati.

    Ma Beno&#238;t Papillault ha avuto la buona idea di scrivere dei drivers LIBERI, e che sono più stabili e molto facili da installare. Molte grazie a lui!

    Se utilizzate una Mandrake 8.1 o 8.2, questo articolo non vi riguarda a priori. Questa distribuzione fornisce in effetti i drivers di B. Papillault e vi propone di configurarli sia prima dell’installazione sia subito dopo. Nell’ultimo caso è sufficiente utilizzare il Mandrake Control Center (DrakConf), andando su Rete Internet/Connessione, cliccando sul bottone Configura (in basso a destra) poi seguendo le istruzioni a schermo! La sola altra cosa che dovete fare è di copiare in seguito il file mgmt.o nella directory /usr/share/speedtouch (se non sapete come recuperare questo file allora consultate questo articolo).
    A causa di un bug che affligge la MDK 8.2: l’installazione dei drivers non funziona durante l’installazione della distribuzione. Bisogna assicurarsi che i files di configurazione sono buoni (vedere sotto), e se è questo il caso, funziona, anche se il messaggio al boot segna [FAILED] al momento di stabilire la connessione.

    Ecco un metodo alternativo per una installazione rapida su una Mandrake 8.x.

    Prerequisiti e test del modem:


    Supporto USB

    Se utilizzate delle altre periferiche USB, potete oltrepassare questo paragrafo. Verificate soltanto che il modem è rilevato.

    In un primo tempo, andremo a configurare il nostro sistema per accettare il modem USB e farlo rilevare.
    Nota: molte distribuzioni attuali installano l’USB come standard (ad esempio la Mandrake 8).

    Si suppone che voi abbiate un kernel recente (a partire dal 2.2.18), compilato con il supporto USB corrispondente al chipset della vostra scheda madre, che gestisca l’USB sia in modo nativo che come modulo.

    Se non sapete quale chipset avete, assicuratevi solo che il vostro kernel sia compilato con questa opzioni:

    Support for USB (CONFIG_USB) [M]
    Preliminary USB device filesystem (CONFIG_USB_DEVICEFS) [Y]
    UHCI (Intel PIIX4, VIA, ...) support (CONFIG_USB_UHCI) [M]
    UHCI Alternate Driver (JE) support (CONFIG_USB_UHCI_ALT) [M]
    OHCI (Compaq, iMacs, OPTi, SiS, ALi, ...) support (CONFIG_USB_OHCI) [M]

    La maggior parte delle volte, se la vostra scheda madre è recente, è il modulo usb-uhci che bisogna caricare (chipset Intel o VIA, i più diffusi).
    Nel caso di una scheda USB addizionale, o su un Apple (iMac, iBook…), può essere che sia scelto usb-ohci. Verificate in tutti i modi sulle notizie della vostra scheda madre o della vostra scheda addizionale il tipo di porta USB che voi avete; nel dubbio prendete tutti i moduli UHCI e OHCI.

    Se il modulo corrispondente al vostro tipo di porta USB non è caricato (questo si verifica tramite il comando lsmod), caricatelo.

    Verificate che il vostro modem è rilevato bene. Per questo eseguite il comando:

    # mount -t usbdevfs none /proc/bus/usb

    Se questo vi dice che il filesystem è già montato, questo non è grave.
    Digitate quindi:

    # cat /proc/bus/usb/devices

    E dovrete veder apparire dei messaggi del tipo:

    ...
    S: Manufacturer=ALCATEL
    S: Product=Speed Touch USB
    S: SerialNumber=0090D013AAB8
    C:* #Ifs= 3 Cfg#= 1 Atr=80 MxPwr=500mA
    I: If#= 0 Alt= 0 #EPs= 1 Cls=ff(vend.) Sub=00 Prot=00 Driver=usbdevfs
    E: Ad=81(I) Atr=03(Int.) MxPS= 16 Ivl= 50ms
    I: If#= 1 Alt= 0 #EPs= 0 Cls=ff(vend.) Sub=00 Prot=00 Driver=usbdevfs
    I: If#= 1 Alt= 1 #EPs= 3 Cls=ff(vend.) Sub=00 Prot=00 Driver=usbdevfs
    E: Ad=06(O) Atr=02(Bulk) MxPS= 64 Ivl= 0ms
    E: Ad=07(O) Atr=02(Bulk) MxPS= 64 Ivl= 0ms
    E: Ad=87(I) Atr=02(Bulk) MxPS= 64 Ivl= 0ms
    ...

    Ok il modem è stato ben rilevato.

    In caso di problemi, scollegate il modem (dalla porta USB), poi ricollegatelo. Adesso, se i due LEDs verdi si accendono, è stato rilevato bene.
    Al contrario se non si accende nulla (nessun LED) o se si accende solo il LED rosso c’è un problema, verificate che il modulo USB è caricato per bene, e che voi avete caricato quello corrispondente al vostro hardware (OHCI o UHCI).

    Supporto PPP

    E’ necessario anche il supporto PPP nel vostro kernel. La maggior delle volte, nelle distribuzioni recenti, questo supporto è già presente. Sappiate che se voi prima utilizzavate una connessione per modem RTC (modem tradizionale sulla linea telefonica) avete già il supporto PPP. In questo caso potete oltrepassare questo paragrafo.

    Per verificare quanto sopra, digitate in una console:

    # pppd

    Se vedrete apparire dei caratteri bizzarri (del tipo %:/lm…) va tutto bene: avete il supporto PPP. Premete CTRL-C per fermare pppd.

    Al contrario se vedrete un messaggio del tipo:

    pppd: This system lacks kernel support for PPP. This could be because the PPP kernel module could not be loaded, or because PPP was not included in the kernel configuration.

    Vuol dire che non avete il supporto PPP nel vostro kernel. In questo caso, ricompilate il vostro kernel con le seguenti opzioni:

    PPP (point-to-point protocol) support (CONFIG_PPP) [M]
    PPP support for sync tty ports (CONFIG_PPP_SYNC_TTY) [M]

    Ultima verifica da fare, verificate che il vostro kernel possegga anche il supporto HDLC (normalmente è così per le distribuzioni recenti) provando a caricare il modulo:

    # modprobe n_hdlc

    Se il supporto non è presente, ricompilate il vostro kernel con le opzioni seguenti:

    Character devices --->
  • Non-standard serial port support
    HDLC line discipline support
  • Unix98 PTY support

    Infine, automatizzate il caricamento dei moduli, e definite gli alias dei moduli inserendoli nel file /etc/modules.conf:

    alias char-major-108 ppp_generic
    alias tty-ldisc-3 ppp_async
    alias tty-ldisc-13 n_hdlc
    alias tty-ldisc-14 ppp_synctty

    E visto che ci siete, inserite le linee seguenti in questo file (questi sono i protocolli di compressione):

    alias ppp-compress-21 bsd_comp
    alias ppp-compress-24 ppp_deflate
    alias ppp-compress-26 ppp_deflate

    Fatto, adesso passiamo all’installazione dei drivers.

    Installazione dei drivers


    Drivers

    Bisogna recuperare i drivers, per questo andate su: http://benoit.papillault.free.fr/speedtouch/user.php3

    Prendete l’ultima versione! Poi scompattatela (tar zxvf speedtouch-VERSION.tar.gz), mettetela nella directory così ottenuta e compilate il tutto:

    $ ./configure
    $ make
    $ su
    Password:
    # make install
    # exit (Essendo root per poter installare sicuramente).

    Firmware

    C’è bisogno anche di uno dei files dei drivers ufficiali Alcatel (si tratta infatti del FIRMWARE che è il programma caricato nel processore del modem stesso), la sola parte dei drivers che Beno&#238;t non ha potuto scrivere, che sono il segreto di Alcatel, e riscrivere un firmware non è poco.
    Per questo andate su questa pagina, e prendete i drivers per Linux.

    Scompattateli (tar zxvf nome_del_file.tar.gz), NON INSTALLATELI, recuperate soltanto il file mgmt.o e copiatelo in /usr/local/share/speedtouch/ (questa directory è stata creata per l’installazione dei drivers). Potete cancellare il resto.

    Nota: se utilizzate Windows, potete anche copiare il file alcaudsl.sys che si trova in c:windows o una sottodirectory, in /usr/local/share/speedtouch/mgmt.o

    Bene, adesso configuriamo la connessione stessa.

    Configurazione della connessione

    Per questa parte avete bisogno dei parametri di configurazione della vostra connessione che il vostro fornitore di accesso vi ha fornito. Andate nella directory /etc/ppp/peers (createla se non esiste), e create un file /etc/ppp/peers/adsl comprendente:

    noauth
    noipdefault
    pty "/usr/local/bin/pppoa2 -vpi VPI -vci VCI"
    sync
    noaccomp
    nopcomp
    noccp
    novj
    holdoff 4
    maxfail 25
    persist
    usepeerdns
    user "vostra login"
    defaultroute
    debug
    kdebug 1

    Con valori come:
    - VPI: 8
    - VCI: 35

    ATTENZIONE: Questi valori sono validi in linea di massima per la Francia, l’italia e il Belgio... Per trovare i vostri VPI/VCI, sotto Windows, dovete avere una piccola icona verde rappresentante il vostro modem a sinistra dell’orologio, cliccateci sopra con il mouse due volte, poi cliccate sul tasto verde intitolata MORE, i parametri di connessione appariranno sulla finestra “Connessione”, notate i valori VPI e VCI. Mettete gli stessi valori nel file descritto qui sopra.
    Se non utilizzate Windows, i valori seguenti potranno forse aiutarvi:
    Olanda: 8.48
    Francia: 8.35 (o 8.67)
    Belgio: 8.35
    Italia: 8.35
    UK: 0.38
    Per il valore della “vostra login” mettete l’utente COMPLETO senza dimenticare il @FAI, spesso obbligatorio. Per esempio nel mio caso, una connessione Wanadoo (fti = France Telecom Interactive), la mia login è del tipo:
    user fti/gf3yud@fti
    Create adesso un file /etc/ppp/chap-secrets (o cambiate quello già esistente) con:

    # Secrets for authentication using CHAP
    # client server secret IP addresses
    "vostra login" "*" "password" "*"

    e anche il file /etc/ppp/pap-secrets:

    # Secrets for authentication using PAP
    # client server secret IP addresses
    "vostra login" "*" "password" "*"

    Anche qua la login dovrà essere completa.

    Ecco tutto è pronto per essere testato!

    Nota: Dovrete forse rimpiazzare la riga

    pty "/usr/local/bin/pppoa2 -vpi VPI -vci VCI"
    con
    pty "/usr/local/sbin/pppoa3 -m 1 -c -vpi VPI -vci VCI",

    e provare pppoa3 invece di pppoa2.

    Testate il tutto!

    Lanciate il seguente comando:

    # /usr/local/bin/modem_run -f /usr/local/share/speedtouch/mgmt.o –m

    Aspettate un po’, che il LED verde di destra non lampeggi più. Se ricevete un messaggio d’insulto e il LED di destra diventa arancio, ridigitate il comando (succede che il modem non si inizializzi bene la prima volta). Se il LED verde e non lampeggia più, lanciate allora questo comando:

    # pppd call adsl

    Se avete un messaggio con degli indirizzi IP, è tutto a posto: funziona!!! (Nota di Jice: da me non c’è alcuna risposta: pppd call adsl ritorna alla riga di comando subito, la connessione è stabilita, e funziona) ;)
    Provate allora a navigare sul web!

    Per automatizzare la connessione all’avvio, potete piazzare questi due comandi in uno script di avvio, o controllate cosa si può fare con lo script /usr/local/share/speedtouch/adsl.sh

    Nota: se avete dei problemi di risoluzione DNS, rinominate il file /etc/resolv.conf in resolv.conf.backup ad esempio, e digitate il comando:

    # ln -s /etc/ppp/resolv.conf /etc/resolv.conf

    Provate di nuovo (ma normalmente i DNS sono recuperati automaticamente alla connessione, è l’opzione usepeerdns vista più sopra).

    Ecco! Buona navigazione ad alta velocità con il vostro pinguino preferito!
  •  楼主| 发表于 2002-8-18 19:50:23 | 显示全部楼层
    北南南北兄,你这个好象是 Mandrake8.2.x下的安装方法呀,不过跟我的那个也差不多哟。你这还是法文,晕撒~~~
    您需要登录后才可以回帖 登录 | 注册

    本版积分规则

    快速回复 返回顶部 返回列表