﻿<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
	>

<channel>
	<title>单调专注的明王子 &#187; ftp</title>
	<atom:link href="http://uyun.com/tag/ftp/feed/" rel="self" type="application/rss+xml" />
	<link>http://uyun.com</link>
	<description>发梦都喊着亚历山大的男孩～</description>
	<lastBuildDate>Sun, 09 Oct 2011 08:16:02 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.0.4</generator>
		<item>
		<title>ADSL 通过路由器共享，FTP上传缓慢，甚至停顿的解决方法</title>
		<link>http://uyun.com/adsl-through-a-router-to-share-ftp-upload-is-slow-even-stop-solution/</link>
		<comments>http://uyun.com/adsl-through-a-router-to-share-ftp-upload-is-slow-even-stop-solution/#comments</comments>
		<pubDate>Tue, 05 Jan 2010 08:28:39 +0000</pubDate>
		<dc:creator>明王子</dc:creator>
				<category><![CDATA[技术]]></category>
		<category><![CDATA[ftp]]></category>
		<category><![CDATA[mtu]]></category>

		<guid isPermaLink="false">http://www.uyun.com/?p=528</guid>
		<description><![CDATA[最近公司换了一个磊科的NW618 的路由器，这个家伙很不错的，一下子把之前浪费的网速拿了回来。不过出现了一个问题，用FTP上传的时候很慢，甚至是停止好几分钟，才能反应过来，上传是能够上传，但是往往要等几分钟才能传几k的东西。实在看不下去…… 开始排查了，由于之前FTP服务器出了问题，重装了一次，一直都觉得是FTP服务器的原因。结果，在服务器上对着pure-ftpd.conf看了老半天还是没什么结论。接着看FTP连接，不是被动模式的问题，更加奇怪的是我在192.168.1.105 能够正常上传，跑换到192.168.2.108 就不行了。 基本将服务器、FTP软件排除掉。 后来百度下，终于发现了问题的根源：MTU 最大传输单元的设置问题！ 如何测试自己最大的MTU呢？ 其实可以通过ping命令来测试：ping -f -l 1440 www.baidu.com 如果这个时候出现类似“来自 192.168.1.105 的回复: 需要拆分数据包但是设置 DF。”的提示，如图： 就说明你的ADSL设置MTU的时候不能超过1440，如何找最大的MTU？ 呵呵，没有办法，逐步减少试下，ping -f -l 1340 www.baidu.com 提示timeout 或者 反应TTL多少ms都是正确的值，多次测试，取一个比较大的就可以了。 然后到modem设置页面，找到ADSL的页面，填入这个数值即可！ 那么，为什么出现在192.168.2.108 不行而192.168.1.105 可以的情况呢？ 往往是因为192.168.2.1 这个路由器的设置问题，对应调整 MTU，重启路由器后一切正常。]]></description>
			<content:encoded><![CDATA[<p>最近公司换了一个磊科的NW618 的路由器，这个家伙很不错的，一下子把之前浪费的网速拿了回来。不过出现了一个问题，用FTP上传的时候很慢，甚至是停止好几分钟，才能反应过来，上传是能够上传，但是往往要等几分钟才能传几k的东西。实在看不下去……</p>
<p style="text-align: center;"><a href="http://www.uyun.com/wp-content/uploads/2010/01/mut-ftp1.png"><img class="size-full wp-image-529 aligncenter" title="mut-ftp1" src="http://www.uyun.com/wp-content/uploads/2010/01/mut-ftp1.png" alt="" width="197" height="151" /></a></p>
<p>开始排查了，由于之前FTP服务器出了问题，重装了一次，一直都觉得是FTP服务器的原因。结果，在服务器上对着pure-ftpd.conf看了老半天还是没什么结论。接着看FTP连接，不是被动模式的问题，更加奇怪的是我在192.168.1.105 能够正常上传，跑换到192.168.2.108 就不行了。 基本将服务器、FTP软件排除掉。</p>
<p>后来百度下，终于发现了问题的根源：<a href="http://baike.baidu.com/view/26974.htm" target="_blank">MTU</a> 最大传输单元的设置问题！</p>
<p>如何测试自己最大的MTU呢？ 其实可以通过ping命令来测试：<strong>ping -f -l 1440 www.baidu.com </strong>如果这个时候出现类似“来自 192.168.1.105 的回复: 需要拆分数据包但是设置 DF。”的提示，如图：</p>
<p><a href="http://www.uyun.com/wp-content/uploads/2010/01/mut-ftp2.png"><img class="aligncenter size-full wp-image-530" title="mut-ftp2" src="http://www.uyun.com/wp-content/uploads/2010/01/mut-ftp2.png" alt="" width="429" height="63" /></a></p>
<p>就说明你的ADSL设置MTU的时候不能超过1440，如何找最大的MTU？ 呵呵，没有办法，逐步减少试下，<strong>ping -f -l 1340 www.baidu.com </strong>提示timeout 或者 反应TTL多少ms都是正确的值，多次测试，取一个比较大的就可以了。</p>
<p>然后到modem设置页面，找到ADSL的页面，填入这个数值即可！</p>
<p><a href="http://www.uyun.com/wp-content/uploads/2010/01/mut-ftp4.png"><img class="aligncenter size-full wp-image-531" title="mut-ftp4" src="http://www.uyun.com/wp-content/uploads/2010/01/mut-ftp4.png" alt="" width="513" height="111" /></a></p>
<p>那么，为什么出现在192.168.2.108 不行而192.168.1.105 可以的情况呢？ 往往是因为192.168.2.1 这个路由器的设置问题，对应调整 MTU，重启路由器后一切正常。</p>
]]></content:encoded>
			<wfw:commentRss>http://uyun.com/adsl-through-a-router-to-share-ftp-upload-is-slow-even-stop-solution/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
	</channel>
</rss>

