reseau en panne?

J Bond 0.07 jojonuxdelux at gmail.com
Sam 23 Fév 08:49:56 UTC 2008


c.kumsta wrote:
> Perso, pour entrer des IP en fixe, je le fais directement dans le fichier "/etc/network/interfaces"
> Par exemple, dans ton cas :
> ========================================
> auto lo
> iface lo inet loopback
> 
> auto eth0
> iface eth0 inet static
>   address 192.168.0.4
>   netmask 255.255.255.0
> 
> auto eth2
> iface eth1 inet static
>   address 192.168.88.1
>   netmask 255.255.255.0
> ========================================

Mon fichier interfaces :
This file describes the network interfaces available on your system
# and how to activate them. For more information, see interfaces(5).

# The loopback network interface
auto lo eth2
iface lo inet loopback

# This is a list of hotpluggable network interfaces.
# They will be activated automatically by the hotplug subsystem.
mapping hotplug
         script grep
         map eth2

# The primary network interface

iface eth2 inet static
address 192.168.88.1
netmask 255.255.255.0
gateway 192.168.1.4




auto dsl-provider
iface dsl-provider inet ppp
pre-up /sbin/ifconfig eth2 up # line maintained by pppoeconf
provider dsl-provider

auto eth0:avah
iface eth0:avah inet manual

#auto eth1


#auto eth0


#auto eth2


#auto eth2

iface eth1 inet static
address 192.168.1.4
netmask 255.255.255.0
gateway 192.168.1.1

auto eth1

iface eth0 inet static
address 192.168.1.4
netmask 255.255.255.0
gateway 192.168.0.50

auto eth0
> 
> (à mon avis, ce n'est pas la peine de rajouter de champs "gateway" étant donné que c'est ta connexion vers ton FAI
> qui va le régler au moment de la négociation avec ton FAI sur ppp0)
> 
> ++dune2
> 
> Jmb at moustique:~$ sudo ifconfig
eth0      Lien encap:Ethernet  HWaddr 00:13:8F:7A:C6:DD
           inet adr:192.168.1.4  Bcast:192.168.1.255  Masque:255.255.255.0
           UP BROADCAST MULTICAST  MTU:1500  Metric:1
           Packets reçus:0 erreurs:0 :0 overruns:0 frame:0
           TX packets:0 errors:0 dropped:0 overruns:0 carrier:0
           collisions:0 lg file transmission:1000
           Octets reçus:0 (0.0 b) Octets transmis:0 (0.0 b)
           Interruption:16 Adresse de base:0xc000

eth1      Lien encap:Ethernet  HWaddr 00:18:E7:07:F9:F4
           inet adr:192.168.1.4  Bcast:192.168.1.255  Masque:255.255.255.0
           adr inet6: fe80::218:e7ff:fe07:f9f4/64 Scope:Lien
           UP BROADCAST RUNNING MULTICAST  MTU:1500  Metric:1
           Packets reçus:45 erreurs:0 :0 overruns:0 frame:0
           TX packets:7 errors:0 dropped:0 overruns:0 carrier:0
           collisions:0 lg file transmission:1000
           Octets reçus:11692 (11.4 KB) Octets transmis:528 (528.0 b)
           Interruption:19 Adresse de base:0x2800

eth2      Lien encap:Ethernet  HWaddr 00:10:A7:0C:8B:55
           inet adr:192.168.88.1  Bcast:192.168.88.255  Masque:255.255.255.0
           adr inet6: fe80::210:a7ff:fe0c:8b55/64 Scope:Lien
           UP BROADCAST RUNNING MULTICAST  MTU:1500  Metric:1
           Packets reçus:4653 erreurs:0 :0 overruns:0 frame:0
           TX packets:4201 errors:0 dropped:0 overruns:0 carrier:0
           collisions:0 lg file transmission:1000
           Octets reçus:3285428 (3.1 MB) Octets transmis:465510 (454.5 KB)
           Interruption:20 Adresse de base:0xec00

lo        Lien encap:Boucle locale
           inet adr:127.0.0.1  Masque:255.0.0.0
           adr inet6: ::1/128 Scope:Hôte
           UP LOOPBACK RUNNING  MTU:16436  Metric:1
           Packets reçus:408 erreurs:0 :0 overruns:0 frame:0
           TX packets:408 errors:0 dropped:0 overruns:0 carrier:0
           collisions:0 lg file transmission:0
           Octets reçus:33437 (32.6 KB) Octets transmis:33437 (32.6 KB)

ppp0      Lien encap:Protocole Point-à-Point
           inet adr:194.206.79.171  P-t-P:195.146.243.10 
Masque:255.255.255.255
           UP POINTOPOINT RUNNING NOARP MULTICAST  MTU:1492  Metric:1
           Packets reçus:4345 erreurs:0 :0 overruns:0 frame:0
           TX packets:3825 errors:0 dropped:0 overruns:0 carrier:0
           collisions:0 lg file transmission:3
           Octets reçus:3171290 (3.0 MB) Octets transmis:357454 (349.0 KB)

mb at moustique:~$

ufconfig est bon, maintenant!
mb at moustique:~$ sudo route
Table de routage IP du noyau
Destination     Passerelle      Genmask         Indic Metric Ref    Use 
Iface
lns2.l0.10.143. *               255.255.255.255 UH    0      0        0 ppp0
192.168.1.0     *               255.255.255.0   U     0      0        0 eth0
192.168.1.0     *               255.255.255.0   U     0      0        0 eth1
192.168.88.0    *               255.255.255.0   U     0      0        0 eth2
link-local      *               255.255.0.0     U     1000   0        0 eth1
default         *               0.0.0.0         U     0      0        0 ppp0
mb at moustique:~$

ça devrait marcher et ça marche pas : les ping sont perdus.

Je regarde maintenant du coté des hosts et hosts.allow! :

hosts:
127.0.0.1 localhost
#
# The following lines are desirable for IPv6 capable hosts
::1 ip6-localhost ip6-loopback
fe00::0 ip6-localnet
ff00::0 ip6-mcastprefix
ff02::1 ip6-allnodes
ff02::2 ip6-allrouters
ff02::3 ip6-allhosts
192.168.88.3 violette
192.168.1.1 modem
192.168.0.50 dlink
192.168.88.5 lombric
192.168.1.4 crapaud.chikungugna.org

hosts.allow :
  /etc/hosts.allow: list of hosts that are allowed to access the system.
#                   See the manual pages hosts_access(5) and 
hosts_options(5).
#
# Example:    ALL: LOCAL @some_netgroup
#             ALL: .foobar.edu EXCEPT terminalserver.foobar.edu
#
# If you're going to protect the portmapper use the name "portmap" for the
# daemon name. Remember that you can only use the keyword "ALL" and IP
# addresses (NOT host or domain names) for the portmapper, as well as for
# rpc.mountd (the NFS mount daemon). See portmap(8) and rpc.mountd(8)
# for further information.
#
192.168.88.3	violette
192.168.88.5	lombric
192.168.1.1	modem
192.168.0.50	dlink
ALL: LOCAL @chikungugna.org
192.168.1.4	crapaud.chikungugna.org

Où est l'erreur? : ça devient compliqué, et le tuto n'est peut etre pas 
trop clair..





Plus d'informations sur la liste de diffusion ubuntu-fr