V2EX = way to explore
V2EX 是一个关于分享和探索的地方
现在注册
已注册用户请  登录
V2EX  ›  btwo  ›  全部回复第 3 页 / 共 6 页
回复总数  101
1  2  3  4  5  6  
@qq286735628 比如?
卡了下,一不小心就发了3条,过了时间,不能删除!抱歉了!
晕,每次都是点箭头,我以为是感谢, 原来要点边上的链接啊!

所有回复的我都感谢一些,谢谢大家!
@hyq 确实是这个问题,搞定了,谢谢!!!!!!!!!再次感谢!!!!!
@hyq FORWARD链 要改成什么呢? 其实我一直纠结出了这样的问题该怎么找问题,确定问题!

再次感谢所有回复的朋友!
@terry0824 又检查了一次
###############################################################################
# $Id: pptpd.conf 4255 2004-10-03 18:44:00Z rene $
#
# Sample Poptop configuration file /etc/pptpd.conf
#
# Changes are effective when pptpd is restarted.
###############################################################################

# TAG: ppp
# Path to the pppd program, default '/usr/sbin/pppd' on Linux
#
#ppp /usr/sbin/pppd

# TAG: option
# Specifies the location of the PPP options file.
# By default PPP looks in '/etc/ppp/options'
#
option /etc/ppp/pptpd-options

# TAG: debug
# Turns on (more) debugging to syslog
#
debug

# TAG: stimeout
# Specifies timeout (in seconds) on starting ctrl connection
#
# stimeout 10

# TAG: noipparam
# Suppress the passing of the client's IP address to PPP, which is
# done by default otherwise.
#
#noipparam

# TAG: logwtmp
# Use wtmp(5) to record client connections and disconnections.
#
logwtmp

# TAG: bcrelay <if>
# Turns on broadcast relay to clients from interface <if>
#
#bcrelay eth1

# TAG: localip
# TAG: remoteip
# Specifies the local and remote IP address ranges.
#
# Any addresses work as long as the local machine takes care of the
# routing. But if you want to use MS-Windows networking, you should
# use IP addresses out of the LAN address space and use the proxyarp
# option in the pppd options file, or run bcrelay.
#
# You can specify single IP addresses seperated by commas or you can
# specify ranges, or both. For example:
#
# 192.168.0.234,192.168.0.245-249,192.168.0.254
#
# IMPORTANT RESTRICTIONS:
#
# 1. No spaces are permitted between commas or within addresses.
#
# 2. If you give more IP addresses than MAX_CONNECTIONS, it will
# start at the beginning of the list and go until it gets
# MAX_CONNECTIONS IPs. Others will be ignored.
#
# 3. No shortcuts in ranges! ie. 234-8 does not mean 234 to 238,
# you must type 234-238 if you mean this.
#
# 4. If you give a single localIP, that's ok - all local IPs will
# be set to the given one. You MUST still give at least one remote
# IP for each simultaneous client.
#
# (Recommended)
localip 192.168.217.1
remoteip 192.168.217.234-238,192.168.217.245
# or
#localip 192.168.0.234-238,192.168.0.245
#remoteip 192.168.1.234-238,192.168.1.245
@lypdarling

你说的规则加上去也不行

root@mail:~# iptables -L
Chain INPUT (policy DROP)
target prot opt source destination
ACCEPT all -- anywhere anywhere state RELATED,ESTABLISHED
ACCEPT tcp -- anywhere anywhere multiport dports www,https,smtp,ssmtp,pop3,pop3s,imap2,imaps,submission,ssmtp,ssh
ACCEPT all -- anywhere anywhere
ACCEPT icmp -- anywhere anywhere icmp echo-request
ACCEPT tcp -- anywhere anywhere tcp dpt:47
ACCEPT tcp -- anywhere anywhere tcp dpt:1723

Chain FORWARD (policy DROP)
target prot opt source destination
TCPMSS tcp -- anywhere anywhere tcp flags:FIN,SYN,RST,ACK/SYN TCPMSS set 1356

Chain OUTPUT (policy ACCEPT)
target prot opt source destination
@grindsgears 谢谢,已经检查 net.ipv4.ip_forward = 1

root@mail:~# iptables -L
Chain INPUT (policy DROP)
target prot opt source destination
ACCEPT all -- anywhere anywhere state RELATED,ESTABLISHED
ACCEPT tcp -- anywhere anywhere multiport dports www,https,smtp,ssmtp,pop3,pop3s,imap2,imaps,submission,ssmtp,ssh
ACCEPT all -- anywhere anywhere
ACCEPT icmp -- anywhere anywhere icmp echo-request
ACCEPT tcp -- anywhere anywhere tcp dpt:47
ACCEPT tcp -- anywhere anywhere tcp dpt:1723

Chain FORWARD (policy DROP)
target prot opt source destination
TCPMSS tcp -- anywhere anywhere tcp flags:FIN,SYN,RST,ACK/SYN TCPMSS set 1356

Chain OUTPUT (policy ACCEPT)
target prot opt source destination


配置iptables 也做了,还是收到不包,能发送出去!
@donnior

Version check and ipsec on-path [OK]
Linux Openswan U2.6.24/K3.4.2-linode44 (netkey)
Checking for IPsec support in kernel [OK]
NETKEY detected, testing for disabled ICMP send_redirects [OK]
NETKEY detected, testing for disabled ICMP accept_redirects [OK]
Checking for RSA private key (/etc/ipsec.secrets) [OK]
Checking that pluto is running [OK]
Pluto listening for IKE on udp 500 [OK]
Pluto listening for NAT-T on udp 4500 [OK]
Two or more interfaces found, checking IP forwarding [OK]
Checking NAT and MASQUERADEing
Checking for 'ip' command [OK]
Checking for 'iptables' command [OK]
Opportunistic Encryption Support [DISABLED]
ipsec_setup: Stopping Openswan IPsec...
ipsec_setup: Starting Openswan IPsec U2.6.24/K3.4.2-linode44...
Checking your system to see if IPsec got installed and started correctly:
Version check and ipsec on-path [OK]
Linux Openswan U2.6.24/K3.4.2-linode44 (netkey)
Checking for IPsec support in kernel [OK]
NETKEY detected, testing for disabled ICMP send_redirects [OK]
NETKEY detected, testing for disabled ICMP accept_redirects [OK]
Checking for RSA private key (/etc/ipsec.secrets) [OK]
Checking that pluto is running [OK]
Pluto listening for IKE on udp 500 [OK]
Pluto listening for NAT-T on udp 4500 [OK]
Two or more interfaces found, checking IP forwarding [OK]
Checking NAT and MASQUERADEing
Checking for 'ip' command [OK]
Checking for 'iptables' command [OK]
Opportunistic Encryption Support [DISABLED]

自动脚本安装的结果, IPAD 连接不到服务器,晕了, 对了脚本中有几个包的地址失效了,需要网上找替换的地址!
@terry0824 我现在很困惑,那个文档有问题还是有什么其他办法确定一下问题呢?
@donnior 我现在又该下试试!
PPTP的帐号 btwo/phoenix 主机是106.187.102.170
各位:有L2TP over IPSec 的安装教程吗?最好是已经验证过的,不是想吃现成的,实在是不想太折腾了!!谢谢各位了!
HKEY_LOCAL_MACHINE/SYSTEM/CurrentControlSet/Services/Tcpip 下面有很多个MTU 都是1300 ,修改了十四号
@ratazzi
@lanbing 这个不错,自动配置的, 我自己配置postfix被害苦了,呵呵
2012-06-29 16:31:54 +08:00
回复了 btwo 创建的主题 Python 请教:关于 Python处理JSON的几个小问题
补充: 我用得是WINDOWS的环境,是不是和本地编码也有关系,网上找了些资料看,都是几个编码的问题,新手看得有点晕乎了!
2012-06-29 16:27:00 +08:00
回复了 btwo 创建的主题 Python 请教:关于 Python处理JSON的几个小问题
1.
http://love.taobao.com/guang/async_search.htm?t=1340953549726&page=6&tagid=170&qc=&order=4&cat=&price=&version=91&nid=&start_price=&end_price=&market_id=0&s_type=&color= 这个淘宝的一个JSON请求地址

#!/usr/bin/env python
# -*- coding: UTF-8 -*-
import requests
r = requests.get('http://love.taobao.com/guang/async_search.htm?t=1340953549726&page=6&tagid=170&qc=&order=4&cat=&price=&version=91&nid=&start_price=&end_price=&market_id=0&s_type=&color=')
print r.text

由于没解决问题,只测试了下。


2.
str= s.replace(r'\r\n', '\n').replace(r'\"', '"').replace(r'\/', '/').replace(r'\t', ' ') 我现在是这样替换的,感觉处理不完美,肯定有更好的解决办法。

3.
def jiema(getstring):
fstr=r""
list_str=getstring.split(r'\u')
for single in list_str:
if single != '':
fstr+=unichr(int(single,16))
print fstr

解码的方法

JSON的地址:http://www.meilishuo.com//aj/getGoods/catalog?frame=0&page=0&view=1&word=0&cata_id=6000000000000&section=hot&price=all&_=1338983940302
2012-06-29 16:21:19 +08:00
回复了 btwo 创建的主题 Python 请教:关于 Python处理JSON的几个小问题
1. &# 38795; &# 20937;&# 38795;&# 40060;&# 22068;&# 38795 的字符, 我提交就自动转换成中文了!汗!
2012-06-24 11:57:26 +08:00
回复了 clowwindy 创建的主题 Linode 用了一段时间的 50 个 Linode 节点,说说感想
Fremont 节点连接不上,我用的长沙电信的网络,测试确实Fremont 节点最快,可以我自己的建的主机就连接不上。等客服回复了!

有经验的朋友知道怎么搞吗?
1  2  3  4  5  6  
关于   ·   帮助文档   ·   博客   ·   API   ·   FAQ   ·   实用小工具   ·   995 人在线   最高记录 6679   ·     Select Language
创意工作者们的社区
World is powered by solitude
VERSION: 3.9.8.5 · 16ms · UTC 19:56 · PVG 03:56 · LAX 11:56 · JFK 14:56
Developed with CodeLauncher
♥ Do have faith in what you're doing.