V2EX = way to explore
V2EX 是一个关于分享和探索的地方
现在注册
已注册用户请  登录
V2EX  ›  lvii  ›  全部回复第 5 页 / 共 5 页
回复总数  91
1  2  3  4  5  
2013-06-23 18:26:45 +08:00
回复了 lvii 创建的主题 Linux TP Link wr703n bridged AP 桥接模式无法连接外网
@dndx 兄,一语点醒。。。

现在的情况看,几乎可以断定是上层路由器的配置问题。
比如是不是设了 MAC 过滤或者防火墙之类的。


上层路由做了 mac 访问限制,我添加 mac 之后,可以访问了

-------------------------------------------------

还有一个问题:使用 bridged AP 模式,管理地址可否再多设置一个虚拟地址:
现在在家中使用的都是 192.168.x.x 这种,如果到办公室:

办公室 DHCP(10.x.x.x) --有线--> wr703n(192.168.x.x) --无线--> 笔记本(10.x.x.x)

如果要管理 openwrt 需要将笔记本 IP 手动改为 192.168.x.x 段的,然后连接到 wr703n
进行管理,但是此时 wr703n 使用的是 192.168.x.x 段的,是无法访问外网的

如果设置为和办公网的 10.x.x.x 网段按理可以(需要明天验证)
那可否在 openwrt 种再添加一个虚拟网卡,配置一个办公网地址
通过它可以在连接到办公网内的时候可以登录 openwrt 进行管理。

谢谢!
2013-06-23 17:01:23 +08:00
回复了 lvii 创建的主题 Linux TP Link wr703n bridged AP 桥接模式无法连接外网
@dndx 关于 DNS 我之前也排查过,后面只能设置为上层路由的管理地址,才能正确解析

在 openwrt 上面 ping 上层路由器,以及内网都是 OK 的,因为 192.168.1.x 的路由
网关是上层路由,所以链路是通的,没有问题的。

--------------------------------------

配置文件,我都是 copy 过的,不知道格式为何变成这样子了。-_-#

--------------------------------------

关于 DNS :

option dns '192.168.1.111'

bridged AP 模式需要设置为上层路由器的地址,由上层路由器代理解析地址:

# cat /etc/resolv.conf
# Interface lan
nameserver 192.168.1.111

# opkg update
Downloading http://downloads.openwrt.org/attitude_adjustment/12.09/ar71xx/generic/packages/Packages.gz.
wget: can't connect to remote host (78.24.191.177): Connection timed out
...

错误提示显示已经解析出 openwrt.org 的 IP 地址(78.24.191.177),DNS 解析是没有问题的
问题应该出在路由上面的

下面的两个输出都表示 DNS 解析是正常的:

# ping openwrt.org
PING openwrt.org (78.24.191.177): 56 data bytes
^C
--- openwrt.org ping statistics ---
7 packets transmitted, 0 packets received, 100% packet loss

# nslookup openwrt.org
Server: 192.168.1.111
Address 1: 192.168.1.111

Name: openwrt.org
Address 1: 78.24.191.177 openwrt.org

如果换成 google 或 电信的 DNS ,直接连 DNS 解析都是失败的:wget: bad address 'downloads.openwrt.org'

# opkg update
Downloading http://downloads.openwrt.org/attitude_adjustment/12.09/ar71xx/generic/packages/Packages.gz.
wget: bad address 'downloads.openwrt.org'
Collected errors:
* opkg_download: Failed to download http://downloads.openwrt.org/attitude_adjustment/12.09/ar71xx/generic/packages/Packages.gz, wget returned 1.

因为出不了 公网,设置外网的 DNS 服务器,根本没用:

# ping 8.8.4.4
PING 8.8.4.4 (8.8.4.4): 56 data bytes
^C
--- 8.8.4.4 ping statistics ---
4 packets transmitted, 0 packets received, 100% packet loss

# nslookup openwrt.org 8.8.8.8
Server: 8.8.8.8
Address 1: 8.8.8.8

nslookup: can't resolve 'openwrt.org': Name or service not known

# traceroute 8.8.4.4
traceroute to 8.8.4.4 (8.8.4.4), 30 hops max, 38 byte packets
1 * * *
2 * * *
3^C
2013-03-08 11:22:59 +08:00
回复了 lvii 创建的主题 Python python logging 模块无法打印日志道文件
@xuwenbao 兄,修改为 logger 对象后,可以输出日志到文件,但是只有 warning 日志
debug 和 info 没有,修改日志级别为 DEBUG 后,debug 和 info 正常输出,谢谢科普 ...
2013-03-05 11:52:23 +08:00
回复了 lvii 创建的主题 Python pdb 调试异常退出问题
怎么插入 gist 代码呢 …… 测试了几个,咋都不行 ……
2013-03-05 11:51:31 +08:00
回复了 lvii 创建的主题 Python pdb 调试异常退出问题
2013-03-05 11:49:52 +08:00
回复了 lvii 创建的主题 Python pdb 调试异常退出问题
2013-03-05 11:46:44 +08:00
回复了 lvii 创建的主题 Python pdb 调试异常退出问题
<script src="http://gist.github.com/lvii/5087791"> </script>
2013-03-05 11:45:56 +08:00
回复了 lvii 创建的主题 Python pdb 调试异常退出问题
2013-03-05 11:35:33 +08:00
回复了 lvii 创建的主题 Python pdb 调试异常退出问题
https://gist.github.com/lvii/5087791

@xsaps 兄,我试了 pdb.run('foo()') 调试到后面

16 -> pdb.run('foo()')
17
[EOF]
(Pdb) n
> <string>(1)<module>()
(Pdb) l
[EOF]
(Pdb) n
--Return--
> <string>(1)<module>()->None
(Pdb) l
[EOF]
(Pdb) n
## 退出,无异常

但是,如果按 'q' 退出,还是会有异常的。pdb.run(...) 是在交互式 shell 中启用 pdb 貌似
对你的回复,原理还不识很明白,还请继续抛玉 :)
2013-01-30 20:01:46 +08:00
回复了 lvii 创建的主题 程序员 firefox 下 goagent 登录 https 提示 ssl_error_bad_cert_domain
问题解决了,没有安装 gevent 和 pyopenssl 依赖,安装后,可以正常访问了

· python2 proxy.py
WARNING: python-gevent not installed. `curl -k -L http://git.io/I9B7RQ|sh`
------------------------------------------------------
GoAgent Version : 2.1.11 (python/2.7.3 gevent/None pyopenssl/Disabled)
2013-01-30 19:23:55 +08:00
回复了 lvii 创建的主题 程序员 firefox 下 goagent 登录 https 提示 ssl_error_bad_cert_domain
在没导入 CA 证书之前提示如下:

twitter.com uses an invalid security certificate.

The certificate is not trusted because it is self-signed.
The certificate is only valid for GoAgent CA

(Error code: sec_error_untrusted_issuer)
1  2  3  4  5  
关于   ·   帮助文档   ·   博客   ·   API   ·   FAQ   ·   我们的愿景   ·   实用小工具   ·   5598 人在线   最高记录 6543   ·     Select Language
创意工作者们的社区
World is powered by solitude
VERSION: 3.9.8.5 · 19ms · UTC 01:44 · PVG 09:44 · LAX 18:44 · JFK 21:44
Developed with CodeLauncher
♥ Do have faith in what you're doing.