Auteur Sujet: Ubuntu server : Pas de communication entre le WLAN et LAN  (Lu 10858 fois)

0 Membres et 1 Invité sur ce sujet

jewome62

  • Abonné Bbox fibre
  • *
  • Messages: 247
  • Maureillas-las-Illas
    • Mon site web personnel
Pas de communication entre le WLAN et LAN
« Réponse #12 le: 10 décembre 2013 à 19:00:19 »
AP, c'est une carte mini pci express dans le pc avec hostapd

Euh je mets ça ou ???
#Reseau Filiaire
auto eth1
iface eth1 inet manual

#Reseau Wifi
auto wlan0
iface wlan0 inet manual

#Reseau local global
auto lan
iface lan inet static
        address 192.168.0.1
        netmask 255.255.255.0
        network 192.168.0.0
        broadcast 192.168.0.255
        post-up iptables-restore < /etc/iptables.rules
        post-up hostapd /etc/hostapd/hostapd.conf
        post-up upnpd eth0 lan
        pre-down iptables-save > /etc/iptables.rules
        pre-down killall upnpd
        pre-down killall hostapd
        bridge-ports wlan0 eth1

kgersen

  • Modérateur
  • Abonné Bbox fibre
  • *
  • Messages: 9 078
  • Paris (75)
Pas de communication entre le WLAN et LAN
« Réponse #13 le: 10 décembre 2013 à 19:07:50 »
tu vires la derniere ligne deja (bridge-ports wlan0 eth1).
et met ces lignes entre le "broadcast 192.168.0.255" et le 1er "post-up.."

mais t'as pas répondu pour le point d'acces wifi ? si il y'a un point d'acces Wifi qui sert entre le routeur et le Pc portable ca ne marchera probablement pas.
Il faut configurer la carte wifi (wlan0) en mode "hotspot".

jewome62

  • Abonné Bbox fibre
  • *
  • Messages: 247
  • Maureillas-las-Illas
    • Mon site web personnel
Pas de communication entre le WLAN et LAN
« Réponse #14 le: 10 décembre 2013 à 19:11:54 »
Voici les quelques première lignes de hostapd.conf
##### hostapd configuration file ##############################################
# Empty lines and lines starting with # are ignored

# AP netdevice name (without 'ap' postfix, i.e., wlan0 uses wlan0ap for
# management frames); ath0 for madwifi
interface=wlan0

# In case of madwifi, atheros, and nl80211 driver interfaces, an additional
# configuration parameter, bridge, may be used to notify hostapd if the
# interface is included in a bridge. This parameter is not used with Host AP
# driver. If the bridge parameter is not set, the drivers will automatically
# figure out the bridge interface (assuming sysfs is enabled and mounted to
# /sys) and this parameter may not be needed.
#
# For nl80211, this parameter can be used to request the AP interface to be
# added to the bridge automatically (brctl may refuse to do this before hostapd
# has been started to change the interface mode). If needed, the bridge
# interface is also created.
bridge=lan

# Driver interface type (hostap/wired/madwifi/test/none/nl80211/bsd);
# default: hostap). nl80211 is used with all Linux mac80211 drivers.
# Use driver=none if building hostapd as a standalone RADIUS server that does
# not control any wireless/wired driver.
driver=nl80211

kgersen

  • Modérateur
  • Abonné Bbox fibre
  • *
  • Messages: 9 078
  • Paris (75)
Pas de communication entre le WLAN et LAN
« Réponse #15 le: 10 décembre 2013 à 21:45:28 »
est-ce un ubuntu server ou desktop ? est-ce que le 'network manager' tourne ( "sudo service network-manager status" ca affiche quoi?) ?

"sudo iw list" ca affiche quoi ? (notamment la section "Supported interface modes").

"sudo iwconfig" ca affiche quoi ?

ca se met dans le bridge via le hostapd.conf aussi donc y'a une double configuration redondante la...
elle sort d'ou ta config a l'origine ? fait maison ou copier de quelque part ?

