LinuxQuestions.org
Share your knowledge at the LQ Wiki.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Software
User Name
Password
Linux - Software This forum is for Software issues.
Having a problem installing a new program? Want to know which application is best for the job? Post your question in this forum.

Notices


Closed Thread
  Search this Thread
Old 10-04-2014, 02:31 AM   #1
TeaYoung
LQ Newbie
 
Registered: Apr 2013
Posts: 26

Rep: Reputation: Disabled
How do you bridge the eth0 (ethernet) and eth1 (WiFi_Ap)?


Hello.

I am in the WiFi test embedded board.

The ethernet port eth0 is connected to the Internet.

The interface eth1 is caused due to the WiFi chip.

The Access Point can be used as a WiFi eth1 is.

We use the following instructions to Acess Point with WiFi on eth1 is.

# ifconfig eth1 192.168.10.1 up
# dnsmasq
# iwpriv eth1 AP_SET_CFG ASCII_CMD=AP_CFG,SSID="WiFi_Test",SEC="wpa2-psk",KEY=ac10b3e2e8b13e67841b01e2eb07bd95da516fdac049d486112997bf16afb24b,CHANNEL=11,PREAMBLE=0,MAX_ SCB=8,END
# iwpriv eth1 AP_BSS_START

also has access to a WiFi Access Point in Mobile when used with the eth1.

But this was a closed network eth1 and Mobile Bay.

What I want eth0 and eth1 are connected to each other must also be connected to the Acess Point Mobile is another place to use ping.

I can use the Ping to 192.168.1.1 eth0.

But I can not use Ping to 192.168.1.1 Mobile In.

I can not use the brctl command.

I must be the only bridge to eth0 and eth1 using only iptables command.


1. If I bridge the eth1 eth0 and the dnsmasq command should I run?
( I think you are thinking of eth0 dhcp also not necessary because the bridge.)

2.How should I use to bridge the eth0 and eth1 (WiFi Access Point) the iptables command?
(I did not work looked like using the command below.)

# echo 1 > /proc/sys/net/ipv4/ip_forward
# iptables -t nat -A POSTROUTING -o eth1 -j MASQUERADE
# iptables -A FORWARD -i eth1 -o eth0 -j ACCEPT
# iptables -A FORWARD -i eth0 -o eth1 -m state --state ESTABLISHED,RELATED -j ACCEPT

3. If that bridge is normally eth0 and eth1 eth1 geotingayo also be automatically assigned an IP doeneunge fit?


Below is my ifconfig results.


root@test:~# ifconfig
eth0 Link encap:Ethernet HWaddr 00:00:00:00:00:00
inet addr:192.168.0.88 Bcast:192.168.255.255 Mask:255.255.0.0
UP BROADCAST MULTICAST MTU:1500 Metric:1
RX packets:0 errors:0 dropped:0 overruns:0 frame:0
TX packets:0 errors:0 dropped:0 overruns:0 carrier:0
collisions:0 txqueuelen:1000
RX bytes:0 (0.0 b) TX bytes:0 (0.0 b)
Interrupt:170

eth1 Link encap:Ethernet HWaddr C4:23:7A:00:6E:93
UP BROADCAST MULTICAST MTU:1500 Metric:1
RX packets:0 errors:0 dropped:0 overruns:0 frame:0
TX packets:0 errors:0 dropped:0 overruns:0 carrier:0
collisions:0 txqueuelen:1000
RX bytes:0 (0.0 b) TX bytes:0 (0.0 b)

lo Link encap:Local Loopback
inet addr:127.0.0.1 Mask:255.0.0.0
UP LOOPBACK RUNNING MTU:65536 Metric:1
RX packets:0 errors:0 dropped:0 overruns:0 frame:0
TX packets:0 errors:0 dropped:0 overruns:0 carrier:0
collisions:0 txqueuelen:0
RX bytes:0 (0.0 b) TX bytes:0 (0.0 b)

root@test:~#
 
Old 10-25-2014, 06:51 AM   #2
colucix
LQ Guru
 
Registered: Sep 2003
Location: Bologna
Distribution: CentOS 6.5 OpenSuSE 12.3
Posts: 10,509

Rep: Reputation: 1983Reputation: 1983Reputation: 1983Reputation: 1983Reputation: 1983Reputation: 1983Reputation: 1983Reputation: 1983Reputation: 1983Reputation: 1983Reputation: 1983
Please post your thread in only one forum. Posting a single thread in the most relevant forum will make it easier for members to help you and will keep the discussion in one place. This thread is being closed because it is a duplicate. Please follow discussion here: http://www.linuxquestions.org/questi...ap-4175521419/
 
1 members found this post helpful.
  


Closed Thread


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
Ethernet Interface changed name (eth1 > eth0) liri Linux - Server 1 10-25-2009 05:23 AM
can i bridge eth0:1 with eth1? stankeeper Linux - Networking 1 11-06-2005 02:53 PM
How To Rename Ethernet Card Eth1 to Eth0 chammoud Linux - Networking 4 04-20-2005 07:01 AM
Wireless network on eth1 diabled Ethernet eth0 and eth0 never comes back tadatoshi Linux - Wireless Networking 4 09-23-2004 06:57 PM
ethernet bridge (wlan0 eth1) - canīt ping magicien Linux - Wireless Networking 0 07-05-2004 04:59 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Software

All times are GMT -5. The time now is 08:20 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration