Capítulo 7. Internet

Índice

Ligar à Internet
Configurar uma rede
Navegação web com o Firefox.
Send and receive emails
Instant Messaging
Outras aplicações da Internet
Design web pages

Esta secção descreve algumas das tarefas relacionadas com a Internet, incluindo como se ligar à Internet, configurar e utilizar um navegador web, e usar outros tipos de programas relacionados com a Internet.

Ligar à Internet

Procedimento Básico

Esta secção descreve o procedimento básico para se ligar à Internet.

[Nota]

Se possui uma rede sem fios ou liga-se à Internet através de um modem (incluindo um modem ADSL), e esta secção não o ajuda, deverá ler “Placas wireless” ou “Ligações ADSL”.

Para se ligar à Internet:

  1. Abrir AplicaçõesSistemaRede.

  2. Vá até ao separador Ligações e clique na ligação que deseja utilizar para a seleccionar.

  3. Pressione Propriedades para modificar algumas definições.

  4. If your ISP or network administrator has given you an IP address, set Configuration to Static IP address, then enter the address in the IP address field and click OK. Otherwise, set Configuration to Automatic configuration (DHCP) and click OK.

  5. Marque a caixa ao lado da sua ligação para a ligar.

Placas wireless

Many wireless cards are automatically detected by Xubuntu during installation. To see if your card is supported, open ApplicationsSystemNetwork. If your wireless card is listed, you can follow “Procedimento Básico” to connect to the Internet. You need to enter a valid ESSID value. If in doubt, type any. A complete listing of wireless cards which work with Xubuntu can be found online at the Ubuntu Wiki. Please add your wireless card to the list if it works with Xubuntu.

Se a sua rede wireless é protegida por encriptação WEP, certifique-se que especificou a sua senha de acesso à rede ao configurar a sua ligação.

  1. Press ApplicationsSystemNetwork and click the wireless connection you wish to use.

  2. Press Properties, choose Password Type and enter your WEP password in Network Password form below.

  3. Pressione Ok e Fechar para aplicar as modificações.

Placas wireless não suportadas

Algumas placas wireless podem não funcionar automaticamente com Xubuntu. Se for este o caso, por favor, dê uma olhada no Guia de Solução de Problemas Wireless no Ubuntu Wiki, um excelente recurso para resolver problemas de placas wireless.

If your wireless card does not work with Xubuntu, you may have to do some research in order to activate it. A relatively reliable way of getting a wireless card to work is to use the ndiswrapper tool which allows Xubuntu to use the Microsoft Windows driver for the wireless card. To do this, follow the instructions below in “Using Windows wireless drivers”.

Quaisquer outras informações referentes a redes sem fio no Xubuntu está armazenada em Central de Rede Wireless no Wiki Ubuntu.

Resolução de problemas

Verificar o reconhecimento do dispositivo

  1. Open a Terminal (ApplicationsAccessoriesTerminal) and type the command: sudo lshw -C network

  2. Se existir um controlador listado veja “Verifique se o dispositivo se encontra activo”.

  3. Configure o NDISWrapper (“Using Windows wireless drivers”).

Verifique se o dispositivo se encontra activo

  1. Many wireless network devices can be turned on or off. Check to see if the device is turned on by opening a Terminal (ApplicationsAccessoriesTerminal) and type the command: sudo lshw -C network.

  2. Se estiver ligado então veja “Verifique a ligação ao router”.