Au pire essais d'enlever wlan0 du bridge (donc "bridge-ports eth1" seulement ou "pre-up brctl addif lan eth1" si version brctl).
le service hotspot (hostapd) va mettre lui meme l'interface wlan0 dans le bridge quand il va demarrer vu que c'est dans hostapd.conf

jewome62

  • Abonné Bbox fibre
  • *
  • Messages: 247
  • Maureillas-las-Illas
    • Mon site web personnel
Pas de communication entre le WLAN et LAN
« Réponse #16 le: 10 décembre 2013 à 22:10:09 »
Ok,

C'est une config perso avec un mélange de tout ce que j'ai trouvé.
C'est un ubuntu server donc pas de network manager

jewome62@homeServer:~$ sudo iwconfig
[sudo] password for jewome62:
mon.wlan0  IEEE 802.11bgn  Mode:Monitor  Tx-Power=16 dBm
          Retry  long limit:7   RTS thr:off   Fragment thr:off
          Power Management:off

eth0      no wireless extensions.

eth1      no wireless extensions.

lan       no wireless extensions.

lo        no wireless extensions.

wlan0     IEEE 802.11bgn  Mode:Master  Tx-Power=16 dBm
          Retry  long limit:7   RTS thr:off   Fragment thr:off
          Power Management:off

