Jump to content

Recommended Posts

Posted

Hi every body,

 

Tanks igor for your great job with your linux versions for cubietruck.

I installed jessie with kernel 3.4.

 

I'm trying to make a media server with minidlna. Cubietruck is connected to the router with ethernet when i'm at home and minidlna stream fine.

 

I sucessfully installed hostapd with your interfaces.hostapd file.

Ethernet plugged, i can connect to wlan0 and access to minidlna.

 

My problem is when ethernet is unplugged and i reboot the cubietruck. I cannot access to minidlna via wlan0.

 

I set network_interface=br0 in minidlna configuration.

 

Do i need to manually configure dhcp or something like that?

Posted

I don't know if it can help you.

on my Rpi2 jessie and kernel 4.1, waiting upto 2 minutes after booting, the Rpi joins my wlan host => so I can access the Rpi as if it was on the LAN excepted it is on the WLAN.

gr@pi ~ $ cat /etc/network/interfaces
auto lo
iface lo inet loopback

auto br0
iface br0 inet dhcp
        bridge_ports eth0 wlan0

allow-hotplug eth0
iface eth0 inet manual

allow-hotplug wlan0
iface wlan0 inet manual
        wpa-conf /etc/wpa_supplicant/wpa_supplicant.conf

wpa_supplicant.conf => contains the SSID and password

 

note:

 

br0 get the MAC address of the eth0 (probably because it is declared first in the bridge)

wlan0 has a separate MAC

 

I have added in the dhcpd.conf

- the eth0 MAC address to get an "fixed" IP address if I connect ethernet

- the wlan0 MAC address to get a "fixed" IP address if ethernet is not connected

Posted

Thanks for your answer.

 

I'm not sure to understand. I think adding this to dhcpd.conf:

- the eth0 MAC address to get an "fixed" IP address if I connect ethernet

- the wlan0 MAC address to get a "fixed" IP address if ethernet is not connected

Will only give the same ip address to my cubietruck if it's connected to the router through eth0 or wlan0.

 

What i want to do is to stream movies, with minidlna, throught ethernet when this one is plugged to my router while i'm at home.

 

When i'm not at home, i want my cubie turning to a hotspot and stream through wlan0, with my tablet directly connected on wlan0.

 

That´s why i think, br0 can allow me to connect to minidlna in anyway through eth0 or wlan0 but it's not.

 

I Know what i want to do but i'm not sure about the way

Posted (edited)

you are welcome. I didn't get the "host" part, my bad :rolleyes: we are not native english speakers.

 

my first (wrong answer):

 

so you need to change the config of your wlan interface : guest (home) or host (outside)

 

ok, in my configuration both ethernet and wifi of my Rpi2 are "guest" for my home "router" Armbian for lamobo-r1

so I can connect either ethernet and/or wifi to access my local network.

=> keep this.

 

You need also a wlan host AP daemon (hotspot) for "outdoor" use to broadcast your files.

 

1/

so by default (outside), you need to config and launch hostapd service (so you can connect to the cubie) also you need to "comment" the  line "wpa-conf /etc/wpa_supplicant/wpa_supplicant.conf" in /etc/network/interface

 

2/

when you are back home connected with ethernet Lan, stop hostapd service and uncomment the "wpa-conf /etc/wpa_supplicant/wpa_supplicant.conf" and sudo ifdown wlan0;sudo ifup wlan0

 

you need:

A/

a config for wlan guest @home (depends on your home router)

B/

a config for wlan host @outside

 

 

 

more appropriate answer:

 

so you need to have your wlan interface as a host (outside)

 

1/

so by default @bootup, you need to config and launch hostapd service (so you can connect to the cubie) => depending on your hardware you need to build a proper /etc/hostapd.conf file

 

you can use

gr@pi ~ $ cat /etc/network/interfaces
auto lo
iface lo inet loopback

auto br0
iface br0 inet dhcp
        bridge_ports eth0 wlan0

allow-hotplug eth0
iface eth0 inet manual

allow-hotplug wlan0
iface wlan0 inet manual

2/

when you are back home connected with ethernet Lan, stop hostapd service if not needed

 

you need:

a config for wlan host @outside => /etc/hostapd.conf

 

see http://forum.armbian.com/index.php/topic/567-issue-with-hostapd-rt/

 

is this correct?

Edited by wildcat_paris
Guest
This topic is now closed to further replies.
×
×
  • Create New...

Important Information

Terms of Use - Privacy Policy - Guidelines