Verifique a ligação ao router

  1. Abra um Terminal (AplicativosAcessóriosTerminal)e digite o comando: iwconfig.

  2. Se houver uma entrada que diz ESSID="" então veja Configurar o WPA (“Configurar o suporte a WPA.”

  3. Se o ESSID para nosso router for mostrado pode haver um problema com o suporte ACPI. Inicie o kernel com a opção pci=noacpi.

Verifique a atribuição de IP

  1. Open a Terminal (ApplicationsAccessoriesTerminal) and type the command: ifconfig.

  2. If there is an IP address shown see “Verifique o DNS”.

  3. From the Terminal enter the command: dhclient if_name where if_name is the connection listed earlier.

  4. If you receive a message that says bound to xxx.xxx.xxx.xxx then see “Verifique o DNS”

  5. If not then reboot the system.

Verifique o DNS

  1. Open a Terminal (ApplicationsAccessoriesTerminal) and type the command: ping 82.211.81.158.

  2. Now type the command: ping www.ubuntu.com.

  3. Type the command: cat /etc/resolv.conf. If there is no nameserver listed then contact your ISP and find out your primary and secondary domain name servers. Once you have this information see “Placas wireless”.

Using Windows wireless drivers

Even if your wireless network card does not have a native Linux driver, you may still be able to get it working with ndiswrapper. Ndiswrapper is a Linux module which allows Xubuntu to use Microsoft Windows driver for wireless cards (in most cases).

[Nota]

These instructions apply only to the x86 and AMD64 versions of Xubuntu, and not to Xubuntu for Power PC (PPC).

[Dica]

If you have access to the Internet, you can see if your wireless cards is in the list of cards supported by ndiswrapper on the ndiswrapper website.

To install ndiswrapper, install the package ndiswrapper-utils (see Capítulo 11, Instalar, Remover e Atualizar Aplicações). This package is provided on the Xubuntu CD. If you have access to the Internet, you can also optionally install a graphical tool, ndisgtk from the Universe repository (see “Repositórios de Software”).

In order to set up ndiswrapper, it is necessary to obtain the Windows driver for your wireless card. Generally, the best way to do this is from the CD supplied with your wireless card. You should copy two files to the same place on your computer, one ending in .SYS and one ending in .INF. If you find any files which end in .BIN, also copy those. If you are not able to find the right files, and have alternative access to the Internet, you may be able to obtain help from the ndiswrapper website.

If you have installed the graphical tool ndisgtk, to set up ndiswrapper, simply select ApplicationsSystemWindows Wireless Drivers from the menu, and follow the instructions given.

Se não instalou a ferramenta gráfica, use o seguinte procedimento:

  1. Open ApplicationsAccessoriesTerminal and type:

    sudo ndiswrapper -i ~/Desktop/drivername.inf
    [Nota]

    The above command assumes that your .INF file is named drivername.inf and was copied to your Desktop. Replace these values if necessary.

  2. To check if it is working correctly, type:

    ndiswrapper -l

    If it is working correctly, you should see:

    Installed ndis drivers:
    {name of driver}  driver present, hardware present

  3. For ndiswrapper to function, you need to load a module. To do this, type:

    sudo depmod -a
    sudo modprobe ndiswrapper
  4. To ensure that the module is loaded each time you boot the computer, type:

    sudo ndiswrapper -m

You should now be able to connect to the Internet by following the instructions at “Procedimento Básico”.

Segurança de rede sem fios

Configurar o suporte a WPA.

WiFi Protected Access (WPA) is an based on WEP and provides stronger security.

WPA is integrated with Network Manager. You must also have the wpasupplicant package installed.

If you need to manually configure WPA support, see the Wiki Entry.

Ligações ADSL

All PPPoE and router-style ADSL modems that use an Ethernet connection are supported by Xubuntu, and some USB ADSL modems are supported too.

For a router-style ADSL modem, simply follow “Procedimento Básico”

For information on setting up a PPPoE ADSL modem see “Modems PPPoE”.

For information on setting up a USB ADSL modem see “Modems ADSL USB”.

Modems PPPoE

This section is about setting up an ADSL Internet connection using an ethernet PPPoE modem.

You will need to have subscribed to an Internet Service Provider, and your Internet connection must be installed and functional. A "DSL" light on your modem usually shows that the line is synchronized.

You will need your username and password for the account. You must also have an ethernet card connected to your PPPoE modem with the correct type of cable.

Finally, you need the PPPoE package to be installed in order for the following command to work. This package is installed by default, but can be missing if the configuration has been changed. If the following command does not work, you will need to install this package, which can be found on the Xubuntu CD.

Para configurar o modem:

  1. Open ApplicationsAccessoriesTerminal

  2. In the terminal type:

    sudo pppoeconf
  3. A text-based menu program will guide you through the next steps, which are:

    1. Confirme que a sua placa Ethernet é detectada.

    2. Introduza o seu nome de utilizador.

    3. Introduza a sua palavra passe.

    4. Se já tiver uma Ligação PPPoE configurada, ser-lhe-á perguntado se esta pode ser modificada.

    5. Opções comuns: se lhe perguntarem se deseja as opções “noauth” e “defaultroute” e se quer remover “nodetach” - escolha Sim.

    6. Use peer DNS - choose Yes.

    7. Limited MSS problem - choose Yes.

    8. When you are asked if you want to connect at start up, you will probably want to say yes.

    9. Finally you are asked if you want to establish the connection immediately.

  4. Once you have finished these steps, your connection should be working.

To start your ADSL connection on demand, in a terminal type:

sudo pon dsl-provider

Para parar a sua ligação ADSL, escreva num terminal:

sudo poff dsl-provider

Modems ADSL USB

Often parts of ADSL USB modem drivers are proprietary, closed source software, with a restrictive licence, and so the whole driver cannot be supplied with Xubuntu. To get a modem to work with these drivers, you will need to download files from Internet with a computer having a working connection, then transfer the downloaded files to you Xubuntu installation.

[Atenção]

USB is far from the ideal medium for network access. If you have a modem that can connect both via USB and ethernet, or an ethernet router, you should use the ethernet connection instead of the USB modem.

Since any USB modem installation will require Internet access to download the necessary proprietary drivers, as well as extensive configuration which is beyond the scope of this guide, all we can do here is to list the USB Modem models known to work with Xubuntu with links to the relevant installation instructions on the Xubuntu community help site.

The installation procedure of USB modems differs depending on the specific make and model of your modem. To identify model of your modem, note the name and number on the front. Occasionaly you may have to look for a label to discover the exact model. Consult the list below to see which driver your modem requires and note the link.

When you go online to download the necessary drivers, you can access the relevant driver download links from the page with the installation instructions relevant to that model of USB modem.

Modems Dialup

Most dialup modems are not supported by Xubuntu, but drivers can be found that will enable the use of such modems. You need a working internet connection to proceed. First you need to identify what chipset your dialup modem is using. Open ApplicationsAccessoriesTerminal and type:

wget -c http://linmodems.technion.ac.il/packages/scanModem.gz 
gunzip -c scanModem.gz > scanModem 
chmod +x scanModem
sudo ./scanModem 

Read carefully instructions on the screen and follow them if necessary. Once the script obtains the relevant information, type:

mousepad Modem/ModemData.txt

Leia este ficheiro, deverá listar o tipo de chipset do modem que você tem. Assim que conhecer o chipset, veja http://www.linmodems.org/ e siga as direcções para o seu modem. Mais informação pode ser encontrada em Configurar Modems no Wiki Ubuntu.

Network Manager provides graphical tools to configure a modem connection.

[Importante]

Irá precisar de saber a seguinte informação:

ISP Phone Number; Username; Password.

  1. Open Network Manager(ApplicationsSystemNetwork)

  2. Select Modem Connection

  3. Choose Properties and fill out the fields.

  4. Clique em OK

Tools to help with network connection problems

If you have a network connection which is not working properly, you can use a few tools to help diagnose what the problem is.

Most of the tools in this section require use of the Terminal, which you can open by pressing ApplicationsAccessoriesTerminal.

Identifique as ligações sem fios

iwconfig allows you to change certain settings of your wireless hardware. However, it is also very useful for identifying wireless connections.

Para identificar uma ligação sem fios.

  1. Press ApplicationsAccessoriesTerminal to open a Terminal

  2. Type iwconfig in the Terminal and press Return

  3. Deverá ter como resultado algo semelhante a:

    lo        no wireless extensions.
    
    eth0      no wireless extensions.
    
    eth1      IEEE 802.11g  ESSID:"WLAN Name"  
            Mode:Managed  Frequency:2.432 GHz  Access Point: 00:12:CF:02:6F:EC   
            Bit Rate:54 Mb/s   Tx-Power=20 dBm   Sensitivity=8/0  
            Retry limit:7   RTS thr:off   Fragment thr:off
            Power Management:off
            Link Quality=75/100  Signal level=-54 dBm  Noise level=-89 dBm
            Rx invalid nwid:0  Rx invalid crypt:0  Rx invalid frag:0
            Tx excessive retries:0  Invalid misc:0   Missed beacon:1
  4. The column on the left gives the name of the connection, such as “eth0” or “wlan0

  5. If the column on the right says “no wireless extensions”, that connection has not been recognized as a wireless connection and is probably a wired network connection

  6. If the connection has been recognized as a wireless connection, details of the wireless connection will be shown in the column on the right

    • ESSID mostra o nome da rede sem fios a que está ligado, caso exista uma

    • Link Quality gives a measure of the strength of the wireless signal

Find information about wireless connections

iwlist is able to display information about your wireless connection.

  1. Press ApplicationsAccessoriesTerminal to open a Terminal

  2. Type the following commands in the Terminal and press Return to run them. Make sure that you replace eth1 with the name of your wireless interface, if it is different.

    • iwlist eth1 accesspoints - Show a list of available wireless access points

    • iwlist eth1 rate - Show a list of all possible transmission rates for your wireless connection, including the current rate

    • iwlist eth1 key - Show information about wireless encryption

Obter informação sobre a ligação actual

ifconfig is intended to allow you to change the settings of your network connections, but can also be used to list information about the current connection.

  1. Press ApplicationsAccessoriesTerminal to open a Terminal

  2. Type ifconfig eth1 in the Terminal and press Return, replacing eth1 with the name of your network interface if it is different.

    • O inet addr mostra o endereço IP actual da ligação

    • HWaddr gives the MAC address of your network device

Verifique se a ligação está a funcionar correctamente

A good way of checking if a connection is working correctly is to ping another computer on the network or the Internet.

To check if you are connected to the Internet press ApplicationsAccessoriesTerminal and type:

ping -c 8 xubuntu.com

After a while, xubuntu.com ping statistics should appear. Look at the % packet loss.

  • 0% packet loss - Your computer should have a good connection to the Internet

  • More than 0% packet loss - Your computer probably has a poor connection to the Internet or a poor wireless signal

  • 100% packet loss - Your connection is set improperly, or your computer is connected to an access point or router which is not connected to the Internet

If you get an error message which says ping: unknown host 'xubuntu.com' , then your computer is probably not connected to the Internet or cannot reach a DNS server.