jewome62@homeServer:~$ sudo iw list
Wiphy phy0
        Band 1:
                Capabilities: 0x1072
                        HT20/HT40
                        Static SM Power Save
                        RX Greenfield
                        RX HT20 SGI
                        RX HT40 SGI
                        No RX STBC
                        Max AMSDU length: 3839 bytes
                        DSSS/CCK HT40
                Maximum RX AMPDU length 65535 bytes (exponent: 0x003)
                Minimum RX AMPDU time spacing: 4 usec (0x05)
                HT TX/RX MCS rate indexes supported: 0-15, 32
                Frequencies:
                        * 2412 MHz [1] (16.0 dBm)
                        * 2417 MHz [2] (16.0 dBm)
                        * 2422 MHz [3] (16.0 dBm)
                        * 2427 MHz [4] (16.0 dBm)
                        * 2432 MHz [5] (16.0 dBm)
                        * 2437 MHz [6] (16.0 dBm)
                        * 2442 MHz [7] (16.0 dBm)
                        * 2447 MHz [8] (16.0 dBm)
                        * 2452 MHz [9] (16.0 dBm)
                        * 2457 MHz [10] (16.0 dBm)
                        * 2462 MHz [11] (16.0 dBm)
                        * 2467 MHz [12] (16.0 dBm) (passive scanning, no IBSS)
                        * 2472 MHz [13] (16.0 dBm) (passive scanning, no IBSS)
                Bitrates (non-HT):
                        * 1.0 Mbps
                        * 2.0 Mbps (short preamble supported)
                        * 5.5 Mbps (short preamble supported)
                        * 11.0 Mbps (short preamble supported)
                        * 6.0 Mbps
                        * 9.0 Mbps
                        * 12.0 Mbps
                        * 18.0 Mbps
                        * 24.0 Mbps
                        * 36.0 Mbps
                        * 48.0 Mbps
                        * 54.0 Mbps
        max # scan SSIDs: 20
        max scan IEs length: 195 bytes
        Coverage class: 0 (up to 0m)
        Supported Ciphers:
                * WEP40 (00-0f-ac:1)
                * WEP104 (00-0f-ac:5)
                * TKIP (00-0f-ac:2)
                * CCMP (00-0f-ac:4)
        Available Antennas: TX 0 RX 0
        Supported interface modes:
                 * IBSS
                 * managed
                 * AP
                 * AP/VLAN
                 * monitor
        software interface modes (can always be added):
                 * AP/VLAN
                 * monitor
        valid interface combinations:
                 * #{ managed } <= 1, #{ AP } <= 1,
                   total <= 2, #channels <= 1, STA/AP BI must match
                 * #{ managed } <= 2,
                   total <= 2, #channels <= 1
        Supported commands:
                 * new_interface
                 * set_interface
                 * new_key
                 * new_beacon
                 * new_station
                 * new_mpath
                 * set_mesh_params
                 * set_bss
                 * authenticate
                 * associate
                 * deauthenticate
                 * disassociate
                 * join_ibss
                 * join_mesh
                 * remain_on_channel
                 * set_tx_bitrate_mask
                 * action
                 * frame_wait_cancel
                 * set_wiphy_netns
                 * set_channel
                 * set_wds_peer
                 * Unknown command (84)
                 * Unknown command (87)
                 * Unknown command (85)
                 * Unknown command (89)
                 * Unknown command (92)
                 * testmode
                 * connect
                 * disconnect
        Supported TX frame types:
                 * IBSS: 0x00 0x10 0x20 0x30 0x40 0x50 0x60 0x70 0x80 0x90 0xa0 0xb0 0xc0 0xd0 0xe0 0xf0
                 * managed: 0x00 0x10 0x20 0x30 0x40 0x50 0x60 0x70 0x80 0x90 0xa0 0xb0 0xc0 0xd0 0xe0 0xf0
                 * AP: 0x00 0x10 0x20 0x30 0x40 0x50 0x60 0x70 0x80 0x90 0xa0 0xb0 0xc0 0xd0 0xe0 0xf0
                 * AP/VLAN: 0x00 0x10 0x20 0x30 0x40 0x50 0x60 0x70 0x80 0x90 0xa0 0xb0 0xc0 0xd0 0xe0 0xf0
                 * mesh point: 0x00 0x10 0x20 0x30 0x40 0x50 0x60 0x70 0x80 0x90 0xa0 0xb0 0xc0 0xd0 0xe0 0xf0
                 * P2P-client: 0x00 0x10 0x20 0x30 0x40 0x50 0x60 0x70 0x80 0x90 0xa0 0xb0 0xc0 0xd0 0xe0 0xf0
                 * P2P-GO: 0x00 0x10 0x20 0x30 0x40 0x50 0x60 0x70 0x80 0x90 0xa0 0xb0 0xc0 0xd0 0xe0 0xf0
                 * Unknown mode (10): 0x00 0x10 0x20 0x30 0x40 0x50 0x60 0x70 0x80 0x90 0xa0 0xb0 0xc0 0xd0 0xe0 0xf0
        Supported RX frame types:
                 * IBSS: 0x40 0xb0 0xc0 0xd0
                 * managed: 0x40 0xd0
                 * AP: 0x00 0x20 0x40 0xa0 0xb0 0xc0 0xd0
                 * AP/VLAN: 0x00 0x20 0x40 0xa0 0xb0 0xc0 0xd0
                 * mesh point: 0xb0 0xc0 0xd0
                 * P2P-client: 0x40 0xd0
                 * P2P-GO: 0x00 0x20 0x40 0xa0 0xb0 0xc0 0xd0
                 * Unknown mode (10): 0x40 0xd0
        Device supports RSN-IBSS.
        WoWLAN support:
                 * wake up on disconnect
                 * wake up on magic packet
                 * wake up on pattern match, up to 20 patterns of 16-128 bytes
                 * can do GTK rekeying
                 * wake up on GTK rekey failure
                 * wake up on EAP identity request
                 * wake up on rfkill release
        HT Capability overrides:
                 * MCS: ff ff ff ff ff ff ff ff ff ff
                 * maximum A-MSDU length
                 * supported channel width
                 * short GI for 40 MHz
                 * max A-MPDU length exponent
                 * min MPDU start spacing
        Device supports TX status socket option.
        Device supports HT-IBSS.


