V2EX = way to explore
V2EX 是一个关于分享和探索的地方
现在注册
已注册用户请  登录
OpenWrt 是一个专门面向嵌入式设备的 Linux 发行版。你可以将 OpenWrt 支持的型号的嵌入式设备,比如各种路由器上的系统,换成一个有更多可能性可以折腾的 Linux 系统。
OpenWrt 官方网站
hhp
V2EX  ›  OpenWrt

[搜索无果,不懂就问] 刷了 openwrt 之后连不上网

  •  
  •   hhp · 2016-08-03 22:14:23 +08:00 · 284 次点击
    这是一个创建于 2844 天前的主题,其中的信息可能已经有所发展或是发生改变。
    手里有个闲置的路由,刚刷了 openwrt ,想在公司随便用用
    但是配置后有线接公司内网插口,电脑连 wifi ,根本上不了网,查了半天也一头雾水,只能来求教了。。。

    根据官网和网上各种教程,配置如下
    到底是哪里不对啊。。。。。。

    /etc/config/dhcp

    config dnsmasq
    option domainneeded '1'
    option boguspriv '1'
    option filterwin2k '0'
    option localise_queries '1'
    option rebind_protection '1'
    option rebind_localhost '1'
    option local '/lan/'
    option domain 'lan'
    option expandhosts '1'
    option nonegcache '0'
    option authoritative '1'
    option readethers '1'
    option leasefile '/tmp/dhcp.leases'
    option resolvfile '/tmp/resolv.conf.auto'
    option localservice '1'

    config dhcp 'lan'
    option interface 'lan'
    option start '100'
    option limit '150'
    option leasetime '12h'
    option dhcpv6 'server'
    option ra 'server'

    config dhcp 'wan'
    option interface 'wan'
    option ignore '1'

    config odhcpd 'odhcpd'
    option maindhcp '0'
    option leasefile '/tmp/hosts/odhcpd'
    option leasetrigger '/usr/sbin/odhcpd-update'



    /etc/config/network

    config interface 'loopback'
    option ifname 'lo'
    option proto 'static'
    option ipaddr '127.0.0.1'
    option netmask '255.0.0.0'

    config globals 'globals'
    option ula_prefix ''

    config interface 'lan'
    option type 'bridge'
    # option ifname 'eth0'
    option proto 'static'
    option ipaddr '192.168.2.1'
    option netmask '255.255.255.0'
    option ip6assign '60'

    config interface 'wan'
    option ifname 'eth0'
    option proto 'dhcp'




    /etc/config/wireless

    config wifi-device radio0
    option type mac80211
    option channel 11
    option hwmode 11g
    option path 'platform/ar933x_wmac'
    option htmode HT20
    # REMOVE THIS LINE TO ENABLE WIFI:

    config wifi-iface
    option device radio0
    option network lan
    option mode ap
    option ssid OpenWrt
    option encryption psk2
    option key ''
    1 条回复    2016-08-07 08:22:37 +08:00
    zhengnanlee
        1
    zhengnanlee  
       2016-08-07 08:22:37 +08:00 via Android
    看看路由器能不能获取到公司网络的 IP ?
    关于   ·   帮助文档   ·   博客   ·   API   ·   FAQ   ·   实用小工具   ·   2564 人在线   最高记录 6679   ·     Select Language
    创意工作者们的社区
    World is powered by solitude
    VERSION: 3.9.8.5 · 35ms · UTC 03:16 · PVG 11:16 · LAX 20:16 · JFK 23:16
    Developed with CodeLauncher
    ♥ Do have faith in what you're doing.