kgersen

  • Modérateur
  • Abonné Bbox fibre
  • *
  • Messages: 9 078
  • Paris (75)
Pas de communication entre le WLAN et LAN
« Réponse #17 le: 10 décembre 2013 à 23:08:13 »
mouais curieux. je vois pas ou ca coince.

On peut recheck les trucs de base au cas ou:
Le routing est-il bien activé sur le routeur ? ("sudo su" puis "cat /proc/sys/net/ipv4/ip_forward" devrait afficher 1).
La commande "route" affiche quoi ?
Regardes si avec le firewall coupé ca marche ou pas: "sudo ufw disable" pour le couper, "sudo ufw enable" pour le remettre (attention a pas le laisser couper)
"sudo iptables -L -n -v" ca affiche quoi quand le firewall marche.

J'espere que c'est pas un probleme juste entre les 2 PCs (genre ils sont protégés et repondent pas au ping ou a ce que tu cherches à faire entre eux). Par acquis de conscience verif ca quand meme avant de poursuivre ...as tu essayé entre 2 trucs en wifi? ou le PC fixe et un autre appareil en wifi ?

sinon:

faudrait regarder aux niveaux des adresses MAC. faire du trafic depuis le PC fixe. faire du trafic depuis le PC portable. tenter un ping entre eux 2.

puis sur le routeur:

sudo brctl showmacs lan

et "arp -a" sur chaque poste. Comparer les @ IP et les @ MAC.


jewome62

  • Abonné Bbox fibre
  • *
  • Messages: 247
  • Maureillas-las-Illas
    • Mon site web personnel
Pas de communication entre le WLAN et LAN
« Réponse #18 le: 10 décembre 2013 à 23:33:41 »
euh attrend hein :D

ou les route sont bien activé, et j'arrive à pinguer les machine quand les deux machine sont en lan ou wlan

Je n'ai pas encore appliqué tes solution, je n'ai fais que donner reponse a tes question. je testerai demain soir quand le réseau sera "libre" :D

jewome62

  • Abonné Bbox fibre
  • *
  • Messages: 247
  • Maureillas-las-Illas
    • Mon site web personnel
Ubuntu server : Pas de communication entre le WLAN et LAN
« Réponse #19 le: 27 janvier 2014 à 00:12:30 »
Je me remet sur le sujet, j'en ai marre de ne pas pouvoir imprimer sur l'imprimante wifi avec mon pc connecté en ethernet

jewome62@homeServer:~$ sudo iptables -L -n -v
Chain INPUT (policy DROP 461K packets, 625M bytes)
 pkts bytes target     prot opt in     out     source               destination
30442 6684K fail2ban-ssh  tcp  --  *      *       0.0.0.0/0            0.0.0.0/0            multiport dports 22
 501K 1156M ACCEPT     all  --  lo     *       0.0.0.0/0            0.0.0.0/0
 291M   39G ACCEPT     all  --  eth0   *       0.0.0.0/0            0.0.0.0/0            state RELATED,ESTABLISHED
 111M   14G ACCEPT     all  --  lan    *       0.0.0.0/0            0.0.0.0/0
  371 20036 ACCEPT     tcp  --  *      *       0.0.0.0/0            0.0.0.0/0            tcp dpt:22 state NEW,ESTABLISHED
45842 1467K ACCEPT     2    --  *      *       0.0.0.0/0            0.0.0.0/0
 3054  277K ACCEPT     icmp --  *      *       0.0.0.0/0            0.0.0.0/0
 1188 63312 ACCEPT     tcp  --  *      *       0.0.0.0/0            0.0.0.0/0            tcp dpt:80
 210K   11M ACCEPT     tcp  --  *      *       0.0.0.0/0            0.0.0.0/0            tcp dpt:6881
 148K 9754K ACCEPT     udp  --  *      *       0.0.0.0/0            0.0.0.0/0            udp dpt:6881
   47  2796 ACCEPT     tcp  --  *      *       0.0.0.0/0            0.0.0.0/0            tcp dpt:4040
 1570 79543 ACCEPT     tcp  --  *      *       0.0.0.0/0            0.0.0.0/0            tcp dpt:4141

Chain FORWARD (policy DROP 592 packets, 282K bytes)
 pkts bytes target     prot opt in     out     source               destination
    0     0 ACCEPT     tcp  --  *      *       0.0.0.0/0            10.54.159.71         tcp dpt:63819
    0     0 ACCEPT     udp  --  *      *       0.0.0.0/0            10.54.159.71         udp dpt:63819
    3   411 ACCEPT     udp  --  *      *       0.0.0.0/0            192.168.0.43         udp dpt:3074
   43  5891 ACCEPT     udp  --  *      *       0.0.0.0/0            192.168.0.52         udp dpt:50768
6675K 2352M ACCEPT     all  --  lan    eth0    0.0.0.0/0            0.0.0.0/0
 128M  182G ACCEPT     all  --  eth0   lan     0.0.0.0/0            0.0.0.0/0
jewome62@homeServer:~$ sudo brctl showmacs lan
port no mac addr                is local?       ageing timer
  1     00:25:9c:6d:bc:7d       no                 0.76
  1     08:9e:01:b4:1e:81       no                 0.01
  2     30:10:e4:1d:b0:42       no                 2.06
  1     30:7e:cb:f6:f9:f0       no                 0.37
  2     5c:f8:a1:df:b6:9a       no                 0.05
  1     64:66:b3:ce:11:00       no                 6.06
  1     7c:2f:80:04:58:98       no                 0.87
  2     84:a6:c8:08:33:88       yes                0.00
  1     90:2b:34:5d:f0:bf       yes                0.00
  2     c4:17:fe:94:1b:be       no                 9.02
  1     e0:a1:d7:c6:0e:10       no                 1.39



Je ne peux pas faire de arp sur une imprimante Wifi

Mais globalement, le problème existe aussi avec mon iPhone, je joins l'imprimante mais pas le pc fixe

PC Fixe : 192.168.0.50 08:9e:01:b4:1e:81
Iphone : 192.168.0.31  31:10:e4:1d:b0:42
Imprimante : 192.168.0.24 c4:17:fe:94:1b:be

je vais faire une capture réseau du pc en le pinguant depuis l'iphone

edit :
la seul ligne intéressante c'est


Un wireshark depuis le routeur : filtre sur le pc 192.168.0.50 : http://home.jerome-desjardins.fr/lan3.pcapng
« Modifié: 27 janvier 2014 à 00:35:09 par jewome62 »

jewome62

  • Abonné Bbox fibre
  • *
  • Messages: 247
  • Maureillas-las-Illas
    • Mon site web personnel
Ubuntu server : Pas de communication entre le WLAN et LAN
« Réponse #20 le: 02 février 2014 à 00:28:14 »
Apparemment, ce problème peut etre réglé avec ebtables
mais il faut inscrire une règle par client wifi ?

https://wiki.debian.org/BridgeNetworkConnections#Bridging_with_a_wireless_NIC

Une solution ?
comment font les autres ??

corrector

  • Invité
Ubuntu server : Pas de communication entre le WLAN et LAN
« Réponse #21 le: 04 février 2014 à 22:31:34 »
Tu veux "bridger" un STA avec une carte Ethernet?

jewome62

  • Abonné Bbox fibre
  • *
  • Messages: 247
  • Maureillas-las-Illas
    • Mon site web personnel
Ubuntu server : Pas de communication entre le WLAN et LAN
« Réponse #22 le: 04 février 2014 à 23:41:05 »
STA ???

corrector

  • Invité
Ubuntu server : Pas de communication entre le WLAN et LAN
« Réponse #23 le: 05 février 2014 à 00:50:20 »
Un client Wifi, quoi. Le contraire de AP.