<?xml version='1.0' encoding='UTF-8'?><?xml-stylesheet href="http://www.blogger.com/styles/atom.css" type="text/css"?><feed xmlns='http://www.w3.org/2005/Atom' xmlns:openSearch='http://a9.com/-/spec/opensearchrss/1.0/' xmlns:georss='http://www.georss.org/georss' xmlns:gd='http://schemas.google.com/g/2005' xmlns:thr='http://purl.org/syndication/thread/1.0'><id>tag:blogger.com,1999:blog-4984480909360655633</id><updated>2011-09-04T06:08:52.116-07:00</updated><title type='text'>World In The Net</title><subtitle type='html'>WorldInTheNet &amp;gt;&amp;gt; WorldInternet.

Purely random technical stuff.

Information changes life.</subtitle><link rel='http://schemas.google.com/g/2005#feed' type='application/atom+xml' href='http://worldinthenet.blogspot.com/feeds/posts/default'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/4984480909360655633/posts/default?max-results=100'/><link rel='alternate' type='text/html' href='http://worldinthenet.blogspot.com/'/><link rel='hub' href='http://pubsubhubbub.appspot.com/'/><author><name>Taojun</name><uri>http://www.blogger.com/profile/12946690813153575136</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><generator version='7.00' uri='http://www.blogger.com'>Blogger</generator><openSearch:totalResults>33</openSearch:totalResults><openSearch:startIndex>1</openSearch:startIndex><openSearch:itemsPerPage>100</openSearch:itemsPerPage><entry><id>tag:blogger.com,1999:blog-4984480909360655633.post-325065415600500046</id><published>2011-01-27T15:00:00.000-08:00</published><updated>2011-01-27T15:02:00.238-08:00</updated><title type='text'>[zz]Android装置的开发挑战：软硬体如何巧妙整合</title><content type='html'>http://laoyaoba.com/ss6/?action-viewnews-itemid-166915&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;来源： 集微网   发布者：集微网&lt;br /&gt;热度1票   【共0条评论】【我要评论】 时间：2011年1月26日 16:18&lt;br /&gt;随着科技的快速演进，现代人对行动通讯、无线上网与多媒体娱乐的需求更甚以往，所谓的智慧型手机（Smart Phone）便成了炙手可热的个人消费电子产品之一，从Apple不断推出iPhone企图颠覆消费者对手机的想象、RIM推出主打商务功能的黑莓机、Google的Android系统让众家手机厂商争食大饼，到微软屡败屡战的从WinMo一路开发到WP7，智慧型手机的这块战场可说是打的如火如荼。然而在这些众家竞争者中，Android可说是目前行情看俏的一套作业系统，以国际市调研究机构Gartner最新出炉2010年第三季的调查为例，采用Android作业系统的智慧型手机在过去一年以来成长幅度最高，光是市占率便是前一年同期的七倍之多，销售量更是达到14倍的成长，同时也一举从市占率排名的第六名窜升到第二名。而在今年一月份甫落幕的国际消费性电子展（CES），也处处可见各式各样采用Android作业系统的产品。&lt;br /&gt;Android在过去一直扮演后起之秀的角色，切入智慧型手机的速度似乎慢了苹果的iOS一步，但与Apple相同的是，它也成功的将其应用从手机移植到了平板电脑（Tablet PC）上。Android开放原始码（Open Source）的特性，能轻易地提高厂商对自家产品的接受度，更不用提背后Google的强力撑腰能带来多大的经济效益。目前可见包括手机厂商HTC、Motorola、SAMSUNG，以及电脑大厂HP与Dell等皆投向Android的怀抱，Android被广泛应用可说是势在必行。&lt;br /&gt;&lt;br /&gt;尽管Android系统的普及看似指日可待，但在实际的产品应用上，也有其可能产生的问题风险。Android作为一个开放式的作业系统，是Google提供厂商的作业系统参考架构（reference design），厂商能有充足的发挥空间，以Android为基础向上开发设计自家产品，但也因为这样的开放性与自由性，让厂商在软硬体结合的这个环节必须下更大的功夫，像是如何挑选合适的硬体包括基频处理器、通讯晶片、触控感应晶片、天线与记忆体模组等，以及如何调整出最适当的软体设定等，更重要的是如何将软硬体整合，开发出差异化的产品。这中间所有的细节都会对产品最终样貌产生莫大的影响，像是其功能的完整度、使用介面的设计、效能表现（例如触控滑动画面、开启程式所需时间）、品质可靠度、甚至是后续的韧体升级动作等等。在此百佳泰便试图以专业中立的测试实验室角度，来点出厂商应用Android于手机、平板电脑或其他装置时应注意的开发重点，以希冀作为一个有效的参考资讯。&lt;br /&gt;&lt;br /&gt;解构Android基本技术架构&lt;br /&gt;&lt;br /&gt;首先我们先来看到Android的基本技术架构，Android是以Linux为核心，并采用软体堆迭（software stack）的架构延伸发展的一套软体平台与作业系统。根据下图可以看出，其基本架构分为五层：&lt;br /&gt;Linux核心（Linux Kernel）：以Linux开发提供最底层的核心系统服务，包括安全性 (Security)、、记忆体管理(Memory Management)、进程管理(Process Management)、网路堆迭(Network Stack)与驱动程式模型（Driver Model）。&lt;br /&gt;Android执行环境（Android Runtime）：透过Core Libraries(核心函式库)以及暂存器型态的Dalvik Virtual Machine(Dalvik虚拟机器)来执行程式。&lt;br /&gt;系统函式库（Library）：使用C/C++函式库的系统元件以供呼叫使用，开发者可透过上层的应用程式框架来运用这些功能，这也是主要Android装置的效能关键。&lt;br /&gt;应用程式框架（Application Framework）：被设计来简化元件的再运用，开发者能完整存取使用与核心应用程式（Core Application）相同的API，应用程式可以发布功能并为其它应用程式所使用（需受限于其安全性限制），开发者也可运用同样的机制来新增与置换元件。&lt;br /&gt;应用程式（Application）：所有Android应用程式皆是以Java程式语言编写，原始就会包含像是Email、简讯、日历、地图、浏览器、联络人等其它应用程式，让使用者一开始就拥有这些基本功能，开发者也可在此客制其使用介面。&lt;br /&gt;&lt;br /&gt;厂商越想要设计出与原始设定不同且增强效能的产品，便越需要对这五层架构进行修改。譬如像是多工处理能力（multi-tasking），便可能需要修改包括Linux核心与应用程式框架的设计；而应用程式的开发者更可能需要针对应用程式与框架进行调整。由此可见，对Android装置而言，任何一个功能的置入或是对硬体设定的细微更动，都需要对Android系统进行从下到上的调整以达到最优化的效能，而这正是最为困难与需要验证的一环。&lt;br /&gt;&lt;br /&gt;Android装置软硬体整合的五大技术环节&lt;br /&gt;&lt;br /&gt;如前所述，对众家开发厂商而言最大的挑战其实在于，如何将自己理想的产品诉求，与Android系统巧妙结合成一个功能完整并使用流畅顺手的产品，这其中牵涉了不同技术间的整合与运用。在此我们便根据其多年的测试与研究经验，归纳出五大Android相关装置在技术整合上的重要环节：&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;一、Linux驱动程式的导入&lt;br /&gt;&lt;br /&gt;由于Android是根源于Linux所延伸出来的作业系统，因此各种关键功能的驱动程式也必须要能顺利的写入其中，举凡像是字元装置、记忆体的空间配置、中断处理、网路通讯、萤幕显示或是连接介面像是USB与PCI的驱动程式，这些可能是自行撰写、或是来自不同元件厂商的驱动程式，都必须要能被导入到Android系统，并维持良好稳定的效能表现。&lt;br /&gt;&lt;br /&gt;二、系统单晶片的优化处理&lt;br /&gt;&lt;br /&gt;对厂商而言，开发一款Android装置，不仅仅只是将所有零组件组合成为一个产品那么容易，最大的学问便在于将系统单晶片（System-on-a-chip，SoC）、各种新技术和Android系统进行整合，SoC涉及像是Dalvik Virtual Machine、OpenGL、V8、Webkit Engine等上层的演算，与Android间的结合便必须透过不断的尝试与验证，才能研发出既符合成本效益、又有良好效能的优化产品。目前市面上有些SoC厂商已针对Android系统的特性，提供整合过的SoC平台，将蓝牙、相机或上网等常用功能模组预先写入，减少终端成品厂商费力整合开发的时间，但对厂商而言，这样的预先整合是否适合自身产品，以及是否需要再作更细致的修改，则又是更困难的课题。&lt;br /&gt;&lt;br /&gt;三、新技术的移植&lt;br /&gt;&lt;br /&gt;随着技术的快速发展，更多新兴的技术规格也逐渐应用在手机等手持装置上，以手机为例，已经从过去以拨打电话为主要功能，转变为拥有各种多样化用途的产品。像是触控技术让消费者可以透过手指的滑动传送指令甚至是具备多点触控的支援、Wi-Fi模组提供随时无线上网的可能、通用图形处理器（General-purpose computing on graphics processing units，GPGPU）则能以并行方式透过图形处理器来执行通用计算任务、Android 2.3版所支持的NFC近场通讯技术，以及更高阶的相机模组等等，背后都有各自的驱动程式与软体技术，也必须要与Android系统相结合使用。&lt;br /&gt;&lt;br /&gt;四、效能表现的稳定&lt;br /&gt;&lt;br /&gt;尽管上述这些技术不断推陈出新，但也都不能因此而牺牲装置原本的效能表现，让处理速度因此变慢或造成使用上不顺畅的状况。除了采用更好的硬体设备外（例如现今处理器的时脉已迈向1GHz），更需要作业系统的支持，像是如何在多工运作的状况下维持程式执行速度以及系统满载的处理等等，都必须要透过软体面的奥援。也就是说，一台Android装置除了要能将各种功能与技术收纳起来、将软硬体整合外，更必须同时注重它在效能上能否维持应有的水准，以提供使用者在操作上流畅易上手的感受。&lt;br /&gt;&lt;br /&gt;五、低电耗设计&lt;br /&gt;&lt;br /&gt;Android的设计概念主要是应用于可携式装置上，目前市面上可见的像是平板电脑与智慧型手机等。对这类产品而言，电池续航力的好坏可说是影响消费者使用感受的关键之一，试想，若是一台智慧型手机的待机时间过短，而使用者在外时又无法随时充电使用，不能即时的连网查询资料或执行其他手机功能，这样的产品便失去了它作为可携式行动装置应有的便利性。追根究底，良好的待机时间除了需仰赖高容量的电池以提供充足电力之外，另一个重点就是装置本身在被使用执行时能否作到低电耗设计。Android装置让使用者能透过各种多样化的应用程式，来达到各种不同的使用目的，举凡像是单纯上网、观看新闻、邮件推播或是游戏等等，各种不同功能的程式都能透过自由下载使用，也由于其多工处理与让程式背景执行的能力，更让降低耗电量成为开发者不可轻忽的一项课题。&lt;br /&gt;&lt;br /&gt;持续验证修正  找出最佳Android整合方案&lt;br /&gt;&lt;br /&gt;正如前面我们不断提到的，对Android装置而言，最困难的开发挑战便在于如何完美地”整合”软体与硬体，以开发出一项功能完整又同时注重使用者感受的产品。从对Android本身程式码的修改、相关硬体的选择，到驱动程式的结合运用以及能否维持稳定的效能表现等，在在都必须要透过仔细的研究与不断的尝试，才能找出问题的根源并解决、更进而找出最合适的整合方案。&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;附图我们归纳出一些在Android装置上经常出现的问题与其可能肇因，而这些也都是开发厂商必须重视却可能忽略的一环。像是Android原始码中对音源的重新取样（Re-sampling）设计，就会导致装置在读取48K音源时重新取样成44K，而造成谐波失真的现象影响音质，这便是厂商不会注意到而未去修改的问题；另外像是天线位置的设计，也可能直接的影响到收讯能力的好坏；而不良的电源管理设计，也极有可能影响到装置在持续使用状态中的耗电情形。百佳泰在此仅以专业测试验证实验室的角度，希冀以宏观的方式，针对Android装置的开发设计提供可用的参考，近期内我们也将会提供实际的相关测试数据报告，并进一步指陈这些可能的问题风险，以期让更多厂商与消费者都能注意到品质验证的重要性，是从产品设计的根源就要开始层层把关。&lt;br /&gt;&lt;br /&gt;（本文由测试服务暨谘询顾问公司百佳泰Allion Test Labs, Inc提供）&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/4984480909360655633-325065415600500046?l=worldinthenet.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://worldinthenet.blogspot.com/feeds/325065415600500046/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://worldinthenet.blogspot.com/2011/01/zzandroid.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/4984480909360655633/posts/default/325065415600500046'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/4984480909360655633/posts/default/325065415600500046'/><link rel='alternate' type='text/html' href='http://worldinthenet.blogspot.com/2011/01/zzandroid.html' title='[zz]Android装置的开发挑战：软硬体如何巧妙整合'/><author><name>Taojun</name><uri>http://www.blogger.com/profile/12946690813153575136</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-4984480909360655633.post-1390086277479199559</id><published>2010-12-07T12:47:00.000-08:00</published><updated>2010-12-07T12:52:40.356-08:00</updated><title type='text'>YBox2 Kit - v1.1</title><content type='html'>&lt;span class="Apple-style-span" style="font-family: verdana, arial, helvetica, sans-serif; color: rgb(102, 102, 102); "&gt;&lt;div id="productImage" style="float: left; width: 450px; "&gt;&lt;div id="productMainImage" style="margin-top: 0em; margin-right: 1em; margin-bottom: 1em; margin-left: 0em; text-align: center; float: left; width: 400px; "&gt;&lt;a href="http://www.adafruit.com/index.php?main_page=product_info&amp;amp;cPath=26&amp;amp;products_id=95" id="mainImageLink" style="color: rgb(94, 134, 164); text-decoration: none; "&gt;&lt;span class="Apple-style-span" style="color: rgb(0, 0, 0); "&gt;&lt;/span&gt;&lt;/a&gt;&lt;div id="productCenter" style="margin-left: 15px; width: 700px; color: rgb(102, 102, 102); "&gt;&lt;a href="http://www.adafruit.com/index.php?main_page=product_info&amp;amp;cPath=26&amp;amp;products_id=95" id="mainImageLink" style="color: rgb(94, 134, 164); text-decoration: none; "&gt;&lt;/a&gt;&lt;div id="productImagesWrapper" style="width: 450px; float: left; font-size: 10px; "&gt;&lt;a href="http://www.adafruit.com/index.php?main_page=product_info&amp;amp;cPath=26&amp;amp;products_id=95" id="mainImageLink" style="color: rgb(94, 134, 164); text-decoration: none; "&gt;&lt;/a&gt;&lt;div id="productImage" style="float: left; width: 450px; "&gt;&lt;a href="http://www.adafruit.com/index.php?main_page=product_info&amp;amp;cPath=26&amp;amp;products_id=95" id="mainImageLink" style="color: rgb(94, 134, 164); text-decoration: none; "&gt;&lt;/a&gt;&lt;div id="productMainImage" style="margin-top: 0em; margin-right: 1em; margin-bottom: 1em; margin-left: 0em; text-align: center; float: left; width: 400px; "&gt;&lt;a href="http://www.adafruit.com/index.php?main_page=product_info&amp;amp;cPath=26&amp;amp;products_id=95" id="mainImageLink" style="color: rgb(94, 134, 164); text-decoration: none; "&gt;&lt;/a&gt;&lt;a href="http://www.adafruit.com/index.php?main_page=product_info&amp;amp;cPath=26&amp;amp;products_id=95" id="mainImageLink" style="color: rgb(94, 134, 164); text-decoration: none; "&gt;&lt;img id="mainReplaceableImage" src="http://www.adafruit.com/images/medium/yboxtv_MED.jpg" alt="YBox2 Kit" title="YBox2 Kit" width="400" style="border-top-style: solid; border-right-style: solid; border-bottom-style: solid; border-left-style: solid; border-width: initial; border-color: initial; float: left; padding-top: 20px; padding-right: 20px; padding-bottom: 20px; padding-left: 20px; border-top-width: 1px; border-right-width: 1px; border-bottom-width: 1px; border-left-width: 1px; border-top-color: rgb(226, 226, 226); border-right-color: rgb(226, 226, 226); border-bottom-color: rgb(226, 226, 226); border-left-color: rgb(226, 226, 226); " /&gt;&lt;br /&gt;&lt;/a&gt;&lt;/div&gt;&lt;/div&gt;&lt;div id="productAdditionalImages" style="float: left; "&gt;&lt;div class="additionalImages centeredContent" style="vertical-align: top; margin-top: 1em; margin-right: 5px; margin-bottom: 1em; margin-left: 0em; text-align: center; display: inline; float: left; border-top-width: 1px; border-right-width: 1px; border-bottom-width: 1px; border-left-width: 1px; border-top-style: solid; border-right-style: solid; border-bottom-style: solid; border-left-style: solid; border-top-color: rgb(226, 226, 226); border-right-color: rgb(226, 226, 226); border-bottom-color: rgb(226, 226, 226); border-left-color: rgb(226, 226, 226); width: 143px; line-height: 100px; "&gt;&lt;a href="http://www.adafruit.com/index.php?main_page=product_info&amp;amp;cPath=26&amp;amp;products_id=95" style="color: rgb(94, 134, 164); text-decoration: none; "&gt;&lt;img src="http://www.adafruit.com/images/yboxtvangle.jpg" alt="YBox2 Kit" title=" YBox2 Kit " width="133" height="99" style="border-top-style: none; border-right-style: none; border-bottom-style: none; border-left-style: none; border-width: initial; border-color: initial; display: inline; vertical-align: middle; margin-top: 5px; margin-right: 5px; margin-bottom: 5px; margin-left: 5px; " /&gt;&lt;br /&gt;&lt;/a&gt;&lt;/div&gt;&lt;div class="additionalImages centeredContent" style="vertical-align: top; margin-top: 1em; margin-right: 5px; margin-bottom: 1em; margin-left: 0em; text-align: center; display: inline; float: left; border-top-width: 1px; border-right-width: 1px; border-bottom-width: 1px; border-left-width: 1px; border-top-style: solid; border-right-style: solid; border-bottom-style: solid; border-left-style: solid; border-top-color: rgb(226, 226, 226); border-right-color: rgb(226, 226, 226); border-bottom-color: rgb(226, 226, 226); border-left-color: rgb(226, 226, 226); width: 143px; line-height: 100px; "&gt;&lt;a href="http://www.adafruit.com/index.php?main_page=product_info&amp;amp;cPath=26&amp;amp;products_id=95" style="color: rgb(94, 134, 164); text-decoration: none; "&gt;&lt;img src="http://www.adafruit.com/images/yboxtvbox.jpg" alt="YBox2 Kit" title=" YBox2 Kit " width="133" height="99" style="border-top-style: none; border-right-style: none; border-bottom-style: none; border-left-style: none; border-width: initial; border-color: initial; display: inline; vertical-align: middle; margin-top: 5px; margin-right: 5px; margin-bottom: 5px; margin-left: 5px; " /&gt;&lt;br /&gt;&lt;/a&gt;&lt;/div&gt;&lt;div class="additionalImages centeredContent" style="vertical-align: top; margin-top: 1em; margin-right: 5px; margin-bottom: 1em; margin-left: 0em; text-align: center; display: inline; float: left; border-top-width: 1px; border-right-width: 1px; border-bottom-width: 1px; border-left-width: 1px; border-top-style: solid; border-right-style: solid; border-bottom-style: solid; border-left-style: solid; border-top-color: rgb(226, 226, 226); border-right-color: rgb(226, 226, 226); border-bottom-color: rgb(226, 226, 226); border-left-color: rgb(226, 226, 226); width: 143px; line-height: 100px; "&gt;&lt;a href="http://www.adafruit.com/index.php?main_page=product_info&amp;amp;cPath=26&amp;amp;products_id=95" style="color: rgb(94, 134, 164); text-decoration: none; "&gt;&lt;img src="http://www.adafruit.com/images/yboxtvinfo.jpg" alt="YBox2 Kit" title=" YBox2 Kit " width="133" height="96" style="border-top-style: none; border-right-style: none; border-bottom-style: none; border-left-style: none; border-width: initial; border-color: initial; display: inline; vertical-align: middle; margin-top: 5px; margin-right: 5px; margin-bottom: 5px; margin-left: 5px; " /&gt;&lt;br /&gt;&lt;/a&gt;&lt;/div&gt;&lt;br /&gt;&lt;div class="additionalImages centeredContent" style="vertical-align: top; margin-top: 1em; margin-right: 5px; margin-bottom: 1em; margin-left: 0em; text-align: center; display: inline; float: left; border-top-width: 1px; border-right-width: 1px; border-bottom-width: 1px; border-left-width: 1px; border-top-style: solid; border-right-style: solid; border-bottom-style: solid; border-left-style: solid; border-top-color: rgb(226, 226, 226); border-right-color: rgb(226, 226, 226); border-bottom-color: rgb(226, 226, 226); border-left-color: rgb(226, 226, 226); width: 143px; line-height: 100px; "&gt;&lt;a href="http://www.adafruit.com/index.php?main_page=product_info&amp;amp;cPath=26&amp;amp;products_id=95" style="color: rgb(94, 134, 164); text-decoration: none; "&gt;&lt;img src="http://www.adafruit.com/images/yboxtvtwit.jpg" alt="YBox2 Kit" title=" YBox2 Kit " width="133" height="95" style="border-top-style: none; border-right-style: none; border-bottom-style: none; border-left-style: none; border-width: initial; border-color: initial; display: inline; vertical-align: middle; margin-top: 5px; margin-right: 5px; margin-bottom: 5px; margin-left: 5px; " /&gt;&lt;br /&gt;&lt;/a&gt;&lt;/div&gt;&lt;div class="additionalImages centeredContent" style="vertical-align: top; margin-top: 1em; margin-right: 5px; margin-bottom: 1em; margin-left: 0em; text-align: center; display: inline; float: left; border-top-width: 1px; border-right-width: 1px; border-bottom-width: 1px; border-left-width: 1px; border-top-style: solid; border-right-style: solid; border-bottom-style: solid; border-left-style: solid; border-top-color: rgb(226, 226, 226); border-right-color: rgb(226, 226, 226); border-bottom-color: rgb(226, 226, 226); border-left-color: rgb(226, 226, 226); width: 143px; line-height: 100px; "&gt;&lt;a href="http://www.adafruit.com/index.php?main_page=product_info&amp;amp;cPath=26&amp;amp;products_id=95" style="color: rgb(94, 134, 164); text-decoration: none; "&gt;&lt;img src="http://www.adafruit.com/images/yboxtv.jpg" alt="YBox2 Kit" title=" YBox2 Kit " width="133" height="99" style="border-top-style: none; border-right-style: none; border-bottom-style: none; border-left-style: none; border-width: initial; border-color: initial; display: inline; vertical-align: middle; margin-top: 5px; margin-right: 5px; margin-bottom: 5px; margin-left: 5px; " /&gt;&lt;br /&gt;&lt;/a&gt;&lt;/div&gt;&lt;br /&gt;&lt;/div&gt;&lt;/div&gt;&lt;span class="Apple-style-span" style="font-size: 12px;"&gt;&lt;b&gt;&lt;br /&gt;&lt;/b&gt;&lt;/span&gt;&lt;/div&gt;&lt;div id="productDescription" class="productGeneral biggerText" style="font-size: 1.1em; padding-top: 0.5em; padding-right: 0.5em; padding-bottom: 0.5em; padding-left: 0.5em; float: left; margin-left: 15px; width: 500px; "&gt;The YBox2 is a DIY networked set-top box. Connect it to your TV and you can design customized content to be delivered direct from the Internet.&lt;p style="padding-top: 0.5em; padding-right: 0.5em; padding-bottom: 0.5em; padding-left: 0.5em; "&gt;This project is great for people who want a new platform to experiment with. The video and Internet cores are ready to go and easy to work with. We have some example widgets that demonstrate the YBox2's capability, and the whole project is open source so you can start hacking your own. If you've ever been curious about the &lt;a href="http://www.parallax.com/Default.aspx?tabid=407" style="color: rgb(94, 134, 164); text-decoration: none; font-weight: bold; "&gt;Parallax Propeller chip&lt;/a&gt;, the YBox2 is a perky little platform with tons of accessories.&lt;/p&gt;&lt;p style="padding-top: 0.5em; padding-right: 0.5em; padding-bottom: 0.5em; padding-left: 0.5em; "&gt;The kit comes with PCB and all necessary electronic parts, unassembled. Assembly is not difficult, but considering the number of components, it will take a couple hours to complete. Power supply, mint tin, TV, tools and cables not included.&lt;/p&gt;&lt;p style="padding-top: 0.5em; padding-right: 0.5em; padding-bottom: 0.5em; padding-left: 0.5em; "&gt;Details:&lt;/p&gt;&lt;ul&gt;&lt;li&gt;Built using the new Parallax Propeller chip - 8 cores, 32KB of RAM running at 80MHz!&lt;/li&gt;&lt;li&gt;Works with any NTSC or PAL TV that has composite (RCA) input&lt;/li&gt;&lt;li&gt;Works with any network router that supports DHCP, just plug in an Ethernet cable and you're ready to go&lt;/li&gt;&lt;li&gt;Kit comes with an Internet-enabled bootloader already installed, so you can upload new programs directly from your computer, without a special cable or prop-plug (Propeller chip programmer)&lt;/li&gt;&lt;li&gt;IR receiver for using a TV remote control&lt;/li&gt;&lt;li&gt;Full color status LED&lt;/li&gt;&lt;li&gt;Piezo Buzzer for generating beeps, alarms, and tones&lt;/li&gt;&lt;li&gt;Pushbutton for input&lt;/li&gt;&lt;li&gt;Lots of &lt;a href="http://ladyada.net/make/ybox2/widgets.html" style="color: rgb(94, 134, 164); text-decoration: none; font-weight: bold; "&gt;examples widgets&lt;/a&gt; to try out&lt;/li&gt;&lt;li&gt;Fits in an altoids tin!&lt;/li&gt;&lt;/ul&gt;&lt;p style="padding-top: 0.5em; padding-right: 0.5em; padding-bottom: 0.5em; padding-left: 0.5em; "&gt;Theres tons of information at the &lt;a href="http://www.ladyada.net/make/ybox2" style="color: rgb(94, 134, 164); text-decoration: none; font-weight: bold; "&gt;YBox2 site&lt;/a&gt; so go check that out! YBox2 is a collaboration with &lt;a href="http://www.deepdarc.com/ybox2" style="color: rgb(94, 134, 164); text-decoration: none; font-weight: bold; "&gt;Robert Quattlebaum&lt;/a&gt; and based off work by &lt;a href="http://www.uncommonprojects.com/" style="color: rgb(94, 134, 164); text-decoration: none; font-weight: bold; "&gt;Uncommon Projects&lt;/a&gt;.&lt;/p&gt;&lt;/div&gt;&lt;/div&gt;&lt;/div&gt;&lt;/span&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/4984480909360655633-1390086277479199559?l=worldinthenet.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://worldinthenet.blogspot.com/feeds/1390086277479199559/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://worldinthenet.blogspot.com/2010/12/ybox2-kit-v11.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/4984480909360655633/posts/default/1390086277479199559'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/4984480909360655633/posts/default/1390086277479199559'/><link rel='alternate' type='text/html' href='http://worldinthenet.blogspot.com/2010/12/ybox2-kit-v11.html' title='YBox2 Kit - v1.1'/><author><name>Taojun</name><uri>http://www.blogger.com/profile/12946690813153575136</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-4984480909360655633.post-913668282894958683</id><published>2010-03-20T14:47:00.001-07:00</published><updated>2010-03-20T14:47:39.764-07:00</updated><title type='text'>[zz]How to Dual Boot Windows 7 and Linux using BCDEdit</title><content type='html'>&lt;span class="Apple-style-span" style="font-family: 'Lucida Grande', Verdana, Arial, sans-serif; font-size: 12px; color: rgb(146, 146, 128); "&gt;&lt;h2 style="font-family: 'Trebuchet MS', 'Lucida Grande', Verdana, Arial, sans-serif; font-weight: bold; font-size: 1.6em; text-decoration: none; margin-top: 30px; margin-right: 0px; margin-bottom: 10px; margin-left: 0px; "&gt;&lt;a href="http://www.iceflatline.com/2009/09/how-to-dual-boot-windows-7-and-linux-using-bcdedit/"&gt;http://www.iceflatline.com/2009/09/how-to-dual-boot-windows-7-and-linux-using-bcdedit/&lt;/a&gt;&lt;/h2&gt;&lt;h2 style="font-family: 'Trebuchet MS', 'Lucida Grande', Verdana, Arial, sans-serif; font-weight: bold; font-size: 1.6em; text-decoration: none; margin-top: 30px; margin-right: 0px; margin-bottom: 10px; margin-left: 0px; "&gt;&lt;span style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; "&gt;&lt;a href="http://www.iceflatline.com/category/windows/" title="View all posts in Windows" rel="category tag" style="color: rgb(146, 146, 128); text-decoration: underline; "&gt;Windows&lt;/a&gt; &lt;/span&gt;→ &lt;a href="http://www.iceflatline.com/2009/09/how-to-dual-boot-windows-7-and-linux-using-bcdedit/" rel="bookmark" title="Permanent Link to How to Dual Boot Windows 7 and Linux using BCDEdit" style="color: rgb(0, 102, 153); text-decoration: none; "&gt;How to Dual Boot Windows 7 and Linux using BCDEdit&lt;/a&gt;&lt;/h2&gt;&lt;p class="comment_edit" style="float: right; margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; "&gt;&lt;span class="comment_link" style="background-image: url(http://www.iceflatline.com/wp-content/themes/dreamline/icons/action_im.gif); background-attachment: scroll; background-origin: initial; background-clip: initial; background-color: initial; padding-left: 20px; margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; background-position: 0% 0%; background-repeat: no-repeat no-repeat; "&gt;&lt;a href="http://www.iceflatline.com/2009/09/how-to-dual-boot-windows-7-and-linux-using-bcdedit/#comments" title="Comment on How to Dual Boot Windows 7 and Linux using BCDEdit" style="color: rgb(146, 146, 128); text-decoration: none; "&gt;14 Comments&lt;/a&gt;&lt;/span&gt;&lt;/p&gt;&lt;div class="time_link" style="background-image: url(http://www.iceflatline.com/wp-content/themes/dreamline/icons/clock.gif); background-attachment: scroll; background-origin: initial; background-clip: initial; background-color: initial; padding-left: 20px; background-position: 0% 0%; background-repeat: no-repeat no-repeat; "&gt;September 16th, 2009 by iceflatline&lt;/div&gt;&lt;div class="entry" style="line-height: 1.4em; "&gt;&lt;p&gt;This post will describe how to set up a system that can boot into Windows 7 or a Linux distribution. The Window 7 Boot Configuration Data Editor (BCDEdit) will be used to configure Windows 7 to display a menu at boot time that will allow the user to choose between Windows 7 and a Linux distribution of your choice.&lt;/p&gt;&lt;p&gt;To help explain the steps involved, we’ll use an 80 GB hard drive with Windows 7 already installed. We’ll then re-partition the drive using Gnome Partition Editor (GParted) in order to add Ubuntu or Fedora. We’ll then use BCDedit to add a boot menu option for our Linux distribution. All steps involved assume you have a functioning CD drive (or USB drive if you’d prefer) that the system can boot from. The versions for the software used in this post were as follows:&lt;/p&gt;&lt;p&gt;Fedora v11&lt;br /&gt;GParted v0.4.6-1&lt;br /&gt;Ubuntu v9.04&lt;br /&gt;Windows 7 RC Build 7100&lt;/p&gt;&lt;p&gt;Oh… and while I’ve never encountered a situation where GParted destroyed existing disk data, make sure you backup any critical files before you proceed.&lt;/p&gt;&lt;p&gt;So, let’s get started.&lt;/p&gt;&lt;p&gt;&lt;strong&gt;Partitioning for Ubuntu&lt;/strong&gt;&lt;/p&gt;&lt;p&gt;The first thing we’ll want to do is re-partition our 80GB drive. &lt;a href="http://gparted.sourceforge.net/download.php" target="_blank" style="color: rgb(0, 102, 153); text-decoration: none; "&gt;Download a copy of GParted Live&lt;/a&gt; and burn it to a CD (or place it on a bootable USB drive). Next, boot the system using the GParted disk. After accepting the default settings for keymap, language, and X-window configuration, you should arrive at the GParted desktop (See Figure 1).&lt;/p&gt;&lt;p class="center" style="text-align: center; "&gt;&lt;a href="http://www.iceflatline.com/wp-content/images/gparted-desktop.png" target="_blank" rel="nofollow" style="color: rgb(0, 102, 153); text-decoration: none; "&gt;&lt;img src="http://www.iceflatline.com/wp-content/images/gparted-desktop-small.png" title="Screenshot of the GParted Desktop" alt="Screenshot of the GParted Desktop" style="padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; max-width: 100%; border-top-style: none; border-right-style: none; border-bottom-style: none; border-left-style: none; border-width: initial; border-color: initial; " /&gt;&lt;/a&gt;&lt;/p&gt;&lt;div class="caption" style="text-align: center; font-style: italic; "&gt;Figure 1&lt;/div&gt;&lt;p&gt;You’ll notice that GParted is reporting ~74 GB of total disk space (1 Gigabyte = 1,073,741,824 Bytes) and that Windows 7 currently occupies all of that space using two primary partitions: one small boot partition at device /dev/hdd1 and the remaining operating system at device /dev/hdd2. Eventually, we will have five partitions in total: the two Windows 7 partitions just mentioned, as well as ones for the Ubuntu operating system and Linux swap. We’ll also create a FAT32 partition for sharing data between Windows 7 and Ubuntu. You’ll need to determine how much disk space you want to allocate to each of these partitions based on your disk size, but for our 80 GB example disk, we’ll use the following partition layout:&lt;/p&gt;&lt;p&gt;Windows 7: ~100MB (Windows 7 bootloader)&lt;br /&gt;Windows 7: ~40 GB&lt;br /&gt;Ubuntu: ~24 GB&lt;br /&gt;Linux-Swap: ~1 GB&lt;br /&gt;FAT32: ~9 GB&lt;/p&gt;&lt;p&gt;Let’s leave the Windows 7 boot partition at /dev/hdd1 alone and reduce the partition at /dev/hdd2 to ~40GB. Highlight /dev/hdd2 by left-clicking on it and then select “Resize/Move.” This will bring up a new window where the new size for the partition can be entered manually, or you can left-click and hold the graphical bar to resize the partition. Make sure the free space is following /dev/hdd2. Now hit “Resize/Move” to complete the resizing (See Figure 2).&lt;/p&gt;&lt;p class="center" style="text-align: center; "&gt;&lt;a href="http://www.iceflatline.com/wp-content/images/gparted-resize.png" target="_blank" rel="nofollow" style="color: rgb(0, 102, 153); text-decoration: none; "&gt;&lt;img src="http://www.iceflatline.com/wp-content/images/gparted-resize-small.png" title="Screenshot of a Partition Resized using GParted" alt="Screenshot of a Partition Resized using GParted" style="padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; max-width: 100%; border-top-style: none; border-right-style: none; border-bottom-style: none; border-left-style: none; border-width: initial; border-color: initial; " /&gt;&lt;/a&gt;&lt;/p&gt;&lt;div class="caption" style="text-align: center; font-style: italic; "&gt;Figure 2&lt;/div&gt;&lt;p&gt;Once the size of /dev/hdd2 is reduced, you’ll see that the remaining space is now labeled unallocated. Left-click this space to highlight it and then select “New” to create a new partition. Make this partition a primary partition and the file system ext3. Now, reduce the partition to ~29 GB – you can do this by typing in the value in the New Size field or by moving the slider to the left until you reach the desired size. When complete, select “Add” (See Figure 3).&lt;/p&gt;&lt;p class="center" style="text-align: center; "&gt;&lt;a href="http://www.iceflatline.com/wp-content/images/gparted-new.png" target="_blank" rel="nofollow" style="color: rgb(0, 102, 153); text-decoration: none; "&gt;&lt;img src="http://www.iceflatline.com/wp-content/images/gparted-new-small.png" title="Screenshot of a New Partition Created Using GParted" alt="Screenshot of a New Partition Created Using GParted" style="padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; max-width: 100%; border-top-style: none; border-right-style: none; border-bottom-style: none; border-left-style: none; border-width: initial; border-color: initial; " /&gt;&lt;/a&gt;&lt;/p&gt;&lt;div class="caption" style="text-align: center; font-style: italic; "&gt;Figure 3&lt;/div&gt;&lt;p&gt;The disk is limited to four primary partitions, so in the remaining unallocated space we’ll need to create a new extended partition instead of a primary partition. Once the new extended partition is created, left-click to highlight it and create two new logical partitions following the steps above. One should be linux-swap and sized to 1 GB; the other (in the remaining space) will be our FAT32 partition. When complete, you should have a partition layout that resembles Figure 4.&lt;/p&gt;&lt;p class="center" style="text-align: center; "&gt;&lt;a href="http://www.iceflatline.com/wp-content/images/gparted-ubuntu1.png" target="_blank" rel="nofollow" style="color: rgb(0, 102, 153); text-decoration: none; "&gt;&lt;img src="http://www.iceflatline.com/wp-content/images/gparted-ubuntu1-small.png" title="Screenshot of New Ubuntu Partition Layout Created Using GParted" alt="Screenshot of New Ubuntu Partition Layout Created Using GParted" style="padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; max-width: 100%; border-top-style: none; border-right-style: none; border-bottom-style: none; border-left-style: none; border-width: initial; border-color: initial; " /&gt;&lt;/a&gt;&lt;/p&gt;&lt;div class="caption" style="text-align: center; font-style: italic; "&gt;Figure 4&lt;/div&gt;&lt;p&gt;Review the newly created partition layout and make any necessary adjustments. You can back out of any changes you’ve made by selecting “Undo Last Operation” or “Clear All Operations” (under the Edit menu). Now select “Apply All Operations” and GParted will proceed with writing the changes to the disk. After a few minutes you should see the re-partitioned drive (See Figure 5).&lt;/p&gt;&lt;p class="center" style="text-align: center; "&gt;&lt;a href="http://www.iceflatline.com/wp-content/images/gparted-ubuntu2.png" target="_blank" rel="nofollow" style="color: rgb(0, 102, 153); text-decoration: none; "&gt;&lt;img src="http://www.iceflatline.com/wp-content/images/gparted-ubuntu2-small.png" title="Screenshot of New Ubuntu Partitions with Device Names Assigned by GParted" alt="Screenshot of New Ubuntu Partitions with Device Names Assigned by GParted" style="padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; max-width: 100%; border-top-style: none; border-right-style: none; border-bottom-style: none; border-left-style: none; border-width: initial; border-color: initial; " /&gt;&lt;/a&gt;&lt;/p&gt;&lt;div class="caption" style="text-align: center; font-style: italic; "&gt;Figure 5&lt;/div&gt;&lt;p&gt;You’ll notice that GParted retained the device designations /dev/hdd1 and /dev/hdd2 for Windows 7 but has now assigned the appropriate device designations to each of our newly minted partitions:&lt;/p&gt;&lt;p&gt;/dev/hdd1 – Windows 7 boot (Primary partition)&lt;br /&gt;/dev/hdd2 – Windows 7 (Primary partition)&lt;br /&gt;/dev/hdd3 – ext3 (Primary partition)&lt;br /&gt;/dev/hdd4 – (Extended partition)&lt;br /&gt;/dev/hdd5 – Linux-Swap (Logical partition)&lt;br /&gt;/dev/hdd6 – FAT32 (Logical partition)&lt;/p&gt;&lt;p&gt;Make note of these partition designations because you will need to refer to them when we install Ubuntu. Now, let’s exit out of GParted and reboot the system. If all went well, you will arrive at the Windows 7 logon screen. Along the way, you may see Windows perform a disk check – don’t worry that’s normal. If you log into Windows 7 and access Explorer or Disk Manager you should see your FAT32 partition.&lt;/p&gt;&lt;p&gt;&lt;strong&gt;Partitioning for Fedora&lt;/strong&gt;&lt;/p&gt;&lt;p&gt;The process for creating partitions for an Fedora 11 install is essentially the same as described for Ubuntu. What does differ, however, is the number and type of the partitions we’ll need. The Fedora 11 operating system utilizes the ext4 file system. Unfortunately, Fedora is incapable of placing its bootloader on the ext4 partition. Therefore, we’ll need to create a small primary partition that Fedora 11 can use to install the bootloader. For our 80 GB example disk, we’ll use the following partition layout. Note the addition of a small 100 MB partition that we will eventually format as ext3 and use for the Fedora bootloader:&lt;/p&gt;&lt;p&gt;Windows 7: ~100MB (Windows 7 bootloader)&lt;br /&gt;Windows 7: ~40 GB&lt;br /&gt;Fedora: ~100MB (Fedora bootloader)&lt;br /&gt;Fedora: ~24 GB&lt;br /&gt;Linux-Swap: ~1 GB&lt;br /&gt;FAT32: ~9 GB&lt;/p&gt;&lt;p&gt;Now, using GParted and following similar steps described above for Ubuntu, create the following partitions (See Figure 6):&lt;/p&gt;&lt;p&gt;/dev/hdd1 – Windows 7 boot (Primary partition)&lt;br /&gt;/dev/hdd2 – Windows 7 (Primary partition)&lt;br /&gt;/dev/hdd3 – ext3 (Primary partition)&lt;br /&gt;/dev/hdd4 – (Extended partition)&lt;br /&gt;/dev.hdd5 – ext4 (Logical partition)&lt;br /&gt;/dev/hdd6 – Linux-Swap (Logical partition)&lt;br /&gt;/dev/hdd7 – FAT32 (Logical partition)&lt;/p&gt;&lt;p class="center" style="text-align: center; "&gt;&lt;a href="http://www.iceflatline.com/wp-content/images/gparted-fedora1.png" target="_blank" rel="nofollow" style="color: rgb(0, 102, 153); text-decoration: none; "&gt;&lt;img src="http://www.iceflatline.com/wp-content/images/gparted-fedora1-small.png" title="Screenshot of a Fedora Partition Layout Using GParted" alt="Screenshot of a Fedora Partition Layout Using GParted" style="padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; max-width: 100%; border-top-style: none; border-right-style: none; border-bottom-style: none; border-left-style: none; border-width: initial; border-color: initial; " /&gt;&lt;/a&gt;&lt;/p&gt;&lt;div class="caption" style="text-align: center; font-style: italic; "&gt;Figure 6&lt;/div&gt;&lt;p&gt;&lt;strong&gt;Installing Ubuntu&lt;/strong&gt;&lt;/p&gt;&lt;p&gt;Now it’s time to install Ubuntu on to the partitions we created with Gparted. &lt;a href="http://www.ubuntu.com/GetUbuntu/download" target="_blank" style="color: rgb(0, 102, 153); text-decoration: none; "&gt;Download a copy of Ubuntu Desktop&lt;/a&gt; and burn it to a CD (or place it on a bootable USB drive). Boot the system using the Ubuntu disk. Double-click the install icon on the desktop to get started. Continue through the installation process until you arrive at “Prepare disk space” and select “Specify partitions manually (advanced)” to advance to the “Prepare partitions” screen (See Figure 7). This is where we’ll instruct Ubuntu which mount points and file systems to use on the partitions we created. You’ll notice that the Ubuntu installer references the partitions using the /dev/sda1, 2, 3…, etc. device labels typically used for SCSI, SATA, and USB drives. These correspond directly to the /dev/hdd1, 2, 3…, etc. device labels used by Gparted (e.g., device /dev/hdd3 = device /dev/sda3).&lt;/p&gt;&lt;p class="center" style="text-align: center; "&gt;&lt;a href="http://www.iceflatline.com/wp-content/images/ubuntu-install1.png" target="_blank" rel="nofollow" style="color: rgb(0, 102, 153); text-decoration: none; "&gt;&lt;img src="http://www.iceflatline.com/wp-content/images/ubuntu-install1-small.png" title="Screenshot of the Ubuntu Partition Preparation Screen" alt="Screenshot of the Ubuntu Partition Preparation Screen" style="padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; max-width: 100%; border-top-style: none; border-right-style: none; border-bottom-style: none; border-left-style: none; border-width: initial; border-color: initial; " /&gt;&lt;/a&gt;&lt;/p&gt;&lt;div class="caption" style="text-align: center; font-style: italic; "&gt;Figure 7&lt;/div&gt;&lt;p&gt;Left-click to highlight /dev/sda3 and then select “Edit partition.” On the pop-up screen make sure that the ext3 file system is selected and the check box instructing Ubuntu to format the partition is checked. Device /dev/sda3 will serve as the root partition for Ubuntu so we’ll set the mount point to / from the list of choices in the drop down menu. Now select “Okay” to accept the changes (See Figure 8).&lt;/p&gt;&lt;p class="center" style="text-align: center; "&gt;&lt;a href="http://www.iceflatline.com/wp-content/images/ubuntu-install2.png" target="_blank" rel="nofollow" style="color: rgb(0, 102, 153); text-decoration: none; "&gt;&lt;img src="http://www.iceflatline.com/wp-content/images/ubuntu-install2-small.png" title="Screenshot of the Ubuntu Edit Partition Screen" alt="Screenshot of the Ubuntu Edit Partition Screen" style="padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; max-width: 100%; border-top-style: none; border-right-style: none; border-bottom-style: none; border-left-style: none; border-width: initial; border-color: initial; " /&gt;&lt;/a&gt;&lt;/p&gt;&lt;div class="caption" style="text-align: center; font-style: italic; "&gt;Figure 8&lt;/div&gt;&lt;p&gt;Following similar steps, let’s move on to /dev/sda5 and set the mount point to linux-swap. There is no need to format this partition. Finally, device /dev/sda6 will serve as our FAT32 partition to share files between our Windows 7 and Linux systems so make sure the FAT32 file system is selected and set the mount point to /os-share (you can choose and alternative name if desired). There is also no need to format this partition. Do a final review and then select “Forward” to continue to the “Ready to install” screen (See Figure 9).&lt;/p&gt;&lt;p class="center" style="text-align: center; "&gt;&lt;a href="http://www.iceflatline.com/wp-content/images/ubuntu-install3.png" target="_blank" rel="nofollow" style="color: rgb(0, 102, 153); text-decoration: none; "&gt;&lt;img src="http://www.iceflatline.com/wp-content/images/ubuntu-install3-small.png" title="Screenshot of the Ubuntu Confirm Partition Screen" alt="Screenshot of the Ubuntu Confirm Partition Screen" style="padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; max-width: 100%; border-top-style: none; border-right-style: none; border-bottom-style: none; border-left-style: none; border-width: initial; border-color: initial; " /&gt;&lt;/a&gt;&lt;/p&gt;&lt;div class="caption" style="text-align: center; font-style: italic; "&gt;Figure 9&lt;/div&gt;&lt;p&gt;This next step is critical. We need to tell Ubuntu where to install its bootloader (GRUB). We DO NOT want to install GRUB on /dev/sda, as that would overwrite our disk’s Master Boot Record, nor do we want to install it on /dev/sda1, as that is being used for the Windows 7 boot configuration data. Instead, let’s have Ubuntu install GRUB on the partition that will contain the Ubuntu operating system – in our case /dev/sda3. To do this, left-click on the tab that says “Advanced.” This will bring up a pop-up screen where we can specify the location for the bootloader (See Figure 10).&lt;/p&gt;&lt;p class="center" style="text-align: center; "&gt;&lt;a href="http://www.iceflatline.com/wp-content/images/ubuntu-install4.png" target="_blank" rel="nofollow" style="color: rgb(0, 102, 153); text-decoration: none; "&gt;&lt;img src="http://www.iceflatline.com/wp-content/images/ubuntu-install4-small.png" title="Screenshot of the Ubuntu Bootloader Install Screen" alt="Screenshot of the Ubuntu Bootloader Install Screen" style="padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; max-width: 100%; border-top-style: none; border-right-style: none; border-bottom-style: none; border-left-style: none; border-width: initial; border-color: initial; " /&gt;&lt;/a&gt;&lt;/p&gt;&lt;div class="caption" style="text-align: center; font-style: italic; "&gt;Figure 10&lt;/div&gt;&lt;p&gt;First, make sure that the check box for installing the bootloader is checked. Next, we need to place GRUB on the same partition Ubuntu will be installed on. GRUB starts counting disk partitions from the beginning of the disk starting with 0 so let’s change (hd0) to (hd0,2). That will tell Ubuntu to install GRUB on the third partition of our disk (/dev/sda3). Now select “Okay” and continue with the Ubuntu installation. When the install completes you’ll be asked to reboot the system. If all went well, you will arrive once again arrive at the Windows 7 logon screen.&lt;/p&gt;&lt;p&gt;&lt;strong&gt;Installing Fedora&lt;/strong&gt;&lt;/p&gt;&lt;p&gt;If you’re installing Fedora you’ll follow similar steps described in the Ubuntu install above.&lt;a href="http://fedoraproject.org/get-fedora" target="_blank" style="color: rgb(0, 102, 153); text-decoration: none; "&gt;Download a copy of Fedora Desktop&lt;/a&gt; and burn it to a CD (or place it on a bootable USB drive). Boot the system using the Fedora disk and double-click on the install icon on the desktop to get started. Continue through the installation process until you arrive at Fedora’s disk partitioner, then select “Create custom layout” from the drop down menu list and select “Next.” (See Figure 11).&lt;/p&gt;&lt;p class="center" style="text-align: center; "&gt;&lt;a href="http://www.iceflatline.com/wp-content/images/fedora-install1.png" target="_blank" rel="nofollow" style="color: rgb(0, 102, 153); text-decoration: none; "&gt;&lt;img src="http://www.iceflatline.com/wp-content/images/fedora-install1-small.png" title="Screenshot of the Fedora Partition Selection Screen" alt="Screenshot of the Fedora Partition Selection Screen" style="padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; max-width: 100%; border-top-style: none; border-right-style: none; border-bottom-style: none; border-left-style: none; border-width: initial; border-color: initial; " /&gt;&lt;/a&gt;&lt;/p&gt;&lt;div class="caption" style="text-align: center; font-style: italic; "&gt;Figure 11&lt;/div&gt;&lt;p&gt;Scroll down the list of devices until you find /dev/sda3 (that’s the small primary partition we created using Gparted), left-click to highlight it and select “Edit.” In the pop-up screen chose /boot as the mount point and format the partition as ext3 (See Figure 12). When finished, select “Okay.” Next, highlight and edit /dev/sda5. This partition will contain the Fedora operating system so make sure to choose / for the mount point and format as ext4. Repeat these steps for the /dev/sda6 and /dev/sda7 – these will be used for our swap and FAT32 partitions respectively. Make sure to choose vfat (FAT32) for the /dev/sda7 partition and set the mount point to /os-share (you can choose and alternative name if desired).&lt;/p&gt;&lt;p class="center" style="text-align: center; "&gt;&lt;a href="http://www.iceflatline.com/wp-content/images/fedora-install2.png" target="_blank" rel="nofollow" style="color: rgb(0, 102, 153); text-decoration: none; "&gt;&lt;img src="http://www.iceflatline.com/wp-content/images/fedora-install2-small.png" title="Screenshot of the Fedora Edit Partition Screen" alt="Screenshot of the Fedora Edit Partition Screen" style="padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; max-width: 100%; border-top-style: none; border-right-style: none; border-bottom-style: none; border-left-style: none; border-width: initial; border-color: initial; " /&gt;&lt;/a&gt;&lt;/p&gt;&lt;div class="caption" style="text-align: center; font-style: italic; "&gt;Figure 12&lt;/div&gt;&lt;p&gt;When complete, select “Next” and do a final review of these partition changes in the pop-up screen, then select “Format.” Confirm the choices by selecting “Write changes to disk.” At this point you will be presented with some choices for where Fedora should install its bootloader (GRUB). This next step is critical. We DO NOT want to install the GRUB to /dev/sda as that will overwrite our disk’s Master Boot Record. Instead, let’s have Fedora install GRUB on the same partition as the Fedora boot partition – in our case /dev/sda3. To do this, left-click on the tab that says “Change device.” This will bring up a pop-up screen where we can specify location for the boot partition (See Figure 13).&lt;/p&gt;&lt;p class="center" style="text-align: center; "&gt;&lt;a href="http://www.iceflatline.com/wp-content/images/fedora-install3.png" target="_blank" rel="nofollow" style="color: rgb(0, 102, 153); text-decoration: none; "&gt;&lt;img src="http://www.iceflatline.com/wp-content/images/fedora-install3-small.png" title="Screenshot of the Fedora Bootloader Installation Screen" alt="Screenshot of the Fedora Bootloader Installation Screen" style="padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; max-width: 100%; border-top-style: none; border-right-style: none; border-bottom-style: none; border-left-style: none; border-width: initial; border-color: initial; " /&gt;&lt;/a&gt;&lt;/p&gt;&lt;div class="caption" style="text-align: center; font-style: italic; "&gt;Figure 13&lt;/div&gt;&lt;p&gt;When finished, select “Next” and Fedora will write the changes to disk and complete the install. After you reboot, if all went well, you will arrive at the Windows 7 logon screen.&lt;/p&gt;&lt;p&gt;&lt;strong&gt;Configuring for Dual Boot&lt;/strong&gt;&lt;/p&gt;&lt;p&gt;Now that we have our disk partitioned and Fedora or Ubuntu installed, let’s set up our system to boot Windows 7 or the Linux distribution. This will involve copying the first 512 bytes of our Linux boot partition to Windows 7 and then use that file, and BCDEdit, to configure Windows 7 to display a menu at boot time that will give you a choice between Windows 7 and Linux.&lt;/p&gt;&lt;p&gt;Boot the system again using the Gparted disk and let’s make a mount point for the FAT32 share partition we created. Open up a terminal in Gparted and enter the following:&lt;/p&gt;&lt;div id="highlighter_298118" class="syntaxhighlighter nogutter  " style="margin-top: 1em !important; margin-right: 0px !important; margin-bottom: 1em !important; margin-left: 0px !important; padding-top: 1px !important; padding-right: 1px !important; padding-bottom: 1px !important; padding-left: 1px !important; border-top-width: 0px !important; border-right-width: 0px !important; border-bottom-width: 0px !important; border-left-width: 0px !important; border-style: initial !important; border-color: initial !important; outline-width: 0px !important; outline-style: initial !important; outline-color: initial !important; background-image: none !important; background-attachment: initial !important; background-origin: initial !important; background-clip: initial !important; background-color: rgb(15, 25, 42) !important; text-align: left !important; float: none !important; vertical-align: baseline !important; position: relative !important; left: auto !important; top: auto !important; right: auto !important; bottom: auto !important; height: auto !important; width: 584px; line-height: 1.1em !important; font-family: Consolas, 'Bitstream Vera Sans Mono', 'Courier New', Courier, monospace !important; font-weight: normal !important; font-style: normal !important; font-size: 1em !important; direction: ltr !important; background-position: initial initial !important; background-repeat: initial initial !important; "&gt;&lt;div class="lines" style="margin-top: 0px !important; margin-right: 0px !important; margin-bottom: 0px !important; margin-left: 0px !important; padding-top: 0px !important; padding-right: 0px !important; padding-bottom: 0px !important; padding-left: 0px !important; border-top-width: 0px !important; border-right-width: 0px !important; border-bottom-width: 0px !important; border-left-width: 0px !important; border-style: initial !important; border-color: initial !important; outline-width: 0px !important; outline-style: initial !important; outline-color: initial !important; background-image: none !important; background-attachment: initial !important; background-origin: initial !important; background-clip: initial !important; background-color: initial !important; text-align: left !important; float: none !important; vertical-align: baseline !important; position: static !important; left: auto !important; top: auto !important; right: auto !important; bottom: auto !important; height: auto !important; width: auto !important; line-height: 1.1em !important; font-family: Consolas, 'Bitstream Vera Sans Mono', 'Courier New', Courier, monospace !important; font-weight: normal !important; font-style: normal !important; font-size: 1em !important; direction: ltr !important; background-position: initial initial !important; background-repeat: initial initial !important; "&gt;&lt;div class="line alt1" style="margin-top: 0px !important; margin-right: 0px !important; margin-bottom: 0px !important; margin-left: 0px !important; padding-top: 0px !important; padding-right: 0px !important; padding-bottom: 0px !important; padding-left: 0px !important; border-top-width: 0px !important; border-right-width: 0px !important; border-bottom-width: 0px !important; border-left-width: 0px !important; border-style: initial !important; border-color: initial !important; outline-width: 0px !important; outline-style: initial !important; outline-color: initial !important; background-image: none !important; background-attachment: initial !important; background-origin: initial !important; background-clip: initial !important; background-color: rgb(15, 25, 42) !important; text-align: left !important; float: none !important; vertical-align: baseline !important; position: static !important; left: auto !important; top: auto !important; right: auto !important; bottom: auto !important; height: auto !important; width: auto !important; line-height: 1.1em !important; font-family: Consolas, 'Bitstream Vera Sans Mono', 'Courier New', Courier, monospace !important; font-weight: normal !important; font-style: normal !important; font-size: 1em !important; direction: ltr !important; background-position: initial initial !important; background-repeat: initial initial !important; "&gt;&lt;table style="margin-top: 0px !important; margin-right: 0px !important; margin-bottom: 0px !important; margin-left: 0px !important; padding-top: 0px !important; padding-right: 0px !important; padding-bottom: 0px !important; padding-left: 0px !important; border-top-width: 0px !important; border-right-width: 0px !important; border-bottom-width: 0px !important; border-left-width: 0px !important; border-style: initial !important; border-color: initial !important; outline-width: 0px !important; outline-style: initial !important; outline-color: initial !important; background-image: none !important; background-attachment: initial !important; background-origin: initial !important; background-clip: initial !important; background-color: initial !important; text-align: left !important; float: none !important; vertical-align: baseline !important; position: static !important; left: auto !important; top: auto !important; right: auto !important; bottom: auto !important; height: auto !important; width: auto !important; line-height: 1.1em !important; font-family: Consolas, 'Bitstream Vera Sans Mono', 'Courier New', Courier, monospace !important; font-weight: normal !important; font-style: normal !important; font-size: 1em !important; direction: ltr !important; border-collapse: collapse !important; background-position: initial initial !important; background-repeat: initial initial !important; "&gt;&lt;tbody style="margin-top: 0px !important; margin-right: 0px !important; margin-bottom: 0px !important; margin-left: 0px !important; padding-top: 0px !important; padding-right: 0px !important; padding-bottom: 0px !important; padding-left: 0px !important; border-top-width: 0px !important; border-right-width: 0px !important; border-bottom-width: 0px !important; border-left-width: 0px !important; border-style: initial !important; border-color: initial !important; outline-width: 0px !important; outline-style: initial !important; outline-color: initial !important; background-image: none !important; background-attachment: initial !important; background-origin: initial !important; background-clip: initial !important; background-color: initial !important; text-align: left !important; float: none !important; vertical-align: baseline !important; position: static !important; left: auto !important; top: auto !important; right: auto !important; bottom: auto !important; height: auto !important; width: auto !important; line-height: 1.1em !important; font-family: Consolas, 'Bitstream Vera Sans Mono', 'Courier New', Courier, monospace !important; font-weight: normal !important; font-style: normal !important; font-size: 1em !important; direction: ltr !important; background-position: initial initial !important; background-repeat: initial initial !important; "&gt;&lt;tr style="margin-top: 0px !important; margin-right: 0px !important; margin-bottom: 0px !important; margin-left: 0px !important; padding-top: 0px !important; padding-right: 0px !important; padding-bottom: 0px !important; padding-left: 0px !important; border-top-width: 0px !important; border-right-width: 0px !important; border-bottom-width: 0px !important; border-left-width: 0px !important; border-style: initial !important; border-color: initial !important; outline-width: 0px !important; outline-style: initial !important; outline-color: initial !important; background-image: none !important; background-attachment: initial !important; background-origin: initial !important; background-clip: initial !important; background-color: initial !important; text-align: left !important; float: none !important; vertical-align: baseline !important; position: static !important; left: auto !important; top: auto !important; right: auto !important; bottom: auto !important; height: auto !important; width: auto !important; line-height: 1.1em !important; font-family: Consolas, 'Bitstream Vera Sans Mono', 'Courier New', Courier, monospace !important; font-weight: normal !important; font-style: normal !important; font-size: 1em !important; direction: ltr !important; background-position: initial initial !important; background-repeat: initial initial !important; "&gt;&lt;td class="content" style="margin-top: 0px !important; margin-right: 0px !important; margin-bottom: 0px !important; margin-left: 0px !important; padding-top: 0px !important; padding-right: 0px !important; padding-bottom: 0px !important; padding-left: 0.5em !important; border-top-width: 0px !important; border-right-width: 0px !important; border-bottom-width: 0px !important; border-left-width: initial !important; border-style: initial !important; border-color: initial !important; outline-width: 0px !important; outline-style: initial !important; outline-color: initial !important; background-image: none !important; background-attachment: initial !important; background-origin: initial !important; background-clip: initial !important; background-color: initial !important; text-align: left !important; float: none !important; vertical-align: top !important; position: static !important; left: auto !important; top: auto !important; right: auto !important; bottom: auto !important; height: auto !important; width: auto !important; line-height: 1.1em !important; font-family: Consolas, 'Bitstream Vera Sans Mono', 'Courier New', Courier, monospace !important; font-weight: normal !important; font-style: normal !important; font-size: 1em !important; direction: ltr !important; border-left-style: none !important; border-left-color: initial !important; color: rgb(185, 189, 182) !important; background-position: initial initial !important; background-repeat: initial initial !important; "&gt;&lt;code class="functions" style="font: normal normal normal 1.1em/normal 'Courier New', Courier, Fixed; margin-top: 0px !important; margin-right: 0px !important; margin-bottom: 0px !important; margin-left: 0px !important; padding-top: 0px !important; padding-right: 0px !important; padding-bottom: 0px !important; padding-left: 0px !important; border-top-width: 0px !important; border-right-width: 0px !important; border-bottom-width: 0px !important; border-left-width: 0px !important; border-style: initial !important; border-color: initial !important; outline-width: 0px !important; outline-style: initial !important; outline-color: initial !important; background-image: none !important; background-attachment: initial !important; background-origin: initial !important; background-clip: initial !important; background-color: initial !important; text-align: left !important; float: none !important; vertical-align: baseline !important; position: static !important; left: auto !important; top: auto !important; right: auto !important; bottom: auto !important; height: auto !important; width: auto !important; line-height: 1.1em !important; font-family: Consolas, 'Bitstream Vera Sans Mono', 'Courier New', Courier, monospace !important; font-weight: normal !important; font-style: normal !important; font-size: 1em !important; direction: ltr !important; display: inline !important; color: rgb(255, 170, 62) !important; background-position: initial initial !important; background-repeat: initial initial !important; "&gt;mkdir&lt;/code&gt; &lt;code class="plain" style="font: normal normal normal 1.1em/normal 'Courier New', Courier, Fixed; margin-top: 0px !important; margin-right: 0px !important; margin-bottom: 0px !important; margin-left: 0px !important; padding-top: 0px !important; padding-right: 0px !important; padding-bottom: 0px !important; padding-left: 0px !important; border-top-width: 0px !important; border-right-width: 0px !important; border-bottom-width: 0px !important; border-left-width: 0px !important; border-style: initial !important; border-color: initial !important; outline-width: 0px !important; outline-style: initial !important; outline-color: initial !important; background-image: none !important; background-attachment: initial !important; background-origin: initial !important; background-clip: initial !important; background-color: initial !important; text-align: left !important; float: none !important; vertical-align: baseline !important; position: static !important; left: auto !important; top: auto !important; right: auto !important; bottom: auto !important; height: auto !important; width: auto !important; line-height: 1.1em !important; font-family: Consolas, 'Bitstream Vera Sans Mono', 'Courier New', Courier, monospace !important; font-weight: normal !important; font-style: normal !important; font-size: 1em !important; direction: ltr !important; display: inline !important; color: rgb(209, 237, 255) !important; background-position: initial initial !important; background-repeat: initial initial !important; "&gt;/mnt/os-share&lt;/code&gt;&lt;/td&gt;&lt;/tr&gt;&lt;/tbody&gt;&lt;/table&gt;&lt;/div&gt;&lt;/div&gt;&lt;/div&gt;&lt;p&gt;Next, let’s mount the correct device to this directory. Recall from the Gparted partitioning steps above that the FAT32 partition is located at device /dev/hdd6 in the case of Ubuntu and device /dev/hdd7 in the case of Fedora. Assuming Ubuntu then for this example, enter the following:&lt;/p&gt;&lt;div id="highlighter_511199" class="syntaxhighlighter nogutter  " style="margin-top: 1em !important; margin-right: 0px !important; margin-bottom: 1em !important; margin-left: 0px !important; padding-top: 1px !important; padding-right: 1px !important; padding-bottom: 1px !important; padding-left: 1px !important; border-top-width: 0px !important; border-right-width: 0px !important; border-bottom-width: 0px !important; border-left-width: 0px !important; border-style: initial !important; border-color: initial !important; outline-width: 0px !important; outline-style: initial !important; outline-color: initial !important; background-image: none !important; background-attachment: initial !important; background-origin: initial !important; background-clip: initial !important; background-color: rgb(15, 25, 42) !important; text-align: left !important; float: none !important; vertical-align: baseline !important; position: relative !important; left: auto !important; top: auto !important; right: auto !important; bottom: auto !important; height: auto !important; width: 584px; line-height: 1.1em !important; font-family: Consolas, 'Bitstream Vera Sans Mono', 'Courier New', Courier, monospace !important; font-weight: normal !important; font-style: normal !important; font-size: 1em !important; direction: ltr !important; background-position: initial initial !important; background-repeat: initial initial !important; "&gt;&lt;div class="lines" style="margin-top: 0px !important; margin-right: 0px !important; margin-bottom: 0px !important; margin-left: 0px !important; padding-top: 0px !important; padding-right: 0px !important; padding-bottom: 0px !important; padding-left: 0px !important; border-top-width: 0px !important; border-right-width: 0px !important; border-bottom-width: 0px !important; border-left-width: 0px !important; border-style: initial !important; border-color: initial !important; outline-width: 0px !important; outline-style: initial !important; outline-color: initial !important; background-image: none !important; background-attachment: initial !important; background-origin: initial !important; background-clip: initial !important; background-color: initial !important; text-align: left !important; float: none !important; vertical-align: baseline !important; position: static !important; left: auto !important; top: auto !important; right: auto !important; bottom: auto !important; height: auto !important; width: auto !important; line-height: 1.1em !important; font-family: Consolas, 'Bitstream Vera Sans Mono', 'Courier New', Courier, monospace !important; font-weight: normal !important; font-style: normal !important; font-size: 1em !important; direction: ltr !important; background-position: initial initial !important; background-repeat: initial initial !important; "&gt;&lt;div class="line alt1" style="margin-top: 0px !important; margin-right: 0px !important; margin-bottom: 0px !important; margin-left: 0px !important; padding-top: 0px !important; padding-right: 0px !important; padding-bottom: 0px !important; padding-left: 0px !important; border-top-width: 0px !important; border-right-width: 0px !important; border-bottom-width: 0px !important; border-left-width: 0px !important; border-style: initial !important; border-color: initial !important; outline-width: 0px !important; outline-style: initial !important; outline-color: initial !important; background-image: none !important; background-attachment: initial !important; background-origin: initial !important; background-clip: initial !important; background-color: rgb(15, 25, 42) !important; text-align: left !important; float: none !important; vertical-align: baseline !important; position: static !important; left: auto !important; top: auto !important; right: auto !important; bottom: auto !important; height: auto !important; width: auto !important; line-height: 1.1em !important; font-family: Consolas, 'Bitstream Vera Sans Mono', 'Courier New', Courier, monospace !important; font-weight: normal !important; font-style: normal !important; font-size: 1em !important; direction: ltr !important; background-position: initial initial !important; background-repeat: initial initial !important; "&gt;&lt;table style="margin-top: 0px !important; margin-right: 0px !important; margin-bottom: 0px !important; margin-left: 0px !important; padding-top: 0px !important; padding-right: 0px !important; padding-bottom: 0px !important; padding-left: 0px !important; border-top-width: 0px !important; border-right-width: 0px !important; border-bottom-width: 0px !important; border-left-width: 0px !important; border-style: initial !important; border-color: initial !important; outline-width: 0px !important; outline-style: initial !important; outline-color: initial !important; background-image: none !important; background-attachment: initial !important; background-origin: initial !important; background-clip: initial !important; background-color: initial !important; text-align: left !important; float: none !important; vertical-align: baseline !important; position: static !important; left: auto !important; top: auto !important; right: auto !important; bottom: auto !important; height: auto !important; width: auto !important; line-height: 1.1em !important; font-family: Consolas, 'Bitstream Vera Sans Mono', 'Courier New', Courier, monospace !important; font-weight: normal !important; font-style: normal !important; font-size: 1em !important; direction: ltr !important; border-collapse: collapse !important; background-position: initial initial !important; background-repeat: initial initial !important; "&gt;&lt;tbody style="margin-top: 0px !important; margin-right: 0px !important; margin-bottom: 0px !important; margin-left: 0px !important; padding-top: 0px !important; padding-right: 0px !important; padding-bottom: 0px !important; padding-left: 0px !important; border-top-width: 0px !important; border-right-width: 0px !important; border-bottom-width: 0px !important; border-left-width: 0px !important; border-style: initial !important; border-color: initial !important; outline-width: 0px !important; outline-style: initial !important; outline-color: initial !important; background-image: none !important; background-attachment: initial !important; background-origin: initial !important; background-clip: initial !important; background-color: initial !important; text-align: left !important; float: none !important; vertical-align: baseline !important; position: static !important; left: auto !important; top: auto !important; right: auto !important; bottom: auto !important; height: auto !important; width: auto !important; line-height: 1.1em !important; font-family: Consolas, 'Bitstream Vera Sans Mono', 'Courier New', Courier, monospace !important; font-weight: normal !important; font-style: normal !important; font-size: 1em !important; direction: ltr !important; background-position: initial initial !important; background-repeat: initial initial !important; "&gt;&lt;tr style="margin-top: 0px !important; margin-right: 0px !important; margin-bottom: 0px !important; margin-left: 0px !important; padding-top: 0px !important; padding-right: 0px !important; padding-bottom: 0px !important; padding-left: 0px !important; border-top-width: 0px !important; border-right-width: 0px !important; border-bottom-width: 0px !important; border-left-width: 0px !important; border-style: initial !important; border-color: initial !important; outline-width: 0px !important; outline-style: initial !important; outline-color: initial !important; background-image: none !important; background-attachment: initial !important; background-origin: initial !important; background-clip: initial !important; background-color: initial !important; text-align: left !important; float: none !important; vertical-align: baseline !important; position: static !important; left: auto !important; top: auto !important; right: auto !important; bottom: auto !important; height: auto !important; width: auto !important; line-height: 1.1em !important; font-family: Consolas, 'Bitstream Vera Sans Mono', 'Courier New', Courier, monospace !important; font-weight: normal !important; font-style: normal !important; font-size: 1em !important; direction: ltr !important; background-position: initial initial !important; background-repeat: initial initial !important; "&gt;&lt;td class="content" style="margin-top: 0px !important; margin-right: 0px !important; margin-bottom: 0px !important; margin-left: 0px !important; padding-top: 0px !important; padding-right: 0px !important; padding-bottom: 0px !important; padding-left: 0.5em !important; border-top-width: 0px !important; border-right-width: 0px !important; border-bottom-width: 0px !important; border-left-width: initial !important; border-style: initial !important; border-color: initial !important; outline-width: 0px !important; outline-style: initial !important; outline-color: initial !important; background-image: none !important; background-attachment: initial !important; background-origin: initial !important; background-clip: initial !important; background-color: initial !important; text-align: left !important; float: none !important; vertical-align: top !important; position: static !important; left: auto !important; top: auto !important; right: auto !important; bottom: auto !important; height: auto !important; width: auto !important; line-height: 1.1em !important; font-family: Consolas, 'Bitstream Vera Sans Mono', 'Courier New', Courier, monospace !important; font-weight: normal !important; font-style: normal !important; font-size: 1em !important; direction: ltr !important; border-left-style: none !important; border-left-color: initial !important; color: rgb(185, 189, 182) !important; background-position: initial initial !important; background-repeat: initial initial !important; "&gt;&lt;code class="functions" style="font: normal normal normal 1.1em/normal 'Courier New', Courier, Fixed; margin-top: 0px !important; margin-right: 0px !important; margin-bottom: 0px !important; margin-left: 0px !important; padding-top: 0px !important; padding-right: 0px !important; padding-bottom: 0px !important; padding-left: 0px !important; border-top-width: 0px !important; border-right-width: 0px !important; border-bottom-width: 0px !important; border-left-width: 0px !important; border-style: initial !important; border-color: initial !important; outline-width: 0px !important; outline-style: initial !important; outline-color: initial !important; background-image: none !important; background-attachment: initial !important; background-origin: initial !important; background-clip: initial !important; background-color: initial !important; text-align: left !important; float: none !important; vertical-align: baseline !important; position: static !important; left: auto !important; top: auto !important; right: auto !important; bottom: auto !important; height: auto !important; width: auto !important; line-height: 1.1em !important; font-family: Consolas, 'Bitstream Vera Sans Mono', 'Courier New', Courier, monospace !important; font-weight: normal !important; font-style: normal !important; font-size: 1em !important; direction: ltr !important; display: inline !important; color: rgb(255, 170, 62) !important; background-position: initial initial !important; background-repeat: initial initial !important; "&gt;mount&lt;/code&gt; &lt;code class="plain" style="font: normal normal normal 1.1em/normal 'Courier New', Courier, Fixed; margin-top: 0px !important; margin-right: 0px !important; margin-bottom: 0px !important; margin-left: 0px !important; padding-top: 0px !important; padding-right: 0px !important; padding-bottom: 0px !important; padding-left: 0px !important; border-top-width: 0px !important; border-right-width: 0px !important; border-bottom-width: 0px !important; border-left-width: 0px !important; border-style: initial !important; border-color: initial !important; outline-width: 0px !important; outline-style: initial !important; outline-color: initial !important; background-image: none !important; background-attachment: initial !important; background-origin: initial !important; background-clip: initial !important; background-color: initial !important; text-align: left !important; float: none !important; vertical-align: baseline !important; position: static !important; left: auto !important; top: auto !important; right: auto !important; bottom: auto !important; height: auto !important; width: auto !important; line-height: 1.1em !important; font-family: Consolas, 'Bitstream Vera Sans Mono', 'Courier New', Courier, monospace !important; font-weight: normal !important; font-style: normal !important; font-size: 1em !important; direction: ltr !important; display: inline !important; color: rgb(209, 237, 255) !important; background-position: initial initial !important; background-repeat: initial initial !important; "&gt;/dev/hdd6 /mnt/os-share&lt;/code&gt;&lt;/td&gt;&lt;/tr&gt;&lt;/tbody&gt;&lt;/table&gt;&lt;/div&gt;&lt;/div&gt;&lt;/div&gt;&lt;p&gt;Finally, let’s write the first 512 bytes from our Linux boot partition to a file and copy that file to our FAT32 partition. Note that the boot partition in the case of both Ubuntu and Fedora was the same – /dev/sda3:&lt;/p&gt;&lt;div id="highlighter_590953" class="syntaxhighlighter nogutter  " style="margin-top: 1em !important; margin-right: 0px !important; margin-bottom: 1em !important; margin-left: 0px !important; padding-top: 1px !important; padding-right: 1px !important; padding-bottom: 1px !important; padding-left: 1px !important; border-top-width: 0px !important; border-right-width: 0px !important; border-bottom-width: 0px !important; border-left-width: 0px !important; border-style: initial !important; border-color: initial !important; outline-width: 0px !important; outline-style: initial !important; outline-color: initial !important; background-image: none !important; background-attachment: initial !important; background-origin: initial !important; background-clip: initial !important; background-color: rgb(15, 25, 42) !important; text-align: left !important; float: none !important; vertical-align: baseline !important; position: relative !important; left: auto !important; top: auto !important; right: auto !important; bottom: auto !important; height: auto !important; width: 584px; line-height: 1.1em !important; font-family: Consolas, 'Bitstream Vera Sans Mono', 'Courier New', Courier, monospace !important; font-weight: normal !important; font-style: normal !important; font-size: 1em !important; direction: ltr !important; background-position: initial initial !important; background-repeat: initial initial !important; "&gt;&lt;div class="lines" style="margin-top: 0px !important; margin-right: 0px !important; margin-bottom: 0px !important; margin-left: 0px !important; padding-top: 0px !important; padding-right: 0px !important; padding-bottom: 0px !important; padding-left: 0px !important; border-top-width: 0px !important; border-right-width: 0px !important; border-bottom-width: 0px !important; border-left-width: 0px !important; border-style: initial !important; border-color: initial !important; outline-width: 0px !important; outline-style: initial !important; outline-color: initial !important; background-image: none !important; background-attachment: initial !important; background-origin: initial !important; background-clip: initial !important; background-color: initial !important; text-align: left !important; float: none !important; vertical-align: baseline !important; position: static !important; left: auto !important; top: auto !important; right: auto !important; bottom: auto !important; height: auto !important; width: auto !important; line-height: 1.1em !important; font-family: Consolas, 'Bitstream Vera Sans Mono', 'Courier New', Courier, monospace !important; font-weight: normal !important; font-style: normal !important; font-size: 1em !important; direction: ltr !important; background-position: initial initial !important; background-repeat: initial initial !important; "&gt;&lt;div class="line alt1" style="margin-top: 0px !important; margin-right: 0px !important; margin-bottom: 0px !important; margin-left: 0px !important; padding-top: 0px !important; padding-right: 0px !important; padding-bottom: 0px !important; padding-left: 0px !important; border-top-width: 0px !important; border-right-width: 0px !important; border-bottom-width: 0px !important; border-left-width: 0px !important; border-style: initial !important; border-color: initial !important; outline-width: 0px !important; outline-style: initial !important; outline-color: initial !important; background-image: none !important; background-attachment: initial !important; background-origin: initial !important; background-clip: initial !important; background-color: rgb(15, 25, 42) !important; text-align: left !important; float: none !important; vertical-align: baseline !important; position: static !important; left: auto !important; top: auto !important; right: auto !important; bottom: auto !important; height: auto !important; width: auto !important; line-height: 1.1em !important; font-family: Consolas, 'Bitstream Vera Sans Mono', 'Courier New', Courier, monospace !important; font-weight: normal !important; font-style: normal !important; font-size: 1em !important; direction: ltr !important; background-position: initial initial !important; background-repeat: initial initial !important; "&gt;&lt;table style="margin-top: 0px !important; margin-right: 0px !important; margin-bottom: 0px !important; margin-left: 0px !important; padding-top: 0px !important; padding-right: 0px !important; padding-bottom: 0px !important; padding-left: 0px !important; border-top-width: 0px !important; border-right-width: 0px !important; border-bottom-width: 0px !important; border-left-width: 0px !important; border-style: initial !important; border-color: initial !important; outline-width: 0px !important; outline-style: initial !important; outline-color: initial !important; background-image: none !important; background-attachment: initial !important; background-origin: initial !important; background-clip: initial !important; background-color: initial !important; text-align: left !important; float: none !important; vertical-align: baseline !important; position: static !important; left: auto !important; top: auto !important; right: auto !important; bottom: auto !important; height: auto !important; width: auto !important; line-height: 1.1em !important; font-family: Consolas, 'Bitstream Vera Sans Mono', 'Courier New', Courier, monospace !important; font-weight: normal !important; font-style: normal !important; font-size: 1em !important; direction: ltr !important; border-collapse: collapse !important; background-position: initial initial !important; background-repeat: initial initial !important; "&gt;&lt;tbody style="margin-top: 0px !important; margin-right: 0px !important; margin-bottom: 0px !important; margin-left: 0px !important; padding-top: 0px !important; padding-right: 0px !important; padding-bottom: 0px !important; padding-left: 0px !important; border-top-width: 0px !important; border-right-width: 0px !important; border-bottom-width: 0px !important; border-left-width: 0px !important; border-style: initial !important; border-color: initial !important; outline-width: 0px !important; outline-style: initial !important; outline-color: initial !important; background-image: none !important; background-attachment: initial !important; background-origin: initial !important; background-clip: initial !important; background-color: initial !important; text-align: left !important; float: none !important; vertical-align: baseline !important; position: static !important; left: auto !important; top: auto !important; right: auto !important; bottom: auto !important; height: auto !important; width: auto !important; line-height: 1.1em !important; font-family: Consolas, 'Bitstream Vera Sans Mono', 'Courier New', Courier, monospace !important; font-weight: normal !important; font-style: normal !important; font-size: 1em !important; direction: ltr !important; background-position: initial initial !important; background-repeat: initial initial !important; "&gt;&lt;tr style="margin-top: 0px !important; margin-right: 0px !important; margin-bottom: 0px !important; margin-left: 0px !important; padding-top: 0px !important; padding-right: 0px !important; padding-bottom: 0px !important; padding-left: 0px !important; border-top-width: 0px !important; border-right-width: 0px !important; border-bottom-width: 0px !important; border-left-width: 0px !important; border-style: initial !important; border-color: initial !important; outline-width: 0px !important; outline-style: initial !important; outline-color: initial !important; background-image: none !important; background-attachment: initial !important; background-origin: initial !important; background-clip: initial !important; background-color: initial !important; text-align: left !important; float: none !important; vertical-align: baseline !important; position: static !important; left: auto !important; top: auto !important; right: auto !important; bottom: auto !important; height: auto !important; width: auto !important; line-height: 1.1em !important; font-family: Consolas, 'Bitstream Vera Sans Mono', 'Courier New', Courier, monospace !important; font-weight: normal !important; font-style: normal !important; font-size: 1em !important; direction: ltr !important; background-position: initial initial !important; background-repeat: initial initial !important; "&gt;&lt;td class="content" style="margin-top: 0px !important; margin-right: 0px !important; margin-bottom: 0px !important; margin-left: 0px !important; padding-top: 0px !important; padding-right: 0px !important; padding-bottom: 0px !important; padding-left: 0.5em !important; border-top-width: 0px !important; border-right-width: 0px !important; border-bottom-width: 0px !important; border-left-width: initial !important; border-style: initial !important; border-color: initial !important; outline-width: 0px !important; outline-style: initial !important; outline-color: initial !important; background-image: none !important; background-attachment: initial !important; background-origin: initial !important; background-clip: initial !important; background-color: initial !important; text-align: left !important; float: none !important; vertical-align: top !important; position: static !important; left: auto !important; top: auto !important; right: auto !important; bottom: auto !important; height: auto !important; width: auto !important; line-height: 1.1em !important; font-family: Consolas, 'Bitstream Vera Sans Mono', 'Courier New', Courier, monospace !important; font-weight: normal !important; font-style: normal !important; font-size: 1em !important; direction: ltr !important; border-left-style: none !important; border-left-color: initial !important; color: rgb(185, 189, 182) !important; background-position: initial initial !important; background-repeat: initial initial !important; "&gt;&lt;code class="functions" style="font: normal normal normal 1.1em/normal 'Courier New', Courier, Fixed; margin-top: 0px !important; margin-right: 0px !important; margin-bottom: 0px !important; margin-left: 0px !important; padding-top: 0px !important; padding-right: 0px !important; padding-bottom: 0px !important; padding-left: 0px !important; border-top-width: 0px !important; border-right-width: 0px !important; border-bottom-width: 0px !important; border-left-width: 0px !important; border-style: initial !important; border-color: initial !important; outline-width: 0px !important; outline-style: initial !important; outline-color: initial !important; background-image: none !important; background-attachment: initial !important; background-origin: initial !important; background-clip: initial !important; background-color: initial !important; text-align: left !important; float: none !important; vertical-align: baseline !important; position: static !important; left: auto !important; top: auto !important; right: auto !important; bottom: auto !important; height: auto !important; width: auto !important; line-height: 1.1em !important; font-family: Consolas, 'Bitstream Vera Sans Mono', 'Courier New', Courier, monospace !important; font-weight: normal !important; font-style: normal !important; font-size: 1em !important; direction: ltr !important; display: inline !important; color: rgb(255, 170, 62) !important; background-position: initial initial !important; background-repeat: initial initial !important; "&gt;dd&lt;/code&gt; &lt;code class="keyword" style="font: normal normal normal 1.1em/normal 'Courier New', Courier, Fixed; margin-top: 0px !important; margin-right: 0px !important; margin-bottom: 0px !important; margin-left: 0px !important; padding-top: 0px !important; padding-right: 0px !important; padding-bottom: 0px !important; padding-left: 0px !important; border-top-width: 0px !important; border-right-width: 0px !important; border-bottom-width: 0px !important; border-left-width: 0px !important; border-style: initial !important; border-color: initial !important; outline-width: 0px !important; outline-style: initial !important; outline-color: initial !important; background-image: none !important; background-attachment: initial !important; background-origin: initial !important; background-clip: initial !important; background-color: initial !important; text-align: left !important; float: none !important; vertical-align: baseline !important; position: static !important; left: auto !important; top: auto !important; right: auto !important; bottom: auto !important; height: auto !important; width: auto !important; line-height: 1.1em !important; font-family: Consolas, 'Bitstream Vera Sans Mono', 'Courier New', Courier, monospace !important; font-weight: normal !important; font-style: normal !important; font-size: 1em !important; direction: ltr !important; display: inline !important; color: rgb(180, 61, 61) !important; background-position: initial initial !important; background-repeat: initial initial !important; "&gt;if&lt;/code&gt;&lt;code class="plain" style="font: normal normal normal 1.1em/normal 'Courier New', Courier, Fixed; margin-top: 0px !important; margin-right: 0px !important; margin-bottom: 0px !important; margin-left: 0px !important; padding-top: 0px !important; padding-right: 0px !important; padding-bottom: 0px !important; padding-left: 0px !important; border-top-width: 0px !important; border-right-width: 0px !important; border-bottom-width: 0px !important; border-left-width: 0px !important; border-style: initial !important; border-color: initial !important; outline-width: 0px !important; outline-style: initial !important; outline-color: initial !important; background-image: none !important; background-attachment: initial !important; background-origin: initial !important; background-clip: initial !important; background-color: initial !important; text-align: left !important; float: none !important; vertical-align: baseline !important; position: static !important; left: auto !important; top: auto !important; right: auto !important; bottom: auto !important; height: auto !important; width: auto !important; line-height: 1.1em !important; font-family: Consolas, 'Bitstream Vera Sans Mono', 'Courier New', Courier, monospace !important; font-weight: normal !important; font-style: normal !important; font-size: 1em !important; direction: ltr !important; display: inline !important; color: rgb(209, 237, 255) !important; background-position: initial initial !important; background-repeat: initial initial !important; "&gt;=/dev/hdd3 of=/mnt/os-share/linux.bin bs=512 count=1&lt;/code&gt;&lt;/td&gt;&lt;/tr&gt;&lt;/tbody&gt;&lt;/table&gt;&lt;/div&gt;&lt;/div&gt;&lt;/div&gt;&lt;p&gt;Exit Gparted now and reboot to Windows 7. Open the FAT32 partition and you should see the linux.bin file. Copy that file to the root of the Windows boot (active) partition (e.g., C:\). Next, let’s use BCDEdit to modify Windows 7’s boot configuration data to add a boot menu option for our Linux distribution. Administrative privileges are required to use BCDEdit, so navigate to Start-&gt;All Programs-&gt;Accessories, Right-click on Command Prompt and select “Run as administrator.” Okay, now let’s start by creating an entry for our Linux distribution. Note here that you are free to choose another entry name if desired:&lt;/p&gt;&lt;div id="highlighter_837297" class="syntaxhighlighter nogutter  " style="margin-top: 1em !important; margin-right: 0px !important; margin-bottom: 1em !important; margin-left: 0px !important; padding-top: 1px !important; padding-right: 1px !important; padding-bottom: 1px !important; padding-left: 1px !important; border-top-width: 0px !important; border-right-width: 0px !important; border-bottom-width: 0px !important; border-left-width: 0px !important; border-style: initial !important; border-color: initial !important; outline-width: 0px !important; outline-style: initial !important; outline-color: initial !important; background-image: none !important; background-attachment: initial !important; background-origin: initial !important; background-clip: initial !important; background-color: rgb(15, 25, 42) !important; text-align: left !important; float: none !important; vertical-align: baseline !important; position: relative !important; left: auto !important; top: auto !important; right: auto !important; bottom: auto !important; height: auto !important; width: 584px; line-height: 1.1em !important; font-family: Consolas, 'Bitstream Vera Sans Mono', 'Courier New', Courier, monospace !important; font-weight: normal !important; font-style: normal !important; font-size: 1em !important; direction: ltr !important; background-position: initial initial !important; background-repeat: initial initial !important; "&gt;&lt;div class="lines" style="margin-top: 0px !important; margin-right: 0px !important; margin-bottom: 0px !important; margin-left: 0px !important; padding-top: 0px !important; padding-right: 0px !important; padding-bottom: 0px !important; padding-left: 0px !important; border-top-width: 0px !important; border-right-width: 0px !important; border-bottom-width: 0px !important; border-left-width: 0px !important; border-style: initial !important; border-color: initial !important; outline-width: 0px !important; outline-style: initial !important; outline-color: initial !important; background-image: none !important; background-attachment: initial !important; background-origin: initial !important; background-clip: initial !important; background-color: initial !important; text-align: left !important; float: none !important; vertical-align: baseline !important; position: static !important; left: auto !important; top: auto !important; right: auto !important; bottom: auto !important; height: auto !important; width: auto !important; line-height: 1.1em !important; font-family: Consolas, 'Bitstream Vera Sans Mono', 'Courier New', Courier, monospace !important; font-weight: normal !important; font-style: normal !important; font-size: 1em !important; direction: ltr !important; background-position: initial initial !important; background-repeat: initial initial !important; "&gt;&lt;div class="line alt1" style="margin-top: 0px !important; margin-right: 0px !important; margin-bottom: 0px !important; margin-left: 0px !important; padding-top: 0px !important; padding-right: 0px !important; padding-bottom: 0px !important; padding-left: 0px !important; border-top-width: 0px !important; border-right-width: 0px !important; border-bottom-width: 0px !important; border-left-width: 0px !important; border-style: initial !important; border-color: initial !important; outline-width: 0px !important; outline-style: initial !important; outline-color: initial !important; background-image: none !important; background-attachment: initial !important; background-origin: initial !important; background-clip: initial !important; background-color: rgb(15, 25, 42) !important; text-align: left !important; float: none !important; vertical-align: baseline !important; position: static !important; left: auto !important; top: auto !important; right: auto !important; bottom: auto !important; height: auto !important; width: auto !important; line-height: 1.1em !important; font-family: Consolas, 'Bitstream Vera Sans Mono', 'Courier New', Courier, monospace !important; font-weight: normal !important; font-style: normal !important; font-size: 1em !important; direction: ltr !important; background-position: initial initial !important; background-repeat: initial initial !important; "&gt;&lt;table style="margin-top: 0px !important; margin-right: 0px !important; margin-bottom: 0px !important; margin-left: 0px !important; padding-top: 0px !important; padding-right: 0px !important; padding-bottom: 0px !important; padding-left: 0px !important; border-top-width: 0px !important; border-right-width: 0px !important; border-bottom-width: 0px !important; border-left-width: 0px !important; border-style: initial !important; border-color: initial !important; outline-width: 0px !important; outline-style: initial !important; outline-color: initial !important; background-image: none !important; background-attachment: initial !important; background-origin: initial !important; background-clip: initial !important; background-color: initial !important; text-align: left !important; float: none !important; vertical-align: baseline !important; position: static !important; left: auto !important; top: auto !important; right: auto !important; bottom: auto !important; height: auto !important; width: auto !important; line-height: 1.1em !important; font-family: Consolas, 'Bitstream Vera Sans Mono', 'Courier New', Courier, monospace !important; font-weight: normal !important; font-style: normal !important; font-size: 1em !important; direction: ltr !important; border-collapse: collapse !important; background-position: initial initial !important; background-repeat: initial initial !important; "&gt;&lt;tbody style="margin-top: 0px !important; margin-right: 0px !important; margin-bottom: 0px !important; margin-left: 0px !important; padding-top: 0px !important; padding-right: 0px !important; padding-bottom: 0px !important; padding-left: 0px !important; border-top-width: 0px !important; border-right-width: 0px !important; border-bottom-width: 0px !important; border-left-width: 0px !important; border-style: initial !important; border-color: initial !important; outline-width: 0px !important; outline-style: initial !important; outline-color: initial !important; background-image: none !important; background-attachment: initial !important; background-origin: initial !important; background-clip: initial !important; background-color: initial !important; text-align: left !important; float: none !important; vertical-align: baseline !important; position: static !important; left: auto !important; top: auto !important; right: auto !important; bottom: auto !important; height: auto !important; width: auto !important; line-height: 1.1em !important; font-family: Consolas, 'Bitstream Vera Sans Mono', 'Courier New', Courier, monospace !important; font-weight: normal !important; font-style: normal !important; font-size: 1em !important; direction: ltr !important; background-position: initial initial !important; background-repeat: initial initial !important; "&gt;&lt;tr style="margin-top: 0px !important; margin-right: 0px !important; margin-bottom: 0px !important; margin-left: 0px !important; padding-top: 0px !important; padding-right: 0px !important; padding-bottom: 0px !important; padding-left: 0px !important; border-top-width: 0px !important; border-right-width: 0px !important; border-bottom-width: 0px !important; border-left-width: 0px !important; border-style: initial !important; border-color: initial !important; outline-width: 0px !important; outline-style: initial !important; outline-color: initial !important; background-image: none !important; background-attachment: initial !important; background-origin: initial !important; background-clip: initial !important; background-color: initial !important; text-align: left !important; float: none !important; vertical-align: baseline !important; position: static !important; left: auto !important; top: auto !important; right: auto !important; bottom: auto !important; height: auto !important; width: auto !important; line-height: 1.1em !important; font-family: Consolas, 'Bitstream Vera Sans Mono', 'Courier New', Courier, monospace !important; font-weight: normal !important; font-style: normal !important; font-size: 1em !important; direction: ltr !important; background-position: initial initial !important; background-repeat: initial initial !important; "&gt;&lt;td class="content" style="margin-top: 0px !important; margin-right: 0px !important; margin-bottom: 0px !important; margin-left: 0px !important; padding-top: 0px !important; padding-right: 0px !important; padding-bottom: 0px !important; padding-left: 0.5em !important; border-top-width: 0px !important; border-right-width: 0px !important; border-bottom-width: 0px !important; border-left-width: initial !important; border-style: initial !important; border-color: initial !important; outline-width: 0px !important; outline-style: initial !important; outline-color: initial !important; background-image: none !important; background-attachment: initial !important; background-origin: initial !important; background-clip: initial !important; background-color: initial !important; text-align: left !important; float: none !important; vertical-align: top !important; position: static !important; left: auto !important; top: auto !important; right: auto !important; bottom: auto !important; height: auto !important; width: auto !important; line-height: 1.1em !important; font-family: Consolas, 'Bitstream Vera Sans Mono', 'Courier New', Courier, monospace !important; font-weight: normal !important; font-style: normal !important; font-size: 1em !important; direction: ltr !important; border-left-style: none !important; border-left-color: initial !important; color: rgb(185, 189, 182) !important; background-position: initial initial !important; background-repeat: initial initial !important; "&gt;&lt;code class="plain" style="font: normal normal normal 1.1em/normal 'Courier New', Courier, Fixed; margin-top: 0px !important; margin-right: 0px !important; margin-bottom: 0px !important; margin-left: 0px !important; padding-top: 0px !important; padding-right: 0px !important; padding-bottom: 0px !important; padding-left: 0px !important; border-top-width: 0px !important; border-right-width: 0px !important; border-bottom-width: 0px !important; border-left-width: 0px !important; border-style: initial !important; border-color: initial !important; outline-width: 0px !important; outline-style: initial !important; outline-color: initial !important; background-image: none !important; background-attachment: initial !important; background-origin: initial !important; background-clip: initial !important; background-color: initial !important; text-align: left !important; float: none !important; vertical-align: baseline !important; position: static !important; left: auto !important; top: auto !important; right: auto !important; bottom: auto !important; height: auto !important; width: auto !important; line-height: 1.1em !important; font-family: Consolas, 'Bitstream Vera Sans Mono', 'Courier New', Courier, monospace !important; font-weight: normal !important; font-style: normal !important; font-size: 1em !important; direction: ltr !important; display: inline !important; color: rgb(209, 237, 255) !important; background-position: initial initial !important; background-repeat: initial initial !important; "&gt;bcdedit /create /d “Linux” /application BOOTSECTOR&lt;/code&gt;&lt;/td&gt;&lt;/tr&gt;&lt;/tbody&gt;&lt;/table&gt;&lt;/div&gt;&lt;/div&gt;&lt;/div&gt;&lt;p&gt;BCDEdit will return an alphanumeric identifier for this entry that I will refer to as {ID} in the remaining steps. You’ll need to replace {ID} by the actual returned identifier. An example of {ID} is {d7294d4e-9837-11de-99ac-f3f3a79e3e93}. Next, let’s specify which partition hosts a copy of the linux.bin file:&lt;/p&gt;&lt;div id="highlighter_311838" class="syntaxhighlighter nogutter  " style="margin-top: 1em !important; margin-right: 0px !important; margin-bottom: 1em !important; margin-left: 0px !important; padding-top: 1px !important; padding-right: 1px !important; padding-bottom: 1px !important; padding-left: 1px !important; border-top-width: 0px !important; border-right-width: 0px !important; border-bottom-width: 0px !important; border-left-width: 0px !important; border-style: initial !important; border-color: initial !important; outline-width: 0px !important; outline-style: initial !important; outline-color: initial !important; background-image: none !important; background-attachment: initial !important; background-origin: initial !important; background-clip: initial !important; background-color: rgb(15, 25, 42) !important; text-align: left !important; float: none !important; vertical-align: baseline !important; position: relative !important; left: auto !important; top: auto !important; right: auto !important; bottom: auto !important; height: auto !important; width: 584px; line-height: 1.1em !important; font-family: Consolas, 'Bitstream Vera Sans Mono', 'Courier New', Courier, monospace !important; font-weight: normal !important; font-style: normal !important; font-size: 1em !important; direction: ltr !important; background-position: initial initial !important; background-repeat: initial initial !important; "&gt;&lt;div class="lines" style="margin-top: 0px !important; margin-right: 0px !important; margin-bottom: 0px !important; margin-left: 0px !important; padding-top: 0px !important; padding-right: 0px !important; padding-bottom: 0px !important; padding-left: 0px !important; border-top-width: 0px !important; border-right-width: 0px !important; border-bottom-width: 0px !important; border-left-width: 0px !important; border-style: initial !important; border-color: initial !important; outline-width: 0px !important; outline-style: initial !important; outline-color: initial !important; background-image: none !important; background-attachment: initial !important; background-origin: initial !important; background-clip: initial !important; background-color: initial !important; text-align: left !important; float: none !important; vertical-align: baseline !important; position: static !important; left: auto !important; top: auto !important; right: auto !important; bottom: auto !important; height: auto !important; width: auto !important; line-height: 1.1em !important; font-family: Consolas, 'Bitstream Vera Sans Mono', 'Courier New', Courier, monospace !important; font-weight: normal !important; font-style: normal !important; font-size: 1em !important; direction: ltr !important; background-position: initial initial !important; background-repeat: initial initial !important; "&gt;&lt;div class="line alt1" style="margin-top: 0px !important; margin-right: 0px !important; margin-bottom: 0px !important; margin-left: 0px !important; padding-top: 0px !important; padding-right: 0px !important; padding-bottom: 0px !important; padding-left: 0px !important; border-top-width: 0px !important; border-right-width: 0px !important; border-bottom-width: 0px !important; border-left-width: 0px !important; border-style: initial !important; border-color: initial !important; outline-width: 0px !important; outline-style: initial !important; outline-color: initial !important; background-image: none !important; background-attachment: initial !important; background-origin: initial !important; background-clip: initial !important; background-color: rgb(15, 25, 42) !important; text-align: left !important; float: none !important; vertical-align: baseline !important; position: static !important; left: auto !important; top: auto !important; right: auto !important; bottom: auto !important; height: auto !important; width: auto !important; line-height: 1.1em !important; font-family: Consolas, 'Bitstream Vera Sans Mono', 'Courier New', Courier, monospace !important; font-weight: normal !important; font-style: normal !important; font-size: 1em !important; direction: ltr !important; background-position: initial initial !important; background-repeat: initial initial !important; "&gt;&lt;table style="margin-top: 0px !important; margin-right: 0px !important; margin-bottom: 0px !important; margin-left: 0px !important; padding-top: 0px !important; padding-right: 0px !important; padding-bottom: 0px !important; padding-left: 0px !important; border-top-width: 0px !important; border-right-width: 0px !important; border-bottom-width: 0px !important; border-left-width: 0px !important; border-style: initial !important; border-color: initial !important; outline-width: 0px !important; outline-style: initial !important; outline-color: initial !important; background-image: none !important; background-attachment: initial !important; background-origin: initial !important; background-clip: initial !important; background-color: initial !important; text-align: left !important; float: none !important; vertical-align: baseline !important; position: static !important; left: auto !important; top: auto !important; right: auto !important; bottom: auto !important; height: auto !important; width: auto !important; line-height: 1.1em !important; font-family: Consolas, 'Bitstream Vera Sans Mono', 'Courier New', Courier, monospace !important; font-weight: normal !important; font-style: normal !important; font-size: 1em !important; direction: ltr !important; border-collapse: collapse !important; background-position: initial initial !important; background-repeat: initial initial !important; "&gt;&lt;tbody style="margin-top: 0px !important; margin-right: 0px !important; margin-bottom: 0px !important; margin-left: 0px !important; padding-top: 0px !important; padding-right: 0px !important; padding-bottom: 0px !important; padding-left: 0px !important; border-top-width: 0px !important; border-right-width: 0px !important; border-bottom-width: 0px !important; border-left-width: 0px !important; border-style: initial !important; border-color: initial !important; outline-width: 0px !important; outline-style: initial !important; outline-color: initial !important; background-image: none !important; background-attachment: initial !important; background-origin: initial !important; background-clip: initial !important; background-color: initial !important; text-align: left !important; float: none !important; vertical-align: baseline !important; position: static !important; left: auto !important; top: auto !important; right: auto !important; bottom: auto !important; height: auto !important; width: auto !important; line-height: 1.1em !important; font-family: Consolas, 'Bitstream Vera Sans Mono', 'Courier New', Courier, monospace !important; font-weight: normal !important; font-style: normal !important; font-size: 1em !important; direction: ltr !important; background-position: initial initial !important; background-repeat: initial initial !important; "&gt;&lt;tr style="margin-top: 0px !important; margin-right: 0px !important; margin-bottom: 0px !important; margin-left: 0px !important; padding-top: 0px !important; padding-right: 0px !important; padding-bottom: 0px !important; padding-left: 0px !important; border-top-width: 0px !important; border-right-width: 0px !important; border-bottom-width: 0px !important; border-left-width: 0px !important; border-style: initial !important; border-color: initial !important; outline-width: 0px !important; outline-style: initial !important; outline-color: initial !important; background-image: none !important; background-attachment: initial !important; background-origin: initial !important; background-clip: initial !important; background-color: initial !important; text-align: left !important; float: none !important; vertical-align: baseline !important; position: static !important; left: auto !important; top: auto !important; right: auto !important; bottom: auto !important; height: auto !important; width: auto !important; line-height: 1.1em !important; font-family: Consolas, 'Bitstream Vera Sans Mono', 'Courier New', Courier, monospace !important; font-weight: normal !important; font-style: normal !important; font-size: 1em !important; direction: ltr !important; background-position: initial initial !important; background-repeat: initial initial !important; "&gt;&lt;td class="content" style="margin-top: 0px !important; margin-right: 0px !important; margin-bottom: 0px !important; margin-left: 0px !important; padding-top: 0px !important; padding-right: 0px !important; padding-bottom: 0px !important; padding-left: 0.5em !important; border-top-width: 0px !important; border-right-width: 0px !important; border-bottom-width: 0px !important; border-left-width: initial !important; border-style: initial !important; border-color: initial !important; outline-width: 0px !important; outline-style: initial !important; outline-color: initial !important; background-image: none !important; background-attachment: initial !important; background-origin: initial !important; background-clip: initial !important; background-color: initial !important; text-align: left !important; float: none !important; vertical-align: top !important; position: static !important; left: auto !important; top: auto !important; right: auto !important; bottom: auto !important; height: auto !important; width: auto !important; line-height: 1.1em !important; font-family: Consolas, 'Bitstream Vera Sans Mono', 'Courier New', Courier, monospace !important; font-weight: normal !important; font-style: normal !important; font-size: 1em !important; direction: ltr !important; border-left-style: none !important; border-left-color: initial !important; color: rgb(185, 189, 182) !important; background-position: initial initial !important; background-repeat: initial initial !important; "&gt;&lt;code class="plain" style="font: normal normal normal 1.1em/normal 'Courier New', Courier, Fixed; margin-top: 0px !important; margin-right: 0px !important; margin-bottom: 0px !important; margin-left: 0px !important; padding-top: 0px !important; padding-right: 0px !important; padding-bottom: 0px !important; padding-left: 0px !important; border-top-width: 0px !important; border-right-width: 0px !important; border-bottom-width: 0px !important; border-left-width: 0px !important; border-style: initial !important; border-color: initial !important; outline-width: 0px !important; outline-style: initial !important; outline-color: initial !important; background-image: none !important; background-attachment: initial !important; background-origin: initial !important; background-clip: initial !important; background-color: initial !important; text-align: left !important; float: none !important; vertical-align: baseline !important; position: static !important; left: auto !important; top: auto !important; right: auto !important; bottom: auto !important; height: auto !important; width: auto !important; line-height: 1.1em !important; font-family: Consolas, 'Bitstream Vera Sans Mono', 'Courier New', Courier, monospace !important; font-weight: normal !important; font-style: normal !important; font-size: 1em !important; direction: ltr !important; display: inline !important; color: rgb(209, 237, 255) !important; background-position: initial initial !important; background-repeat: initial initial !important; "&gt;bcdedit /set {ID} device partition=c:&lt;/code&gt;&lt;/td&gt;&lt;/tr&gt;&lt;/tbody&gt;&lt;/table&gt;&lt;/div&gt;&lt;/div&gt;&lt;/div&gt;&lt;p&gt;The path to our linux.bin file:&lt;/p&gt;&lt;div id="highlighter_156643" class="syntaxhighlighter nogutter  " style="margin-top: 1em !important; margin-right: 0px !important; margin-bottom: 1em !important; margin-left: 0px !important; padding-top: 1px !important; padding-right: 1px !important; padding-bottom: 1px !important; padding-left: 1px !important; border-top-width: 0px !important; border-right-width: 0px !important; border-bottom-width: 0px !important; border-left-width: 0px !important; border-style: initial !important; border-color: initial !important; outline-width: 0px !important; outline-style: initial !important; outline-color: initial !important; background-image: none !important; background-attachment: initial !important; background-origin: initial !important; background-clip: initial !important; background-color: rgb(15, 25, 42) !important; text-align: left !important; float: none !important; vertical-align: baseline !important; position: relative !important; left: auto !important; top: auto !important; right: auto !important; bottom: auto !important; height: auto !important; width: 584px; line-height: 1.1em !important; font-family: Consolas, 'Bitstream Vera Sans Mono', 'Courier New', Courier, monospace !important; font-weight: normal !important; font-style: normal !important; font-size: 1em !important; direction: ltr !important; background-position: initial initial !important; background-repeat: initial initial !important; "&gt;&lt;div class="lines" style="margin-top: 0px !important; margin-right: 0px !important; margin-bottom: 0px !important; margin-left: 0px !important; padding-top: 0px !important; padding-right: 0px !important; padding-bottom: 0px !important; padding-left: 0px !important; border-top-width: 0px !important; border-right-width: 0px !important; border-bottom-width: 0px !important; border-left-width: 0px !important; border-style: initial !important; border-color: initial !important; outline-width: 0px !important; outline-style: initial !important; outline-color: initial !important; background-image: none !important; background-attachment: initial !important; background-origin: initial !important; background-clip: initial !important; background-color: initial !important; text-align: left !important; float: none !important; vertical-align: baseline !important; position: static !important; left: auto !important; top: auto !important; right: auto !important; bottom: auto !important; height: auto !important; width: auto !important; line-height: 1.1em !important; font-family: Consolas, 'Bitstream Vera Sans Mono', 'Courier New', Courier, monospace !important; font-weight: normal !important; font-style: normal !important; font-size: 1em !important; direction: ltr !important; background-position: initial initial !important; background-repeat: initial initial !important; "&gt;&lt;div class="line alt1" style="margin-top: 0px !important; margin-right: 0px !important; margin-bottom: 0px !important; margin-left: 0px !important; padding-top: 0px !important; padding-right: 0px !important; padding-bottom: 0px !important; padding-left: 0px !important; border-top-width: 0px !important; border-right-width: 0px !important; border-bottom-width: 0px !important; border-left-width: 0px !important; border-style: initial !important; border-color: initial !important; outline-width: 0px !important; outline-style: initial !important; outline-color: initial !important; background-image: none !important; background-attachment: initial !important; background-origin: initial !important; background-clip: initial !important; background-color: rgb(15, 25, 42) !important; text-align: left !important; float: none !important; vertical-align: baseline !important; position: static !important; left: auto !important; top: auto !important; right: auto !important; bottom: auto !important; height: auto !important; width: auto !important; line-height: 1.1em !important; font-family: Consolas, 'Bitstream Vera Sans Mono', 'Courier New', Courier, monospace !important; font-weight: normal !important; font-style: normal !important; font-size: 1em !important; direction: ltr !important; background-position: initial initial !important; background-repeat: initial initial !important; "&gt;&lt;table style="margin-top: 0px !important; margin-right: 0px !important; margin-bottom: 0px !important; margin-left: 0px !important; padding-top: 0px !important; padding-right: 0px !important; padding-bottom: 0px !important; padding-left: 0px !important; border-top-width: 0px !important; border-right-width: 0px !important; border-bottom-width: 0px !important; border-left-width: 0px !important; border-style: initial !important; border-color: initial !important; outline-width: 0px !important; outline-style: initial !important; outline-color: initial !important; background-image: none !important; background-attachment: initial !important; background-origin: initial !important; background-clip: initial !important; background-color: initial !important; text-align: left !important; float: none !important; vertical-align: baseline !important; position: static !important; left: auto !important; top: auto !important; right: auto !important; bottom: auto !important; height: auto !important; width: auto !important; line-height: 1.1em !important; font-family: Consolas, 'Bitstream Vera Sans Mono', 'Courier New', Courier, monospace !important; font-weight: normal !important; font-style: normal !important; font-size: 1em !important; direction: ltr !important; border-collapse: collapse !important; background-position: initial initial !important; background-repeat: initial initial !important; "&gt;&lt;tbody style="margin-top: 0px !important; margin-right: 0px !important; margin-bottom: 0px !important; margin-left: 0px !important; padding-top: 0px !important; padding-right: 0px !important; padding-bottom: 0px !important; padding-left: 0px !important; border-top-width: 0px !important; border-right-width: 0px !important; border-bottom-width: 0px !important; border-left-width: 0px !important; border-style: initial !important; border-color: initial !important; outline-width: 0px !important; outline-style: initial !important; outline-color: initial !important; background-image: none !important; background-attachment: initial !important; background-origin: initial !important; background-clip: initial !important; background-color: initial !important; text-align: left !important; float: none !important; vertical-align: baseline !important; position: static !important; left: auto !important; top: auto !important; right: auto !important; bottom: auto !important; height: auto !important; width: auto !important; line-height: 1.1em !important; font-family: Consolas, 'Bitstream Vera Sans Mono', 'Courier New', Courier, monospace !important; font-weight: normal !important; font-style: normal !important; font-size: 1em !important; direction: ltr !important; background-position: initial initial !important; background-repeat: initial initial !important; "&gt;&lt;tr style="margin-top: 0px !important; margin-right: 0px !important; margin-bottom: 0px !important; margin-left: 0px !important; padding-top: 0px !important; padding-right: 0px !important; padding-bottom: 0px !important; padding-left: 0px !important; border-top-width: 0px !important; border-right-width: 0px !important; border-bottom-width: 0px !important; border-left-width: 0px !important; border-style: initial !important; border-color: initial !important; outline-width: 0px !important; outline-style: initial !important; outline-color: initial !important; background-image: none !important; background-attachment: initial !important; background-origin: initial !important; background-clip: initial !important; background-color: initial !important; text-align: left !important; float: none !important; vertical-align: baseline !important; position: static !important; left: auto !important; top: auto !important; right: auto !important; bottom: auto !important; height: auto !important; width: auto !important; line-height: 1.1em !important; font-family: Consolas, 'Bitstream Vera Sans Mono', 'Courier New', Courier, monospace !important; font-weight: normal !important; font-style: normal !important; font-size: 1em !important; direction: ltr !important; background-position: initial initial !important; background-repeat: initial initial !important; "&gt;&lt;td class="content" style="margin-top: 0px !important; margin-right: 0px !important; margin-bottom: 0px !important; margin-left: 0px !important; padding-top: 0px !important; padding-right: 0px !important; padding-bottom: 0px !important; padding-left: 0.5em !important; border-top-width: 0px !important; border-right-width: 0px !important; border-bottom-width: 0px !important; border-left-width: initial !important; border-style: initial !important; border-color: initial !important; outline-width: 0px !important; outline-style: initial !important; outline-color: initial !important; background-image: none !important; background-attachment: initial !important; background-origin: initial !important; background-clip: initial !important; background-color: initial !important; text-align: left !important; float: none !important; vertical-align: top !important; position: static !important; left: auto !important; top: auto !important; right: auto !important; bottom: auto !important; height: auto !important; width: auto !important; line-height: 1.1em !important; font-family: Consolas, 'Bitstream Vera Sans Mono', 'Courier New', Courier, monospace !important; font-weight: normal !important; font-style: normal !important; font-size: 1em !important; direction: ltr !important; border-left-style: none !important; border-left-color: initial !important; color: rgb(185, 189, 182) !important; background-position: initial initial !important; background-repeat: initial initial !important; "&gt;&lt;code class="plain" style="font: normal normal normal 1.1em/normal 'Courier New', Courier, Fixed; margin-top: 0px !important; margin-right: 0px !important; margin-bottom: 0px !important; margin-left: 0px !important; padding-top: 0px !important; padding-right: 0px !important; padding-bottom: 0px !important; padding-left: 0px !important; border-top-width: 0px !important; border-right-width: 0px !important; border-bottom-width: 0px !important; border-left-width: 0px !important; border-style: initial !important; border-color: initial !important; outline-width: 0px !important; outline-style: initial !important; outline-color: initial !important; background-image: none !important; background-attachment: initial !important; background-origin: initial !important; background-clip: initial !important; background-color: initial !important; text-align: left !important; float: none !important; vertical-align: baseline !important; position: static !important; left: auto !important; top: auto !important; right: auto !important; bottom: auto !important; height: auto !important; width: auto !important; line-height: 1.1em !important; font-family: Consolas, 'Bitstream Vera Sans Mono', 'Courier New', Courier, monospace !important; font-weight: normal !important; font-style: normal !important; font-size: 1em !important; direction: ltr !important; display: inline !important; color: rgb(209, 237, 255) !important; background-position: initial initial !important; background-repeat: initial initial !important; "&gt;bcdedit /set {ID}  path \linux.bin&lt;/code&gt;&lt;/td&gt;&lt;/tr&gt;&lt;/tbody&gt;&lt;/table&gt;&lt;/div&gt;&lt;/div&gt;&lt;/div&gt;&lt;p&gt;An entry to the displayed menu at boot time:&lt;/p&gt;&lt;div id="highlighter_684743" class="syntaxhighlighter nogutter  " style="margin-top: 1em !important; margin-right: 0px !important; margin-bottom: 1em !important; margin-left: 0px !important; padding-top: 1px !important; padding-right: 1px !important; padding-bottom: 1px !important; padding-left: 1px !important; border-top-width: 0px !important; border-right-width: 0px !important; border-bottom-width: 0px !important; border-left-width: 0px !important; border-style: initial !important; border-color: initial !important; outline-width: 0px !important; outline-style: initial !important; outline-color: initial !important; background-image: none !important; background-attachment: initial !important; background-origin: initial !important; background-clip: initial !important; background-color: rgb(15, 25, 42) !important; text-align: left !important; float: none !important; vertical-align: baseline !important; position: relative !important; left: auto !important; top: auto !important; right: auto !important; bottom: auto !important; height: auto !important; width: 584px; line-height: 1.1em !important; font-family: Consolas, 'Bitstream Vera Sans Mono', 'Courier New', Courier, monospace !important; font-weight: normal !important; font-style: normal !important; font-size: 1em !important; direction: ltr !important; background-position: initial initial !important; background-repeat: initial initial !important; "&gt;&lt;div class="lines" style="margin-top: 0px !important; margin-right: 0px !important; margin-bottom: 0px !important; margin-left: 0px !important; padding-top: 0px !important; padding-right: 0px !important; padding-bottom: 0px !important; padding-left: 0px !important; border-top-width: 0px !important; border-right-width: 0px !important; border-bottom-width: 0px !important; border-left-width: 0px !important; border-style: initial !important; border-color: initial !important; outline-width: 0px !important; outline-style: initial !important; outline-color: initial !important; background-image: none !important; background-attachment: initial !important; background-origin: initial !important; background-clip: initial !important; background-color: initial !important; text-align: left !important; float: none !important; vertical-align: baseline !important; position: static !important; left: auto !important; top: auto !important; right: auto !important; bottom: auto !important; height: auto !important; width: auto !important; line-height: 1.1em !important; font-family: Consolas, 'Bitstream Vera Sans Mono', 'Courier New', Courier, monospace !important; font-weight: normal !important; font-style: normal !important; font-size: 1em !important; direction: ltr !important; background-position: initial initial !important; background-repeat: initial initial !important; "&gt;&lt;div class="line alt1" style="margin-top: 0px !important; margin-right: 0px !important; margin-bottom: 0px !important; margin-left: 0px !important; padding-top: 0px !important; padding-right: 0px !important; padding-bottom: 0px !important; padding-left: 0px !important; border-top-width: 0px !important; border-right-width: 0px !important; border-bottom-width: 0px !important; border-left-width: 0px !important; border-style: initial !important; border-color: initial !important; outline-width: 0px !important; outline-style: initial !important; outline-color: initial !important; background-image: none !important; background-attachment: initial !important; background-origin: initial !important; background-clip: initial !important; background-color: rgb(15, 25, 42) !important; text-align: left !important; float: none !important; vertical-align: baseline !important; position: static !important; left: auto !important; top: auto !important; right: auto !important; bottom: auto !important; height: auto !important; width: auto !important; line-height: 1.1em !important; font-family: Consolas, 'Bitstream Vera Sans Mono', 'Courier New', Courier, monospace !important; font-weight: normal !important; font-style: normal !important; font-size: 1em !important; direction: ltr !important; background-position: initial initial !important; background-repeat: initial initial !important; "&gt;&lt;table style="margin-top: 0px !important; margin-right: 0px !important; margin-bottom: 0px !important; margin-left: 0px !important; padding-top: 0px !important; padding-right: 0px !important; padding-bottom: 0px !important; padding-left: 0px !important; border-top-width: 0px !important; border-right-width: 0px !important; border-bottom-width: 0px !important; border-left-width: 0px !important; border-style: initial !important; border-color: initial !important; outline-width: 0px !important; outline-style: initial !important; outline-color: initial !important; background-image: none !important; background-attachment: initial !important; background-origin: initial !important; background-clip: initial !important; background-color: initial !important; text-align: left !important; float: none !important; vertical-align: baseline !important; position: static !important; left: auto !important; top: auto !important; right: auto !important; bottom: auto !important; height: auto !important; width: auto !important; line-height: 1.1em !important; font-family: Consolas, 'Bitstream Vera Sans Mono', 'Courier New', Courier, monospace !important; font-weight: normal !important; font-style: normal !important; font-size: 1em !important; direction: ltr !important; border-collapse: collapse !important; background-position: initial initial !important; background-repeat: initial initial !important; "&gt;&lt;tbody style="margin-top: 0px !important; margin-right: 0px !important; margin-bottom: 0px !important; margin-left: 0px !important; padding-top: 0px !important; padding-right: 0px !important; padding-bottom: 0px !important; padding-left: 0px !important; border-top-width: 0px !important; border-right-width: 0px !important; border-bottom-width: 0px !important; border-left-width: 0px !important; border-style: initial !important; border-color: initial !important; outline-width: 0px !important; outline-style: initial !important; outline-color: initial !important; background-image: none !important; background-attachment: initial !important; background-origin: initial !important; background-clip: initial !important; background-color: initial !important; text-align: left !important; float: none !important; vertical-align: baseline !important; position: static !important; left: auto !important; top: auto !important; right: auto !important; bottom: auto !important; height: auto !important; width: auto !important; line-height: 1.1em !important; font-family: Consolas, 'Bitstream Vera Sans Mono', 'Courier New', Courier, monospace !important; font-weight: normal !important; font-style: normal !important; font-size: 1em !important; direction: ltr !important; background-position: initial initial !important; background-repeat: initial initial !important; "&gt;&lt;tr style="margin-top: 0px !important; margin-right: 0px !important; margin-bottom: 0px !important; margin-left: 0px !important; padding-top: 0px !important; padding-right: 0px !important; padding-bottom: 0px !important; padding-left: 0px !important; border-top-width: 0px !important; border-right-width: 0px !important; border-bottom-width: 0px !important; border-left-width: 0px !important; border-style: initial !important; border-color: initial !important; outline-width: 0px !important; outline-style: initial !important; outline-color: initial !important; background-image: none !important; background-attachment: initial !important; background-origin: initial !important; background-clip: initial !important; background-color: initial !important; text-align: left !important; float: none !important; vertical-align: baseline !important; position: static !important; left: auto !important; top: auto !important; right: auto !important; bottom: auto !important; height: auto !important; width: auto !important; line-height: 1.1em !important; font-family: Consolas, 'Bitstream Vera Sans Mono', 'Courier New', Courier, monospace !important; font-weight: normal !important; font-style: normal !important; font-size: 1em !important; direction: ltr !important; background-position: initial initial !important; background-repeat: initial initial !important; "&gt;&lt;td class="content" style="margin-top: 0px !important; margin-right: 0px !important; margin-bottom: 0px !important; margin-left: 0px !important; padding-top: 0px !important; padding-right: 0px !important; padding-bottom: 0px !important; padding-left: 0.5em !important; border-top-width: 0px !important; border-right-width: 0px !important; border-bottom-width: 0px !important; border-left-width: initial !important; border-style: initial !important; border-color: initial !important; outline-width: 0px !important; outline-style: initial !important; outline-color: initial !important; background-image: none !important; background-attachment: initial !important; background-origin: initial !important; background-clip: initial !important; background-color: initial !important; text-align: left !important; float: none !important; vertical-align: top !important; position: static !important; left: auto !important; top: auto !important; right: auto !important; bottom: auto !important; height: auto !important; width: auto !important; line-height: 1.1em !important; font-family: Consolas, 'Bitstream Vera Sans Mono', 'Courier New', Courier, monospace !important; font-weight: normal !important; font-style: normal !important; font-size: 1em !important; direction: ltr !important; border-left-style: none !important; border-left-color: initial !important; color: rgb(185, 189, 182) !important; background-position: initial initial !important; background-repeat: initial initial !important; "&gt;&lt;code class="plain" style="font: normal normal normal 1.1em/normal 'Courier New', Courier, Fixed; margin-top: 0px !important; margin-right: 0px !important; margin-bottom: 0px !important; margin-left: 0px !important; padding-top: 0px !important; padding-right: 0px !important; padding-bottom: 0px !important; padding-left: 0px !important; border-top-width: 0px !important; border-right-width: 0px !important; border-bottom-width: 0px !important; border-left-width: 0px !important; border-style: initial !important; border-color: initial !important; outline-width: 0px !important; outline-style: initial !important; outline-color: initial !important; background-image: none !important; background-attachment: initial !important; background-origin: initial !important; background-clip: initial !important; background-color: initial !important; text-align: left !important; float: none !important; vertical-align: baseline !important; position: static !important; left: auto !important; top: auto !important; right: auto !important; bottom: auto !important; height: auto !important; width: auto !important; line-height: 1.1em !important; font-family: Consolas, 'Bitstream Vera Sans Mono', 'Courier New', Courier, monospace !important; font-weight: normal !important; font-style: normal !important; font-size: 1em !important; direction: ltr !important; display: inline !important; color: rgb(209, 237, 255) !important; background-position: initial initial !important; background-repeat: initial initial !important; "&gt;bcdedit /displayorder {ID} /addlast&lt;/code&gt;&lt;/td&gt;&lt;/tr&gt;&lt;/tbody&gt;&lt;/table&gt;&lt;/div&gt;&lt;/div&gt;&lt;/div&gt;&lt;p&gt;and finally, let’s specify how long the menu choices will be displayed:&lt;/p&gt;&lt;div id="highlighter_173387" class="syntaxhighlighter nogutter  " style="margin-top: 1em !important; margin-right: 0px !important; margin-bottom: 1em !important; margin-left: 0px !important; padding-top: 1px !important; padding-right: 1px !important; padding-bottom: 1px !important; padding-left: 1px !important; border-top-width: 0px !important; border-right-width: 0px !important; border-bottom-width: 0px !important; border-left-width: 0px !important; border-style: initial !important; border-color: initial !important; outline-width: 0px !important; outline-style: initial !important; outline-color: initial !important; background-image: none !important; background-attachment: initial !important; background-origin: initial !important; background-clip: initial !important; background-color: rgb(15, 25, 42) !important; text-align: left !important; float: none !important; vertical-align: baseline !important; position: relative !important; left: auto !important; top: auto !important; right: auto !important; bottom: auto !important; height: auto !important; width: 584px; line-height: 1.1em !important; font-family: Consolas, 'Bitstream Vera Sans Mono', 'Courier New', Courier, monospace !important; font-weight: normal !important; font-style: normal !important; font-size: 1em !important; direction: ltr !important; background-position: initial initial !important; background-repeat: initial initial !important; "&gt;&lt;div class="lines" style="margin-top: 0px !important; margin-right: 0px !important; margin-bottom: 0px !important; margin-left: 0px !important; padding-top: 0px !important; padding-right: 0px !important; padding-bottom: 0px !important; padding-left: 0px !important; border-top-width: 0px !important; border-right-width: 0px !important; border-bottom-width: 0px !important; border-left-width: 0px !important; border-style: initial !important; border-color: initial !important; outline-width: 0px !important; outline-style: initial !important; outline-color: initial !important; background-image: none !important; background-attachment: initial !important; background-origin: initial !important; background-clip: initial !important; background-color: initial !important; text-align: left !important; float: none !important; vertical-align: baseline !important; position: static !important; left: auto !important; top: auto !important; right: auto !important; bottom: auto !important; height: auto !important; width: auto !important; line-height: 1.1em !important; font-family: Consolas, 'Bitstream Vera Sans Mono', 'Courier New', Courier, monospace !important; font-weight: normal !important; font-style: normal !important; font-size: 1em !important; direction: ltr !important; background-position: initial initial !important; background-repeat: initial initial !important; "&gt;&lt;div class="line alt1" style="margin-top: 0px !important; margin-right: 0px !important; margin-bottom: 0px !important; margin-left: 0px !important; padding-top: 0px !important; padding-right: 0px !important; padding-bottom: 0px !important; padding-left: 0px !important; border-top-width: 0px !important; border-right-width: 0px !important; border-bottom-width: 0px !important; border-left-width: 0px !important; border-style: initial !important; border-color: initial !important; outline-width: 0px !important; outline-style: initial !important; outline-color: initial !important; background-image: none !important; background-attachment: initial !important; background-origin: initial !important; background-clip: initial !important; background-color: rgb(15, 25, 42) !important; text-align: left !important; float: none !important; vertical-align: baseline !important; position: static !important; left: auto !important; top: auto !important; right: auto !important; bottom: auto !important; height: auto !important; width: auto !important; line-height: 1.1em !important; font-family: Consolas, 'Bitstream Vera Sans Mono', 'Courier New', Courier, monospace !important; font-weight: normal !important; font-style: normal !important; font-size: 1em !important; direction: ltr !important; background-position: initial initial !important; background-repeat: initial initial !important; "&gt;&lt;table style="margin-top: 0px !important; margin-right: 0px !important; margin-bottom: 0px !important; margin-left: 0px !important; padding-top: 0px !important; padding-right: 0px !important; padding-bottom: 0px !important; padding-left: 0px !important; border-top-width: 0px !important; border-right-width: 0px !important; border-bottom-width: 0px !important; border-left-width: 0px !important; border-style: initial !important; border-color: initial !important; outline-width: 0px !important; outline-style: initial !important; outline-color: initial !important; background-image: none !important; background-attachment: initial !important; background-origin: initial !important; background-clip: initial !important; background-color: initial !important; text-align: left !important; float: none !important; vertical-align: baseline !important; position: static !important; left: auto !important; top: auto !important; right: auto !important; bottom: auto !important; height: auto !important; width: auto !important; line-height: 1.1em !important; font-family: Consolas, 'Bitstream Vera Sans Mono', 'Courier New', Courier, monospace !important; font-weight: normal !important; font-style: normal !important; font-size: 1em !important; direction: ltr !important; border-collapse: collapse !important; background-position: initial initial !important; background-repeat: initial initial !important; "&gt;&lt;tbody style="margin-top: 0px !important; margin-right: 0px !important; margin-bottom: 0px !important; margin-left: 0px !important; padding-top: 0px !important; padding-right: 0px !important; padding-bottom: 0px !important; padding-left: 0px !important; border-top-width: 0px !important; border-right-width: 0px !important; border-bottom-width: 0px !important; border-left-width: 0px !important; border-style: initial !important; border-color: initial !important; outline-width: 0px !important; outline-style: initial !important; outline-color: initial !important; background-image: none !important; background-attachment: initial !important; background-origin: initial !important; background-clip: initial !important; background-color: initial !important; text-align: left !important; float: none !important; vertical-align: baseline !important; position: static !important; left: auto !important; top: auto !important; right: auto !important; bottom: auto !important; height: auto !important; width: auto !important; line-height: 1.1em !important; font-family: Consolas, 'Bitstream Vera Sans Mono', 'Courier New', Courier, monospace !important; font-weight: normal !important; font-style: normal !important; font-size: 1em !important; direction: ltr !important; background-position: initial initial !important; background-repeat: initial initial !important; "&gt;&lt;tr style="margin-top: 0px !important; margin-right: 0px !important; margin-bottom: 0px !important; margin-left: 0px !important; padding-top: 0px !important; padding-right: 0px !important; padding-bottom: 0px !important; padding-left: 0px !important; border-top-width: 0px !important; border-right-width: 0px !important; border-bottom-width: 0px !important; border-left-width: 0px !important; border-style: initial !important; border-color: initial !important; outline-width: 0px !important; outline-style: initial !important; outline-color: initial !important; background-image: none !important; background-attachment: initial !important; background-origin: initial !important; background-clip: initial !important; background-color: initial !important; text-align: left !important; float: none !important; vertical-align: baseline !important; position: static !important; left: auto !important; top: auto !important; right: auto !important; bottom: auto !important; height: auto !important; width: auto !important; line-height: 1.1em !important; font-family: Consolas, 'Bitstream Vera Sans Mono', 'Courier New', Courier, monospace !important; font-weight: normal !important; font-style: normal !important; font-size: 1em !important; direction: ltr !important; background-position: initial initial !important; background-repeat: initial initial !important; "&gt;&lt;td class="content" style="margin-top: 0px !important; margin-right: 0px !important; margin-bottom: 0px !important; margin-left: 0px !important; padding-top: 0px !important; padding-right: 0px !important; padding-bottom: 0px !important; padding-left: 0.5em !important; border-top-width: 0px !important; border-right-width: 0px !important; border-bottom-width: 0px !important; border-left-width: initial !important; border-style: initial !important; border-color: initial !important; outline-width: 0px !important; outline-style: initial !important; outline-color: initial !important; background-image: none !important; background-attachment: initial !important; background-origin: initial !important; background-clip: initial !important; background-color: initial !important; text-align: left !important; float: none !important; vertical-align: top !important; position: static !important; left: auto !important; top: auto !important; right: auto !important; bottom: auto !important; height: auto !important; width: auto !important; line-height: 1.1em !important; font-family: Consolas, 'Bitstream Vera Sans Mono', 'Courier New', Courier, monospace !important; font-weight: normal !important; font-style: normal !important; font-size: 1em !important; direction: ltr !important; border-left-style: none !important; border-left-color: initial !important; color: rgb(185, 189, 182) !important; background-position: initial initial !important; background-repeat: initial initial !important; "&gt;&lt;code class="plain" style="font: normal normal normal 1.1em/normal 'Courier New', Courier, Fixed; margin-top: 0px !important; margin-right: 0px !important; margin-bottom: 0px !important; margin-left: 0px !important; padding-top: 0px !important; padding-right: 0px !important; padding-bottom: 0px !important; padding-left: 0px !important; border-top-width: 0px !important; border-right-width: 0px !important; border-bottom-width: 0px !important; border-left-width: 0px !important; border-style: initial !important; border-color: initial !important; outline-width: 0px !important; outline-style: initial !important; outline-color: initial !important; background-image: none !important; background-attachment: initial !important; background-origin: initial !important; background-clip: initial !important; background-color: initial !important; text-align: left !important; float: none !important; vertical-align: baseline !important; position: static !important; left: auto !important; top: auto !important; right: auto !important; bottom: auto !important; height: auto !important; width: auto !important; line-height: 1.1em !important; font-family: Consolas, 'Bitstream Vera Sans Mono', 'Courier New', Courier, monospace !important; font-weight: normal !important; font-style: normal !important; font-size: 1em !important; direction: ltr !important; display: inline !important; color: rgb(209, 237, 255) !important; background-position: initial initial !important; background-repeat: initial initial !important; "&gt;bcdedit /timeout 30&lt;/code&gt;&lt;/td&gt;&lt;/tr&gt;&lt;/tbody&gt;&lt;/table&gt;&lt;/div&gt;&lt;/div&gt;&lt;/div&gt;&lt;p&gt;That’s it! Now reboot and you will be presented with menu where you can choose to boot to Windows 7 or Linux. When you choose Linux, you’ll be taken to the GRUB menu where you can choose to continue booting your Linux distribution or return to the previous menu.&lt;/p&gt;&lt;p&gt;&lt;strong&gt;Windows XP?&lt;/strong&gt;&lt;/p&gt;&lt;p&gt;If you plan to dual boot using Windows XP then you will still partition and install Ubuntu or Fedora as described above (Note, however, that XP does not use a small primary partition for boot configuration data like Windows 7 does), but you won’t be needing BCDEdit. Instead, you can simply open the boot.ini file located at C:\ and add the following entry:&lt;/p&gt;&lt;div id="highlighter_151050" class="syntaxhighlighter nogutter  " style="margin-top: 1em !important; margin-right: 0px !important; margin-bottom: 1em !important; margin-left: 0px !important; padding-top: 1px !important; padding-right: 1px !important; padding-bottom: 1px !important; padding-left: 1px !important; border-top-width: 0px !important; border-right-width: 0px !important; border-bottom-width: 0px !important; border-left-width: 0px !important; border-style: initial !important; border-color: initial !important; outline-width: 0px !important; outline-style: initial !important; outline-color: initial !important; background-image: none !important; background-attachment: initial !important; background-origin: initial !important; background-clip: initial !important; background-color: rgb(15, 25, 42) !important; text-align: left !important; float: none !important; vertical-align: baseline !important; position: relative !important; left: auto !important; top: auto !important; right: auto !important; bottom: auto !important; height: auto !important; width: 584px; line-height: 1.1em !important; font-family: Consolas, 'Bitstream Vera Sans Mono', 'Courier New', Courier, monospace !important; font-weight: normal !important; font-style: normal !important; font-size: 1em !important; direction: ltr !important; background-position: initial initial !important; background-repeat: initial initial !important; "&gt;&lt;div class="lines" style="margin-top: 0px !important; margin-right: 0px !important; margin-bottom: 0px !important; margin-left: 0px !important; padding-top: 0px !important; padding-right: 0px !important; padding-bottom: 0px !important; padding-left: 0px !important; border-top-width: 0px !important; border-right-width: 0px !important; border-bottom-width: 0px !important; border-left-width: 0px !important; border-style: initial !important; border-color: initial !important; outline-width: 0px !important; outline-style: initial !important; outline-color: initial !important; background-image: none !important; background-attachment: initial !important; background-origin: initial !important; background-clip: initial !important; background-color: initial !important; text-align: left !important; float: none !important; vertical-align: baseline !important; position: static !important; left: auto !important; top: auto !important; right: auto !important; bottom: auto !important; height: auto !important; width: auto !important; line-height: 1.1em !important; font-family: Consolas, 'Bitstream Vera Sans Mono', 'Courier New', Courier, monospace !important; font-weight: normal !important; font-style: normal !important; font-size: 1em !important; direction: ltr !important; background-position: initial initial !important; background-repeat: initial initial !important; "&gt;&lt;div class="line alt1" style="margin-top: 0px !important; margin-right: 0px !important; margin-bottom: 0px !important; margin-left: 0px !important; padding-top: 0px !important; padding-right: 0px !important; padding-bottom: 0px !important; padding-left: 0px !important; border-top-width: 0px !important; border-right-width: 0px !important; border-bottom-width: 0px !important; border-left-width: 0px !important; border-style: initial !important; border-color: initial !important; outline-width: 0px !important; outline-style: initial !important; outline-color: initial !important; background-image: none !important; background-attachment: initial !important; background-origin: initial !important; background-clip: initial !important; background-color: rgb(15, 25, 42) !important; text-align: left !important; float: none !important; vertical-align: baseline !important; position: static !important; left: auto !important; top: auto !important; right: auto !important; bottom: auto !important; height: auto !important; width: auto !important; line-height: 1.1em !important; font-family: Consolas, 'Bitstream Vera Sans Mono', 'Courier New', Courier, monospace !important; font-weight: normal !important; font-style: normal !important; font-size: 1em !important; direction: ltr !important; background-position: initial initial !important; background-repeat: initial initial !important; "&gt;&lt;table style="margin-top: 0px !important; margin-right: 0px !important; margin-bottom: 0px !important; margin-left: 0px !important; padding-top: 0px !important; padding-right: 0px !important; padding-bottom: 0px !important; padding-left: 0px !important; border-top-width: 0px !important; border-right-width: 0px !important; border-bottom-width: 0px !important; border-left-width: 0px !important; border-style: initial !important; border-color: initial !important; outline-width: 0px !important; outline-style: initial !important; outline-color: initial !important; background-image: none !important; background-attachment: initial !important; background-origin: initial !important; background-clip: initial !important; background-color: initial !important; text-align: left !important; float: none !important; vertical-align: baseline !important; position: static !important; left: auto !important; top: auto !important; right: auto !important; bottom: auto !important; height: auto !important; width: auto !important; line-height: 1.1em !important; font-family: Consolas, 'Bitstream Vera Sans Mono', 'Courier New', Courier, monospace !important; font-weight: normal !important; font-style: normal !important; font-size: 1em !important; direction: ltr !important; border-collapse: collapse !important; background-position: initial initial !important; background-repeat: initial initial !important; "&gt;&lt;tbody style="margin-top: 0px !important; margin-right: 0px !important; margin-bottom: 0px !important; margin-left: 0px !important; padding-top: 0px !important; padding-right: 0px !important; padding-bottom: 0px !important; padding-left: 0px !important; border-top-width: 0px !important; border-right-width: 0px !important; border-bottom-width: 0px !important; border-left-width: 0px !important; border-style: initial !important; border-color: initial !important; outline-width: 0px !important; outline-style: initial !important; outline-color: initial !important; background-image: none !important; background-attachment: initial !important; background-origin: initial !important; background-clip: initial !important; background-color: initial !important; text-align: left !important; float: none !important; vertical-align: baseline !important; position: static !important; left: auto !important; top: auto !important; right: auto !important; bottom: auto !important; height: auto !important; width: auto !important; line-height: 1.1em !important; font-family: Consolas, 'Bitstream Vera Sans Mono', 'Courier New', Courier, monospace !important; font-weight: normal !important; font-style: normal !important; font-size: 1em !important; direction: ltr !important; background-position: initial initial !important; background-repeat: initial initial !important; "&gt;&lt;tr style="margin-top: 0px !important; margin-right: 0px !important; margin-bottom: 0px !important; margin-left: 0px !important; padding-top: 0px !important; padding-right: 0px !important; padding-bottom: 0px !important; padding-left: 0px !important; border-top-width: 0px !important; border-right-width: 0px !important; border-bottom-width: 0px !important; border-left-width: 0px !important; border-style: initial !important; border-color: initial !important; outline-width: 0px !important; outline-style: initial !important; outline-color: initial !important; background-image: none !important; background-attachment: initial !important; background-origin: initial !important; background-clip: initial !important; background-color: initial !important; text-align: left !important; float: none !important; vertical-align: baseline !important; position: static !important; left: auto !important; top: auto !important; right: auto !important; bottom: auto !important; height: auto !important; width: auto !important; line-height: 1.1em !important; font-family: Consolas, 'Bitstream Vera Sans Mono', 'Courier New', Courier, monospace !important; font-weight: normal !important; font-style: normal !important; font-size: 1em !important; direction: ltr !important; background-position: initial initial !important; background-repeat: initial initial !important; "&gt;&lt;td class="content" style="margin-top: 0px !important; margin-right: 0px !important; margin-bottom: 0px !important; margin-left: 0px !important; padding-top: 0px !important; padding-right: 0px !important; padding-bottom: 0px !important; padding-left: 0.5em !important; border-top-width: 0px !important; border-right-width: 0px !important; border-bottom-width: 0px !important; border-left-width: initial !important; border-style: initial !important; border-color: initial !important; outline-width: 0px !important; outline-style: initial !important; outline-color: initial !important; background-image: none !important; background-attachment: initial !important; background-origin: initial !important; background-clip: initial !important; background-color: initial !important; text-align: left !important; float: none !important; vertical-align: top !important; position: static !important; left: auto !important; top: auto !important; right: auto !important; bottom: auto !important; height: auto !important; width: auto !important; line-height: 1.1em !important; font-family: Consolas, 'Bitstream Vera Sans Mono', 'Courier New', Courier, monospace !important; font-weight: normal !important; font-style: normal !important; font-size: 1em !important; direction: ltr !important; border-left-style: none !important; border-left-color: initial !important; color: rgb(185, 189, 182) !important; background-position: initial initial !important; background-repeat: initial initial !important; "&gt;&lt;code class="plain" style="font: normal normal normal 1.1em/normal 'Courier New', Courier, Fixed; margin-top: 0px !important; margin-right: 0px !important; margin-bottom: 0px !important; margin-left: 0px !important; padding-top: 0px !important; padding-right: 0px !important; padding-bottom: 0px !important; padding-left: 0px !important; border-top-width: 0px !important; border-right-width: 0px !important; border-bottom-width: 0px !important; border-left-width: 0px !important; border-style: initial !important; border-color: initial !important; outline-width: 0px !important; outline-style: initial !important; outline-color: initial !important; background-image: none !important; background-attachment: initial !important; background-origin: initial !important; background-clip: initial !important; background-color: initial !important; text-align: left !important; float: none !important; vertical-align: baseline !important; position: static !important; left: auto !important; top: auto !important; right: auto !important; bottom: auto !important; height: auto !important; width: auto !important; line-height: 1.1em !important; font-family: Consolas, 'Bitstream Vera Sans Mono', 'Courier New', Courier, monospace !important; font-weight: normal !important; font-style: normal !important; font-size: 1em !important; direction: ltr !important; display: inline !important; color: rgb(209, 237, 255) !important; background-position: initial initial !important; background-repeat: initial initial !important; "&gt;c:\linux.bin="Linux"&lt;/code&gt;&lt;/td&gt;&lt;/tr&gt;&lt;/tbody&gt;&lt;/table&gt;&lt;/div&gt;&lt;/div&gt;&lt;/div&gt;&lt;p&gt;&lt;strong&gt;Conclusion&lt;/strong&gt;&lt;/p&gt;&lt;p&gt;With a minimal amount time, the free and open source disk partitioning tool Gparted, and a little command line foo, you can easily set up a system that can dual boot Windows 7 and your choice of Linux distributions.&lt;/p&gt;&lt;p&gt;&lt;strong&gt;References&lt;/strong&gt;&lt;/p&gt;&lt;p&gt;&lt;a href="http://technet.microsoft.com/en-us/library/cc709667%28WS.10%29.aspx" target="_blank" title="BCDEdit command line options" style="color: rgb(0, 102, 153); text-decoration: none; "&gt;http://technet.microsoft.com/en-us/library/cc709667%28WS.10%29.aspx&lt;/a&gt;&lt;/p&gt;&lt;/div&gt;&lt;/span&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/4984480909360655633-913668282894958683?l=worldinthenet.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://worldinthenet.blogspot.com/feeds/913668282894958683/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://worldinthenet.blogspot.com/2010/03/zzhow-to-dual-boot-windows-7-and-linux.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/4984480909360655633/posts/default/913668282894958683'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/4984480909360655633/posts/default/913668282894958683'/><link rel='alternate' type='text/html' href='http://worldinthenet.blogspot.com/2010/03/zzhow-to-dual-boot-windows-7-and-linux.html' title='[zz]How to Dual Boot Windows 7 and Linux using BCDEdit'/><author><name>Taojun</name><uri>http://www.blogger.com/profile/12946690813153575136</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-4984480909360655633.post-3607181766971112471</id><published>2009-07-16T17:30:00.000-07:00</published><updated>2009-07-16T19:55:32.150-07:00</updated><title type='text'>Build OpenWrt howto</title><content type='html'>* get code from svn repository&lt;br /&gt;cd ~/openwrt/&lt;br /&gt;svn co svn://svn.openwrt.org/openwrt/branches/8.09/ 8.09/&lt;br /&gt;svn co svn://svn.openwrt.org/openwrt/packages 8.09/feeds/packages&lt;br /&gt;cd 8.09/&lt;br /&gt;./scripts/feeds update -a&lt;br /&gt;* build&lt;br /&gt;make package/symlinks&lt;br /&gt;make menuconfig&lt;br /&gt;make prereq&lt;br /&gt;make world&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/4984480909360655633-3607181766971112471?l=worldinthenet.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://worldinthenet.blogspot.com/feeds/3607181766971112471/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://worldinthenet.blogspot.com/2009/07/build-openwrt-howto.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/4984480909360655633/posts/default/3607181766971112471'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/4984480909360655633/posts/default/3607181766971112471'/><link rel='alternate' type='text/html' href='http://worldinthenet.blogspot.com/2009/07/build-openwrt-howto.html' title='Build OpenWrt howto'/><author><name>Taojun</name><uri>http://www.blogger.com/profile/12946690813153575136</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-4984480909360655633.post-4979888198464772262</id><published>2009-07-15T19:31:00.000-07:00</published><updated>2009-07-15T19:32:15.432-07:00</updated><title type='text'>[zz] USB Storage Howto</title><content type='html'>&lt;span class="anchor" id="top"&gt;&lt;/span&gt; &lt;span class="anchor" id="line-1"&gt;&lt;/span&gt;&lt;p class="line867"&gt;&lt;strong&gt;USB storage howto&lt;/strong&gt; &lt;span class="anchor" id="line-2"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-3"&gt;&lt;/span&gt;&lt;/p&gt;&lt;div class="table-of-contents"&gt;&lt;p class="table-of-contents-heading"&gt;Contents&lt;/p&gt;&lt;ol&gt;&lt;li&gt;&lt;a href="http://oldwiki.openwrt.org/UsbStorageHowto.html#head-7c1815e4262bd7d8a8e0abd4756a1c7ab7593cb6"&gt;Intro&lt;/a&gt;&lt;/li&gt;&lt;li&gt;&lt;a href="http://oldwiki.openwrt.org/UsbStorageHowto.html#head-0667198f4bc3f449b19998820e75e8ae5f123a79"&gt;Requirements&lt;/a&gt;&lt;/li&gt;&lt;li&gt;&lt;a href="http://oldwiki.openwrt.org/UsbStorageHowto.html#head-4d171351157612255bc75912e7863556a1ae1286"&gt;Installation&lt;/a&gt;&lt;ol&gt;&lt;li&gt;&lt;a href="http://oldwiki.openwrt.org/UsbStorageHowto.html#head-4cae2302df70d74b6416a642e63ba92971ec34ad"&gt;Modules for USB 1.1&lt;/a&gt;&lt;/li&gt;&lt;li&gt;&lt;a href="http://oldwiki.openwrt.org/UsbStorageHowto.html#head-ad6b8dec2f6b27b1df39b011525c3c3989905701"&gt;Modules for USB 2.0&lt;/a&gt;&lt;/li&gt;&lt;li&gt;&lt;a href="http://oldwiki.openwrt.org/UsbStorageHowto.html#head-39f5cf9537651b17002a9d0fb488a4386d8cf226"&gt;Modules for storage&lt;/a&gt;&lt;/li&gt;&lt;li&gt;&lt;a href="http://oldwiki.openwrt.org/UsbStorageHowto.html#head-4267e67bea64dbd91e57895b89848e2f8b0e739e"&gt;Clean up&lt;/a&gt;&lt;/li&gt;&lt;/ol&gt;&lt;/li&gt;&lt;li&gt;&lt;a href="http://oldwiki.openwrt.org/UsbStorageHowto.html#head-cac7be08fbd6b1131515325711d9d86ac90d98fe"&gt;Configuration&lt;/a&gt;&lt;ol&gt;&lt;li&gt;&lt;a href="http://oldwiki.openwrt.org/UsbStorageHowto.html#head-0564458d5d98fa72705d153da0fd069f51e24e56"&gt;Usage as a storage device to extend storage&lt;/a&gt;&lt;/li&gt;&lt;li&gt;&lt;a href="http://oldwiki.openwrt.org/UsbStorageHowto.html#head-6d1886b78cce38eb5669113e3f4231a8497c9493"&gt;How do I boot from the USB device (prep)&lt;/a&gt;&lt;/li&gt;&lt;li&gt;&lt;a href="http://oldwiki.openwrt.org/UsbStorageHowto.html#head-9ebe967f8f380ab10e914cb14f761b7a5f27b07b"&gt;Boot Configuration - (White Russian)&lt;/a&gt;&lt;/li&gt;&lt;li&gt;&lt;a href="http://oldwiki.openwrt.org/UsbStorageHowto.html#head-48a82837822ffa8e49a817d3800f3f02c6bd7fb4"&gt;Boot Configuration (Kamikaze)&lt;/a&gt;&lt;/li&gt;&lt;li&gt;&lt;a href="http://oldwiki.openwrt.org/UsbStorageHowto.html#head-49c812f0ec696ae1a37f585b66987725718d533f"&gt;Installing and using OPKG packages in mount point other than root&lt;/a&gt;&lt;/li&gt;&lt;/ol&gt;&lt;/li&gt;&lt;li&gt;&lt;a href="http://oldwiki.openwrt.org/UsbStorageHowto.html#head-e449724bf5a50fe2216a2ba585a3c075a875396a"&gt;Links&lt;/a&gt;&lt;/li&gt;&lt;/ol&gt;&lt;/div&gt;&lt;p class="line874"&gt; &lt;span class="anchor" id="line-4"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-5"&gt;&lt;/span&gt;&lt;/p&gt;&lt;p class="line867"&gt; &lt;/p&gt;&lt;h1 id="head-7c1815e4262bd7d8a8e0abd4756a1c7ab7593cb6"&gt;Intro&lt;/h1&gt; &lt;span class="anchor" id="line-6"&gt;&lt;/span&gt;&lt;p class="line874"&gt;It's useful to extend the storage capacity of your USB enabled Wrt router f. e. making a central file server. This can easily be done with connecting USB storage devices (like a USB stick or a external USB harddisc) to the USB port on your router. &lt;span class="anchor" id="line-7"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-8"&gt;&lt;/span&gt;&lt;/p&gt;&lt;p class="line867"&gt; &lt;/p&gt;&lt;h1 id="head-0667198f4bc3f449b19998820e75e8ae5f123a79"&gt;Requirements&lt;/h1&gt; &lt;span class="anchor" id="line-9"&gt;&lt;/span&gt;&lt;ul&gt;&lt;li&gt;&lt;p class="line862"&gt;Supported router by &lt;a class="nonexistent" href="http://oldwiki.openwrt.org/OpenWrt.html"&gt;OpenWrt&lt;/a&gt; with USB (f. e. the Asus &lt;a href="http://oldwiki.openwrt.org/OpenWrtDocs%282f%29Hardware%282f%29Asus%282f%29WL500G.html"&gt;WL-500G&lt;/a&gt; or the Asus &lt;a href="http://oldwiki.openwrt.org/OpenWrtDocs%282f%29Hardware%282f%29Asus%282f%29WL500GD.html"&gt;WL-500G deluxe&lt;/a&gt;) &lt;span class="anchor" id="line-10"&gt;&lt;/span&gt;&lt;/p&gt;&lt;/li&gt;&lt;li&gt;&lt;p class="line862"&gt;a recent OpenWrt version installed (at least White Russian RC3) &lt;span class="anchor" id="line-11"&gt;&lt;/span&gt;&lt;/p&gt;&lt;/li&gt;&lt;li&gt;some kind of a USB storage device (a USB stick or a external USB harddisc) supported by Linux &lt;span class="anchor" id="line-12"&gt;&lt;/span&gt;&lt;/li&gt;&lt;li&gt;a USB hub (optional) to add more USB ports (it's probably a good idea to use an active USB hub with it's own PSU) &lt;span class="anchor" id="line-13"&gt;&lt;/span&gt;&lt;/li&gt;&lt;/ul&gt;&lt;p class="line867"&gt;&lt;strong&gt;NOTE: &lt;/strong&gt;&lt;a href="http://oldwiki.openwrt.org/WithUSBv2.html"&gt;Devices supporting USB v2.0&lt;/a&gt; &lt;span class="anchor" id="line-14"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-15"&gt;&lt;/span&gt;&lt;/p&gt;&lt;p class="line867"&gt; &lt;/p&gt;&lt;h1 id="head-4d171351157612255bc75912e7863556a1ae1286"&gt;Installation&lt;/h1&gt; &lt;span class="anchor" id="line-16"&gt;&lt;/span&gt;&lt;p class="line867"&gt;&lt;strong&gt;TIP:&lt;/strong&gt; Some routers are USB 1.1 and 2.0 compatible. To use both devices with both versions install the modules for USB 1.1 and 2.0. &lt;span class="anchor" id="line-17"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-18"&gt;&lt;/span&gt;&lt;/p&gt;&lt;p class="line867"&gt; &lt;/p&gt;&lt;h2 id="head-4cae2302df70d74b6416a642e63ba92971ec34ad"&gt;Modules for USB 1.1&lt;/h2&gt; &lt;span class="anchor" id="line-19"&gt;&lt;/span&gt;&lt;p class="line874"&gt;For USB 1.1, try installing the UHCI drivers first: &lt;span class="anchor" id="line-20"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-21"&gt;&lt;/span&gt;&lt;/p&gt;&lt;p class="line867"&gt;&lt;span class="anchor" id="line-22"&gt;&lt;/span&gt;&lt;/p&gt;&lt;pre&gt;ipkg install kmod-usb-uhci&lt;br /&gt;&lt;span class="anchor" id="line-23"&gt;&lt;/span&gt;insmod usbcore&lt;br /&gt;&lt;span class="anchor" id="line-24"&gt;&lt;/span&gt;insmod uhci&lt;br /&gt;&lt;span class="anchor" id="line-25"&gt;&lt;/span&gt;&lt;/pre&gt;&lt;span class="anchor" id="line-26"&gt;&lt;/span&gt;&lt;p class="line874"&gt;If you see the message: &lt;span class="anchor" id="line-27"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-28"&gt;&lt;/span&gt;&lt;/p&gt;&lt;p class="line867"&gt;&lt;span class="anchor" id="line-29"&gt;&lt;/span&gt;&lt;/p&gt;&lt;pre&gt;insmod: init_module: uhci: No such device&lt;br /&gt;&lt;span class="anchor" id="line-30"&gt;&lt;/span&gt;&lt;/pre&gt;&lt;span class="anchor" id="line-31"&gt;&lt;/span&gt;&lt;p class="line874"&gt;then your hardware does not have a UHCI compliant device, so you might as well remove the package: &lt;span class="anchor" id="line-32"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-33"&gt;&lt;/span&gt;&lt;/p&gt;&lt;p class="line867"&gt;&lt;span class="anchor" id="line-34"&gt;&lt;/span&gt;&lt;/p&gt;&lt;pre&gt;ipkg remove kmod-usb-uhci&lt;br /&gt;&lt;span class="anchor" id="line-35"&gt;&lt;/span&gt;&lt;/pre&gt;&lt;span class="anchor" id="line-36"&gt;&lt;/span&gt;&lt;p class="line867"&gt;&lt;strong&gt;TIP:&lt;/strong&gt; Most USB chips have UHCI controllers. If you received a "No such device" error, then try installing the &lt;tt&gt;kmod-usb-ohci&lt;/tt&gt; package instead. The BCM4710 and BCM4712 based routers require &lt;tt&gt;kmod-usb-ohci&lt;/tt&gt;: &lt;span class="anchor" id="line-37"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-38"&gt;&lt;/span&gt;&lt;/p&gt;&lt;p class="line867"&gt;&lt;span class="anchor" id="line-39"&gt;&lt;/span&gt;&lt;/p&gt;&lt;pre&gt;ipkg install kmod-usb-ohci&lt;br /&gt;&lt;span class="anchor" id="line-40"&gt;&lt;/span&gt;insmod usb-ohci&lt;br /&gt;&lt;span class="anchor" id="line-41"&gt;&lt;/span&gt;&lt;/pre&gt;&lt;span class="anchor" id="line-42"&gt;&lt;/span&gt;&lt;p class="line874"&gt;If you see the message: &lt;span class="anchor" id="line-43"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-44"&gt;&lt;/span&gt;&lt;/p&gt;&lt;p class="line867"&gt;&lt;span class="anchor" id="line-45"&gt;&lt;/span&gt;&lt;/p&gt;&lt;pre&gt;insmod: init_module: usb-ohci: No such device&lt;br /&gt;&lt;span class="anchor" id="line-46"&gt;&lt;/span&gt;&lt;/pre&gt;&lt;span class="anchor" id="line-47"&gt;&lt;/span&gt;&lt;p class="line874"&gt;then your hardware does not have a OHCI compliant device, so you might as well remove the package: &lt;span class="anchor" id="line-48"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-49"&gt;&lt;/span&gt;&lt;/p&gt;&lt;p class="line867"&gt;&lt;span class="anchor" id="line-50"&gt;&lt;/span&gt;&lt;/p&gt;&lt;pre&gt;ipkg remove kmod-usb-ohci&lt;br /&gt;&lt;span class="anchor" id="line-51"&gt;&lt;/span&gt;&lt;/pre&gt;&lt;span class="anchor" id="line-52"&gt;&lt;/span&gt;&lt;p class="line867"&gt; &lt;/p&gt;&lt;h2 id="head-ad6b8dec2f6b27b1df39b011525c3c3989905701"&gt;Modules for USB 2.0&lt;/h2&gt; &lt;span class="anchor" id="line-53"&gt;&lt;/span&gt;&lt;p class="line874"&gt;This package includes the modules for USB 2.0. &lt;span class="anchor" id="line-54"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-55"&gt;&lt;/span&gt;&lt;/p&gt;&lt;p class="line867"&gt;&lt;strong&gt;NOTE:&lt;/strong&gt; USB 2.0 support in White Russian is broken. There are some threads in the forum and some tickets as well if you like to read about what happens. (Im using WR 0.9 on an ASUS WL-500g Premium and USB 2.0 works just fine) &lt;span class="anchor" id="line-56"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-57"&gt;&lt;/span&gt;&lt;/p&gt;&lt;p class="line867"&gt;&lt;span class="anchor" id="line-58"&gt;&lt;/span&gt;&lt;/p&gt;&lt;pre&gt;ipkg install kmod-usb2&lt;br /&gt;&lt;span class="anchor" id="line-59"&gt;&lt;/span&gt;insmod ehci-hcd&lt;br /&gt;&lt;span class="anchor" id="line-60"&gt;&lt;/span&gt;&lt;/pre&gt;&lt;span class="anchor" id="line-61"&gt;&lt;/span&gt;&lt;p class="line874"&gt;If you see messages like this: &lt;span class="anchor" id="line-62"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-63"&gt;&lt;/span&gt;&lt;/p&gt;&lt;p class="line867"&gt;&lt;span class="anchor" id="line-64"&gt;&lt;/span&gt;&lt;/p&gt;&lt;pre&gt;insmod: unresolved symbol usb_calc_bus_time&lt;br /&gt;&lt;span class="anchor" id="line-65"&gt;&lt;/span&gt;&lt;/pre&gt;&lt;span class="anchor" id="line-66"&gt;&lt;/span&gt;&lt;p class="line874"&gt;try loading usbcore and then try ehci-hcd again: &lt;span class="anchor" id="line-67"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-68"&gt;&lt;/span&gt;&lt;/p&gt;&lt;p class="line867"&gt;&lt;span class="anchor" id="line-69"&gt;&lt;/span&gt;&lt;/p&gt;&lt;pre&gt;insmod usbcore&lt;br /&gt;&lt;span class="anchor" id="line-70"&gt;&lt;/span&gt;insmod ehci-hcd&lt;br /&gt;&lt;span class="anchor" id="line-71"&gt;&lt;/span&gt;&lt;/pre&gt;&lt;span class="anchor" id="line-72"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-73"&gt;&lt;/span&gt;&lt;p class="line874"&gt;Note that you may want to have available the utility, lsusb.  To enable it in Kamikaze, run  &lt;span class="anchor" id="line-74"&gt;&lt;/span&gt;"opkg install usbutils". &lt;span class="anchor" id="line-75"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-76"&gt;&lt;/span&gt;&lt;/p&gt;&lt;p class="line867"&gt; &lt;/p&gt;&lt;h2 id="head-39f5cf9537651b17002a9d0fb488a4386d8cf226"&gt;Modules for storage&lt;/h2&gt; &lt;span class="anchor" id="line-77"&gt;&lt;/span&gt;&lt;p class="line874"&gt;To add storage support finally install &lt;span class="anchor" id="line-78"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-79"&gt;&lt;/span&gt;&lt;/p&gt;&lt;p class="line867"&gt;&lt;span class="anchor" id="line-80"&gt;&lt;/span&gt;&lt;/p&gt;&lt;pre&gt;ipkg install kmod-usb-storage&lt;br /&gt;&lt;span class="anchor" id="line-81"&gt;&lt;/span&gt;insmod scsi_mod&lt;br /&gt;&lt;span class="anchor" id="line-82"&gt;&lt;/span&gt;insmod sd_mod&lt;br /&gt;&lt;span class="anchor" id="line-83"&gt;&lt;/span&gt;insmod usb-storage&lt;br /&gt;&lt;span class="anchor" id="line-84"&gt;&lt;/span&gt;&lt;/pre&gt;&lt;span class="anchor" id="line-85"&gt;&lt;/span&gt;&lt;p class="line867"&gt; &lt;/p&gt;&lt;h2 id="head-4267e67bea64dbd91e57895b89848e2f8b0e739e"&gt;Clean up&lt;/h2&gt; &lt;span class="anchor" id="line-86"&gt;&lt;/span&gt;&lt;p class="line867"&gt;&lt;strong&gt;TIP:&lt;/strong&gt; The &lt;tt&gt;max_scsi_luns=8&lt;/tt&gt; bit is needed for multi-card readers and should be added to the end of the &lt;tt&gt;scsi_mod&lt;/tt&gt; line in the &lt;tt&gt;/etc/modules.d/60-usb-storage&lt;/tt&gt; file. &lt;span class="anchor" id="line-87"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-88"&gt;&lt;/span&gt;&lt;/p&gt;&lt;p class="line867"&gt;OpenWrt uses &lt;tt&gt;/etc/modules.d&lt;/tt&gt; directory to load the modules automatically on the next reboot. So reboot the router with &lt;span class="anchor" id="line-89"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-90"&gt;&lt;/span&gt;&lt;/p&gt;&lt;p class="line867"&gt;&lt;span class="anchor" id="line-91"&gt;&lt;/span&gt;&lt;/p&gt;&lt;pre&gt;reboot&lt;br /&gt;&lt;span class="anchor" id="line-92"&gt;&lt;/span&gt;&lt;/pre&gt;&lt;span class="anchor" id="line-93"&gt;&lt;/span&gt;&lt;p class="line862"&gt;Now check if OpenWrt sees your USB device (of course inserting it into your Wrt router). If it's correct you should see similar messages as on the &lt;tt&gt;dmesg&lt;/tt&gt; dump below. &lt;span class="anchor" id="line-94"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-95"&gt;&lt;/span&gt;&lt;/p&gt;&lt;p class="line867"&gt;&lt;span class="anchor" id="line-96"&gt;&lt;/span&gt;&lt;/p&gt;&lt;pre&gt;dmesg&lt;br /&gt;&lt;span class="anchor" id="line-97"&gt;&lt;/span&gt;&lt;/pre&gt;&lt;span class="anchor" id="line-98"&gt;&lt;/span&gt;&lt;p class="line867"&gt;&lt;span class="anchor" id="line-99"&gt;&lt;/span&gt;&lt;/p&gt;&lt;pre&gt;usb.c: registered new driver usbdevfs&lt;br /&gt;&lt;span class="anchor" id="line-100"&gt;&lt;/span&gt;usb.c: registered new driver hub&lt;br /&gt;&lt;span class="anchor" id="line-101"&gt;&lt;/span&gt;uhci.c: USB Universal Host Controller Interface driver v1.1&lt;br /&gt;&lt;span class="anchor" id="line-102"&gt;&lt;/span&gt;PCI: Enabling device 01:02.0 (0000 -&gt; 0001)&lt;br /&gt;&lt;span class="anchor" id="line-103"&gt;&lt;/span&gt;uhci.c: USB UHCI at I/O 0x100, IRQ 2&lt;br /&gt;&lt;span class="anchor" id="line-104"&gt;&lt;/span&gt;usb.c: new USB bus registered, assigned bus number 1&lt;br /&gt;&lt;span class="anchor" id="line-105"&gt;&lt;/span&gt;hub.c: USB hub found&lt;br /&gt;&lt;span class="anchor" id="line-106"&gt;&lt;/span&gt;hub.c: 2 ports detected&lt;br /&gt;&lt;span class="anchor" id="line-107"&gt;&lt;/span&gt;PCI: Enabling device 01:02.1 (0000 -&gt; 0001)&lt;br /&gt;&lt;span class="anchor" id="line-108"&gt;&lt;/span&gt;uhci.c: USB UHCI at I/O 0x120, IRQ 2&lt;br /&gt;&lt;span class="anchor" id="line-109"&gt;&lt;/span&gt;usb.c: new USB bus registered, assigned bus number 2&lt;br /&gt;&lt;span class="anchor" id="line-110"&gt;&lt;/span&gt;hub.c: USB hub found&lt;br /&gt;&lt;span class="anchor" id="line-111"&gt;&lt;/span&gt;hub.c: 2 ports detected&lt;br /&gt;&lt;span class="anchor" id="line-112"&gt;&lt;/span&gt;hub.c: new USB device 01:02.0-2, assigned address 2&lt;br /&gt;&lt;span class="anchor" id="line-113"&gt;&lt;/span&gt;usb.c: USB device 2 (vend/prod 0xd7d/0x100) is not claimed by any active driver.&lt;br /&gt;&lt;span class="anchor" id="line-114"&gt;&lt;/span&gt;Initializing USB Mass Storage driver...&lt;br /&gt;&lt;span class="anchor" id="line-115"&gt;&lt;/span&gt;usb.c: registered new driver usb-storage&lt;br /&gt;&lt;span class="anchor" id="line-116"&gt;&lt;/span&gt;scsi0 : SCSI emulation for USB Mass Storage devices&lt;br /&gt;&lt;span class="anchor" id="line-117"&gt;&lt;/span&gt;  Vendor: Apacer    Model: Drive             Rev: 1.05&lt;br /&gt;&lt;span class="anchor" id="line-118"&gt;&lt;/span&gt;  Type:   Direct-Access                      ANSI SCSI revision: 02&lt;br /&gt;&lt;span class="anchor" id="line-119"&gt;&lt;/span&gt;Attached scsi removable disk sda at scsi0, channel 0, id 0, lun 0&lt;br /&gt;&lt;span class="anchor" id="line-120"&gt;&lt;/span&gt;SCSI device sda: 256000 512-byte hdwr sectors (131 MB)&lt;br /&gt;&lt;span class="anchor" id="line-121"&gt;&lt;/span&gt;sda: Write Protect is off&lt;br /&gt;&lt;span class="anchor" id="line-122"&gt;&lt;/span&gt;Partition check:&lt;br /&gt;&lt;span class="anchor" id="line-123"&gt;&lt;/span&gt; /dev/scsi/host0/bus0/target0/lun0: p1&lt;br /&gt;&lt;span class="anchor" id="line-124"&gt;&lt;/span&gt;WARNING: USB Mass Storage data integrity not assured&lt;br /&gt;&lt;span class="anchor" id="line-125"&gt;&lt;/span&gt;USB Mass Storage device found at 2&lt;br /&gt;&lt;span class="anchor" id="line-126"&gt;&lt;/span&gt;USB Mass Storage support registered.&lt;br /&gt;&lt;span class="anchor" id="line-127"&gt;&lt;/span&gt;&lt;/pre&gt;&lt;span class="anchor" id="line-128"&gt;&lt;/span&gt;&lt;p class="line867"&gt; &lt;/p&gt;&lt;h1 id="head-cac7be08fbd6b1131515325711d9d86ac90d98fe"&gt;Configuration&lt;/h1&gt; &lt;span class="anchor" id="line-129"&gt;&lt;/span&gt;&lt;p class="line867"&gt; &lt;/p&gt;&lt;h2 id="head-0564458d5d98fa72705d153da0fd069f51e24e56"&gt;Usage as a storage device to extend storage&lt;/h2&gt; &lt;span class="anchor" id="line-130"&gt;&lt;/span&gt;&lt;p class="line874"&gt;First install the kernel file system modules, for example: &lt;span class="anchor" id="line-131"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-132"&gt;&lt;/span&gt;&lt;/p&gt;&lt;p class="line867"&gt;&lt;span class="anchor" id="line-133"&gt;&lt;/span&gt;&lt;/p&gt;&lt;pre&gt;ipkg install kmod-vfat&lt;br /&gt;&lt;span class="anchor" id="line-134"&gt;&lt;/span&gt;&lt;/pre&gt;&lt;span class="anchor" id="line-135"&gt;&lt;/span&gt;&lt;p class="line874"&gt;Under Kamikaze 7.07 or later, use &lt;span class="anchor" id="line-136"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-137"&gt;&lt;/span&gt;&lt;/p&gt;&lt;p class="line867"&gt;&lt;span class="anchor" id="line-138"&gt;&lt;/span&gt;&lt;/p&gt;&lt;pre&gt;ipkg install kmod-fs-vfat&lt;br /&gt;&lt;span class="anchor" id="line-139"&gt;&lt;/span&gt;&lt;/pre&gt;&lt;span class="anchor" id="line-140"&gt;&lt;/span&gt;&lt;p class="line867"&gt;&lt;strong&gt;TIP:&lt;/strong&gt; After installing the modules, you should either reboot the device or load the installed modules manually: &lt;span class="anchor" id="line-141"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-142"&gt;&lt;/span&gt;&lt;/p&gt;&lt;p class="line867"&gt;&lt;span class="anchor" id="line-143"&gt;&lt;/span&gt;&lt;/p&gt;&lt;pre&gt;insmod fat&lt;br /&gt;&lt;span class="anchor" id="line-144"&gt;&lt;/span&gt;insmod vfat&lt;br /&gt;&lt;span class="anchor" id="line-145"&gt;&lt;/span&gt;&lt;/pre&gt;&lt;span class="anchor" id="line-146"&gt;&lt;/span&gt;&lt;p class="line867"&gt;&lt;strong&gt;TIP:&lt;/strong&gt; You can install support for more file systems by installing the appropriate packages. &lt;span class="anchor" id="line-147"&gt;&lt;/span&gt;&lt;/p&gt;&lt;div&gt;&lt;table&gt;&lt;tbody&gt;&lt;tr&gt;  &lt;td&gt;&lt;p class="line891"&gt;&lt;strong&gt;File system&lt;/strong&gt; &lt;/p&gt;&lt;/td&gt;   &lt;td&gt;&lt;p class="line891"&gt;&lt;strong&gt;Package name&lt;/strong&gt; &lt;/p&gt;&lt;/td&gt;   &lt;td&gt;&lt;p class="line891"&gt;&lt;strong&gt;Comment&lt;/strong&gt; &lt;/p&gt;&lt;/td&gt; &lt;/tr&gt; &lt;tr&gt;  &lt;td&gt;&lt;span class="anchor" id="line-148"&gt;&lt;/span&gt;&lt;p class="line862"&gt;VFAT/MSDOS &lt;/p&gt;&lt;/td&gt;   &lt;td&gt;&lt;p class="line862"&gt;kmod-vfat (kmod-fs-vfat) &lt;/p&gt;&lt;/td&gt;   &lt;td&gt;&lt;p class="line862"&gt;File system generally used in USB devices and older Windows &lt;/p&gt;&lt;/td&gt; &lt;/tr&gt; &lt;tr&gt;  &lt;td&gt;&lt;span class="anchor" id="line-149"&gt;&lt;/span&gt;&lt;p class="line862"&gt;EXT2 &lt;/p&gt;&lt;/td&gt;   &lt;td&gt;&lt;p class="line862"&gt;kmod-ext2 (kmod-fs-ext2) &lt;/p&gt;&lt;/td&gt;   &lt;td&gt;&lt;p class="line862"&gt; &lt;/p&gt;&lt;br /&gt;&lt;/td&gt; &lt;/tr&gt; &lt;tr&gt;  &lt;td&gt;&lt;span class="anchor" id="line-150"&gt;&lt;/span&gt;&lt;p class="line862"&gt;EXT3 &lt;/p&gt;&lt;/td&gt;   &lt;td&gt;&lt;p class="line862"&gt;kmod-ext3 (kmod-fs-ext3) &lt;/p&gt;&lt;/td&gt;   &lt;td&gt;&lt;p class="line862"&gt; &lt;/p&gt;&lt;br /&gt;&lt;/td&gt; &lt;/tr&gt; &lt;/tbody&gt;&lt;/table&gt;&lt;/div&gt;&lt;span class="anchor" id="line-151"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-152"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-153"&gt;&lt;/span&gt;&lt;p class="line862"&gt;Now install the &lt;tt&gt;fdisk&lt;/tt&gt; package from the White Russian's backports repository. How to use the backports repository see &lt;a href="http://oldwiki.openwrt.org/OpenWrtDocs%282f%29Packages.html"&gt;OpenWrtDocs/Packages&lt;/a&gt;. &lt;span class="anchor" id="line-154"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-155"&gt;&lt;/span&gt;&lt;/p&gt;&lt;p class="line867"&gt;&lt;span class="anchor" id="line-156"&gt;&lt;/span&gt;&lt;/p&gt;&lt;pre&gt;ipkg install fdisk&lt;br /&gt;&lt;span class="anchor" id="line-157"&gt;&lt;/span&gt;&lt;/pre&gt;&lt;span class="anchor" id="line-158"&gt;&lt;/span&gt;&lt;p class="line867"&gt;&lt;strong&gt;TIP:&lt;/strong&gt; If you don't find fdisk in the rc6 backports repository, you can use the rc5 backports version: &lt;span class="anchor" id="line-159"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-160"&gt;&lt;/span&gt;&lt;/p&gt;&lt;p class="line867"&gt;&lt;span class="anchor" id="line-161"&gt;&lt;/span&gt;&lt;/p&gt;&lt;pre&gt;ipkg install http://downloads.openwrt.org/backports/rc5/fdisk_2.12r-1_mipsel.ipk&lt;/pre&gt;&lt;span class="anchor" id="line-162"&gt;&lt;/span&gt;&lt;p class="line862"&gt;Create the&lt;tt&gt;/mnt&lt;/tt&gt;directory for the mount point on the flash &lt;span class="anchor" id="line-163"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-164"&gt;&lt;/span&gt;&lt;/p&gt;&lt;p class="line867"&gt;&lt;span class="anchor" id="line-165"&gt;&lt;/span&gt;&lt;/p&gt;&lt;pre&gt;mkdir /mnt&lt;br /&gt;&lt;span class="anchor" id="line-166"&gt;&lt;/span&gt;&lt;/pre&gt;&lt;span class="anchor" id="line-167"&gt;&lt;/span&gt;&lt;p class="line874"&gt;Check what partition you like to mount from your USB device &lt;span class="anchor" id="line-168"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-169"&gt;&lt;/span&gt;&lt;/p&gt;&lt;p class="line867"&gt;&lt;span class="anchor" id="line-170"&gt;&lt;/span&gt;&lt;/p&gt;&lt;pre&gt;fdisk -l&lt;br /&gt;&lt;span class="anchor" id="line-171"&gt;&lt;/span&gt;&lt;/pre&gt;&lt;span class="anchor" id="line-172"&gt;&lt;/span&gt;&lt;p class="line874"&gt;Finally you can mount and use your USB device (with relevant modules for your file system in memory and created directory for mount): &lt;span class="anchor" id="line-173"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-174"&gt;&lt;/span&gt;&lt;/p&gt;&lt;p class="line867"&gt;&lt;span class="anchor" id="line-175"&gt;&lt;/span&gt;&lt;/p&gt;&lt;pre&gt;mount /dev/scsi/host0/bus0/target0/lun0/part1 /mnt&lt;br /&gt;&lt;span class="anchor" id="line-176"&gt;&lt;/span&gt;&lt;/pre&gt;&lt;span class="anchor" id="line-177"&gt;&lt;/span&gt;&lt;p class="line874"&gt;Be happy and use your USB device like on every other GNU/Linux system or create a file server using Samba. &lt;span class="anchor" id="line-178"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-179"&gt;&lt;/span&gt;&lt;/p&gt;&lt;p class="line874"&gt;If you go with ext2 with journaling and install kmod-fs-ext2 , kmod-fs-ext3 and e2fsprogs you can use it like a normal unix type disk. Create the script /etc/init.d/usbdrive ( changing the mount point to match yours ) &lt;span class="anchor" id="line-180"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-181"&gt;&lt;/span&gt;&lt;/p&gt;&lt;p class="line867"&gt;&lt;span class="anchor" id="line-182"&gt;&lt;/span&gt;&lt;/p&gt;&lt;pre&gt;#!/bin/sh /etc/rc.common&lt;br /&gt;&lt;span class="anchor" id="line-183"&gt;&lt;/span&gt;START=99&lt;br /&gt;&lt;span class="anchor" id="line-184"&gt;&lt;/span&gt;STOP=40&lt;br /&gt;&lt;span class="anchor" id="line-185"&gt;&lt;/span&gt;start()&lt;br /&gt;&lt;span class="anchor" id="line-186"&gt;&lt;/span&gt;{&lt;br /&gt;&lt;span class="anchor" id="line-187"&gt;&lt;/span&gt;        echo -n "Testing USB Partition:  "&lt;br /&gt;&lt;span class="anchor" id="line-188"&gt;&lt;/span&gt;        e2fsck -p /dev/scsi/host0/bus0/target0/lun0/part1 &amp;amp;&lt;br /&gt;&lt;span class="anchor" id="line-189"&gt;&lt;/span&gt;        sleep 5&lt;br /&gt;&lt;span class="anchor" id="line-190"&gt;&lt;/span&gt;        echo -n "Mounting USB drive: "&lt;br /&gt;&lt;span class="anchor" id="line-191"&gt;&lt;/span&gt;        mount -t ext3 -o noatime /dev/scsi/host0/bus0/target0/lun0/part1 /usb&lt;br /&gt;&lt;span class="anchor" id="line-192"&gt;&lt;/span&gt;        echo "Done."&lt;br /&gt;&lt;span class="anchor" id="line-193"&gt;&lt;/span&gt;}&lt;br /&gt;&lt;span class="anchor" id="line-194"&gt;&lt;/span&gt;stop()&lt;br /&gt;&lt;span class="anchor" id="line-195"&gt;&lt;/span&gt;{&lt;br /&gt;&lt;span class="anchor" id="line-196"&gt;&lt;/span&gt;        echo -n "Umounting USB drive:  "&lt;br /&gt;&lt;span class="anchor" id="line-197"&gt;&lt;/span&gt;        sync&lt;br /&gt;&lt;span class="anchor" id="line-198"&gt;&lt;/span&gt;        sync&lt;br /&gt;&lt;span class="anchor" id="line-199"&gt;&lt;/span&gt;        umount /dev/scsi/host0/bus0/target0/lun0/part1&lt;br /&gt;&lt;span class="anchor" id="line-200"&gt;&lt;/span&gt;        echo "Done."&lt;br /&gt;&lt;span class="anchor" id="line-201"&gt;&lt;/span&gt;}&lt;br /&gt;&lt;span class="anchor" id="line-202"&gt;&lt;/span&gt;restart()&lt;br /&gt;&lt;span class="anchor" id="line-203"&gt;&lt;/span&gt;{&lt;br /&gt;&lt;span class="anchor" id="line-204"&gt;&lt;/span&gt;        stop&lt;br /&gt;&lt;span class="anchor" id="line-205"&gt;&lt;/span&gt;        start&lt;br /&gt;&lt;span class="anchor" id="line-206"&gt;&lt;/span&gt;}&lt;br /&gt;&lt;span class="anchor" id="line-207"&gt;&lt;/span&gt;&lt;/pre&gt;&lt;span class="anchor" id="line-208"&gt;&lt;/span&gt;&lt;p class="line874"&gt;then do a ./usbdrive enable &lt;span class="anchor" id="line-209"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-210"&gt;&lt;/span&gt;&lt;/p&gt;&lt;p class="line874"&gt;You may need language packages to support the filenames on various file systems: &lt;span class="anchor" id="line-211"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-212"&gt;&lt;/span&gt;&lt;/p&gt;&lt;p class="line874"&gt;kmod-nls-base - Kernel modules for basic native language support &lt;span class="anchor" id="line-213"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-214"&gt;&lt;/span&gt;&lt;/p&gt;&lt;p class="line874"&gt;kmod-nls-cp437 - Kernel module for codepage 437 &lt;span class="anchor" id="line-215"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-216"&gt;&lt;/span&gt;&lt;/p&gt;&lt;p class="line874"&gt;kmod-nls-cp850 - Kernel module for codepage 850 &lt;span class="anchor" id="line-217"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-218"&gt;&lt;/span&gt;&lt;/p&gt;&lt;p class="line874"&gt;kmod-nls-iso8859-1 - Kernel module for iso8859-1 charset support &lt;span class="anchor" id="line-219"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-220"&gt;&lt;/span&gt;&lt;/p&gt;&lt;p class="line874"&gt;kmod-nls-iso8859-15 - Kernel module for iso8859-15 charset support &lt;span class="anchor" id="line-221"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-222"&gt;&lt;/span&gt;&lt;/p&gt;&lt;p class="line874"&gt;kmod-nls-utf8 - Kernel module for utf8 support &lt;span class="anchor" id="line-223"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-224"&gt;&lt;/span&gt;&lt;/p&gt;&lt;p class="line867"&gt; &lt;/p&gt;&lt;h2 id="head-6d1886b78cce38eb5669113e3f4231a8497c9493"&gt;How do I boot from the USB device (prep)&lt;/h2&gt; &lt;span class="anchor" id="line-225"&gt;&lt;/span&gt;&lt;p class="line874"&gt;For this to work you need the same kernel modules for USB as described above. You also need the modules for the EXT3 file system: &lt;span class="anchor" id="line-226"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-227"&gt;&lt;/span&gt;&lt;/p&gt;&lt;p class="line867"&gt;&lt;img alt="/!\" src="http://oldwiki.openwrt.org/classic/img/alert.png" title="/!\" width="15" height="15" /&gt; &lt;strong&gt;NOTE:&lt;/strong&gt; &lt;strong&gt;IMPORTANT:&lt;/strong&gt; &lt;em&gt;There are reports that this procedure bricks routers running Kamikaze with 2.6 kernel - proceed at your own risk! (It works for some, not for others)&lt;/em&gt; &lt;span class="anchor" id="line-228"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-229"&gt;&lt;/span&gt;&lt;/p&gt;&lt;p class="line867"&gt;&lt;span class="anchor" id="line-230"&gt;&lt;/span&gt;&lt;/p&gt;&lt;pre&gt;ipkg install kmod-ext2 kmod-ext3&lt;br /&gt;&lt;span class="anchor" id="line-231"&gt;&lt;/span&gt;&lt;/pre&gt;&lt;span class="anchor" id="line-232"&gt;&lt;/span&gt;&lt;p class="line874"&gt;After installing the modules, you should either reboot the device or load the installed modules manually: &lt;span class="anchor" id="line-233"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-234"&gt;&lt;/span&gt;&lt;/p&gt;&lt;p class="line867"&gt;&lt;span class="anchor" id="line-235"&gt;&lt;/span&gt;&lt;/p&gt;&lt;pre&gt;insmod ext2&lt;br /&gt;&lt;span class="anchor" id="line-236"&gt;&lt;/span&gt;insmod jbd&lt;br /&gt;&lt;span class="anchor" id="line-237"&gt;&lt;/span&gt;insmod ext3&lt;br /&gt;&lt;span class="anchor" id="line-238"&gt;&lt;/span&gt;&lt;/pre&gt;&lt;span class="anchor" id="line-239"&gt;&lt;/span&gt;&lt;p class="line862"&gt;The next step is to partition the USB device and create an EXT3 FS partition. This requires &lt;tt&gt;fdisk&lt;/tt&gt; (install it as described above). You can do the partioning in OpenWrt it self or on a normal PC. &lt;span class="anchor" id="line-240"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-241"&gt;&lt;/span&gt;&lt;/p&gt;&lt;p class="line867"&gt;&lt;strong&gt;In OpenWrt do&lt;/strong&gt; &lt;span class="anchor" id="line-242"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-243"&gt;&lt;/span&gt;&lt;/p&gt;&lt;p class="line867"&gt;&lt;span class="anchor" id="line-244"&gt;&lt;/span&gt;&lt;/p&gt;&lt;pre&gt;fdisk /dev/sda&lt;br /&gt;&lt;span class="anchor" id="line-245"&gt;&lt;/span&gt;-OR-&lt;br /&gt;&lt;span class="anchor" id="line-246"&gt;&lt;/span&gt;fdisk /dev/scsi/host0/bus0/target0/lun0/disc&lt;br /&gt;&lt;span class="anchor" id="line-247"&gt;&lt;/span&gt;&lt;/pre&gt;&lt;span class="anchor" id="line-248"&gt;&lt;/span&gt;&lt;p class="line867"&gt;&lt;strong&gt;On a GNU/Linux desktop PC do&lt;/strong&gt; &lt;span class="anchor" id="line-249"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-250"&gt;&lt;/span&gt;&lt;/p&gt;&lt;p class="line867"&gt;&lt;span class="anchor" id="line-251"&gt;&lt;/span&gt;&lt;/p&gt;&lt;pre&gt;fdisk /dev/sda&lt;br /&gt;&lt;span class="anchor" id="line-252"&gt;&lt;/span&gt;&lt;/pre&gt;&lt;span class="anchor" id="line-253"&gt;&lt;/span&gt;&lt;p class="line867"&gt;&lt;img alt="/!\" src="http://oldwiki.openwrt.org/classic/img/alert.png" title="/!\" width="15" height="15" /&gt; &lt;strong&gt;IMPORTANT:&lt;/strong&gt; Make sure you are modifying the right device. If you have any other USB drives, or a SCSI or SATA drive, your USB device might be at &lt;tt&gt;/dev/sdb&lt;/tt&gt; or &lt;tt&gt;/dev/sdc&lt;/tt&gt; (and so on) instead! Also, you do &lt;em&gt;not&lt;/em&gt; want to use a partition such as &lt;tt&gt;/dev/sda1&lt;/tt&gt; (note the number at the end); you &lt;em&gt;do&lt;/em&gt; want the base device name. &lt;span class="anchor" id="line-254"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-255"&gt;&lt;/span&gt;&lt;/p&gt;&lt;p class="line862"&gt;For more information about using &lt;tt&gt;fdisk&lt;/tt&gt;, see &lt;a class="http" href="http://www.tldp.org/HOWTO/Partition/fdisk_partitioning.html"&gt;http://www.tldp.org/HOWTO/Partition/fdisk_partitioning.html&lt;/a&gt;. &lt;span class="anchor" id="line-256"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-257"&gt;&lt;/span&gt;&lt;/p&gt;&lt;p class="line874"&gt;Next, "format" the newly created partition. &lt;span class="anchor" id="line-258"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-259"&gt;&lt;/span&gt;&lt;/p&gt;&lt;p class="line867"&gt;&lt;strong&gt;In OpenWrt do&lt;/strong&gt; &lt;span class="anchor" id="line-260"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-261"&gt;&lt;/span&gt;&lt;/p&gt;&lt;p class="line862"&gt;For doing this in OpenWrt you first have to install the &lt;tt&gt;e2fsprogs&lt;/tt&gt; package from the White Russian's backports repository. How to use the backports repository see &lt;a href="http://oldwiki.openwrt.org/OpenWrtDocs%282f%29Packages.html"&gt;OpenWrtDocs/Packages&lt;/a&gt;. &lt;span class="anchor" id="line-262"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-263"&gt;&lt;/span&gt;&lt;/p&gt;&lt;p class="line867"&gt;&lt;span class="anchor" id="line-264"&gt;&lt;/span&gt;&lt;/p&gt;&lt;pre&gt;ipkg install e2fsprogs&lt;br /&gt;&lt;span class="anchor" id="line-265"&gt;&lt;/span&gt;&lt;/pre&gt;&lt;span class="anchor" id="line-266"&gt;&lt;/span&gt;&lt;p class="line874"&gt;Then "format" your partition with &lt;span class="anchor" id="line-267"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-268"&gt;&lt;/span&gt;&lt;/p&gt;&lt;p class="line867"&gt;&lt;span class="anchor" id="line-269"&gt;&lt;/span&gt;&lt;/p&gt;&lt;pre&gt;mke2fs -j /dev/scsi/host0/bus0/target0/lun0/part1&lt;br /&gt;&lt;span class="anchor" id="line-270"&gt;&lt;/span&gt;&lt;/pre&gt;&lt;span class="anchor" id="line-271"&gt;&lt;/span&gt;&lt;p class="line874"&gt;mke2fs may fail on large disks (e.g. 300GB) if there is not enough memory, consider adding a swap partition, even if it is only used during mke2fs. &lt;span class="anchor" id="line-272"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-273"&gt;&lt;/span&gt;&lt;/p&gt;&lt;p class="line874"&gt;If you keep getting errors like: &lt;span class="anchor" id="line-274"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-275"&gt;&lt;/span&gt;&lt;/p&gt;&lt;p class="line867"&gt;&lt;span class="anchor" id="line-276"&gt;&lt;/span&gt;&lt;/p&gt;&lt;pre&gt;Creating journal (4096 blocks): mke2fs: No such file or directory&lt;br /&gt;&lt;span class="anchor" id="line-277"&gt;&lt;/span&gt;        while trying to create journal&lt;br /&gt;&lt;span class="anchor" id="line-278"&gt;&lt;/span&gt;&lt;/pre&gt;&lt;span class="anchor" id="line-279"&gt;&lt;/span&gt;&lt;p class="line874"&gt;then run the following command: &lt;span class="anchor" id="line-280"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-281"&gt;&lt;/span&gt;&lt;/p&gt;&lt;p class="line867"&gt;&lt;span class="anchor" id="line-282"&gt;&lt;/span&gt;&lt;/p&gt;&lt;pre&gt;ln -s /proc/mounts /etc/mtab&lt;br /&gt;&lt;span class="anchor" id="line-283"&gt;&lt;/span&gt;&lt;/pre&gt;&lt;span class="anchor" id="line-284"&gt;&lt;/span&gt;&lt;p class="line874"&gt;Now, we will copy everything from the flash to the USB device (make sure the EXT3 modules are loaded): &lt;span class="anchor" id="line-285"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-286"&gt;&lt;/span&gt;&lt;/p&gt;&lt;p class="line867"&gt;&lt;span class="anchor" id="line-287"&gt;&lt;/span&gt;&lt;/p&gt;&lt;pre&gt;# mount it&lt;br /&gt;&lt;span class="anchor" id="line-288"&gt;&lt;/span&gt;mount -t ext3 /dev/scsi/host0/bus0/target0/lun0/part1 /mnt&lt;br /&gt;&lt;span class="anchor" id="line-289"&gt;&lt;/span&gt;# now, we need to mount the root contents somewhere so we can copy&lt;br /&gt;&lt;span class="anchor" id="line-290"&gt;&lt;/span&gt;# them without copying /mnt and /proc to the new usb device&lt;br /&gt;&lt;span class="anchor" id="line-291"&gt;&lt;/span&gt;mkdir /tmp/root&lt;br /&gt;&lt;span class="anchor" id="line-292"&gt;&lt;/span&gt;# if you're using squashfs, you want to copy the squashfs contents,&lt;br /&gt;&lt;span class="anchor" id="line-293"&gt;&lt;/span&gt;# not the jffs2 symlinks, so use the command:&lt;br /&gt;&lt;span class="anchor" id="line-294"&gt;&lt;/span&gt;mount -o bind /rom /tmp/root&lt;br /&gt;&lt;span class="anchor" id="line-295"&gt;&lt;/span&gt;# if you're using jffs2 then use the command /&lt;br /&gt;&lt;span class="anchor" id="line-296"&gt;&lt;/span&gt;mount -o bind / /tmp/root&lt;br /&gt;&lt;span class="anchor" id="line-297"&gt;&lt;/span&gt;# now /tmp/root contains the root filesystem with no extra directories mounted&lt;br /&gt;&lt;span class="anchor" id="line-298"&gt;&lt;/span&gt;# so we just copy this to the usb device&lt;br /&gt;&lt;span class="anchor" id="line-299"&gt;&lt;/span&gt;cp /tmp/root/* /mnt -a&lt;br /&gt;&lt;span class="anchor" id="line-300"&gt;&lt;/span&gt;# and now we unmount both the usb and our /tmp/root&lt;br /&gt;&lt;span class="anchor" id="line-301"&gt;&lt;/span&gt;umount /tmp/root&lt;br /&gt;&lt;span class="anchor" id="line-302"&gt;&lt;/span&gt;umount /mnt&lt;br /&gt;&lt;span class="anchor" id="line-303"&gt;&lt;/span&gt;&lt;/pre&gt;&lt;span class="anchor" id="line-304"&gt;&lt;/span&gt;&lt;p class="line867"&gt;&lt;img alt="/!\" src="http://oldwiki.openwrt.org/classic/img/alert.png" title="/!\" width="15" height="15" /&gt; Problems with booting from USB storage were reported with &lt;a href="http://oldwiki.openwrt.org/WhiteRussian.html"&gt;WhiteRussian&lt;/a&gt; RC4 or later, which is the version that introduced USB hotplug support. If you encounter problems as well, try disabling USB hotplug. (more info on this?) &lt;span class="anchor" id="line-305"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-306"&gt;&lt;/span&gt;&lt;/p&gt;&lt;p class="line862"&gt;As earlier stated on this page (to remove &lt;tt&gt;/etc/hotplug.d/usb/01-mount&lt;/tt&gt;) is NOT a good idea, as this is where usbfs is mounted, so usb-storage might work fine but lsusb wohn't list your devices, and most software using USB won't be able to find devices since /proc/bus/usb will remain empty? &lt;span class="anchor" id="line-307"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-308"&gt;&lt;/span&gt;&lt;/p&gt;&lt;p class="line862"&gt;So either remove the file and mount usbfs somewhere else, or everything inside except the line which goes: [ -f /proc/bus/usb/devices ] || mount -t usbfs none /proc/bus/usb &lt;span class="anchor" id="line-309"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-310"&gt;&lt;/span&gt;&lt;/p&gt;&lt;p class="line867"&gt; &lt;/p&gt;&lt;h2 id="head-9ebe967f8f380ab10e914cb14f761b7a5f27b07b"&gt;Boot Configuration - (White Russian)&lt;/h2&gt; &lt;span class="anchor" id="line-311"&gt;&lt;/span&gt;&lt;p class="line862"&gt;Next, remove &lt;tt&gt;/sbin/init&lt;/tt&gt; from the JFFS2 partition (this is just a symlink to BusyBox anyway): &lt;span class="anchor" id="line-312"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-313"&gt;&lt;/span&gt;&lt;/p&gt;&lt;p class="line867"&gt;&lt;span class="anchor" id="line-314"&gt;&lt;/span&gt;&lt;/p&gt;&lt;pre&gt;rm /sbin/init&lt;br /&gt;&lt;span class="anchor" id="line-315"&gt;&lt;/span&gt;&lt;/pre&gt;&lt;span class="anchor" id="line-316"&gt;&lt;/span&gt;&lt;p class="line874"&gt;And replace it with this script: &lt;span class="anchor" id="line-317"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-318"&gt;&lt;/span&gt;&lt;/p&gt;&lt;p class="line867"&gt;&lt;span class="anchor" id="line-319"&gt;&lt;/span&gt;&lt;/p&gt;&lt;pre&gt;#!/bin/sh&lt;br /&gt;&lt;span class="anchor" id="line-320"&gt;&lt;/span&gt;# change this to your boot partition&lt;br /&gt;&lt;span class="anchor" id="line-321"&gt;&lt;/span&gt;boot_dev="/dev/scsi/host0/bus0/target0/lun0/part1"&lt;br /&gt;&lt;span class="anchor" id="line-322"&gt;&lt;/span&gt;# install needed modules for usb and the ext3 filesystem&lt;br /&gt;&lt;span class="anchor" id="line-323"&gt;&lt;/span&gt;# **NOTE** for usb2.0 replace "uhci" with "ehci-hcd"&lt;br /&gt;&lt;span class="anchor" id="line-324"&gt;&lt;/span&gt;# **NOTE** for ohci chipsets replace "uhci" with "usb-ohci"&lt;br /&gt;&lt;span class="anchor" id="line-325"&gt;&lt;/span&gt;for module in usbcore uhci scsi_mod sd_mod usb-storage jbd ext3; do {&lt;br /&gt;&lt;span class="anchor" id="line-326"&gt;&lt;/span&gt;        insmod $module&lt;br /&gt;&lt;span class="anchor" id="line-327"&gt;&lt;/span&gt;}; done&lt;br /&gt;&lt;span class="anchor" id="line-328"&gt;&lt;/span&gt;# this may need to be higher if your disk is slow to initialize&lt;br /&gt;&lt;span class="anchor" id="line-329"&gt;&lt;/span&gt;sleep 4s&lt;br /&gt;&lt;span class="anchor" id="line-330"&gt;&lt;/span&gt;# mount the usb stick&lt;br /&gt;&lt;span class="anchor" id="line-331"&gt;&lt;/span&gt;mount "$boot_dev" /mnt&lt;br /&gt;&lt;span class="anchor" id="line-332"&gt;&lt;/span&gt;# if everything looks ok, do the pivot root&lt;br /&gt;&lt;span class="anchor" id="line-333"&gt;&lt;/span&gt;[ -x /mnt/sbin/init ] &amp;amp;&amp;amp; {&lt;br /&gt;&lt;span class="anchor" id="line-334"&gt;&lt;/span&gt;        mount -o move /proc /mnt/proc &amp;amp;&amp;amp; \&lt;br /&gt;&lt;span class="anchor" id="line-335"&gt;&lt;/span&gt;        pivot_root /mnt /mnt/mnt &amp;amp;&amp;amp; {&lt;br /&gt;&lt;span class="anchor" id="line-336"&gt;&lt;/span&gt;                mount -o move /mnt/dev /dev&lt;br /&gt;&lt;span class="anchor" id="line-337"&gt;&lt;/span&gt;                mount -o move /mnt/tmp /tmp&lt;br /&gt;&lt;span class="anchor" id="line-338"&gt;&lt;/span&gt;                mount -o move /mnt/jffs2 /jffs2 2&gt;&amp;amp;-&lt;br /&gt;&lt;span class="anchor" id="line-339"&gt;&lt;/span&gt;                mount -o move /mnt/sys /sys 2&gt;&amp;amp;-&lt;br /&gt;&lt;span class="anchor" id="line-340"&gt;&lt;/span&gt;        }&lt;br /&gt;&lt;span class="anchor" id="line-341"&gt;&lt;/span&gt;}&lt;br /&gt;&lt;span class="anchor" id="line-342"&gt;&lt;/span&gt;# finally, run the real init (from USB hopefully).&lt;br /&gt;&lt;span class="anchor" id="line-343"&gt;&lt;/span&gt;exec /bin/busybox init&lt;br /&gt;&lt;span class="anchor" id="line-344"&gt;&lt;/span&gt;&lt;/pre&gt;&lt;span class="anchor" id="line-345"&gt;&lt;/span&gt;&lt;p class="line862"&gt;Make sure your new &lt;tt&gt;/sbin/init&lt;/tt&gt; is executable: &lt;span class="anchor" id="line-346"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-347"&gt;&lt;/span&gt;&lt;/p&gt;&lt;p class="line867"&gt;&lt;span class="anchor" id="line-348"&gt;&lt;/span&gt;&lt;/p&gt;&lt;pre&gt;chmod a+x /sbin/init&lt;br /&gt;&lt;span class="anchor" id="line-349"&gt;&lt;/span&gt;&lt;/pre&gt;&lt;span class="anchor" id="line-350"&gt;&lt;/span&gt;&lt;p class="line874"&gt;Now just reboot, and if you did everything right it should boot from the USB device automatically. &lt;span class="anchor" id="line-351"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-352"&gt;&lt;/span&gt;&lt;/p&gt;&lt;p class="line874"&gt;If it could not boot from the USB device it will boot normally from the file system found on the flash as fallback. &lt;span class="anchor" id="line-353"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-354"&gt;&lt;/span&gt;&lt;/p&gt;&lt;p class="line874"&gt;Note that it is safest to leave the 'pivot_root' procedure as an ordinary script file, not part of the code automatically run on startup, at least until you are certain that it is operating as desired. This allows you to recover from any problems created by this script by simply rebooting the router without it. &lt;span class="anchor" id="line-355"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-356"&gt;&lt;/span&gt;&lt;/p&gt;&lt;p class="line867"&gt; &lt;/p&gt;&lt;h2 id="head-48a82837822ffa8e49a817d3800f3f02c6bd7fb4"&gt;Boot Configuration (Kamikaze)&lt;/h2&gt; &lt;span class="anchor" id="line-357"&gt;&lt;/span&gt;&lt;p class="line874"&gt;First Create a script /etc/init.d/pivotroot &lt;span class="anchor" id="line-358"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-359"&gt;&lt;/span&gt;&lt;/p&gt;&lt;p class="line867"&gt;&lt;span class="anchor" id="line-360"&gt;&lt;/span&gt;&lt;/p&gt;&lt;pre&gt;#!/bin/sh&lt;br /&gt;&lt;span class="anchor" id="line-361"&gt;&lt;/span&gt;# change this to your boot partition&lt;br /&gt;&lt;span class="anchor" id="line-362"&gt;&lt;/span&gt;boot_dev="/dev/sda1"&lt;br /&gt;&lt;span class="anchor" id="line-363"&gt;&lt;/span&gt;# install needed modules for usb and the ext3 filesystem&lt;br /&gt;&lt;span class="anchor" id="line-364"&gt;&lt;/span&gt;# **NOTE** for usb2.0 replace "uhci" with "ehci_hcd"&lt;br /&gt;&lt;span class="anchor" id="line-365"&gt;&lt;/span&gt;# **NOTE** for ohci chipsets replace "uhci" with "usb-ohci"&lt;br /&gt;&lt;span class="anchor" id="line-366"&gt;&lt;/span&gt;for module in usbcore uhci scsi_mod sd_mod usb-storage jbd kmod-fs-ext2 kmod-fs-ext3 ; do {&lt;br /&gt;&lt;span class="anchor" id="line-367"&gt;&lt;/span&gt;        insmod $module&lt;br /&gt;&lt;span class="anchor" id="line-368"&gt;&lt;/span&gt;}; done&lt;br /&gt;&lt;span class="anchor" id="line-369"&gt;&lt;/span&gt;# this may need to be higher if your disk is slow to initialize&lt;br /&gt;&lt;span class="anchor" id="line-370"&gt;&lt;/span&gt;sleep 4s&lt;br /&gt;&lt;span class="anchor" id="line-371"&gt;&lt;/span&gt;# mount the usb stick&lt;br /&gt;&lt;span class="anchor" id="line-372"&gt;&lt;/span&gt;mount "$boot_dev" /mnt&lt;br /&gt;&lt;span class="anchor" id="line-373"&gt;&lt;/span&gt;# if everything looks ok, do the pivot root&lt;br /&gt;&lt;span class="anchor" id="line-374"&gt;&lt;/span&gt;[ -x /mnt/sbin/init ] &amp;amp;&amp;amp; {&lt;br /&gt;&lt;span class="anchor" id="line-375"&gt;&lt;/span&gt;        mount -o move /proc /mnt/proc &amp;amp;&amp;amp; \&lt;br /&gt;&lt;span class="anchor" id="line-376"&gt;&lt;/span&gt;        pivot_root /mnt /mnt/mnt &amp;amp;&amp;amp; {&lt;br /&gt;&lt;span class="anchor" id="line-377"&gt;&lt;/span&gt;                mount -o move /mnt/dev /dev&lt;br /&gt;&lt;span class="anchor" id="line-378"&gt;&lt;/span&gt;                mount -o move /mnt/tmp /tmp&lt;br /&gt;&lt;span class="anchor" id="line-379"&gt;&lt;/span&gt;                mount -o move /mnt/jffs2 /jffs2 2&gt;&amp;amp;-&lt;br /&gt;&lt;span class="anchor" id="line-380"&gt;&lt;/span&gt;                mount -o move /mnt/sys /sys 2&gt;&amp;amp;-&lt;br /&gt;&lt;span class="anchor" id="line-381"&gt;&lt;/span&gt;        }&lt;br /&gt;&lt;span class="anchor" id="line-382"&gt;&lt;/span&gt;}&lt;br /&gt;&lt;span class="anchor" id="line-383"&gt;&lt;/span&gt;&lt;/pre&gt;&lt;span class="anchor" id="line-384"&gt;&lt;/span&gt;&lt;p class="line867"&gt;&lt;em&gt;&lt;strong&gt;Note:&lt;/strong&gt;&lt;/em&gt; for Kamikaze 2.4 kernel that may not have hotplug2 then try using this instead.  Tested with openwrt-brcm-2.4-squashfs. &lt;span class="anchor" id="line-385"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-386"&gt;&lt;/span&gt;&lt;/p&gt;&lt;p class="line867"&gt;&lt;span class="anchor" id="line-387"&gt;&lt;/span&gt;&lt;/p&gt;&lt;pre&gt;#!/bin/sh&lt;br /&gt;&lt;span class="anchor" id="line-388"&gt;&lt;/span&gt;# change this to your boot partition&lt;br /&gt;&lt;span class="anchor" id="line-389"&gt;&lt;/span&gt;boot_dev="/dev/discs/disc0/part1"&lt;br /&gt;&lt;span class="anchor" id="line-390"&gt;&lt;/span&gt;# install needed modules for usb and the ext3 filesystem&lt;br /&gt;&lt;span class="anchor" id="line-391"&gt;&lt;/span&gt;# **NOTE** for usb2.0 replace "uhci" with "ehci-hcd"&lt;br /&gt;&lt;span class="anchor" id="line-392"&gt;&lt;/span&gt;# **NOTE** for ohci chipsets replace "uhci" with "usb-ohci"&lt;br /&gt;&lt;span class="anchor" id="line-393"&gt;&lt;/span&gt;for module in usbcore uhci scsi_mod sd_mod usb-storage jbd ext2 ext3 ; do {&lt;br /&gt;&lt;span class="anchor" id="line-394"&gt;&lt;/span&gt;        insmod $module&lt;br /&gt;&lt;span class="anchor" id="line-395"&gt;&lt;/span&gt;}; done&lt;br /&gt;&lt;span class="anchor" id="line-396"&gt;&lt;/span&gt;# this may need to be higher if your disk is slow to initialize&lt;br /&gt;&lt;span class="anchor" id="line-397"&gt;&lt;/span&gt;sleep 4s&lt;br /&gt;&lt;span class="anchor" id="line-398"&gt;&lt;/span&gt;# mount the usb stick&lt;br /&gt;&lt;span class="anchor" id="line-399"&gt;&lt;/span&gt;mount "$boot_dev" /mnt&lt;br /&gt;&lt;span class="anchor" id="line-400"&gt;&lt;/span&gt;# if everything looks ok, do the pivot root&lt;br /&gt;&lt;span class="anchor" id="line-401"&gt;&lt;/span&gt;[ -x /mnt/sbin/init ] &amp;amp;&amp;amp; {&lt;br /&gt;&lt;span class="anchor" id="line-402"&gt;&lt;/span&gt;        mount -o move /proc /mnt/proc &amp;amp;&amp;amp; \&lt;br /&gt;&lt;span class="anchor" id="line-403"&gt;&lt;/span&gt;        pivot_root /mnt /mnt/mnt &amp;amp;&amp;amp; {&lt;br /&gt;&lt;span class="anchor" id="line-404"&gt;&lt;/span&gt;                mount -o move /mnt/dev /dev&lt;br /&gt;&lt;span class="anchor" id="line-405"&gt;&lt;/span&gt;                mount -o move /mnt/tmp /tmp&lt;br /&gt;&lt;span class="anchor" id="line-406"&gt;&lt;/span&gt;                mount -o move /mnt/jffs /jffs 2&gt;&amp;amp;-&lt;br /&gt;&lt;span class="anchor" id="line-407"&gt;&lt;/span&gt;                mount -o move /mnt/sys /sys 2&gt;&amp;amp;-&lt;br /&gt;&lt;span class="anchor" id="line-408"&gt;&lt;/span&gt;        }&lt;br /&gt;&lt;span class="anchor" id="line-409"&gt;&lt;/span&gt;}&lt;br /&gt;&lt;span class="anchor" id="line-410"&gt;&lt;/span&gt;&lt;/pre&gt;&lt;span class="anchor" id="line-411"&gt;&lt;/span&gt;&lt;p class="line867"&gt;&lt;em&gt;&lt;strong&gt;Note:&lt;/strong&gt;&lt;/em&gt; for Kazimate 2.6 kernel, add this before insmod loop. &lt;span class="anchor" id="line-412"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-413"&gt;&lt;/span&gt;&lt;/p&gt;&lt;p class="line867"&gt;&lt;span class="anchor" id="line-414"&gt;&lt;/span&gt;&lt;/p&gt;&lt;pre&gt;/sbin/hotplug2 --override --persistent --max-children 1 --no-coldplug &amp;amp;&lt;br /&gt;&lt;span class="anchor" id="line-415"&gt;&lt;/span&gt;&lt;/pre&gt;&lt;span class="anchor" id="line-416"&gt;&lt;/span&gt;&lt;p class="line874"&gt;And kill it after the loop. &lt;span class="anchor" id="line-417"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-418"&gt;&lt;/span&gt;&lt;/p&gt;&lt;p class="line867"&gt;&lt;span class="anchor" id="line-419"&gt;&lt;/span&gt;&lt;/p&gt;&lt;pre&gt;killall hotplug2&lt;br /&gt;&lt;span class="anchor" id="line-420"&gt;&lt;/span&gt;&lt;/pre&gt;&lt;span class="anchor" id="line-421"&gt;&lt;/span&gt;&lt;p class="line874"&gt;Make it executable: &lt;span class="anchor" id="line-422"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-423"&gt;&lt;/span&gt;&lt;/p&gt;&lt;p class="line867"&gt;&lt;span class="anchor" id="line-424"&gt;&lt;/span&gt;&lt;/p&gt;&lt;pre&gt;chmod +x /etc/init.d/pivotroot&lt;/pre&gt;&lt;span class="anchor" id="line-425"&gt;&lt;/span&gt;&lt;p class="line874"&gt;Then install the modules, for Kamikaze 7.07 or later (Kernel 2.6), use &lt;span class="anchor" id="line-426"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-427"&gt;&lt;/span&gt;&lt;/p&gt;&lt;p class="line867"&gt;&lt;span class="anchor" id="line-428"&gt;&lt;/span&gt;&lt;/p&gt;&lt;pre&gt;ipkg install kmod-fs-ext2 kmod-fs-ext3&lt;br /&gt;&lt;span class="anchor" id="line-429"&gt;&lt;/span&gt;&lt;/pre&gt;&lt;span class="anchor" id="line-430"&gt;&lt;/span&gt;&lt;p class="line874"&gt;Test to see if pivotroot works: &lt;span class="anchor" id="line-431"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-432"&gt;&lt;/span&gt;&lt;/p&gt;&lt;p class="line867"&gt;&lt;span class="anchor" id="line-433"&gt;&lt;/span&gt;&lt;/p&gt;&lt;pre&gt;/etc/init.d/pivotroot&lt;br /&gt;&lt;span class="anchor" id="line-434"&gt;&lt;/span&gt;df -h&lt;/pre&gt;&lt;span class="anchor" id="line-435"&gt;&lt;/span&gt;&lt;p class="line862"&gt;You may safely ignore errors saying "&lt;tt&gt;insmod: cannot insert ...&lt;/tt&gt;" If pivotroot worked, then df will show that your USB storage is mounted on "/" (root). Now reboot. &lt;span class="anchor" id="line-436"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-437"&gt;&lt;/span&gt;&lt;/p&gt;&lt;p class="line867"&gt;&lt;span class="anchor" id="line-438"&gt;&lt;/span&gt;&lt;/p&gt;&lt;pre&gt;reboot&lt;/pre&gt;&lt;span class="anchor" id="line-439"&gt;&lt;/span&gt;&lt;p class="line874"&gt;after that edit /etc/init.d/rcS &lt;span class="anchor" id="line-440"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-441"&gt;&lt;/span&gt;&lt;/p&gt;&lt;p class="line867"&gt;&lt;span class="anchor" id="line-442"&gt;&lt;/span&gt;&lt;/p&gt;&lt;pre&gt;#!/bin/sh&lt;br /&gt;&lt;span class="anchor" id="line-443"&gt;&lt;/span&gt;# Copyright (C) 2006 OpenWrt.org&lt;br /&gt;&lt;span class="anchor" id="line-444"&gt;&lt;/span&gt;if test $2 == "boot" ; then&lt;br /&gt;&lt;span class="anchor" id="line-445"&gt;&lt;/span&gt;/etc/init.d/pivotroot&lt;br /&gt;&lt;span class="anchor" id="line-446"&gt;&lt;/span&gt;fi&lt;br /&gt;&lt;span class="anchor" id="line-447"&gt;&lt;/span&gt;{&lt;br /&gt;&lt;span class="anchor" id="line-448"&gt;&lt;/span&gt;        for i in /etc/rc.d/$1*; do&lt;br /&gt;&lt;span class="anchor" id="line-449"&gt;&lt;/span&gt;                $i $2 2&gt;&amp;amp;1&lt;br /&gt;&lt;span class="anchor" id="line-450"&gt;&lt;/span&gt;        done&lt;br /&gt;&lt;span class="anchor" id="line-451"&gt;&lt;/span&gt;} | logger -s -p 6 -t '' &amp;amp;&lt;br /&gt;&lt;span class="anchor" id="line-452"&gt;&lt;/span&gt;&lt;/pre&gt;&lt;span class="anchor" id="line-453"&gt;&lt;/span&gt;&lt;p class="line874"&gt;now your System should Startup nicely either from USB or from internal Flash if the USB-disk is not available. &lt;span class="anchor" id="line-454"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-455"&gt;&lt;/span&gt;&lt;/p&gt;&lt;p class="line867"&gt; &lt;/p&gt;&lt;h2 id="head-49c812f0ec696ae1a37f585b66987725718d533f"&gt;Installing and using OPKG packages in mount point other than root&lt;/h2&gt; &lt;span class="anchor" id="line-456"&gt;&lt;/span&gt;&lt;p class="line862"&gt;The &lt;a href="http://oldwiki.openwrt.org/Optware.html"&gt;Optware&lt;/a&gt; packages already make use of a similar concept, by which ipkg-opt uses a config file (/opt/etc/opkg.conf) that points / to /opt in order to force the packages to install there. The settings to control where new packages are installed are defined by single-line entries in /etc/ipkg.conf with the original default being 'root / '. If you have external flash or hard drive, you may want to install packages there and add the corresponding directories to $PATH in /etc/profile. &lt;span class="anchor" id="line-457"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-458"&gt;&lt;/span&gt;&lt;/p&gt;&lt;p class="line867"&gt;&lt;img alt="/!\" src="http://oldwiki.openwrt.org/classic/img/alert.png" title="/!\" width="15" height="15" /&gt; &lt;strong&gt;NOTE:&lt;/strong&gt; This is not tested. Please report if it's working for you. &lt;span class="anchor" id="line-459"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-460"&gt;&lt;/span&gt;&lt;/p&gt;&lt;p class="line862"&gt;-Works for me (&lt;a href="http://oldwiki.openwrt.org/MikkoKorkalo.html"&gt;MikkoKorkalo&lt;/a&gt;) &lt;span class="anchor" id="line-461"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-462"&gt;&lt;/span&gt;&lt;/p&gt;&lt;p class="line874"&gt;-Works for me (ElbenfreunD) &lt;span class="anchor" id="line-463"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-464"&gt;&lt;/span&gt;&lt;/p&gt;&lt;p class="line867"&gt;&lt;img alt="/!\" src="http://oldwiki.openwrt.org/classic/img/alert.png" title="/!\" width="15" height="15" /&gt; &lt;strong&gt;NOTE:&lt;/strong&gt; &lt;a href="http://oldwiki.openwrt.org/PackagesOnExternalMediaHowTo.html"&gt;PackagesOnExternalMediaHowTo&lt;/a&gt;, &lt;a href="http://oldwiki.openwrt.org/OpenWrtDocs%282f%29KamikazeConfiguration%282f%29PackagesOnExternalMediaHowTo.html"&gt;OpenWrtDocs/KamikazeConfiguration/PackagesOnExternalMediaHowTo&lt;/a&gt; and &lt;a href="http://oldwiki.openwrt.org/OpenWrtDocs%282f%29KamikazeConfiguration%282f%29BootFromExternalMediaHowTo.html"&gt;OpenWrtDocs/KamikazeConfiguration/BootFromExternalMediaHowTo&lt;/a&gt; contain additional important infos. &lt;span class="anchor" id="line-465"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-466"&gt;&lt;/span&gt;&lt;/p&gt;&lt;p class="line867"&gt;&lt;img alt="/!\" src="http://oldwiki.openwrt.org/classic/img/alert.png" title="/!\" width="15" height="15" /&gt; &lt;strong&gt;NOTE:&lt;/strong&gt; Destination needs not to have trailing slash in order to make following script work (Nijel). &lt;span class="anchor" id="line-467"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-468"&gt;&lt;/span&gt;&lt;/p&gt;&lt;p class="line867"&gt;&lt;img alt="/!\" src="http://oldwiki.openwrt.org/classic/img/alert.png" title="/!\" width="15" height="15" /&gt; &lt;strong&gt;NOTE: &lt;/strong&gt;Following script has been adjusted to reflect kamikaze using &lt;tt&gt;opkg&lt;/tt&gt; instead of &lt;tt&gt;opkg&lt;/tt&gt; &lt;span class="anchor" id="line-469"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-470"&gt;&lt;/span&gt;&lt;/p&gt;&lt;p class="line862"&gt;Configure &lt;tt&gt;opkg&lt;/tt&gt; for a non-root destination &lt;span class="anchor" id="line-471"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-472"&gt;&lt;/span&gt;&lt;/p&gt;&lt;p class="line867"&gt;&lt;span class="anchor" id="line-473"&gt;&lt;/span&gt;&lt;/p&gt;&lt;pre&gt;echo dest usb /mnt/usb &gt;&gt; /etc/opkg.conf&lt;br /&gt;&lt;span class="anchor" id="line-474"&gt;&lt;/span&gt;&lt;/pre&gt;&lt;span class="anchor" id="line-475"&gt;&lt;/span&gt;&lt;p class="line874"&gt;then install a package to a non-root destination &lt;span class="anchor" id="line-476"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-477"&gt;&lt;/span&gt;&lt;/p&gt;&lt;p class="line867"&gt;&lt;span class="anchor" id="line-478"&gt;&lt;/span&gt;&lt;/p&gt;&lt;pre&gt;opkg -dest usb install kismet-server&lt;br /&gt;&lt;span class="anchor" id="line-479"&gt;&lt;/span&gt;&lt;/pre&gt;&lt;span class="anchor" id="line-480"&gt;&lt;/span&gt;&lt;p class="line862"&gt;Copy &amp;amp; paste this script into &lt;tt&gt;/bin/opkg-link&lt;/tt&gt; (or somewhere in your &lt;tt&gt;$PATH&lt;/tt&gt;). &lt;span class="anchor" id="line-481"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-482"&gt;&lt;/span&gt;&lt;/p&gt;&lt;p class="line867"&gt;&lt;span class="anchor" id="line-483"&gt;&lt;/span&gt;&lt;/p&gt;&lt;pre&gt;#!/bin/sh&lt;br /&gt;&lt;span class="anchor" id="line-484"&gt;&lt;/span&gt;COMMAND=$1&lt;br /&gt;&lt;span class="anchor" id="line-485"&gt;&lt;/span&gt;PACKAGE=$2&lt;br /&gt;&lt;span class="anchor" id="line-486"&gt;&lt;/span&gt;setdest () {&lt;br /&gt;&lt;span class="anchor" id="line-487"&gt;&lt;/span&gt;        for i in `grep dest /etc/opkg.conf | cut -d ' ' -f 3`; do&lt;br /&gt;&lt;span class="anchor" id="line-488"&gt;&lt;/span&gt;                if [ -f $i/usr/lib/opkg/info/$PACKAGE.list ]; then&lt;br /&gt;&lt;span class="anchor" id="line-489"&gt;&lt;/span&gt;                        DEST=$i&lt;br /&gt;&lt;span class="anchor" id="line-490"&gt;&lt;/span&gt;                fi&lt;br /&gt;&lt;span class="anchor" id="line-491"&gt;&lt;/span&gt;        done&lt;br /&gt;&lt;span class="anchor" id="line-492"&gt;&lt;/span&gt;        if [ "x$DEST" = "x" ]; then&lt;br /&gt;&lt;span class="anchor" id="line-493"&gt;&lt;/span&gt;                echo "Can not locate $PACKAGE."&lt;br /&gt;&lt;span class="anchor" id="line-494"&gt;&lt;/span&gt;                echo "Check /etc/opkg.conf for correct dest listings";&lt;br /&gt;&lt;span class="anchor" id="line-495"&gt;&lt;/span&gt;                echo "Check name of requested package: $PACKAGE"&lt;br /&gt;&lt;span class="anchor" id="line-496"&gt;&lt;/span&gt;                exit 1&lt;br /&gt;&lt;span class="anchor" id="line-497"&gt;&lt;/span&gt;        fi&lt;br /&gt;&lt;span class="anchor" id="line-498"&gt;&lt;/span&gt;}&lt;br /&gt;&lt;span class="anchor" id="line-499"&gt;&lt;/span&gt;addlinks () {&lt;br /&gt;&lt;span class="anchor" id="line-500"&gt;&lt;/span&gt;        setdest;&lt;br /&gt;&lt;span class="anchor" id="line-501"&gt;&lt;/span&gt;        cat $DEST/usr/lib/opkg/info/$PACKAGE.list | while read LINE; do&lt;br /&gt;&lt;span class="anchor" id="line-502"&gt;&lt;/span&gt;                SRC=$LINE&lt;br /&gt;&lt;span class="anchor" id="line-503"&gt;&lt;/span&gt;                DST=`echo $SRC | sed "s|$DEST||"`&lt;br /&gt;&lt;span class="anchor" id="line-504"&gt;&lt;/span&gt;                DSTNAME=`basename $DST`&lt;br /&gt;&lt;span class="anchor" id="line-505"&gt;&lt;/span&gt;                DSTDIR=`echo $DST | sed "s|$DSTNAME\$||"`&lt;br /&gt;&lt;span class="anchor" id="line-506"&gt;&lt;/span&gt;                test -f "$SRC"&lt;br /&gt;&lt;span class="anchor" id="line-507"&gt;&lt;/span&gt;                if [ $? = 0 ]; then&lt;br /&gt;&lt;span class="anchor" id="line-508"&gt;&lt;/span&gt;                        test -e "$DST"&lt;br /&gt;&lt;span class="anchor" id="line-509"&gt;&lt;/span&gt;                        if [ $? = 1 ]; then&lt;br /&gt;&lt;span class="anchor" id="line-510"&gt;&lt;/span&gt;                                mkdir -p $DSTDIR&lt;br /&gt;&lt;span class="anchor" id="line-511"&gt;&lt;/span&gt;                                ln -sf $SRC $DST&lt;br /&gt;&lt;span class="anchor" id="line-512"&gt;&lt;/span&gt;                        else&lt;br /&gt;&lt;span class="anchor" id="line-513"&gt;&lt;/span&gt;                                echo "Not linking $SRC to $DST"&lt;br /&gt;&lt;span class="anchor" id="line-514"&gt;&lt;/span&gt;                                echo "$DST Already exists"&lt;br /&gt;&lt;span class="anchor" id="line-515"&gt;&lt;/span&gt;                        fi&lt;br /&gt;&lt;span class="anchor" id="line-516"&gt;&lt;/span&gt;                else&lt;br /&gt;&lt;span class="anchor" id="line-517"&gt;&lt;/span&gt;                        test -d "$SRC"&lt;br /&gt;&lt;span class="anchor" id="line-518"&gt;&lt;/span&gt;                        if [ $? = 0 ]; then&lt;br /&gt;&lt;span class="anchor" id="line-519"&gt;&lt;/span&gt;                                test -e $DST&lt;br /&gt;&lt;span class="anchor" id="line-520"&gt;&lt;/span&gt;                                if [ $? = 1 ]; then&lt;br /&gt;&lt;span class="anchor" id="line-521"&gt;&lt;/span&gt;                                        mkdir -p $DST&lt;br /&gt;&lt;span class="anchor" id="line-522"&gt;&lt;/span&gt;                                else&lt;br /&gt;&lt;span class="anchor" id="line-523"&gt;&lt;/span&gt;                                        echo "directory already exists"&lt;br /&gt;&lt;span class="anchor" id="line-524"&gt;&lt;/span&gt;                                fi&lt;br /&gt;&lt;span class="anchor" id="line-525"&gt;&lt;/span&gt;                        else&lt;br /&gt;&lt;span class="anchor" id="line-526"&gt;&lt;/span&gt;                                echo "Source directory $SRC does not exist"&lt;br /&gt;&lt;span class="anchor" id="line-527"&gt;&lt;/span&gt;                        fi&lt;br /&gt;&lt;span class="anchor" id="line-528"&gt;&lt;/span&gt;                fi&lt;br /&gt;&lt;span class="anchor" id="line-529"&gt;&lt;/span&gt;        done&lt;br /&gt;&lt;span class="anchor" id="line-530"&gt;&lt;/span&gt;}&lt;br /&gt;&lt;span class="anchor" id="line-531"&gt;&lt;/span&gt;removelinks () {&lt;br /&gt;&lt;span class="anchor" id="line-532"&gt;&lt;/span&gt;        setdest;&lt;br /&gt;&lt;span class="anchor" id="line-533"&gt;&lt;/span&gt;        cat $DEST/usr/lib/opkg/info/$PACKAGE.list | while read LINE; do&lt;br /&gt;&lt;span class="anchor" id="line-534"&gt;&lt;/span&gt;                SRC=$LINE&lt;br /&gt;&lt;span class="anchor" id="line-535"&gt;&lt;/span&gt;                DST=`echo $LINE | sed "s|$DEST||"`&lt;br /&gt;&lt;span class="anchor" id="line-536"&gt;&lt;/span&gt;                DSTNAME=`basename $DST`&lt;br /&gt;&lt;span class="anchor" id="line-537"&gt;&lt;/span&gt;                DSTDIR=`echo $DST | sed "s|$DSTNAME\$||"`&lt;br /&gt;&lt;span class="anchor" id="line-538"&gt;&lt;/span&gt;                test -f $DST&lt;br /&gt;&lt;span class="anchor" id="line-539"&gt;&lt;/span&gt;                if [ $? = 0 ]; then&lt;br /&gt;&lt;span class="anchor" id="line-540"&gt;&lt;/span&gt;                        rm -f $DST&lt;br /&gt;&lt;span class="anchor" id="line-541"&gt;&lt;/span&gt;                        test -d $DSTDIR &amp;amp;&amp;amp; rmdir $DSTDIR 2&gt;/dev/null&lt;br /&gt;&lt;span class="anchor" id="line-542"&gt;&lt;/span&gt;                else&lt;br /&gt;&lt;span class="anchor" id="line-543"&gt;&lt;/span&gt;                        test -d $DST&lt;br /&gt;&lt;span class="anchor" id="line-544"&gt;&lt;/span&gt;                        if [ $? = 0 ]; then&lt;br /&gt;&lt;span class="anchor" id="line-545"&gt;&lt;/span&gt;                                rmdir $DST&lt;br /&gt;&lt;span class="anchor" id="line-546"&gt;&lt;/span&gt;                        else&lt;br /&gt;&lt;span class="anchor" id="line-547"&gt;&lt;/span&gt;                                echo "$DST does not exist"&lt;br /&gt;&lt;span class="anchor" id="line-548"&gt;&lt;/span&gt;                        fi&lt;br /&gt;&lt;span class="anchor" id="line-549"&gt;&lt;/span&gt;                fi&lt;br /&gt;&lt;span class="anchor" id="line-550"&gt;&lt;/span&gt;        done&lt;br /&gt;&lt;span class="anchor" id="line-551"&gt;&lt;/span&gt;}&lt;br /&gt;&lt;span class="anchor" id="line-552"&gt;&lt;/span&gt;mountdest () {&lt;br /&gt;&lt;span class="anchor" id="line-553"&gt;&lt;/span&gt;        test -d $PACKAGE&lt;br /&gt;&lt;span class="anchor" id="line-554"&gt;&lt;/span&gt;        if [ $? = 1 ]; then&lt;br /&gt;&lt;span class="anchor" id="line-555"&gt;&lt;/span&gt;                echo "Mount point does not exist"&lt;br /&gt;&lt;span class="anchor" id="line-556"&gt;&lt;/span&gt;                exit 1&lt;br /&gt;&lt;span class="anchor" id="line-557"&gt;&lt;/span&gt;        fi&lt;br /&gt;&lt;span class="anchor" id="line-558"&gt;&lt;/span&gt;        for i in $PACKAGE/usr/lib/opkg/info/*.list; do&lt;br /&gt;&lt;span class="anchor" id="line-559"&gt;&lt;/span&gt;                $0 add `basename $i .list`&lt;br /&gt;&lt;span class="anchor" id="line-560"&gt;&lt;/span&gt;        done&lt;br /&gt;&lt;span class="anchor" id="line-561"&gt;&lt;/span&gt;}&lt;br /&gt;&lt;span class="anchor" id="line-562"&gt;&lt;/span&gt;umountdest () {&lt;br /&gt;&lt;span class="anchor" id="line-563"&gt;&lt;/span&gt;        test -d $PACKAGE&lt;br /&gt;&lt;span class="anchor" id="line-564"&gt;&lt;/span&gt;        if [ $? = 1 ]; then&lt;br /&gt;&lt;span class="anchor" id="line-565"&gt;&lt;/span&gt;                echo "Mount point does not exist"&lt;br /&gt;&lt;span class="anchor" id="line-566"&gt;&lt;/span&gt;                exit 1&lt;br /&gt;&lt;span class="anchor" id="line-567"&gt;&lt;/span&gt;        fi&lt;br /&gt;&lt;span class="anchor" id="line-568"&gt;&lt;/span&gt;        for i in $PACKAGE/usr/lib/opkg/info/*.list; do&lt;br /&gt;&lt;span class="anchor" id="line-569"&gt;&lt;/span&gt;                $0 remove `basename $i .list`&lt;br /&gt;&lt;span class="anchor" id="line-570"&gt;&lt;/span&gt;        done&lt;br /&gt;&lt;span class="anchor" id="line-571"&gt;&lt;/span&gt;}&lt;br /&gt;&lt;span class="anchor" id="line-572"&gt;&lt;/span&gt;case "$COMMAND" in&lt;br /&gt;&lt;span class="anchor" id="line-573"&gt;&lt;/span&gt;  add)&lt;br /&gt;&lt;span class="anchor" id="line-574"&gt;&lt;/span&gt;        addlinks&lt;br /&gt;&lt;span class="anchor" id="line-575"&gt;&lt;/span&gt;  ;;&lt;br /&gt;&lt;span class="anchor" id="line-576"&gt;&lt;/span&gt;  remove)&lt;br /&gt;&lt;span class="anchor" id="line-577"&gt;&lt;/span&gt;        removelinks&lt;br /&gt;&lt;span class="anchor" id="line-578"&gt;&lt;/span&gt;  ;;&lt;br /&gt;&lt;span class="anchor" id="line-579"&gt;&lt;/span&gt;  mount)&lt;br /&gt;&lt;span class="anchor" id="line-580"&gt;&lt;/span&gt;        mountdest&lt;br /&gt;&lt;span class="anchor" id="line-581"&gt;&lt;/span&gt;  ;;&lt;br /&gt;&lt;span class="anchor" id="line-582"&gt;&lt;/span&gt;  umount)&lt;br /&gt;&lt;span class="anchor" id="line-583"&gt;&lt;/span&gt;        umountdest&lt;br /&gt;&lt;span class="anchor" id="line-584"&gt;&lt;/span&gt;  ;;&lt;br /&gt;&lt;span class="anchor" id="line-585"&gt;&lt;/span&gt;  *)&lt;br /&gt;&lt;span class="anchor" id="line-586"&gt;&lt;/span&gt;        echo "Usage: $0 &lt;cmd&gt; &lt;target&gt;"&lt;br /&gt;&lt;span class="anchor" id="line-587"&gt;&lt;/span&gt;        echo "       Commands: add, remove, mount, umount"&lt;br /&gt;&lt;span class="anchor" id="line-588"&gt;&lt;/span&gt;        echo "       Targets: &lt;package&gt;, &lt;mount&gt;"&lt;br /&gt;&lt;span class="anchor" id="line-589"&gt;&lt;/span&gt;        echo "Example:  $0 add kismet-server"&lt;br /&gt;&lt;span class="anchor" id="line-590"&gt;&lt;/span&gt;        echo "Example:  $0 remove kismet-server"&lt;br /&gt;&lt;span class="anchor" id="line-591"&gt;&lt;/span&gt;        echo "Example:  $0 mount /mnt/usb"&lt;br /&gt;&lt;span class="anchor" id="line-592"&gt;&lt;/span&gt;        echo "Example:  $0 umount /mnt/usb"&lt;br /&gt;&lt;span class="anchor" id="line-593"&gt;&lt;/span&gt;        exit 1&lt;br /&gt;&lt;span class="anchor" id="line-594"&gt;&lt;/span&gt;        ;;&lt;br /&gt;&lt;span class="anchor" id="line-595"&gt;&lt;/span&gt;esac&lt;br /&gt;&lt;span class="anchor" id="line-596"&gt;&lt;/span&gt;exit 0&lt;br /&gt;&lt;span class="anchor" id="line-597"&gt;&lt;/span&gt;&lt;/pre&gt;&lt;span class="anchor" id="line-598"&gt;&lt;/span&gt;&lt;p class="line862"&gt;Make sure the &lt;tt&gt;/bin/ipkg-link&lt;/tt&gt; script is executable: &lt;span class="anchor" id="line-599"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-600"&gt;&lt;/span&gt;&lt;/p&gt;&lt;p class="line867"&gt;&lt;span class="anchor" id="line-601"&gt;&lt;/span&gt;&lt;/p&gt;&lt;pre&gt;chmod a+x /bin/opkg-link&lt;br /&gt;&lt;span class="anchor" id="line-602"&gt;&lt;/span&gt;&lt;/pre&gt;&lt;span class="anchor" id="line-603"&gt;&lt;/span&gt;&lt;p class="line874"&gt;Examples howto use the script: &lt;span class="anchor" id="line-604"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-605"&gt;&lt;/span&gt;&lt;/p&gt;&lt;p class="line874"&gt;Link a single package to root: &lt;span class="anchor" id="line-606"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-607"&gt;&lt;/span&gt;&lt;/p&gt;&lt;p class="line867"&gt;&lt;span class="anchor" id="line-608"&gt;&lt;/span&gt;&lt;/p&gt;&lt;pre&gt;opkg-link add kismet-server&lt;br /&gt;&lt;span class="anchor" id="line-609"&gt;&lt;/span&gt;&lt;/pre&gt;&lt;span class="anchor" id="line-610"&gt;&lt;/span&gt;&lt;p class="line874"&gt;Link all packages on a mount point to root: &lt;span class="anchor" id="line-611"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-612"&gt;&lt;/span&gt;&lt;/p&gt;&lt;p class="line867"&gt;&lt;span class="anchor" id="line-613"&gt;&lt;/span&gt;&lt;/p&gt;&lt;pre&gt;opkg-link mount /mnt/usb&lt;br /&gt;&lt;span class="anchor" id="line-614"&gt;&lt;/span&gt;&lt;/pre&gt;&lt;span class="anchor" id="line-615"&gt;&lt;/span&gt;&lt;p class="line874"&gt;Remove symlinks: &lt;span class="anchor" id="line-616"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-617"&gt;&lt;/span&gt;&lt;/p&gt;&lt;p class="line867"&gt;&lt;span class="anchor" id="line-618"&gt;&lt;/span&gt;&lt;/p&gt;&lt;pre&gt;opkg-link remove kismet-server&lt;br /&gt;&lt;span class="anchor" id="line-619"&gt;&lt;/span&gt;&lt;/pre&gt;&lt;span class="anchor" id="line-620"&gt;&lt;/span&gt;&lt;p class="line874"&gt;Remove all symlinks for all packages: &lt;span class="anchor" id="line-621"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-622"&gt;&lt;/span&gt;&lt;/p&gt;&lt;p class="line867"&gt;&lt;span class="anchor" id="line-623"&gt;&lt;/span&gt;&lt;/p&gt;&lt;pre&gt;opkg-link umount /mnt/usb&lt;br /&gt;&lt;/pre&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/4984480909360655633-4979888198464772262?l=worldinthenet.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://worldinthenet.blogspot.com/feeds/4979888198464772262/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://worldinthenet.blogspot.com/2009/07/zz-usb-storage-howto.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/4984480909360655633/posts/default/4979888198464772262'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/4984480909360655633/posts/default/4979888198464772262'/><link rel='alternate' type='text/html' href='http://worldinthenet.blogspot.com/2009/07/zz-usb-storage-howto.html' title='[zz] USB Storage Howto'/><author><name>Taojun</name><uri>http://www.blogger.com/profile/12946690813153575136</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-4984480909360655633.post-3335521902101723358</id><published>2009-07-15T19:29:00.001-07:00</published><updated>2009-07-15T19:29:49.296-07:00</updated><title type='text'>[zz] USB on Kamikaze</title><content type='html'>&lt;h1 class="firstHeading"&gt;USB on Kamikaze&lt;/h1&gt;       &lt;h3 id="siteSub"&gt;From Crashcourse Wiki&lt;/h3&gt;              &lt;div id="jump-to-nav"&gt;Jump to: &lt;a href="http://www.crashcourse.ca/wiki/index.php/USB_on_Kamikaze#column-one"&gt;navigation&lt;/a&gt;, &lt;a href="http://www.crashcourse.ca/wiki/index.php/USB_on_Kamikaze#searchInput"&gt;search&lt;/a&gt;&lt;/div&gt;   &lt;!-- start content --&gt;    &lt;p&gt;This page will shortly have information on how to configure USB on your WL500GP for things like USB drives and so on. Until then, here are a number of links into the OpenWrt wiki (and elsewhere) that should be helpful. &lt;/p&gt; &lt;ul&gt;&lt;li&gt; [&lt;a href="http://www.linux-usb.org/" class="external text" title="http://www.linux-usb.org/" rel="nofollow"&gt;General USB on Linux page&lt;/a&gt;]. &lt;/li&gt;&lt;li&gt; [&lt;a href="http://wiki.openwrt.org/OpenWrtDocs/Customizing/Hardware/USB" class="external text" title="http://wiki.openwrt.org/OpenWrtDocs/Customizing/Hardware/USB" rel="nofollow"&gt;General OpenWrt USB page&lt;/a&gt;]. &lt;/li&gt;&lt;li&gt; [&lt;a href="http://wiki.openwrt.org/WithUSBv2" class="external text" title="http://wiki.openwrt.org/WithUSBv2" rel="nofollow"&gt;OpenWrt devices that support USB 2.0&lt;/a&gt;]. &lt;/li&gt;&lt;li&gt; [&lt;a href="http://wiki.openwrt.org/UsbStorageHowto" class="external text" title="http://wiki.openwrt.org/UsbStorageHowto" rel="nofollow"&gt;USB Storage HOWTO&lt;/a&gt;]. &lt;/li&gt;&lt;li&gt; [&lt;a href="http://wiki.openwrt.org/webcam" class="external text" title="http://wiki.openwrt.org/webcam" rel="nofollow"&gt;USB webcam&lt;/a&gt;]. &lt;/li&gt;&lt;li&gt; [&lt;a href="http://wiki.openwrt.org/UsbAudioHowto" class="external text" title="http://wiki.openwrt.org/UsbAudioHowto" rel="nofollow"&gt;USB Audio HOWTO&lt;/a&gt;]. &lt;/li&gt;&lt;/ul&gt; &lt;table id="toc" class="toc" summary="Contents"&gt;&lt;tbody&gt;&lt;tr&gt;&lt;td&gt;&lt;div id="toctitle"&gt;&lt;h2&gt;Contents&lt;/h2&gt; &lt;span class="toctoggle"&gt;[&lt;a href="javascript:toggleToc()" class="internal" id="togglelink"&gt;hide&lt;/a&gt;]&lt;/span&gt;&lt;/div&gt; &lt;ul&gt;&lt;li class="toclevel-1"&gt;&lt;a href="http://www.crashcourse.ca/wiki/index.php/USB_on_Kamikaze#USB_Devices_on_the_WL500g_Premium"&gt;&lt;span class="tocnumber"&gt;1&lt;/span&gt; &lt;span class="toctext"&gt;USB Devices on the WL500g Premium&lt;/span&gt;&lt;/a&gt;&lt;/li&gt;&lt;li class="toclevel-1"&gt;&lt;a href="http://www.crashcourse.ca/wiki/index.php/USB_on_Kamikaze#USB_Storage_on_the_WL500g_Premium_HOWTO"&gt;&lt;span class="tocnumber"&gt;2&lt;/span&gt; &lt;span class="toctext"&gt;USB Storage on the WL500g Premium HOWTO&lt;/span&gt;&lt;/a&gt; &lt;ul&gt;&lt;li class="toclevel-2"&gt;&lt;a href="http://www.crashcourse.ca/wiki/index.php/USB_on_Kamikaze#File_Transfer_Performance_from_USB_Storage"&gt;&lt;span class="tocnumber"&gt;2.1&lt;/span&gt; &lt;span class="toctext"&gt;File Transfer Performance from USB Storage&lt;/span&gt;&lt;/a&gt;&lt;/li&gt;&lt;/ul&gt; &lt;/li&gt;&lt;li class="toclevel-1"&gt;&lt;a href="http://www.crashcourse.ca/wiki/index.php/USB_on_Kamikaze#USB_Audio_on_the_WL500g_Premium_HOWTO"&gt;&lt;span class="tocnumber"&gt;3&lt;/span&gt; &lt;span class="toctext"&gt;USB Audio on the WL500g Premium HOWTO&lt;/span&gt;&lt;/a&gt;&lt;/li&gt;&lt;li class="toclevel-1"&gt;&lt;a href="http://www.crashcourse.ca/wiki/index.php/USB_on_Kamikaze#Serving_USB_Printers_on_the_WL500g_Premium_HOWTO"&gt;&lt;span class="tocnumber"&gt;4&lt;/span&gt; &lt;span class="toctext"&gt;Serving USB Printers on the WL500g Premium HOWTO&lt;/span&gt;&lt;/a&gt;&lt;/li&gt;&lt;/ul&gt; &lt;/td&gt;&lt;/tr&gt;&lt;/tbody&gt;&lt;/table&gt;&lt;script type="text/javascript"&gt; if (window.showTocToggle) { var tocShowText = "show"; var tocHideText = "hide"; showTocToggle(); } &lt;/script&gt; &lt;a name="USB_Devices_on_the_WL500g_Premium"&gt;&lt;/a&gt;&lt;h3&gt; &lt;span class="mw-headline"&gt; USB Devices on the WL500g Premium &lt;/span&gt;&lt;/h3&gt; &lt;p&gt;Installation, configuration and testing done using Kamikaze devlopment version (bleeding edge, r10760). &lt;/p&gt;&lt;p&gt;All USB devices require the installation of the kmod-usb-core kernel module. For development versions of the operating firmware, packages are most easily accessed by copying the ~/openwrt/bin/packages directory from the git build tree to a USB key and mounting it on the router. Initial configuration can also be achieved by moving required packages to the router with scp. From a directory containing the relevant packages, the ipkg command can be used in direct mode: &lt;/p&gt; &lt;pre&gt;root@OpenWrt:# ipkg install kmod-usb-core*&lt;br /&gt;&lt;/pre&gt; &lt;p&gt;Version 1.1 USB controllers are one of two varieties, UHCI or OHCI.  Installing both modules covers all V1.1 devices: &lt;/p&gt; &lt;pre&gt;ipkg install kmod-usb-uhci*&lt;br /&gt;ipkg install kmod-usb-ohci*&lt;br /&gt;&lt;/pre&gt; &lt;p&gt;Version 2.0 USB devices require the usb2 kernel module: &lt;/p&gt; &lt;pre&gt;ipkg install kmod-usb2*&lt;br /&gt;&lt;/pre&gt; &lt;a name="USB_Storage_on_the_WL500g_Premium_HOWTO"&gt;&lt;/a&gt;&lt;h2&gt; &lt;span class="mw-headline"&gt; USB Storage on the WL500g Premium HOWTO &lt;/span&gt;&lt;/h2&gt; &lt;ul&gt;&lt;li&gt; [&lt;a href="http://wiki.openwrt.org/UsbStorageHowto" class="external text" title="http://wiki.openwrt.org/UsbStorageHowto" rel="nofollow"&gt;OpenWRT USB Storage HOWTO&lt;/a&gt;]. &lt;/li&gt;&lt;/ul&gt; &lt;p&gt;USB storage on the WL500gP in OpenWRT requires the usb-storage module. This module has a dependency of the scsi-core module which must be taken care of manually when using ipkg in direct mode: &lt;/p&gt; &lt;pre&gt;ipkg install kmod-scsi-core*&lt;br /&gt;ipkg install kmod-usb-storage*&lt;br /&gt;&lt;/pre&gt; &lt;p&gt;Standard Linux filesystem capability (ext2/3): &lt;/p&gt; &lt;pre&gt;ipkg install kmod-fs-ext2*&lt;br /&gt;ipkg install kmod-fs-ext3*&lt;br /&gt;&lt;/pre&gt; &lt;p&gt;Basic MS filesystem (msdos) and long filename capability (vfat) for default USB flash drive configurations: &lt;/p&gt; &lt;pre&gt;ipkg install kmod-nls-base*&lt;br /&gt;ipkg install kmod-fs-msdos*&lt;br /&gt;ipkg install kmod-fs-vfat*&lt;br /&gt;&lt;/pre&gt; &lt;p&gt;Further NLS modules may be required to mount filesystems containing filenames with non-English characters: &lt;/p&gt;&lt;p&gt;kmod-nls-cp1250 (Central and Eastern European MS Windows)  &lt;/p&gt;&lt;p&gt;kmod-nls-cp437 (Extended ASCII DOS) &lt;/p&gt;&lt;p&gt;kmod-nls-cp850 (Western European DOS) &lt;/p&gt;&lt;p&gt;kmod-nls-iso8859-1 (Latin #1 ISO) &lt;/p&gt;&lt;p&gt;kmod-nls-iso8859-15 (Latin #9 ISO - includes Euro symbol) &lt;/p&gt;&lt;p&gt;kmod-nls-iso8859-2 (Latin #2 ISO) &lt;/p&gt;&lt;p&gt;kmod-nls-koi8r (Russian) &lt;/p&gt;&lt;p&gt;kmod-nls-utf8 (Unicode standard character set) &lt;/p&gt; &lt;a name="File_Transfer_Performance_from_USB_Storage"&gt;&lt;/a&gt;&lt;h3&gt; &lt;span class="mw-headline"&gt; File Transfer Performance from USB Storage &lt;/span&gt;&lt;/h3&gt; &lt;p&gt;So what is the transfer capability of a WL500gP router acting as a fileserver? &lt;/p&gt;&lt;p&gt;ftp network connection: &lt;/p&gt; &lt;pre&gt; USB2 drive-&gt;(hub*)-&gt;WL500gP-&gt;100mbit network-&gt;laptop&lt;br /&gt;   *Same stats with/out the hub&lt;br /&gt;&lt;/pre&gt; &lt;p&gt;&lt;br /&gt;laptop command line: &lt;/p&gt; &lt;pre&gt;ftp&gt; get ThomasVHS.mpg&lt;br /&gt;local: ThomasVHS.mpg remote: ThomasVHS.mpg&lt;br /&gt;200 PORT command successful. Consider using PASV.&lt;br /&gt;150 Opening BINARY mode data connection for ThomasVHS.mpg (3026878464 bytes).&lt;br /&gt;226 File send OK.&lt;br /&gt;3026878464 bytes received in 1218.19 secs (2426.5 kB/s)&lt;br /&gt;&lt;/pre&gt; &lt;p&gt;&lt;br /&gt;top on router during the transfer: &lt;/p&gt; &lt;pre&gt;Mem: 28824K used, 1104K free, 0K shrd, 228K buff, 21188K cached&lt;br /&gt;CPU:   0% usr  32% sys   0% nice   0% idle   0% io   3% irq  63% softirq&lt;br /&gt;PID  PPID USER     STAT   VSZ %MEM %CPU COMMAND&lt;br /&gt;4772     1 root     R     2076   7%  95% vsftpd&lt;br /&gt;3592     2 root     RW&lt;      0   0%   3% [usb-storage]&lt;br /&gt;&lt;/pre&gt; &lt;p&gt;The router is waiting on the disk I/O  (softirq and sys CPU usage) and is transferring as  efficiently as possible. &lt;/p&gt;&lt;p&gt;&lt;br /&gt;The router can move files off an attached USB2 hard drive at 2.37 MiB/s.  The same drive directly connected to  the laptop shows a 20.6MiB/s transfer rate.  Clearly the router is not saturating the 100Mb/s ethernet link (&gt;10Mib/s) nor the USB port bandwidth.  The transfer rate is bound by the router hardware, most notably the CPU.  Note that  &lt;a href="http://www.xbitlabs.com/articles/other/display/asus-wl500g-premium_12.html" class="external text" title="http://www.xbitlabs.com/articles/other/display/asus-wl500g-premium_12.html" rel="nofollow"&gt;reported&lt;/a&gt; transfer speeds for the stock firmware  are around 1.8MiB/s, so the Kamikaze (bleeding edge, r10760)  firmware shows a distinct performance improvement. &lt;/p&gt; &lt;a name="USB_Audio_on_the_WL500g_Premium_HOWTO"&gt;&lt;/a&gt;&lt;h2&gt; &lt;span class="mw-headline"&gt; USB Audio on the WL500g Premium HOWTO &lt;/span&gt;&lt;/h2&gt; &lt;ul&gt;&lt;li&gt; [&lt;a href="http://wiki.openwrt.org/UsbAudioHowto" class="external text" title="http://wiki.openwrt.org/UsbAudioHowto" rel="nofollow"&gt;OpenWRT USB Audio HOWTO&lt;/a&gt;]. &lt;/li&gt;&lt;/ul&gt; &lt;pre&gt;ipkg install kmod-sound-core*&lt;br /&gt;ipkg install kmod-usb-audio*&lt;br /&gt;ipkg install alsa-lib*&lt;br /&gt;ipkg install libncurses*&lt;br /&gt;ipkg install libpthread*&lt;br /&gt;ipkg install alsa-utils*&lt;br /&gt;reboot&lt;br /&gt;&lt;/pre&gt; &lt;p&gt;&lt;br /&gt;There are several options for USB soundcards. The &lt;a href="http://www.soundblaster.com/products/product.asp?category=1&amp;amp;subcategory=205&amp;amp;product=9103" class="external text" title="http://www.soundblaster.com/products/product.asp?category=1&amp;amp;subcategory=205&amp;amp;product=9103" rel="nofollow"&gt;Creative Audigy 2 NX&lt;/a&gt; USB sound card was used in this example. &lt;/p&gt;&lt;p&gt;By default, ALSA mutes sound devices.  Use alsamixer to unmute and adjust volume of the sound card. &lt;/p&gt;&lt;p&gt;&lt;br /&gt;Madplayer can be used as a command-line client for playback of audio from local or web-based sources. Installation has several dependencies: &lt;/p&gt; &lt;pre&gt;ipkg install zlib*&lt;br /&gt;ipkg install libid3tag*&lt;br /&gt;ipkg install libmad*&lt;br /&gt;ipkg install madplay*&lt;br /&gt;&lt;/pre&gt; &lt;p&gt;Testing: &lt;/p&gt; &lt;pre&gt;# wget -O - http://www.mobiuseng.com/Kermit/Songs/Rainbow.mp3 | madplay -&lt;br /&gt;&lt;/pre&gt; &lt;a name="Serving_USB_Printers_on_the_WL500g_Premium_HOWTO"&gt;&lt;/a&gt;&lt;h2&gt; &lt;span class="mw-headline"&gt; Serving USB Printers on the WL500g Premium HOWTO &lt;/span&gt;&lt;/h2&gt; &lt;p&gt;Printer sharing with OpenWRT is covered in: [&lt;a href="http://wiki.openwrt.org/PrinterSharingHowto?highlight=%28HowTo%29" class="external autonumber" title="http://wiki.openwrt.org/PrinterSharingHowto?highlight=(HowTo)" rel="nofollow"&gt;[1]&lt;/a&gt;].  It uses the lightweight p910nd pass-through print server. &lt;/p&gt;&lt;p&gt;For the WL500g Premium, printer sharing requires the following packages to be installed: &lt;/p&gt; &lt;pre&gt;ipkg install kmod-usb-printer*&lt;br /&gt;ipkg install p910nd*&lt;br /&gt;&lt;/pre&gt; &lt;p&gt;The configuration file for the print server is found in at /etc/config/p910nd. An example which works for a pair of Lexmark laser printers at ports 9100 and 9101 is: &lt;/p&gt; &lt;pre&gt;config p910nd&lt;br /&gt; option device        "/dev/lp0"&lt;br /&gt; option port           0&lt;br /&gt; option bidirectional  1&lt;br /&gt;    &lt;br /&gt;config p910nd&lt;br /&gt; option device        "/dev/lp1"&lt;br /&gt; option port           1&lt;br /&gt; option bidirectional  1    &lt;br /&gt;&lt;/pre&gt; &lt;p&gt;Configuration of clients is straightforward: &lt;/p&gt;&lt;p&gt;From ubuntu, printer configuration uses a device URI of:  &lt;/p&gt; &lt;pre&gt;socket://192.168.254.111:9100&lt;br /&gt;&lt;/pre&gt; &lt;p&gt;for a WL500gP at 192.168.254.111. Be sure to make a rule for forwarding port 9100 for print connections to the router from the WAN side. &lt;/p&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/4984480909360655633-3335521902101723358?l=worldinthenet.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://worldinthenet.blogspot.com/feeds/3335521902101723358/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://worldinthenet.blogspot.com/2009/07/zz-usb-on-kamikaze.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/4984480909360655633/posts/default/3335521902101723358'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/4984480909360655633/posts/default/3335521902101723358'/><link rel='alternate' type='text/html' href='http://worldinthenet.blogspot.com/2009/07/zz-usb-on-kamikaze.html' title='[zz] USB on Kamikaze'/><author><name>Taojun</name><uri>http://www.blogger.com/profile/12946690813153575136</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-4984480909360655633.post-1721729494843756512</id><published>2009-07-15T19:22:00.000-07:00</published><updated>2009-07-15T19:23:01.044-07:00</updated><title type='text'>Tips openWRT</title><content type='html'>* setting openWRT to client mode&lt;br /&gt;things might get missed during the procedure&lt;br /&gt;- change /etc/resolv.conf&lt;br /&gt;nameserver InternetGatewayIP&lt;br /&gt;#nameserver 127.0.0.1        #default version&lt;br /&gt;- missing wl520gu IP with DHCP enabled&lt;br /&gt;after issuing /etc/init.d/network restart, Asus wl520gu IP changes, go to gateway router to see active connections and figure out new IP of wl520gu&lt;br /&gt;* opkg package manager&lt;br /&gt;- update /etc/opkg.conf to reflect package location&lt;br /&gt;- opkg update&lt;br /&gt;- use -force-downgrade when package is older than kernel&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/4984480909360655633-1721729494843756512?l=worldinthenet.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://worldinthenet.blogspot.com/feeds/1721729494843756512/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://worldinthenet.blogspot.com/2009/07/tips-openwrt.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/4984480909360655633/posts/default/1721729494843756512'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/4984480909360655633/posts/default/1721729494843756512'/><link rel='alternate' type='text/html' href='http://worldinthenet.blogspot.com/2009/07/tips-openwrt.html' title='Tips openWRT'/><author><name>Taojun</name><uri>http://www.blogger.com/profile/12946690813153575136</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-4984480909360655633.post-475956700569408148</id><published>2009-07-15T19:10:00.000-07:00</published><updated>2009-07-15T19:11:10.306-07:00</updated><title type='text'>[zz] OpenWRT MP3 player with keyboard and display</title><content type='html'>&lt;span class="serendipity_entryIcon"&gt;&lt;a href="http://www.neophob.com/serendipity/index.php?/categories/12-OpenWRT"&gt;&lt;img class="serendipity_entryIcon" title="OpenWRT: Embedded Linux Bonanza" alt="OpenWRT" src="http://www.neophob.com/serendipity/uploads/WRT54G_shiny1.serendipityThumb.png" /&gt;&lt;/a&gt;                                         &lt;/span&gt;                         Enable an usbkeyboard for OpenWRT&lt;br /&gt;&lt;hr style="width: 100%; height: 2px;"&gt;&lt;br /&gt;Insert those modules:&lt;br /&gt;&lt;br /&gt;&lt;pre&gt;insmod /lib/modules/2.4.30/input.o&lt;br /&gt;insmod /lib/modules/2.4.30/evdev.o&lt;br /&gt;insmod /lib/modules/2.4.30/hid.o&lt;/pre&gt;&lt;br /&gt;Download &lt;a href="http://www.neophob.com/files/owrt/hid-mod.zip"&gt;HERE&lt;/a&gt;&lt;br /&gt;&lt;br /&gt;To compile those modules yourself, you need to enable the following kernel option:&lt;br /&gt;&lt;br /&gt;&lt;pre&gt;Input core support  ---&gt;&lt;br /&gt;&lt;m&gt; Input core support&lt;br /&gt;   &lt; &gt;   Keyboard support&lt;br /&gt;   &lt; &gt;   Mouse support&lt;br /&gt;   &lt; &gt;   Joystick support&lt;br /&gt;   &lt;m&gt;   Event interface support&lt;br /&gt;   &lt; &gt;   User level driver support&lt;/m&gt;&lt;/m&gt;&lt;/pre&gt;&lt;br /&gt;&lt;pre&gt;USB support  ---&gt;&lt;br /&gt;--- USB Human Interface Devices (HID)&lt;br /&gt;       &lt;m&gt;   USB Human Interface Device (full HID) support&lt;br /&gt;       [*]     HID input layer support&lt;br /&gt;       [*]     /dev/hiddev raw HID device support      &lt;br /&gt;&lt;/m&gt;&lt;/pre&gt;&lt;br /&gt;Info: I couldn't use the keyboard module (keybdev.o), when i inserted this module he complained about undefined references:&lt;br /&gt;&lt;br /&gt;&lt;pre&gt; unresolved symbol handle_scancode&lt;br /&gt;unresolved symbol keyboard_tasklet&lt;br /&gt;unresolved symbol kbd_ledfunc&lt;/pre&gt;&lt;br /&gt;I &lt;strong&gt;guess&lt;/strong&gt; this is because the keyboard.o module doesn't exist.&lt;br /&gt;                          Now create a new modules.d config file, /etc/modules.d/61-usb-hid with this content:&lt;br /&gt;input&lt;span style="font-family:monospace;"&gt;&lt;br /&gt;&lt;/span&gt;evdev&lt;span style="font-family:monospace;"&gt;&lt;br /&gt;&lt;/span&gt;hid&lt;br /&gt;Insert the modules manually or reboot your OpenWrt box.&lt;br /&gt;&lt;br /&gt;Syslog when you connect the usb keyboard:&lt;br /&gt;Jan  1 00:01:45 OpenFoensi kern.info kernel: hid-core.c: v1.8.1 Andreas Gal, Vojtech Pavlik &lt;vojtech@suse.cz&gt;&lt;br /&gt;Jan  1 00:01:45 OpenFoensi kern.info kernel: hid-core.c: USB HID support drivers&lt;br /&gt;Jan  1 00:01:51 OpenFoensi kern.info kernel: hub.c: new USB device 01:03.0-2.3, assigned address 8&lt;br /&gt;Jan  1 00:01:51 OpenFoensi kern.info kernel: input: USB HID v1.11 Keyboard [04d9:1203] on usb2:8.0&lt;br /&gt;Jan  1 00:01:51 OpenFoensi kern.info kernel: input: USB HID v1.11 Device [04d9:1203] on usb2:8.1&lt;br /&gt;Now there should be 2 input devices:&lt;br /&gt;/dev/input/event0   /dev/input/event1&lt;br /&gt;&lt;br /&gt;Now we need to handle these keyboard events, its time for cmdpad (&lt;a href="http://cmdpad.sourceforge.net/"&gt;http://cmdpad.sourceforge.net/&lt;/a&gt;). this app will listen to a /dev/input/eventX device (i our case a USB keyboard) and execute a program for each key pressed/released/keep pressing.&lt;br /&gt;there seems to be a similar tool called mpc keyboard daemon, &lt;a href="http://simon.arlott.org/sw/mpckbd/"&gt;http://simon.arlott.org/sw/mpckbd/&lt;/a&gt;, but i didn't test it.&lt;br /&gt;&lt;br /&gt;I compiled cmdpad for OpenWRT, but I didn't manage to create an ipkg package. You can get my &lt;a href="http://www.neophob.com/files/owrt/cmdpad-ipkgatt.zip"&gt;poor ipkg attempt here &lt;/a&gt;or download &lt;a href="http://www.neophob.com/files/owrt/cmdpad-bin-0.0.3.zip"&gt;just the binaries &lt;/a&gt;here.&lt;br /&gt;&lt;br /&gt;install cmdpad to /usr/bin/&lt;br /&gt;install cmdpad.conf to /etc/&lt;br /&gt;install S70USBKbd to /etc/init.d/&lt;br /&gt;&lt;br /&gt;the startscript looks like this:&lt;br /&gt;&lt;br /&gt;/etc/init.d/S70USBKbd&lt;br /&gt;#!/bin/sh&lt;br /&gt;/usr/bin/cmdpad --quiet&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;SOUND&lt;br /&gt;&lt;hr style="width: 100%; height: 2px;"&gt;&lt;br /&gt;Install modules, source: &lt;a href="http://sokrates.mimuw.edu.pl/%7Esebek/openwrt/"&gt;http://sokrates.mimuw.edu.pl/%7Esebek/openwrt/&lt;/a&gt; (&lt;a href="http://sokrates.mimuw.edu.pl/%7Esebek/openwrt/packages/"&gt;http://sokrates.mimuw.edu.pl/%7Esebek/openwrt/packages/&lt;/a&gt;), extract them to /lib/modules/2.4.30/&lt;br /&gt;&lt;br /&gt;Create /etc/modules.d/72-snd-usb-audio:&lt;br /&gt;&lt;pre&gt; soundcore&lt;br /&gt;snd-page-alloc&lt;br /&gt;snd&lt;br /&gt;snd-rawmidi&lt;br /&gt;snd-hwdep&lt;br /&gt;snd-timer&lt;br /&gt;snd-pcm&lt;br /&gt;snd-mixer-oss&lt;br /&gt;snd-pcm-oss&lt;br /&gt;snd-usb-lib&lt;br /&gt;snd-usb-audio&lt;br /&gt;&lt;/pre&gt;&lt;br /&gt;install alsa-lib ipkg&lt;br /&gt;install alsa-utils ipkg&lt;br /&gt;install mpd / mpc ipkg&lt;br /&gt;&lt;br /&gt;Configure mpd:&lt;br /&gt;I mount a usb stick to /mnt/stick1, where the _mp3 subdirectory contains all my mp3's.&lt;br /&gt;&lt;br /&gt;My mpd configuration, /etc/mpd.conf:&lt;br /&gt;&lt;br /&gt;&lt;pre&gt;##################### REQUIRED ###########################&lt;br /&gt;music_directory         "/mnt/stick1/_mp3/"&lt;br /&gt;playlist_directory      "/mnt/stick1/_mp3/playlist"&lt;br /&gt;db_file                 "/mnt/stick1/_mp3/.mpd/mpd.db"&lt;br /&gt;log_file                "/mnt/stick1/_mp3/.mpd/mpd.log"&lt;br /&gt;error_file              "/mnt/stick1/_mp3/.mpd/mpd.error"&lt;br /&gt;pid_file                "/mnt/stick1/_mp3/.mpd/mpd.pid"&lt;br /&gt;##########################################################&lt;br /&gt;&lt;br /&gt;#audio device&lt;br /&gt;audio_output {&lt;br /&gt;       type            "oss"&lt;br /&gt;       name            "my OSS sound card"&lt;br /&gt;       device          "/dev/dsp" # optional&lt;br /&gt;       format          "44100:16:2" #optional&lt;br /&gt;}&lt;br /&gt;&lt;br /&gt;# OSS Mixer&lt;br /&gt;mixer_type              "oss"&lt;br /&gt;mixer_device            "/dev/mixer"&lt;br /&gt;mixer_control           "PCM"&lt;br /&gt;&lt;br /&gt;state_file              "/mnt/stick1/_mp3/.mpd/mpdstate"&lt;br /&gt;&lt;br /&gt;buffer_before_play      "0%"&lt;br /&gt;&lt;/pre&gt;&lt;br /&gt;&lt;br /&gt;Don't forget to create those directories:&lt;br /&gt;mkdir /mnt/stick1/_mp3/.mpd&lt;br /&gt;mkdir /mnt/stick1/_mp3/playlist&lt;br /&gt;&lt;br /&gt;Start mpd, this will create the db and searches for all mp3 files.&lt;br /&gt;&lt;br /&gt;Now add all mp3 files to mpc:&lt;br /&gt;# mpc listall | mpc add -&lt;br /&gt;&lt;br /&gt;WARNING for asus wl500 users, DO NOT INSTALL the package "kmod-usb-ohci" or your usb subsystem will get messy, for example my usb 2.0 stick didn't work anymore, error: usb.c: USB device not responding, giving up (error=-145)&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;DISPLAY&lt;br /&gt;&lt;hr style="width: 100%; height: 2px;"&gt;&lt;br /&gt;First I wanted to use a "regular" LCD display, but compared to a palm device on ebay, they are way too expensive. I bought some palm devices on ebay and the best device I think is the palm 3c. Nice color display and a rechargeable battery. I modded a palm 3x device, so I don't need batteries anymore but take the power from the usb port. This has a big drawback, when the device loose power, all installed applications are gone. You could copy some apps to the internal ROM but there is just 50k free space.&lt;br /&gt;&lt;br /&gt;PalmORB (&lt;a href="http://palmorb.sourceforge.net/"&gt;http://palmorb.sourceforge.net/&lt;/a&gt;) is your friend, this application emulates an Matrix Orbital LK204-25 LCD. My palm use a serial connector, so I need an usb/serial convertor. I had trouble with an FTDI adapter, now I use an PL2303 adapter. It looks like you only can go up to 9600bps, else the connection gets fluffy, but this should be enough for our display.&lt;br /&gt;&lt;br /&gt;On the Openwrt you need to install LCD4Linux, I've patched the mpc plugin, check this article for a &lt;a href="http://www.neophob.com/serendipity/index.php?/archives/114-LCD4Linux-for-OpenWRT,-SVN-Version-including-patched-plugin_mpd.html"&gt;how-to&lt;/a&gt;.&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;CONCLUSION&lt;br /&gt;&lt;hr style="width: 100%; height: 2px;"&gt;There is still much to do here's a small list...&lt;br /&gt;&lt;br /&gt;Current Issues:&lt;br /&gt;- My cheap USB sound card seems to buffer the sound, when i want to pause a song, the device keeps playing for about 4 seconds.&lt;br /&gt;- I need to write some scripts for mount / dismount the USB stick, rescan the music source.&lt;br /&gt;- Currently I'm working on a gps plugin for LCD4Linux.&lt;br /&gt;- ...&lt;br /&gt;&lt;br /&gt;Feel free to support me, contact me at michu at neophob dot com.&lt;/vojtech@suse.cz&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/4984480909360655633-475956700569408148?l=worldinthenet.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://worldinthenet.blogspot.com/feeds/475956700569408148/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://worldinthenet.blogspot.com/2009/07/zz-openwrt-mp3-player-with-keyboard-and.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/4984480909360655633/posts/default/475956700569408148'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/4984480909360655633/posts/default/475956700569408148'/><link rel='alternate' type='text/html' href='http://worldinthenet.blogspot.com/2009/07/zz-openwrt-mp3-player-with-keyboard-and.html' title='[zz] OpenWRT MP3 player with keyboard and display'/><author><name>Taojun</name><uri>http://www.blogger.com/profile/12946690813153575136</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-4984480909360655633.post-5118760117657446574</id><published>2009-07-15T17:46:00.000-07:00</published><updated>2009-07-15T17:47:58.783-07:00</updated><title type='text'>[zz] Building OpenWrt Kamikaze from source</title><content type='html'>Assuming you are using Ubuntu 6.06.1 LTS (on a physical system or in the VMware Player)&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;strong&gt;1.&lt;/strong&gt; install packages required by the OpenWrt Kamikaze buildsystem&lt;br /&gt;&lt;br /&gt;aptitude install build-essential binutils flex bison autoconf gettext texinfo sharutils subversion libncurses5-dev ncurses-term zlib1g-dev&lt;br /&gt;&lt;br /&gt;&lt;strong&gt;2.&lt;/strong&gt; checkout and prepare Kamikaze and the packages&lt;br /&gt;&lt;br /&gt;&lt;div class="codebox"&gt;&lt;div class="incqbox"&gt;&lt;h4&gt;Code:&lt;/h4&gt;&lt;div class="scrollbox" style="height: 10.5em;"&gt;&lt;pre&gt;cd ~&lt;br /&gt;svn co https://svn.openwrt.org/openwrt/trunk/&lt;br /&gt;svn co https://svn.openwrt.org/openwrt/packages/ ~/trunk/feeds/packages/&lt;br /&gt;cd ~/trunk/&lt;br /&gt;make package/symlinks&lt;/pre&gt;&lt;/div&gt;&lt;/div&gt;&lt;/div&gt;&lt;p&gt;&lt;strong&gt;2.1&lt;/strong&gt; Configure Kamikaze (select target system) and the packages (a full build with all packages selected requires about 9GB of free disk space)&lt;br /&gt;&lt;br /&gt;make menuconfig&lt;br /&gt;&lt;br /&gt;&lt;strong&gt;2.2&lt;/strong&gt; If you select extra packages it's a good idea to check if you have all prerequisites installed. Check with:&lt;br /&gt;&lt;br /&gt;make prereq&lt;br /&gt;&lt;br /&gt;TIP: To find the missing packages search at &lt;a href="http://packages.ubuntu.com/"&gt;http://packages.ubuntu.com/&lt;/a&gt;&lt;br /&gt;&lt;br /&gt;&lt;strong&gt;2.3&lt;/strong&gt; Finally build Kamikaze (to download all packages at once use 'make download world')&lt;br /&gt;&lt;br /&gt;make world&lt;br /&gt;&lt;br /&gt;&lt;strong&gt;3.&lt;/strong&gt; After the build finished, ready to use images can be found in $(TOPDIR)/bin&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;Targets for 'make'&lt;br /&gt;&lt;br /&gt;download&lt;br /&gt;    download all source tarballs (from the selected packages and it's dependencies) at once before starting the build&lt;br /&gt;&lt;br /&gt;prereq&lt;br /&gt;    checks if you have all prerequisites installed on the host-system for building the selected packages&lt;br /&gt;&lt;br /&gt;world&lt;br /&gt;    build everything&lt;br /&gt;&lt;br /&gt;tools/install toolchain/install&lt;br /&gt;    only build the tools and the toolchain&lt;br /&gt;&lt;br /&gt;clean&lt;br /&gt;    cleans the packages (NOT the tools and toolchain)&lt;br /&gt;&lt;br /&gt;distclean&lt;br /&gt;    cleans up everything expect $(TOPDIR)/.config and $(TOPDIR)/dl/&lt;br /&gt;&lt;br /&gt;package/&lt;package_name&gt;-{clean,compile}&lt;br /&gt;    rebuild a single package&lt;br /&gt;&lt;br /&gt;package/index&lt;br /&gt;    updates $(TOPDIR)/bin/packages/Packages&lt;br /&gt;&lt;br /&gt;V=99&lt;br /&gt;    turns on debugging&lt;br /&gt;&lt;br /&gt;make kernel_menuconfig&lt;br /&gt;    If you want, you can also modify the kernel config for the selected target system. Simply run "make kernel_menuconfig"&lt;br /&gt;    and the build system will unpack the kernel sources (if necessary), run menuconfig inside of the kernel tree, and then&lt;br /&gt;    copy the kernel config to target/linux/&lt;platform&gt;/config so that it is preserved over "make clean" call. &lt;br /&gt;&lt;br /&gt;&lt;br /&gt;Also look at the OpenWrt Kamikaze documentation at&lt;br /&gt;- &lt;a href="http://nbd.name/openwrt.html#x1-250002.1"&gt;http://nbd.name/openwrt.html#x1-250002.1&lt;/a&gt; or&lt;br /&gt;- &lt;a href="http://nbd.name/openwrt.pdf"&gt;http://nbd.name/openwrt.pdf&lt;/a&gt;&lt;br /&gt;&lt;br /&gt;Some more useful URLs:&lt;br /&gt;- &lt;a href="http://www.vmware.com/download/player/"&gt;Free VMware Player&lt;/a&gt; (enough for most users, no need for the VMware Server)&lt;br /&gt;- &lt;a href="http://www.easyvmx.com/"&gt;Download VMDK and VMX files for VMware Player&lt;/a&gt;&lt;br /&gt;- &lt;a href="http://www.ubuntu.com/"&gt;Ubuntu&lt;/a&gt; (for the Ubuntu ISO image)&lt;br /&gt;- &lt;a href="http://www.vmware.com/download/server/"&gt;Free VMware Server&lt;/a&gt; (also includes the VMware Tools)&lt;/p&gt;      &lt;p class="postedit"&gt;&lt;em&gt;Last edited by forum2006 (2007-05-06 18:24:28)&lt;/em&gt;&lt;/p&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/4984480909360655633-5118760117657446574?l=worldinthenet.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://worldinthenet.blogspot.com/feeds/5118760117657446574/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://worldinthenet.blogspot.com/2009/07/zz-building-openwrt-kamikaze-from.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/4984480909360655633/posts/default/5118760117657446574'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/4984480909360655633/posts/default/5118760117657446574'/><link rel='alternate' type='text/html' href='http://worldinthenet.blogspot.com/2009/07/zz-building-openwrt-kamikaze-from.html' title='[zz] Building OpenWrt Kamikaze from source'/><author><name>Taojun</name><uri>http://www.blogger.com/profile/12946690813153575136</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-4984480909360655633.post-3596300660548662758</id><published>2009-07-15T17:45:00.000-07:00</published><updated>2009-07-15T17:46:18.587-07:00</updated><title type='text'>[zz] The OpenWrt build environment</title><content type='html'>&lt;strong&gt;The OpenWrt build environment&lt;/strong&gt;&lt;br /&gt;&lt;br /&gt;One of the biggest challenges to getting started with embedded devices is that you just can't install a copy of Linux and expect to be able to compile a firmware. Even if you did remember to install a compiler and every development tool offered, you still wouldn't have the basic set of tools needed to produce a firmware image. The embedded device represents an entirely new hardware platform, which is incompatible with the hardware on your development machine, so in a process called cross compiling you need to produce a new compiler capable of generating code for your embedded platform, and then use it to compile a basic Linux distribution to run on your device.&lt;br /&gt;&lt;br /&gt;The process of creating a cross compiler can be tricky, it's not something that's regularly attempted and so the there's a certain amount of mystery and black magic associated with it. In many cases when you're dealing with embedded devices you'll be provided with a binary copy of a compiler and basic libraries rather than instructions for creating your own -- it's a time saving step but at the same time often means you'll be using a rather dated set. Likewise, it's also common to be provided with a patched copy of the Linux kernel from the board or chip vendor, but this is also dated and it can be difficult to spot exactly what has been changed to make the kernel run on the embedded platform.&lt;br /&gt;&lt;br /&gt;&lt;div class="postmsg"&gt;      &lt;p&gt;OpenWrt takes a different approach to building a firmware, downloading, patching and compiling everything from scratch, including the cross compiler. Or to put it in simpler terms, OpenWrt doesn't contain any executables or even sources, it's an automated system for downloading the sources, patching them to work with the given platform and compiling them correctly for the platform. What this means is that just by changing the template, you can change any step in the process.&lt;br /&gt;&lt;br /&gt;As an example, if a new kernel is released, a simple change to one of the Makefiles will download the latest kernel, patch it to run on the embedded platform and produce a new firmware image -- there's no work to be done trying to track down an unmodified copy of the existing kernel to see what changes had been made, the patches are already provided and the process ends up almost completely transparent. This doesn't just apply to the kernel, but to anything included with OpenWrt -- It's this one simple understated concept which is what allows OpenWrt to stay on the bleeding edge with the latest compilers, latest kernels and latest applications.&lt;br /&gt;&lt;br /&gt;So let's take a look at OpenWrt and see how this all works&lt;br /&gt;&lt;br /&gt;&lt;strong&gt;download openwrt&lt;/strong&gt;&lt;br /&gt;&lt;br /&gt;This article refers to the "Kamikaze" branch of OpenWrt, which can be downloaded via subversion using the following command:&lt;br /&gt;&lt;br /&gt;svn co &lt;a href="https://svn.openwrt.org/openwrt/trunk"&gt;https://svn.openwrt.org/openwrt/trunk&lt;/a&gt;&lt;br /&gt;&lt;br /&gt;Additionally, there's a trac interface on &lt;a href="http://dev.openwrt.org/"&gt;http://dev.openwrt.org/&lt;/a&gt; which can be used to monitor svn commits and browse the sources.&lt;br /&gt;&lt;br /&gt;&lt;strong&gt;The directory structure&lt;/strong&gt;&lt;br /&gt;&lt;br /&gt;There are three key directories in the base:&lt;br /&gt;- toolchain&lt;br /&gt;- target&lt;br /&gt;- package&lt;br /&gt;&lt;br /&gt;Toolchain refers to the compiler, the c library, and common tools which will be used to build the firmware image. The result of this is two new directories, toolchain_build_&lt;arch&gt; which is a temporary directory used for building the toolchain for a specific architecture, and staging_dir_&lt;arch&gt; where the resulting toolchain is installed. You won't need to do anything with the toolchain directory unless you intend to add a new version of one of the components above.&lt;br /&gt;&lt;br /&gt;Target refers to the embedded platform, this contains items which are specific to a specific embedded platform. Of particular interest here is the "target/linux" directory which is broken down by platform and contains the kernel config and patches to the kernel for a particular platform. There's also the "target/image" directory which describes how to package a firmware for a specific platform.&lt;br /&gt;&lt;br /&gt;Package is for exactly that -- packages. In an OpenWrt firmware, almost everything is an ipk, a software package which can be added to the firmware to provide new features or removed to save space.&lt;br /&gt;&lt;br /&gt;Both the target and package steps will use the directory "build_&lt;arch&gt;" as a temporary directory for compiling. Additionally, anything downloaded by the toolchain, target or package steps will be placed in the "dl" directory.&lt;br /&gt;&lt;br /&gt;&lt;strong&gt;Building openwrt&lt;/strong&gt;&lt;br /&gt;&lt;br /&gt;While the OpenWrt build environment was intended mostly for developers, it also has to be simple enough that an inexperienced end user can easily build his or her own customized firmware.&lt;br /&gt;&lt;br /&gt;Running the command "make menuconfig" will bring up OpenWrt's configuration menu screen, through this menu you can select which platform you're targeting, which versions of the toolchain you want to use to build and what packages you want to install into the firmware image. Similar to the linux kernel config,&lt;br /&gt;almost every option has three choices, y/m/n which are represented as follows:&lt;br /&gt;&lt;br /&gt;  &lt;*&gt; (pressing y) This will be included in the firmware image&lt;br /&gt;  &lt;m&gt; (pressing m) This will be compiled but not included (for later install)&lt;br /&gt;  &lt;n&gt; (pressing n) This will not be compiled&lt;br /&gt;&lt;br /&gt;After you've finished with the menu configuration, exit and when prompted, save your configuration changes. To begin compiling the firmware, type "make". By default OpenWrt will only display a high level overview of the compile process and not each individual command.&lt;br /&gt;&lt;br /&gt;&lt;/p&gt;&lt;div class="codebox"&gt;&lt;div class="incqbox"&gt;&lt;h4&gt;Code:&lt;/h4&gt;&lt;div class="scrollbox" style="height: 12em;"&gt;&lt;pre&gt;  make[2] toolchain/install&lt;br /&gt; make[3] -C toolchain install&lt;br /&gt; make[2] target/compile&lt;br /&gt; make[3] -C target compile&lt;br /&gt; make[4] -C target/utils prepare&lt;br /&gt; ...&lt;/pre&gt;&lt;/div&gt;&lt;/div&gt;&lt;/div&gt;&lt;p&gt;This makes it easier to monitor which step it's actually compiling and reduces the amount of noise caused by the compile output. To see the full output, run the command "make V=99".&lt;br /&gt;&lt;br /&gt;During the build process, buildroot will download all sources to the "dl" directory and will start patching and compiling them in the "build_&lt;arch&gt;" directory. When finished, the resulting firmware will be in the "bin" directory and packages will be in the "bin/packages" directory.&lt;br /&gt;&lt;br /&gt;&lt;strong&gt;Creating your own packages&lt;/strong&gt;&lt;br /&gt;&lt;br /&gt;One of the things that we've attempted to do with OpenWrt's template system is make it incredibly easy to port software to OpenWrt. If you look at a typical package directory in OpenWrt you'll find two things:&lt;br /&gt;&lt;br /&gt;- package/&lt;name&gt;/Makefile&lt;br /&gt;- package/&lt;name&gt;/patches&lt;br /&gt;&lt;br /&gt;The patches directory is optional and typically contains bug fixes or optimizations to reduce the size of the executable. The package makefile is the important item, provides the steps actually needed to download and compile the package.&lt;br /&gt;&lt;br /&gt;Looking at one of the package makefiles, you'd hardly recognize it as a makefile. Through what can only be described as blatant disregard and abuse of the traditional make format, the makefile has been transformed into an object oriented template which simplifies the entire ordeal.&lt;br /&gt;&lt;br /&gt;Here for example, is package/bridge/Makefile:&lt;br /&gt;&lt;br /&gt;&lt;/p&gt;&lt;div class="codebox"&gt;&lt;div class="incqbox"&gt;&lt;h4&gt;Code:&lt;/h4&gt;&lt;div class="scrollbox" style="height: 35em;"&gt;&lt;pre&gt;include $(TOPDIR)/rules.mk&lt;br /&gt;&lt;br /&gt;PKG_NAME:=bridge&lt;br /&gt;PKG_VERSION:=1.0.6&lt;br /&gt;PKG_RELEASE:=1&lt;br /&gt;&lt;br /&gt;PKG_BUILD_DIR:=$(BUILD_DIR)/bridge-utils-$(PKG_VERSION)&lt;br /&gt;PKG_SOURCE:=bridge-utils-$(PKG_VERSION).tar.gz&lt;br /&gt;PKG_SOURCE_URL:=@SF/bridge&lt;br /&gt;PKG_MD5SUM:=9b7dc52656f5cbec846a7ba3299f73bd&lt;br /&gt;PKG_CAT:=zcat&lt;br /&gt;&lt;br /&gt;include $(INCLUDE_DIR)/package.mk&lt;br /&gt;&lt;br /&gt;define Package/bridge&lt;br /&gt; SECTION:=base&lt;br /&gt; CATEGORY:=Network&lt;br /&gt; DEFAULT:=y&lt;br /&gt; TITLE:=Ethernet bridging configuration utility&lt;br /&gt; DESCRIPTION:=Ethernet bridging configuration utility\\\&lt;br /&gt;   Manage ethernet bridging; a way to connect networks together to\\\&lt;br /&gt;   form a larger network.&lt;br /&gt; URL:=http://bridge.sourceforge.net/&lt;br /&gt;endef&lt;br /&gt;&lt;br /&gt;define Build/Configure&lt;br /&gt; $(call Build/Configure/Default,--with-linux-headers=$(LINUX_DIR))&lt;br /&gt;endef&lt;br /&gt;&lt;br /&gt;define Package/bridge/install&lt;br /&gt;       install -m0755 -d $(1)/usr/sbin&lt;br /&gt;       install -m0755 $(PKG_BUILD_DIR)/brctl/brctl $(1)/usr/sbin/&lt;br /&gt;endef&lt;br /&gt;&lt;br /&gt;$(eval $(call BuildPackage,bridge))&lt;/pre&gt;&lt;/div&gt;&lt;/div&gt;&lt;/div&gt;&lt;p&gt;As you can see, there's not much work to be done; everything is hidden in other makefiles and abstracted to the point where you only need to specify a few variables.&lt;br /&gt;&lt;br /&gt;  PKG_NAME       - The name of the package, as seen via menuconfig and ipkg&lt;br /&gt;  PKG_VERSION    - The upstream version number that we're downloading&lt;br /&gt;  PKG_RELEASE    - The version of this package Makefile&lt;br /&gt;  PKG_BUILD_DIR  - Where to compile the package&lt;br /&gt;  PKG_SOURCE     - The filename of the original sources&lt;br /&gt;  PKG_SOURCE_URL - Where to download the sources from&lt;br /&gt;  PKG_MD5SUM     - A checksum to validate the download&lt;br /&gt;  PKG_CAT        - How to decompress the sources (zcat, bzcat, unzip)&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;The PKG_* variables define where to download the package from; @SF is a special keyword for downloading packages from sourceforge. The md5sum is used to verify the package was downloaded correctly and PKG_BUILD_DIR defines where to find the package after the sources are uncompressed into $(BUILD_DIR).&lt;br /&gt;&lt;br /&gt;At the bottom of the file is where the real magic happens, "BuildPackage" is a macro setup by the earlier include statements. BuildPackage only takes one argument directly -- the name of the package to be built, in this case "bridge". All other information is taken from the define blocks. This is a way of providing a level of verbosity, it's inherently clear what the DESCRIPTION variable in Package/bridge is, which wouldn't be the case if we passed this information directly as the Nth argument to BuildPackage.&lt;br /&gt;&lt;br /&gt;BuildPackage uses the following defines:&lt;br /&gt;&lt;br /&gt;Package/&lt;name&gt;&lt;br /&gt;   &lt;name&gt; matches the argument passed to buildroot, this describes the package&lt;br /&gt;   the menuconfig and ipkg entries. Within Package/&lt;name&gt; you can define the&lt;br /&gt;   following variables:&lt;br /&gt;&lt;br /&gt;   SECTION     - The type of package (currently unused)&lt;br /&gt;   CATEGORY    - Which menu it appears in menuconfig&lt;br /&gt;   TITLE       - A short description of the package&lt;br /&gt;   DESCRIPTION - A long description of the package&lt;br /&gt;   URL         - Where to find the original software&lt;br /&gt;   MAINTAINER  - (optional) Who to contact concerning the package&lt;br /&gt;   DEPENDS     - (optional) Which packages must be built/installed before this package&lt;br /&gt;&lt;br /&gt;Package/&lt;name&gt;/conffiles (optional)&lt;br /&gt;   A list of config files installed by this package, one file per line.&lt;br /&gt; &lt;br /&gt;Build/Prepare (optional)&lt;br /&gt;   A set of commands to unpack and patch the sources. You may safely leave this&lt;br /&gt;   undefined.&lt;br /&gt;&lt;br /&gt;Build/Configure (optional)&lt;br /&gt;   You can leave this undefined if the source doesn't use configure or has a&lt;br /&gt;   normal config script, otherwise you can put your own commands here or use&lt;br /&gt;   "$(call Build/Configure/Default,&lt;args&gt;)" as above to pass in additional&lt;br /&gt;   arguments for a standard configure script.&lt;br /&gt;&lt;br /&gt;Build/Compile (optional)&lt;br /&gt;   How to compile the source; in most cases you should leave this undefined.&lt;br /&gt;&lt;br /&gt;Package/&lt;name&gt;/install&lt;br /&gt;   A set of commands to copy files out of the compiled source and into the ipkg&lt;br /&gt;   which is represented by the $(1) directory.&lt;br /&gt;  &lt;br /&gt;The reason that some of the defines are prefixed by "Package/&lt;name&gt;" and others are simply "Build" is because of the possibility of generating multiple packages from a single source. OpenWrt works under the assumption of one source per package makefile, but you can split that source into as many packages as&lt;br /&gt;desired. Since you only need to compile the sources once, there's one global set of "Build" defines, but you can add as many "Package/&lt;name&gt;" defines as you want by adding extra calls to BuildPackage -- see the dropbear package for an example.&lt;br /&gt;&lt;br /&gt;After you've created your package/&lt;name&gt;/Makefile, the new package will automatically show in the menu the next time you run "make menuconfig" and if selected will be built automatically the next time "make" is run.&lt;br /&gt;&lt;br /&gt;&lt;strong&gt;Troubleshooting&lt;/strong&gt;&lt;br /&gt;&lt;br /&gt;If you find your package doesn't show up in menuconfig, try the following command to see if you get the correct description:&lt;br /&gt;&lt;br /&gt;  TOPDIR=$PWD make -C package/&lt;name&gt; DUMP=1 V=99&lt;br /&gt;&lt;br /&gt;If you're just having trouble getting your package to compile, there's a few shortcuts you can take. Instead of waiting for make to get to your package, you can run one of the following:&lt;br /&gt;&lt;br /&gt;  make package/&lt;name&gt;-clean V=99&lt;br /&gt;  make package/&lt;name&gt;-install V=99&lt;br /&gt;&lt;br /&gt;Another nice trick is that if the source directory under build_&lt;arch&gt; is newer than the package directory, it won't clobber it by unpacking the sources again. If you were working on a patch you could simply edit the sources under build_&lt;arch&gt;/&lt;source&gt; and run the install command above, when satisfied, copy the patched sources elsewhere and diff them with the unpatched sources. A warning though - if you go modify anything under package/&lt;name&gt; it will remove the old sources and unpack a fresh copy.&lt;br /&gt;&lt;br /&gt;&lt;strong&gt;Final notes&lt;/strong&gt;&lt;br /&gt;&lt;br /&gt;I'm always interested to hear about people's experience with OpenWrt or answer questions about it so please don't hesitate to contact me.&lt;/p&gt;     &lt;/div&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/4984480909360655633-3596300660548662758?l=worldinthenet.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://worldinthenet.blogspot.com/feeds/3596300660548662758/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://worldinthenet.blogspot.com/2009/07/zz-openwrt-build-environment.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/4984480909360655633/posts/default/3596300660548662758'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/4984480909360655633/posts/default/3596300660548662758'/><link rel='alternate' type='text/html' href='http://worldinthenet.blogspot.com/2009/07/zz-openwrt-build-environment.html' title='[zz] The OpenWrt build environment'/><author><name>Taojun</name><uri>http://www.blogger.com/profile/12946690813153575136</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-4984480909360655633.post-816018488460205986</id><published>2009-07-15T17:28:00.000-07:00</published><updated>2009-07-15T17:30:11.451-07:00</updated><title type='text'>[zz] Compiling software for OpenWrt (and creating packages)</title><content type='html'>&lt;h3 class="post-title entry-title"&gt; &lt;a href="http://hype-free.blogspot.com/2009/04/compiling-software-for-openwrt-and.html"&gt;Compiling software for OpenWrt (and creating packages)&lt;/a&gt;&lt;form name="dataForm" method="post" target="_blank" action="http://wordscount.info/hw/service/smog/analyze.jsp"&gt;&lt;input name="document_title" value="Compiling software for OpenWrt (and cre" type="hidden"&gt;&lt;input name="user_text" value=" From my experience, compiling software is not especially hard, but most of the tutorials out there are somewhat dated (as this one will be in 6-7 months). But at least until then it can be useful, and hopefully I will find the time to update it later on. I’m using the trunk version of OpenWrt, which a little more up-to-date than 8.09, but most probably everything described here works with 8.09 (the latest release).  I’ve taken inspiration from the following sources:     Writing and Compiling A Simple Program For OpenWrt     OpenWrt - Building software packages     Thinking Understanding Doing     Own IPKG packages build with OpenWRT-SDK    The main ideas would be:     The easiest way to start is by copying an existing makefile and editing it to fit your needs     OpenWrt has an advanced build system which does all the following things:             Download the application from its original source (and verify the integrity of the archive using md5sum)         Apply some local patches to it         Configure / build it       However, for local development you most likely won't need this. An alternative solution (which will be used in the tutorial later on) would be to copy the source to the build directory in the preparation faze.     Makefiles are very sensitive to tabs (so you have to have tabs and not 4 or 8 spaces in certain locations) and also, errors in them are very cryptic (for example &amp;quot;missing separator&amp;quot;). If your build fails, the first thing you should check is that you have your tabs in order. Also verify that your editor doesn’t have some kind of “transform tabs to spaces” option active. For example, if you are using mcedit with the default color-scheme, it will highlight correct tabs in red, as can be seen in the screenshot below.        Also, you might have observed that not all the sections use tabs, some are ok with spaces. However rules for which section should use what are not clear to me, so my recommendation is to stick with tabs everywhere. For a quick make tutorial, you can check out this site. A last word of warning on this matter: copy-pasting from this blogpost will almost certainly mess things up (convert tabs to spaces, etc), so please double check the source after copying it.    Our goal (taken from the first linke tutorial) is to get the following little C program to compile and run:    The first step is to create a Makefile for it:    Place the files in the  directory of either the checked-out OpenWrt source or the Openwrt SDK. Now change into this directory and make sure that everything builds on our local system (without the crosscompiling magic):    Now to create the openwrt makefile. This will be located one level up (ie. ):    The makefile should be pretty self-explanatory. A couple things I would like to highlight:      is the step where we copy our source-code to the build directory. This is a hack to circumvent the need of downloading the tgz file, but it is a hack which works well (you might want to add the –r switch to cp if you have nested directories in src – this isn’t the case for this simple example)     In the  step it is very important to include the  part. Without it, the thing will build, but it will link with the standard libc, rather than the ulibc available on the Openwrt router. Tracking down this error is made harder by the unintuitive error messages. Specifically, you will see something like this on your router: “”, even though you see that the file exists and it has execute permissions! To verify that your issues are caused by this problem, simply too a “” on your router and check to see if you have strings indicating glibc (instead of ulibc).    Now you are ready to compile:     If you are using the SDK, simply go to its root directory and issue the  command     If you are building the complete tree, you have to first do “”, make sure that your package is checked for build (you should see the letter M near it) and then issue . Be aware that compiling the full tree can take a considerable time (more than a hour in some cases).    Your package should now be ready. Copy the package (you will find it in the  subfolder) to your router (or better yet, a Qemu VM running OpenWrt – for safety) and test that everything works:    This would be all :-). Because of simplicity, this tutorial doesn’t cover the the calling of configuration scripts. Also, as far as I’ve seen, there is no easy way to include parts of other projects. For example, if I wish to create a package for LuaFileSystem, I would need  (and some other, related files). However, I haven’t found an easy way reference it from the  package, and have opted for putting a local copy in the  subdirectory.  Picture taken from cantrell.david's buddy icon with permission.  " type="hidden"&gt;&lt;input name="service_id" value="WordsCount" type="hidden"&gt;&lt;input name="service_name" value="SMOG Calculator" type="hidden"&gt;&lt;input class="smog-button" value="SMOG" type="submit"&gt;&lt;/form&gt; &lt;/h3&gt; &lt;span class="post-comment-link" style="float: right;"&gt; &lt;/span&gt;    &lt;p&gt;&lt;a href="http://lh6.ggpht.com/_hrvCBhtWhJ4/SdyWsPnZYbI/AAAAAAAAAlA/9EK_pgXMXT4/s1600-h/2726596365_66a64212fb_b%5B2%5D.jpg"&gt;&lt;img style="border-width: 0px; display: inline; margin-left: 0px; margin-right: 0px;" title="2726596365_66a64212fb_b" alt="2726596365_66a64212fb_b" src="http://lh6.ggpht.com/_hrvCBhtWhJ4/SdyWsqUTDqI/AAAAAAAAAlE/nwln3EBwhq8/2726596365_66a64212fb_b_thumb.jpg?imgmax=800" width="244" align="right" border="0" height="165" /&gt;&lt;/a&gt; From my experience, compiling software is not especially hard, but most of the tutorials out there are somewhat dated (as this one will be in 6-7 months). But at least until then it can be useful, and hopefully I will find the time to update it later on. I’m using the trunk version of OpenWrt, which a little more up-to-date than 8.09, but most probably everything described here works with 8.09 (the latest release).&lt;/p&gt;  &lt;p&gt;I’ve taken inspiration from the following sources:&lt;/p&gt;  &lt;ul&gt;&lt;li&gt;&lt;a href="http://manoftoday.wordpress.com/2007/10/11/writing-and-compiling-a-simple-program-for-openwrt/"&gt;Writing and Compiling A Simple Program For OpenWrt&lt;/a&gt; &lt;/li&gt;&lt;li&gt;&lt;a href="http://hanez.org/openwrt-building-software-packages.html"&gt;OpenWrt - Building software packages&lt;/a&gt; &lt;/li&gt;&lt;li&gt;&lt;a href="http://vivekian2.wordpress.com/2007/03/28/building-your-own-package-for-openwrt/"&gt;Thinking Understanding Doing&lt;/a&gt; &lt;/li&gt;&lt;li&gt;&lt;a href="http://forum.openwrt.org/viewtopic.php?id=10117"&gt;Own IPKG packages build with OpenWRT-SDK&lt;/a&gt; &lt;/li&gt;&lt;/ul&gt;  &lt;p&gt;The main ideas would be:&lt;/p&gt;  &lt;ul&gt;&lt;li&gt;The easiest way to start is by copying an existing makefile and editing it to fit your needs &lt;/li&gt;&lt;li&gt;OpenWrt has an advanced build system which does all the following things:      &lt;ul&gt;&lt;li&gt;Download the application from its original source (and verify the integrity of the archive using md5sum) &lt;/li&gt;&lt;li&gt;Apply some local patches to it &lt;/li&gt;&lt;li&gt;Configure / build it &lt;/li&gt;&lt;/ul&gt; However, for local development you most likely won't need this. An alternative solution (which will be used in the tutorial later on) would be to copy the source to the build directory in the preparation faze. &lt;/li&gt;&lt;li&gt;Makefiles are very sensitive to tabs (so you &lt;em&gt;have&lt;/em&gt; to have tabs and not 4 or 8 spaces in certain locations) and also, errors in them are very cryptic (for example &lt;a href="http://www.delorie.com/djgpp/v2faq/faq22_17.html"&gt;"missing separator"&lt;/a&gt;). If your build fails, the first thing you should check is that you have your tabs in order. Also verify that your editor doesn’t have some kind of “transform tabs to spaces” option active. For example, if you are using &lt;a href="http://www.midnight-commander.org/"&gt;mcedit&lt;/a&gt; with the default color-scheme, it will highlight correct tabs in red, as can be seen in the screenshot below.     &lt;br /&gt;&lt;a href="http://lh3.ggpht.com/_hrvCBhtWhJ4/SdyWtSjF9LI/AAAAAAAAAlI/Ul2Ol9Si-BQ/s1600-h/mcedit_openwrt_package%5B9%5D.png"&gt;&lt;img style="border-width: 0px; display: block; float: none; margin-left: auto; margin-right: auto;" title="mcedit_openwrt_package" alt="mcedit_openwrt_package" src="http://lh3.ggpht.com/_hrvCBhtWhJ4/SdyWt_tT5oI/AAAAAAAAAlM/7zk-Y_FW7GU/mcedit_openwrt_package_thumb%5B7%5D.png?imgmax=800" width="421" border="0" height="480" /&gt;&lt;/a&gt; Also, you might have observed that not all the sections use tabs, some are ok with spaces. However rules for which section should use what are not clear to me, so my recommendation is to stick with tabs everywhere. For a quick make tutorial, you can check out &lt;a href="http://www.eng.hawaii.edu/Tutor/Make/"&gt;this site&lt;/a&gt;. A last word of warning on this matter: copy-pasting from this blogpost will almost certainly mess things up (convert tabs to spaces, etc), so please double check the source after copying it. &lt;/li&gt;&lt;/ul&gt;  &lt;p&gt;Our goal (taken from the first linke tutorial) is to get the following little C program to compile and run:&lt;/p&gt;  &lt;pre&gt;&lt;code&gt;&lt;br /&gt;/****************&lt;br /&gt;* Helloworld.c&lt;br /&gt;* The most simplistic C program ever written.&lt;br /&gt;* An epileptic monkey on crack could write this code.&lt;br /&gt;*****************/&lt;br /&gt;#include &lt;stdio.h&gt;&lt;br /&gt;&lt;br /&gt;int main(void)&lt;br /&gt;{&lt;br /&gt; printf("Hell! O' world, why won't my code compile?\n\n");&lt;br /&gt; return 0;&lt;br /&gt;}&lt;br /&gt;&lt;/stdio.h&gt;&lt;/code&gt;&lt;/pre&gt;  &lt;p&gt;The first step is to create a Makefile for it:&lt;/p&gt;  &lt;pre&gt;&lt;code&gt;&lt;br /&gt;# build helloworld executable when user executes "make"&lt;br /&gt;helloworld: helloworld.o&lt;br /&gt; $(CC) $(LDFLAGS) helloworld.o -o helloworld&lt;br /&gt;helloworld.o: helloworld.c&lt;br /&gt; $(CC) $(CFLAGS) -c helloworld.c&lt;br /&gt;&lt;br /&gt;# remove object files and executable when user executes "make clean"&lt;br /&gt;clean:&lt;br /&gt; rm *.o helloworld&lt;br /&gt;&lt;/code&gt;&lt;/pre&gt;  &lt;p&gt;Place the files in the &lt;code&gt;packages/helloworld/src&lt;/code&gt; directory of either the checked-out OpenWrt source or the Openwrt SDK. Now change into this directory and make sure that everything builds on our local system (without the crosscompiling magic):&lt;/p&gt;  &lt;pre&gt;&lt;code&gt;&lt;br /&gt;make&lt;br /&gt;./helloworld &lt;-- this should output the message make clean   &lt;-- clean up after ourselves &lt;/code&gt;&lt;/pre&gt;  &lt;p&gt;Now to create the openwrt makefile. This will be located one level up (ie. &lt;code&gt;packages/helloworld/Makefile&lt;/code&gt;):&lt;/p&gt;  &lt;pre&gt;&lt;code&gt;&lt;br /&gt;#&lt;br /&gt;# Copyright (C) 2008 OpenWrt.org&lt;br /&gt;#&lt;br /&gt;# This is free software, licensed under the GNU General Public License v2.&lt;br /&gt;# See /LICENSE for more information.&lt;br /&gt;#&lt;br /&gt;# $Id$&lt;br /&gt;&lt;br /&gt;include $(TOPDIR)/rules.mk&lt;br /&gt;&lt;br /&gt;PKG_NAME:=helloworld&lt;br /&gt;PKG_RELEASE:=1&lt;br /&gt;&lt;br /&gt;include $(INCLUDE_DIR)/package.mk&lt;br /&gt;&lt;br /&gt;define Package/helloworld&lt;br /&gt; SECTION:=utils&lt;br /&gt; CATEGORY:=Utilities&lt;br /&gt; TITLE:=Helloworld -- prints a snarky message&lt;br /&gt;endef&lt;br /&gt;&lt;br /&gt;define Build/Prepare&lt;br /&gt; mkdir -p $(PKG_BUILD_DIR)&lt;br /&gt; $(CP) ./src/* $(PKG_BUILD_DIR)/&lt;br /&gt;endef&lt;br /&gt;&lt;br /&gt;define Build/Configure&lt;br /&gt;endef&lt;br /&gt;&lt;br /&gt;define Build/Compile&lt;br /&gt; $(MAKE) -C $(PKG_BUILD_DIR) $(TARGET_CONFIGURE_OPTS)&lt;br /&gt;endef&lt;br /&gt;&lt;br /&gt;define Package/helloworld/install&lt;br /&gt; $(INSTALL_DIR) $(1)/bin&lt;br /&gt; $(INSTALL_BIN) $(PKG_BUILD_DIR)/helloworld $(1)/bin/&lt;br /&gt;endef&lt;br /&gt;&lt;br /&gt;$(eval $(call BuildPackage,helloworld))&lt;br /&gt;&lt;/code&gt;&lt;/pre&gt;  &lt;p&gt;The makefile should be pretty self-explanatory. A couple things I would like to highlight:&lt;/p&gt;  &lt;ul&gt;&lt;li&gt;&lt;code&gt;Build/Prepare&lt;/code&gt; is the step where we copy our source-code to the build directory. This is a hack to circumvent the need of downloading the tgz file, but it is a hack which works well (you might want to add the –r switch to cp if you have nested directories in src – this isn’t the case for this simple example) &lt;/li&gt;&lt;li&gt;In the &lt;code&gt;Build/Compile&lt;/code&gt; step it is &lt;em&gt;very&lt;/em&gt; important to include the &lt;code&gt;$(TARGET_CONFIGURE_OPTS)&lt;/code&gt; part. Without it, the thing will build, but it will link with the standard libc, rather than the ulibc available on the Openwrt router. Tracking down this error is made harder by the unintuitive error messages. Specifically, you will see something like this on your router: “&lt;code&gt;/bin/ash: The command /bin/helloworld can not be found&lt;/code&gt;”, even though you &lt;em&gt;see&lt;/em&gt; that the file exists and it has execute permissions! To verify that your issues are caused by this problem, simply too a “&lt;code&gt;less /bin/helloworld&lt;/code&gt;” on your router and check to see if you have strings indicating glibc (instead of ulibc). &lt;/li&gt;&lt;/ul&gt;  &lt;p&gt;Now you are ready to compile:&lt;/p&gt;  &lt;ul&gt;&lt;li&gt;If you are using the SDK, simply go to its root directory and issue the &lt;code&gt;make V=99&lt;/code&gt; command &lt;/li&gt;&lt;li&gt;If you are building the complete tree, you have to first do “&lt;code&gt;make menuconfig&lt;/code&gt;”, make sure that your package is checked for build (you should see the letter M near it) and then issue &lt;code&gt;make V=99&lt;/code&gt;. Be aware that compiling the full tree can take a considerable time (more than a hour in some cases). &lt;/li&gt;&lt;/ul&gt;  &lt;p&gt;Your package should now be ready. Copy the package (you will find it in the &lt;code&gt;bin/packages/target-...&lt;/code&gt; subfolder) to your router (or better yet, a &lt;a href="http://oldwiki.openwrt.org/RunningKamikazeOnQEMUHowTo.html"&gt;Qemu VM running OpenWrt&lt;/a&gt; – for safety) and test that everything works:&lt;/p&gt;  &lt;pre&gt;&lt;code&gt;&lt;br /&gt;scp helloworld.ipkg root@router:/root&lt;br /&gt;[root@router]# opkg install helloworld.ipkg&lt;br /&gt;[root@router]# helloworld &lt;-- the message should be printed &lt;/code&gt;&lt;/pre&gt;  &lt;p&gt;This would be all :-). Because of simplicity, this tutorial doesn’t cover the the calling of configuration scripts. Also, as far as I’ve seen, there is no easy way to include parts of other projects. For example, if I wish to create a package for &lt;a href="http://www.keplerproject.org/luafilesystem/"&gt;LuaFileSystem&lt;/a&gt;, I would need &lt;code&gt;lua.h&lt;/code&gt; (and some other, related files). However, I haven’t found an easy way reference it from the &lt;code&gt;lua&lt;/code&gt; package, and have opted for putting a local copy in the &lt;code&gt;src/lua&lt;/code&gt; subdirectory.&lt;/p&gt;  &lt;p&gt;Picture taken from &lt;a href="http://www.flickr.com/photos/dcantrell/"&gt;cantrell.david's buddy icon&lt;/a&gt; with permission.&lt;/p&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/4984480909360655633-816018488460205986?l=worldinthenet.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://worldinthenet.blogspot.com/feeds/816018488460205986/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://worldinthenet.blogspot.com/2009/07/zz-compiling-software-for-openwrt-and.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/4984480909360655633/posts/default/816018488460205986'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/4984480909360655633/posts/default/816018488460205986'/><link rel='alternate' type='text/html' href='http://worldinthenet.blogspot.com/2009/07/zz-compiling-software-for-openwrt-and.html' title='[zz] Compiling software for OpenWrt (and creating packages)'/><author><name>Taojun</name><uri>http://www.blogger.com/profile/12946690813153575136</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><media:thumbnail xmlns:media='http://search.yahoo.com/mrss/' url='http://lh6.ggpht.com/_hrvCBhtWhJ4/SdyWsqUTDqI/AAAAAAAAAlE/nwln3EBwhq8/s72-c/2726596365_66a64212fb_b_thumb.jpg?imgmax=800' height='72' width='72'/><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-4984480909360655633.post-8188230544039653692</id><published>2009-07-15T17:24:00.000-07:00</published><updated>2009-07-15T17:25:42.202-07:00</updated><title type='text'>[zz] OpenWRT Howto</title><content type='html'>&lt;div class="table-of-contents"&gt;&lt;p class="table-of-contents-heading"&gt;Contents&lt;/p&gt;&lt;ol&gt;&lt;li&gt; &lt;a href="http://wiki.cacert.org/wiki/OpenWRT#Introduction"&gt;Introduction&lt;/a&gt;&lt;/li&gt;&lt;li&gt; &lt;a href="http://wiki.cacert.org/wiki/OpenWRT#FlashingyourWRT54G"&gt;Flashing your WRT54G&lt;/a&gt;&lt;ol&gt;&lt;li&gt; &lt;a href="http://wiki.cacert.org/wiki/OpenWRT#PreparingyourWRT54G"&gt;Preparing your WRT54G&lt;/a&gt;&lt;/li&gt;&lt;li&gt; &lt;a href="http://wiki.cacert.org/wiki/OpenWRT#InstallingOpenWRT"&gt;Installing OpenWRT&lt;/a&gt;&lt;/li&gt;&lt;/ol&gt;&lt;/li&gt;&lt;li&gt; &lt;a href="http://wiki.cacert.org/wiki/OpenWRT#GettingstartedwithOpenWRT"&gt;Getting started with OpenWRT&lt;/a&gt;&lt;ol&gt;&lt;li&gt; &lt;a href="http://wiki.cacert.org/wiki/OpenWRT#FirstTimeUse"&gt;First Time Use&lt;/a&gt;&lt;/li&gt;&lt;li&gt; &lt;a href="http://wiki.cacert.org/wiki/OpenWRT#Cleaningthingsupalittle"&gt;Cleaning things up a little&lt;/a&gt;&lt;/li&gt;&lt;/ol&gt;&lt;/li&gt;&lt;li&gt; &lt;a href="http://wiki.cacert.org/wiki/OpenWRT#InstallingOpenVPN"&gt;Installing OpenVPN&lt;/a&gt;&lt;ol&gt;&lt;li&gt; &lt;a href="http://wiki.cacert.org/wiki/OpenWRT#Gettingthepackages"&gt;Getting the packages&lt;/a&gt;&lt;/li&gt;&lt;li&gt; &lt;a href="http://wiki.cacert.org/wiki/OpenWRT#Configuration"&gt;Configuration&lt;/a&gt;&lt;/li&gt;&lt;li&gt; &lt;a href="http://wiki.cacert.org/wiki/OpenWRT#FirewallModifications"&gt;Firewall Modifications&lt;/a&gt;&lt;/li&gt;&lt;li&gt; &lt;a href="http://wiki.cacert.org/wiki/OpenWRT#DNSMASQConfiguration"&gt;DNSMASQ Configuration&lt;/a&gt;&lt;/li&gt;&lt;li&gt; &lt;a href="http://wiki.cacert.org/wiki/OpenWRT#OpenVPNConfiguration"&gt;OpenVPN Configuration&lt;/a&gt;&lt;/li&gt;&lt;/ol&gt;&lt;/li&gt;&lt;li&gt; &lt;a href="http://wiki.cacert.org/wiki/OpenWRT#ClientConfiguration"&gt;Client Configuration&lt;/a&gt;&lt;ol&gt;&lt;li&gt; &lt;a href="http://wiki.cacert.org/wiki/OpenWRT#UnderWRT54G"&gt;Under WRT54G&lt;/a&gt;&lt;/li&gt;&lt;li&gt; &lt;a href="http://wiki.cacert.org/wiki/OpenWRT#UnderUbuntu"&gt;Under Ubuntu&lt;/a&gt;&lt;/li&gt;&lt;/ol&gt;&lt;/li&gt;&lt;li&gt; &lt;a href="http://wiki.cacert.org/wiki/OpenWRT#Gotchas"&gt;Gotchas&lt;/a&gt;&lt;ol&gt;&lt;li&gt; &lt;a href="http://wiki.cacert.org/wiki/OpenWRT#OutofSpace"&gt;Out of Space&lt;/a&gt;&lt;/li&gt;&lt;/ol&gt;&lt;/li&gt;&lt;li&gt; &lt;a href="http://wiki.cacert.org/wiki/OpenWRT#Moreinformation"&gt;More information&lt;/a&gt;&lt;ol&gt;&lt;li&gt; &lt;a href="http://wiki.cacert.org/wiki/OpenWRT#Notes"&gt;Notes&lt;/a&gt;&lt;/li&gt;&lt;li&gt; &lt;a href="http://wiki.cacert.org/wiki/OpenWRT#Links"&gt;Links&lt;/a&gt;&lt;/li&gt;&lt;/ol&gt;&lt;/li&gt;&lt;li&gt; &lt;a href="http://wiki.cacert.org/wiki/OpenWRT#Simplewebinterface"&gt;Simple web interface&lt;/a&gt;&lt;ol&gt;&lt;li&gt; &lt;a href="http://wiki.cacert.org/wiki/OpenWRT#InstallingLighttpdandPHP"&gt;Installing Lighttpd and PHP&lt;/a&gt;&lt;/li&gt;&lt;li&gt; &lt;a href="http://wiki.cacert.org/wiki/OpenWRT#ExampleWebInterface"&gt;Example Web Interface&lt;/a&gt;&lt;/li&gt;&lt;li&gt; &lt;a href="http://wiki.cacert.org/wiki/OpenWRT#EnablingPPPoE"&gt;Enabling PPPoE&lt;/a&gt;&lt;/li&gt;&lt;/ol&gt;&lt;/li&gt;&lt;li&gt; &lt;a href="http://wiki.cacert.org/wiki/OpenWRT#Conclusion"&gt;Conclusion&lt;/a&gt;&lt;/li&gt;&lt;/ol&gt;&lt;/div&gt; &lt;span class="anchor" id="line-2"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-3"&gt;&lt;/span&gt;&lt;p class="line867"&gt; &lt;/p&gt;&lt;h2 id="Introduction"&gt;Introduction&lt;/h2&gt; &lt;span class="anchor" id="line-4"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-5"&gt;&lt;/span&gt;&lt;p class="line874"&gt;I went out and bought a WRT54G after playing with a work one that ended up being loaded with OpenWRT firmware and seeing first hand how neat these things really are if you get to tinker with them at a level beyond that of any simple webpage administration that Linksys ship by default. &lt;span class="anchor" id="line-6"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-7"&gt;&lt;/span&gt;&lt;/p&gt;&lt;p class="line862"&gt;The router I have is a &lt;a class="http" href="http://www1.linksys.com/products/product.asp?grid=33&amp;amp;scid=35&amp;amp;prid=601"&gt;WRT54G v3.1&lt;/a&gt; and was pre-loaded with 4.00.7 firmware, which at first attempt wouldn't load OpenWRT firmware either by webpage or TFTP, as described on the &lt;a class="http" href="http://www.openwrt.org/"&gt;OpenWRT&lt;/a&gt; website. My goal for the time being is fairly simple, I wanted a router I could take with me and plug into other peoples networks that wouldn't open the flood gates for the bad guys to get in, it also served as a testing and demonstration platform for customers that want a better then WEP security product for their network. &lt;span class="anchor" id="line-8"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-9"&gt;&lt;/span&gt;&lt;/p&gt;&lt;p class="line867"&gt;&lt;img alt="/!\" src="http://wiki.cacert.org/moin/rightsidebar/img/alert.png" title="/!\" width="15" height="15" /&gt; BIG FAT WARNING: Usual disclaimers about I'm not responsible for your actions, this information is provided for educational purposes only and if you turn your router into a brick it may be because you didn't research the topic enough before moving forward and doing anything. &lt;span class="anchor" id="line-10"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-11"&gt;&lt;/span&gt;&lt;/p&gt;&lt;p class="line867"&gt; &lt;/p&gt;&lt;h2 id="FlashingyourWRT54G"&gt;Flashing your WRT54G&lt;/h2&gt; &lt;span class="anchor" id="line-12"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-13"&gt;&lt;/span&gt;&lt;p class="line867"&gt; &lt;/p&gt;&lt;h3 id="PreparingyourWRT54G"&gt;Preparing your WRT54G&lt;/h3&gt; &lt;span class="anchor" id="line-14"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-15"&gt;&lt;/span&gt;&lt;p class="line862"&gt;This may or may not be optional, but I had to upgrade my WRT54G firmware to v4.20.7 before I could load the OpenWRT firmware via the webpage. You can grab this from the &lt;a class="http" href="http://www.linksys.com/servlet/Satellite?childpagename=US%2FLayout&amp;amp;packedargs=c%3DL_Download_C2%26cid%3D1115417109974%26sku%3D1123637915061&amp;amp;pagename=Linksys%2FCommon%2FVisitorWrapper"&gt;Linksys&lt;/a&gt; website. &lt;span class="anchor" id="line-16"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-17"&gt;&lt;/span&gt;&lt;/p&gt;&lt;p class="line874"&gt;Once loaded you will be able to telnet to your router, by default there is no web config that comes with OpenWRT, so you're stuck using vi for the most part, but then again you get the full power of the device at your disposal rather then a limited feature set. &lt;span class="anchor" id="line-18"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-19"&gt;&lt;/span&gt;&lt;/p&gt;&lt;p class="line867"&gt; &lt;/p&gt;&lt;h3 id="InstallingOpenWRT"&gt;Installing OpenWRT&lt;/h3&gt; &lt;span class="anchor" id="line-20"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-21"&gt;&lt;/span&gt;&lt;p class="line862"&gt;Swatting up on the &lt;a class="http" href="http://wiki.openwrt.org/OpenWrtDocs"&gt;OpenWRT documentation&lt;/a&gt; wouldn't hurt before you do anything, it may take you a little time, but it could save you from turning your shiney new router into an expensive lump of plastic you are no longer able to use. &lt;span class="anchor" id="line-22"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-23"&gt;&lt;/span&gt;&lt;/p&gt;&lt;p class="line874"&gt;Firstly you will need to download a firmware image, the manual suggests using the squashfs version since this gives you a couple of more options if you screw up your install and will allow you to be able to fix it a lot easier then some of the other methods. &lt;span class="anchor" id="line-24"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-25"&gt;&lt;/span&gt;&lt;/p&gt;&lt;p class="line862"&gt;At the time of writting, the current stable image suitable for my WRT54G was &lt;a class="http" href="http://downloads.openwrt.org/whiterussian/rc3/bin/openwrt-wrt54g-squashfs.bin"&gt;WhiteRussian RC3&lt;/a&gt; which seems to be pretty stable, at least I've not come across any problems that I didn't cause myself, all I did to get this working was download and then upload via the webpage, I waited about 30 seconds and was then able to telnet into the router. &lt;span class="anchor" id="line-26"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-27"&gt;&lt;/span&gt;&lt;/p&gt;&lt;p class="line867"&gt; &lt;/p&gt;&lt;h2 id="GettingstartedwithOpenWRT"&gt;Getting started with OpenWRT&lt;/h2&gt; &lt;span class="anchor" id="line-28"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-29"&gt;&lt;/span&gt;&lt;p class="line867"&gt; &lt;/p&gt;&lt;h3 id="FirstTimeUse"&gt;First Time Use&lt;/h3&gt; &lt;span class="anchor" id="line-30"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-31"&gt;&lt;/span&gt;&lt;p class="line874"&gt;I suggest for the first few steps you use a piece of cat5 connected to a computer to update the password on the router, otherwise if you come in over telnet via wireless it's possible someone else could of sniffed your packets while you add one. Enabling a password will then also enable SSH and disable telnet connections as well. &lt;span class="anchor" id="line-32"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-33"&gt;&lt;/span&gt;&lt;/p&gt;&lt;p class="line867"&gt;&lt;span class="anchor" id="line-34"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-35"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-36"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-37"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-38"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-39"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-40"&gt;&lt;/span&gt;&lt;/p&gt;&lt;pre&gt;root@OpenWrt:~# passwd&lt;br /&gt;Changing password for root&lt;br /&gt;Enter the new password (minimum of 5, maximum of 8 characters)&lt;br /&gt;Please use a combination of upper and lower case letters and numbers.&lt;br /&gt;Enter new password:&lt;br /&gt;Re-enter new password:&lt;/pre&gt;&lt;span class="anchor" id="line-41"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-42"&gt;&lt;/span&gt;&lt;p class="line867"&gt; &lt;/p&gt;&lt;h3 id="Cleaningthingsupalittle"&gt;Cleaning things up a little&lt;/h3&gt; &lt;span class="anchor" id="line-43"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-44"&gt;&lt;/span&gt;&lt;p class="line874"&gt;It's a VERY VERY good idea to set the clock on bootup, since every time you restart the router it will reset back to Jan 1st 2000, which can cause all sorts of issues with OpenVPN and time settings on certificates. The best solution is to install ntpclient and then run it to correct the system clock. &lt;span class="anchor" id="line-45"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-46"&gt;&lt;/span&gt;&lt;/p&gt;&lt;p class="line867"&gt;&lt;span class="anchor" id="line-47"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-48"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-49"&gt;&lt;/span&gt;&lt;/p&gt;&lt;pre&gt;ipkg install ntpclient&lt;br /&gt;/etc/init.d/S60ntpclient&lt;/pre&gt;&lt;span class="anchor" id="line-50"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-51"&gt;&lt;/span&gt;&lt;p class="line874"&gt;It's also helpful to setup timezone information unless you prefer to view everything in GMT. For the east coast of Australia that has daylight savings time you'd do something along the lines of: &lt;span class="anchor" id="line-52"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-53"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-54"&gt;&lt;/span&gt;&lt;/p&gt;&lt;pre&gt;echo "EST-10EDT-11,M10.5.0/02:00:00,M3.5.0/03:00:00" &gt; /etc/TZ&lt;/pre&gt;&lt;span class="anchor" id="line-55"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-56"&gt;&lt;/span&gt;&lt;p class="line862"&gt;However due to the number of time zones and there are already articles written up in depth on other sites, so I won't duplicate their efforts, but instead point you to the other site: &lt;a class="http" href="http://wiki.openwrt.org/OpenWrtDocs/Configuration#head-29ce2ea9da8dfba2f1c0dc0eca6fec0a138df148"&gt;More TZ information here&lt;/a&gt; &lt;span class="anchor" id="line-57"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-58"&gt;&lt;/span&gt;&lt;/p&gt;&lt;p class="line874"&gt;You will also need a file to setup the SSID, default time (especially if you plan to run it in client mode), and transmit power level if you want to run lower then the default 255mW. vi /etc/init.d/S41defaults &lt;span class="anchor" id="line-59"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-60"&gt;&lt;/span&gt;&lt;/p&gt;&lt;p class="line867"&gt;&lt;span class="anchor" id="line-61"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-62"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-63"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-64"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-65"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-66"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-67"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-68"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-69"&gt;&lt;/span&gt;&lt;/p&gt;&lt;pre&gt;SSID=$(nvram get wl0_ssid)&lt;br /&gt;TXPWR1=$(nvram get wl0_txpwr1)&lt;br /&gt;&lt;br /&gt;wl ssid $SSID&lt;br /&gt;wl txpwr1 -m $TXPWR1&lt;br /&gt;date -s '110401592005'&lt;/pre&gt;&lt;span class="anchor" id="line-70"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-71"&gt;&lt;/span&gt;&lt;p class="line874"&gt;Since you won't be able to remotely access your router any longer with telnet you can do the following: &lt;span class="anchor" id="line-72"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-73"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-74"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-75"&gt;&lt;/span&gt;&lt;/p&gt;&lt;pre&gt;rm /etc/init.d/S50telnet&lt;br /&gt;killall telnetd&lt;/pre&gt;&lt;span class="anchor" id="line-76"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-77"&gt;&lt;/span&gt;&lt;p class="line867"&gt; &lt;/p&gt;&lt;h2 id="InstallingOpenVPN"&gt;Installing OpenVPN&lt;/h2&gt; &lt;span class="anchor" id="line-78"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-79"&gt;&lt;/span&gt;&lt;p class="line867"&gt; &lt;/p&gt;&lt;h3 id="Gettingthepackages"&gt;Getting the packages&lt;/h3&gt; &lt;span class="anchor" id="line-80"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-81"&gt;&lt;/span&gt;&lt;p class="line874"&gt;Next you will need to install OpenVPN, again due to all the effort put into OpenWRT there is a debian like packaging utility called ipkg, and just do the following: &lt;span class="anchor" id="line-82"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-83"&gt;&lt;/span&gt;&lt;/p&gt;&lt;p class="line867"&gt;&lt;span class="anchor" id="line-84"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-85"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-86"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-87"&gt;&lt;/span&gt;&lt;/p&gt;&lt;pre&gt;ipkg update&lt;br /&gt;ipkg upgrade&lt;br /&gt;ipkg install openvpn wl&lt;/pre&gt;&lt;span class="anchor" id="line-88"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-89"&gt;&lt;/span&gt;&lt;p class="line874"&gt;After installing if you run "df -h" you should have approximately 50% (1.1M) of free space left on your device. &lt;span class="anchor" id="line-90"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-91"&gt;&lt;/span&gt;&lt;/p&gt;&lt;p class="line867"&gt; &lt;/p&gt;&lt;h3 id="Configuration"&gt;Configuration&lt;/h3&gt; &lt;span class="anchor" id="line-92"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-93"&gt;&lt;/span&gt;&lt;p class="line874"&gt;Once the packages have installed, this is where the fun begins, I've set my router up to trust the wired LAN ports, default firewall on the WAN port, and I've removed the wifi network from being bridged with my LAN ports, this way I can disable all traffic to and from the wifi network unless they've sucessfully connected via VPN. &lt;span class="anchor" id="line-94"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-95"&gt;&lt;/span&gt;&lt;/p&gt;&lt;p class="line874"&gt;I'd suggest wiping your nvram configuration and then rebooting: &lt;span class="anchor" id="line-96"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-97"&gt;&lt;/span&gt;&lt;/p&gt;&lt;p class="line867"&gt;&lt;span class="anchor" id="line-98"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-99"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-100"&gt;&lt;/span&gt;&lt;/p&gt;&lt;pre&gt;mtd erase nvram&lt;br /&gt;reboot&lt;/pre&gt;&lt;span class="anchor" id="line-101"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-102"&gt;&lt;/span&gt;&lt;p class="line874"&gt;Once your router boots up you have a number of options, depending how locked down you want to make your router. &lt;span class="anchor" id="line-103"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-104"&gt;&lt;/span&gt;&lt;/p&gt;&lt;p class="line874"&gt;To disable SSID broadcasts: &lt;span class="anchor" id="line-105"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-106"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-107"&gt;&lt;/span&gt;&lt;/p&gt;&lt;pre&gt;nvram set wl0_closed=1&lt;/pre&gt;&lt;span class="anchor" id="line-108"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-109"&gt;&lt;/span&gt;&lt;p class="line874"&gt;To allow G-Mode only (disables 802.11b clients from connecting and slowing your connection down): &lt;span class="anchor" id="line-110"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-111"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-112"&gt;&lt;/span&gt;&lt;/p&gt;&lt;pre&gt;nvram set wl0_gmode=2&lt;/pre&gt;&lt;span class="anchor" id="line-113"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-114"&gt;&lt;/span&gt;&lt;p class="line874"&gt;You can set the channel (1-14 depending on your country) or set it to 0 for auto channel selection: &lt;span class="anchor" id="line-115"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-116"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-117"&gt;&lt;/span&gt;&lt;/p&gt;&lt;pre&gt;nvram set wl0_channel=0&lt;/pre&gt;&lt;span class="anchor" id="line-118"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-119"&gt;&lt;/span&gt;&lt;p class="line874"&gt;To change the SSID: &lt;span class="anchor" id="line-120"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-121"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-122"&gt;&lt;/span&gt;&lt;/p&gt;&lt;pre&gt;nvram set wl0_ssid=My_AP&lt;/pre&gt;&lt;span class="anchor" id="line-123"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-124"&gt;&lt;/span&gt;&lt;p class="line874"&gt;To allow you to recover from bad flash &lt;span class="anchor" id="line-125"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-126"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-127"&gt;&lt;/span&gt;&lt;/p&gt;&lt;pre&gt;nvram set boot_wait=on&lt;/pre&gt;&lt;span class="anchor" id="line-128"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-129"&gt;&lt;/span&gt;&lt;p class="line874"&gt;To fix large file transfer problems &lt;span class="anchor" id="line-130"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-131"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-132"&gt;&lt;/span&gt;&lt;/p&gt;&lt;pre&gt;nvram set clkfreq=216&lt;/pre&gt;&lt;span class="anchor" id="line-133"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-134"&gt;&lt;/span&gt;&lt;p class="line874"&gt;If you have a problem with your router rebooting unsetting the following may help &lt;span class="anchor" id="line-135"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-136"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-137"&gt;&lt;/span&gt;&lt;/p&gt;&lt;pre&gt;nvram unset watchdog&lt;/pre&gt;&lt;span class="anchor" id="line-138"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-139"&gt;&lt;/span&gt;&lt;p class="line874"&gt;Next you need to remove the wifi network from the bridged network inside the router, and you simply do: &lt;span class="anchor" id="line-140"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-141"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-142"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-143"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-144"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-145"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-146"&gt;&lt;/span&gt;&lt;/p&gt;&lt;pre&gt;nvram set lan_proto=static&lt;br /&gt;nvram set lan_ifname=br0&lt;br /&gt;nvram set lan_ifnames=vlan0&lt;br /&gt;nvram set lan_ipaddr=172.16.1.1&lt;br /&gt;nvram set lan_netmask=255.255.255.0&lt;/pre&gt;&lt;span class="anchor" id="line-147"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-148"&gt;&lt;/span&gt;&lt;p class="line874"&gt;Next you need to give your wifi network IP details &lt;span class="anchor" id="line-149"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-150"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-151"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-152"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-153"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-154"&gt;&lt;/span&gt;&lt;/p&gt;&lt;pre&gt;nvram set wifi_ifname=eth1&lt;br /&gt;nvram set wifi_proto=static&lt;br /&gt;nvram set wifi_ipaddr=172.16.2.1&lt;br /&gt;nvram set wifi_netmask=255.255.255.0&lt;/pre&gt;&lt;span class="anchor" id="line-155"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-156"&gt;&lt;/span&gt;&lt;p class="line874"&gt;If you are finished making changes do the following to make your changes go active: &lt;span class="anchor" id="line-157"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-158"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-159"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-160"&gt;&lt;/span&gt;&lt;/p&gt;&lt;pre&gt;nvram commit&lt;br /&gt;reboot&lt;/pre&gt;&lt;span class="anchor" id="line-161"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-162"&gt;&lt;/span&gt;&lt;p class="line867"&gt; &lt;/p&gt;&lt;h3 id="FirewallModifications"&gt;Firewall Modifications&lt;/h3&gt; &lt;span class="anchor" id="line-163"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-164"&gt;&lt;/span&gt;&lt;p class="line874"&gt;Next you'll need to modify your firewall slightly so people connecting via the wifi interface will only be able to request dhcp information and connect to the OpenVPN port. &lt;span class="anchor" id="line-165"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-166"&gt;&lt;/span&gt;&lt;/p&gt;&lt;p class="line867"&gt;&lt;span class="anchor" id="line-167"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-168"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-169"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-170"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-171"&gt;&lt;/span&gt;&lt;/p&gt;&lt;pre&gt;cd /etc&lt;br /&gt;rm firewall.user&lt;br /&gt;cp -a /rom/etc/firewall.user .&lt;br /&gt;vi firewall.user&lt;/pre&gt;&lt;span class="anchor" id="line-172"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-173"&gt;&lt;/span&gt;&lt;p class="line874"&gt;When using vi, move the cursor down below the LAN= line and hit i (for insert), and then add the following line directly beneath it: &lt;span class="anchor" id="line-174"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-175"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-176"&gt;&lt;/span&gt;&lt;/p&gt;&lt;pre&gt;WLAN=$(nvram get wifi_ifname)&lt;/pre&gt;&lt;span class="anchor" id="line-177"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-178"&gt;&lt;/span&gt;&lt;p class="line874"&gt;Now hit the escape key and move the cursor down below the warning section, and directly beneath this hit the i key again and insert the following lines: &lt;span class="anchor" id="line-179"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-180"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-181"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-182"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-183"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-184"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-185"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-186"&gt;&lt;/span&gt;&lt;/p&gt;&lt;pre&gt;if [ -n "$WLAN" ]&lt;br /&gt;then&lt;br /&gt;      iptables -A input_rule -i $WLAN -p udp --dport 67 -j ACCEPT&lt;br /&gt;      iptables -A input_rule -i $WLAN -p udp --dport 1194 -j ACCEPT&lt;br /&gt;      iptables -A input_rule -i $WLAN -j DROP&lt;br /&gt;fi&lt;/pre&gt;&lt;span class="anchor" id="line-187"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-188"&gt;&lt;/span&gt;&lt;p class="line874"&gt;Once you are sure everything is in place hit the escape key and type ":wq" (without the quotes) this will save and exit you out of the program. &lt;span class="anchor" id="line-189"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-190"&gt;&lt;/span&gt;&lt;/p&gt;&lt;p class="line867"&gt; &lt;/p&gt;&lt;h3 id="DNSMASQConfiguration"&gt;DNSMASQ Configuration&lt;/h3&gt; &lt;span class="anchor" id="line-191"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-192"&gt;&lt;/span&gt;&lt;p class="line874"&gt;Next you need to update dnsmasq so it has multiple subnet information, so do the following: &lt;span class="anchor" id="line-193"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-194"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-195"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-196"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-197"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-198"&gt;&lt;/span&gt;&lt;/p&gt;&lt;pre&gt;cd /etc&lt;br /&gt;rm dnsmasq.conf&lt;br /&gt;cp /rom/etc/dnsmasq.conf .&lt;br /&gt;vi dnsmasq.conf&lt;/pre&gt;&lt;span class="anchor" id="line-199"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-200"&gt;&lt;/span&gt;&lt;p class="line874"&gt;You'll need to scroll to the end of file, hit the "$" key then press "a" and paste the following lines into your config: &lt;span class="anchor" id="line-201"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-202"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-203"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-204"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-205"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-206"&gt;&lt;/span&gt;&lt;/p&gt;&lt;pre&gt;dhcp-range=lan,172.16.1.100,172.16.1.250,255.255.255.0,12h&lt;br /&gt;dhcp-range=wlan,172.16.2.100,172.16.2.250,255.255.255.0,12h&lt;br /&gt;dhcp-option=wlan,3&lt;br /&gt;dhcp-option=6,172.16.1.1&lt;/pre&gt;&lt;span class="anchor" id="line-207"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-208"&gt;&lt;/span&gt;&lt;p class="line874"&gt;Then hit the escape key and type ":wq", after which you'll need to restart dnsmasq: &lt;span class="anchor" id="line-209"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-210"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-211"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-212"&gt;&lt;/span&gt;&lt;/p&gt;&lt;pre&gt;killall dnsmasq&lt;br /&gt;/etc/init.d/S50dnsmasq&lt;/pre&gt;&lt;span class="anchor" id="line-213"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-214"&gt;&lt;/span&gt;&lt;p class="line867"&gt; &lt;/p&gt;&lt;h3 id="OpenVPNConfiguration"&gt;OpenVPN Configuration&lt;/h3&gt; &lt;span class="anchor" id="line-215"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-216"&gt;&lt;/span&gt;&lt;p class="line874"&gt;Next we can start with some of the more complicated configurations with OpenVPN itself. Due to the limited space on these devices you will also need a computer that has OpenSSL binaries installed as well. &lt;span class="anchor" id="line-217"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-218"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-219"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-220"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-221"&gt;&lt;/span&gt;&lt;/p&gt;&lt;pre&gt;mkdir /etc/openvpn&lt;br /&gt;cd /etc/openvpn&lt;br /&gt;vi openvpn.conf&lt;/pre&gt;&lt;span class="anchor" id="line-222"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-223"&gt;&lt;/span&gt;&lt;p class="line874"&gt;Next hit the i key and paste the following: &lt;span class="anchor" id="line-224"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-225"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-226"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-227"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-228"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-229"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-230"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-231"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-232"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-233"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-234"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-235"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-236"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-237"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-238"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-239"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-240"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-241"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-242"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-243"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-244"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-245"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-246"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-247"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-248"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-249"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-250"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-251"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-252"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-253"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-254"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-255"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-256"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-257"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-258"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-259"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-260"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-261"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-262"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-263"&gt;&lt;/span&gt;&lt;/p&gt;&lt;pre&gt;mode server&lt;br /&gt;tls-server&lt;br /&gt;port 1194&lt;br /&gt;proto udp&lt;br /&gt;dev tap&lt;br /&gt;&lt;br /&gt;local 172.16.2.1&lt;br /&gt;&lt;br /&gt;up /etc/openvpn/server-tun.up&lt;br /&gt;down /etc/openvpn/server-tun.down&lt;br /&gt;&lt;br /&gt;cipher BF-CBC&lt;br /&gt;auth SHA1&lt;br /&gt;&lt;br /&gt;ifconfig-pool 172.16.1.50 172.16.1.99 255.255.255.0&lt;br /&gt;ifconfig-pool-persist /tmp/ipp.txt&lt;br /&gt;tls-verify /etc/openvpn/access-control.sh&lt;br /&gt;&lt;br /&gt;ca /etc/openvpn/cacert.crt&lt;br /&gt;dh /etc/openvpn/dh1024.pem&lt;br /&gt;cert /etc/openvpn/server.crt&lt;br /&gt;key /etc/openvpn/server.key&lt;br /&gt;&lt;br /&gt;push "route-gateway 172.16.1.1"&lt;br /&gt;push "redirect-gateway"&lt;br /&gt;push "route 0.0.0.0 0.0.0.0"&lt;br /&gt;&lt;br /&gt;client-to-client&lt;br /&gt;&lt;br /&gt;keepalive 10 60&lt;br /&gt;persist-key&lt;br /&gt;persist-tun&lt;br /&gt;ping-timer-rem&lt;br /&gt;&lt;br /&gt;daemon&lt;br /&gt;&lt;br /&gt;log /tmp/openvpn.log&lt;br /&gt;verb 3&lt;/pre&gt;&lt;span class="anchor" id="line-264"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-265"&gt;&lt;/span&gt;&lt;p class="line874"&gt;Then hit the escape key and type ":wq" &lt;span class="anchor" id="line-266"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-267"&gt;&lt;/span&gt;&lt;/p&gt;&lt;p class="line874"&gt;next "vi server-tun.up" &lt;span class="anchor" id="line-268"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-269"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-270"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-271"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-272"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-273"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-274"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-275"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-276"&gt;&lt;/span&gt;&lt;/p&gt;&lt;pre&gt;LAN=$(nvram get lan_ifname)&lt;br /&gt;&lt;br /&gt;# bring up the tap interface&lt;br /&gt;$DEBUG ifconfig $1 0.0.0.0 up&lt;br /&gt;# and add that to the bridge&lt;br /&gt;$DEBUG brctl addif $LAN $1&lt;/pre&gt;&lt;span class="anchor" id="line-277"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-278"&gt;&lt;/span&gt;&lt;p class="line874"&gt;Then hit the escape key and type ":wq" &lt;span class="anchor" id="line-279"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-280"&gt;&lt;/span&gt;&lt;/p&gt;&lt;p class="line874"&gt;next "vi server-tun.down" &lt;span class="anchor" id="line-281"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-282"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-283"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-284"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-285"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-286"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-287"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-288"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-289"&gt;&lt;/span&gt;&lt;/p&gt;&lt;pre&gt;LAN=$(nvram get lan_ifname)&lt;br /&gt;&lt;br /&gt;# and delete that from the bridge&lt;br /&gt;$DEBUG brctl delif $LAN $1&lt;br /&gt;# bring down the tap interface&lt;br /&gt;$DEBUG ifconfig $1 0.0.0.0 down&lt;/pre&gt;&lt;span class="anchor" id="line-290"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-291"&gt;&lt;/span&gt;&lt;p class="line874"&gt;Then hit the escape key and type ":wq", followed by "chmod +x server-tun.up server-tun.down" &lt;span class="anchor" id="line-292"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-293"&gt;&lt;/span&gt;&lt;/p&gt;&lt;p class="line874"&gt;next "vi access-control.sh" &lt;span class="anchor" id="line-294"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-295"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-296"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-297"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-298"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-299"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-300"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-301"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-302"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-303"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-304"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-305"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-306"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-307"&gt;&lt;/span&gt;&lt;/p&gt;&lt;pre&gt;if [ "$1" != "0" ]; then&lt;br /&gt;      exit 0&lt;br /&gt;fi&lt;br /&gt;&lt;br /&gt;whologin=$(grep $2 /etc/openvpn/access-control.txt)&lt;br /&gt;if [ -z ${whologin}]; then&lt;br /&gt;  exit 1&lt;br /&gt;else&lt;br /&gt;  exit 0&lt;br /&gt;fi&lt;/pre&gt;&lt;span class="anchor" id="line-308"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-309"&gt;&lt;/span&gt;&lt;p class="line874"&gt;Then hit the escape key and type ":wq", followed by "chmod +x access-control.sh" &lt;span class="anchor" id="line-310"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-311"&gt;&lt;/span&gt;&lt;/p&gt;&lt;p class="line874"&gt;next "vi access-control.txt" &lt;span class="anchor" id="line-312"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-313"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-314"&gt;&lt;/span&gt;&lt;/p&gt;&lt;pre&gt;/emailAddress=user@isp.com&lt;/pre&gt;&lt;span class="anchor" id="line-315"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-316"&gt;&lt;/span&gt;&lt;p class="line874"&gt;You will need to have at least one domain/hostname registered with CAcert, then you will need to generate a certificate and submit a signing request to CAcert. &lt;span class="anchor" id="line-317"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-318"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-319"&gt;&lt;/span&gt;&lt;/p&gt;&lt;pre&gt;openssl req -nodes -new -keyout server.key -out server.csr&lt;/pre&gt;&lt;span class="anchor" id="line-320"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-321"&gt;&lt;/span&gt;&lt;p class="line874"&gt;Once you have a valid certificate simply "vi server.crt" and paste the contents in there. You will need to set the permissions on server.key so only root can read the file. &lt;span class="anchor" id="line-322"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-323"&gt;&lt;/span&gt;&lt;/p&gt;&lt;p class="line874"&gt;You will also need to put the contents of the CAcert root certificate in the directory as well. &lt;span class="anchor" id="line-324"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-325"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-326"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-327"&gt;&lt;/span&gt;&lt;/p&gt;&lt;pre&gt;wget http://www.cacert.org/cacert.crt&lt;br /&gt;chmod 600 /etc/openvpn/server.key&lt;/pre&gt;&lt;span class="anchor" id="line-328"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-329"&gt;&lt;/span&gt;&lt;p class="line874"&gt;Finally you will need to create a 1024bit dh file: &lt;span class="anchor" id="line-330"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-331"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-332"&gt;&lt;/span&gt;&lt;/p&gt;&lt;pre&gt;openssl dhparam -out dh1024.pem 1024&lt;/pre&gt;&lt;span class="anchor" id="line-333"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-334"&gt;&lt;/span&gt;&lt;p class="line874"&gt;If you want OpenVPN to auto-start (which you should) you need to vi /etc/init.d/openvpn &lt;span class="anchor" id="line-335"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-336"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-337"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-338"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-339"&gt;&lt;/span&gt;&lt;/p&gt;&lt;pre&gt;/usr/sbin/openvpn --config /etc/openvpn/openvpn.conf&lt;/pre&gt;&lt;span class="anchor" id="line-340"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-341"&gt;&lt;/span&gt;&lt;p class="line874"&gt;and &lt;span class="anchor" id="line-342"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-343"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-344"&gt;&lt;/span&gt;&lt;/p&gt;&lt;pre&gt;ln -sf /etc/init.d/openvpn /etc/init.d/S75openvpn&lt;/pre&gt;&lt;span class="anchor" id="line-345"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-346"&gt;&lt;/span&gt;&lt;p class="line874"&gt;At this point you should restart your router to see if everything is working, once your router has rebooted you can run "ps auxww" to see if openvpn is listed. &lt;span class="anchor" id="line-347"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-348"&gt;&lt;/span&gt;&lt;/p&gt;&lt;p class="line867"&gt; &lt;/p&gt;&lt;h2 id="ClientConfiguration"&gt;Client Configuration&lt;/h2&gt; &lt;span class="anchor" id="line-349"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-350"&gt;&lt;/span&gt;&lt;p class="line867"&gt; &lt;/p&gt;&lt;h3 id="UnderWRT54G"&gt;Under WRT54G&lt;/h3&gt; &lt;span class="anchor" id="line-351"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-352"&gt;&lt;/span&gt;&lt;p class="line874"&gt;You can use a WRT54G as a ethernet bridge/router, and use the WAN port as another LAN port so you end up with a 5 port ethernet bridge/router which is useful for linking buildings togeather or even just floors/rooms in the same house without the hassle/expense of having cat5 cables run, or tripping over them in the middle of the night. The best bit is the price, in Australia the going price for a WRT54G is about AU$120 (inc GST) if you were to buy an ethernet bridge or gaming adapter they are at least $50 more and you only get 1 ethernet port not 5! &lt;span class="anchor" id="line-353"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-354"&gt;&lt;/span&gt;&lt;/p&gt;&lt;p class="line874"&gt;So once you have a second unit flashed (see above) and ready to be worked on run the following commands: &lt;span class="anchor" id="line-355"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-356"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-357"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-358"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-359"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-360"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-361"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-362"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-363"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-364"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-365"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-366"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-367"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-368"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-369"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-370"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-371"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-372"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-373"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-374"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-375"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-376"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-377"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-378"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-379"&gt;&lt;/span&gt;&lt;/p&gt;&lt;pre&gt;nvram set wl0_ssid=My_AP&lt;br /&gt;nvram set lan_ifnames='vlan0 vlan1'&lt;br /&gt;nvram set wan_ifname=tap0&lt;br /&gt;nvram set wan_proto=dhcp&lt;br /&gt;nvram set wifi_proto=dhcp&lt;br /&gt;nvram set wl0_mode=sta&lt;br /&gt;nvram unset wl0_channel&lt;br /&gt;nvram set wl0_closed=1&lt;br /&gt;nvram set wl0_gmode=2&lt;br /&gt;nvram set boot_wait=on&lt;br /&gt;nvram set clkfreq=216&lt;br /&gt;nvram unset watchdog&lt;br /&gt;nvram set boot_wait=on&lt;br /&gt;nvram set lan_proto=static&lt;br /&gt;nvram set lan_ifname=br0&lt;br /&gt;nvram set lan_ipaddr=172.17.1.1&lt;br /&gt;nvram set lan_netmask=255.255.255.0&lt;br /&gt;nvram set wifi_ifname=eth1&lt;br /&gt;nvram set wifi_ipaddr=172.17.2.1&lt;br /&gt;nvram set wifi_netmask=255.255.255.0&lt;br /&gt;nvram commit&lt;br /&gt;mkdir /etc/openvpn-client&lt;br /&gt;reboot&lt;/pre&gt;&lt;span class="anchor" id="line-380"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-381"&gt;&lt;/span&gt;&lt;p class="line874"&gt;Next you'll need to create an vi /etc/openvpn-client/openvpn.conf file: &lt;span class="anchor" id="line-382"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-383"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-384"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-385"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-386"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-387"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-388"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-389"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-390"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-391"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-392"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-393"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-394"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-395"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-396"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-397"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-398"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-399"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-400"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-401"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-402"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-403"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-404"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-405"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-406"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-407"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-408"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-409"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-410"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-411"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-412"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-413"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-414"&gt;&lt;/span&gt;&lt;/p&gt;&lt;pre&gt;tls-client&lt;br /&gt;remote 172.16.2.1&lt;br /&gt;port 1194&lt;br /&gt;proto udp&lt;br /&gt;dev tap&lt;br /&gt;&lt;br /&gt;pull&lt;br /&gt;&lt;br /&gt;resolv-retry infinite&lt;br /&gt;nobind&lt;br /&gt;&lt;br /&gt;cipher BF-CBC&lt;br /&gt;auth SHA1&lt;br /&gt;&lt;br /&gt;ca /etc/openvpn-client/cacert.crt&lt;br /&gt;cert /etc/openvpn-client/client.crt&lt;br /&gt;key /etc/openvpn-client/client.key&lt;br /&gt;&lt;br /&gt;daemon&lt;br /&gt;user nobody&lt;br /&gt;group nogroup&lt;br /&gt;&lt;br /&gt;ping 5&lt;br /&gt;ping-restart 15&lt;br /&gt;resolv-retry 300&lt;br /&gt;ping-timer-rem&lt;br /&gt;persist-tun&lt;br /&gt;persist-key&lt;br /&gt;&lt;br /&gt;log /tmp/openvpn-client.log&lt;br /&gt;verb 1&lt;/pre&gt;&lt;span class="anchor" id="line-415"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-416"&gt;&lt;/span&gt;&lt;p class="line874"&gt;You will need to have a signed client/email certificate from the CAcert website, this is a simple step by step process on the website, once you have one you will need to export it from your brower, and most likely it will be in pkcs12 format so you will need to split this using openssl. &lt;span class="anchor" id="line-417"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-418"&gt;&lt;/span&gt;&lt;/p&gt;&lt;p class="line867"&gt;&lt;span class="anchor" id="line-419"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-420"&gt;&lt;/span&gt;&lt;/p&gt;&lt;pre&gt;openssl pkcs12 -in &lt;file&gt;.p12 -clcert&lt;/file&gt;&lt;/pre&gt;&lt;span class="anchor" id="line-421"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-422"&gt;&lt;/span&gt;&lt;p class="line874"&gt;You'll need to split the output into a .key file and a .crt file, most likely openssl will force you to set a password on your private key you will also need to remove this if you plan to use OpenVPN in any sort of automate manner. You will need to mark the client private key as read/write by root only. You also need to grab a copy of the root certificate. &lt;span class="anchor" id="line-423"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-424"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-425"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-426"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-427"&gt;&lt;/span&gt;&lt;/p&gt;&lt;pre&gt;openssl rsa -in client.pem -out client.key&lt;br /&gt;chmod 600 client.key&lt;br /&gt;wget http://www.cacert.org/cacert.crt&lt;/pre&gt;&lt;span class="anchor" id="line-428"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-429"&gt;&lt;/span&gt;&lt;p class="line874"&gt;One final thing you'll need to vi /etc/init.d/openvpn-client &lt;span class="anchor" id="line-430"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-431"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-432"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-433"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-434"&gt;&lt;/span&gt;&lt;/p&gt;&lt;pre&gt;/usr/sbin/openvpn --config /etc/openvpn-client/openvpn.conf&lt;/pre&gt;&lt;span class="anchor" id="line-435"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-436"&gt;&lt;/span&gt;&lt;p class="line874"&gt;and &lt;span class="anchor" id="line-437"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-438"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-439"&gt;&lt;/span&gt;&lt;/p&gt;&lt;pre&gt;ln -sf /etc/init.d/openvpn-client /etc/init.d/S75openvpn&lt;/pre&gt;&lt;span class="anchor" id="line-440"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-441"&gt;&lt;/span&gt;&lt;p class="line867"&gt; &lt;/p&gt;&lt;h3 id="UnderUbuntu"&gt;Under Ubuntu&lt;/h3&gt; &lt;span class="anchor" id="line-442"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-443"&gt;&lt;/span&gt;&lt;p class="line874"&gt;OpenVPN has clients for a lot of platforms, at this point in time the only thing I need to connect via is my laptop running Ubuntu, hopefully others with experience on other platforms can add further information in this section. &lt;span class="anchor" id="line-444"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-445"&gt;&lt;/span&gt;&lt;/p&gt;&lt;p class="line874"&gt;firstly you will need to install OpenVPN and do some misc other things: &lt;span class="anchor" id="line-446"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-447"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-448"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-449"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-450"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-451"&gt;&lt;/span&gt;&lt;/p&gt;&lt;pre&gt;apt-get install openvpn&lt;br /&gt;mkdir -p /etc/openvpn&lt;br /&gt;cd /etc/openvpn&lt;br /&gt;wget http://www.cacert.org/cacert.crt&lt;/pre&gt;&lt;span class="anchor" id="line-452"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-453"&gt;&lt;/span&gt;&lt;p class="line874"&gt;Next you can start working on the openvpn.conf file: &lt;span class="anchor" id="line-454"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-455"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-456"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-457"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-458"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-459"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-460"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-461"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-462"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-463"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-464"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-465"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-466"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-467"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-468"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-469"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-470"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-471"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-472"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-473"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-474"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-475"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-476"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-477"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-478"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-479"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-480"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-481"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-482"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-483"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-484"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-485"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-486"&gt;&lt;/span&gt;&lt;/p&gt;&lt;pre&gt;tls-client&lt;br /&gt;remote 172.16.2.1&lt;br /&gt;port 1194&lt;br /&gt;proto udp&lt;br /&gt;dev tap&lt;br /&gt;&lt;br /&gt;pull&lt;br /&gt;&lt;br /&gt;resolv-retry infinite&lt;br /&gt;nobind&lt;br /&gt;&lt;br /&gt;cipher BF-CBC&lt;br /&gt;auth SHA1&lt;br /&gt;&lt;br /&gt;ca /etc/openvpn/cacert.crt&lt;br /&gt;cert /etc/openvpn/client.crt&lt;br /&gt;key /etc/openvpn/client.key&lt;br /&gt;&lt;br /&gt;daemon&lt;br /&gt;user nobody&lt;br /&gt;group nogroup&lt;br /&gt;&lt;br /&gt;ping 15&lt;br /&gt;ping-restart 45&lt;br /&gt;resolv-retry 300&lt;br /&gt;ping-timer-rem&lt;br /&gt;persist-tun&lt;br /&gt;persist-key&lt;br /&gt;&lt;br /&gt;log /var/log/openvpn/openvpn.log&lt;br /&gt;verb 3&lt;/pre&gt;&lt;span class="anchor" id="line-487"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-488"&gt;&lt;/span&gt;&lt;p class="line874"&gt;You will need to have a signed client/email certificate from the CAcert website, this is a simple step by step process on the website, once you have one you will need to export it from your brower, and most likely it will be in pkcs12 format so you will need to split this using openssl. &lt;span class="anchor" id="line-489"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-490"&gt;&lt;/span&gt;&lt;/p&gt;&lt;p class="line867"&gt;&lt;span class="anchor" id="line-491"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-492"&gt;&lt;/span&gt;&lt;/p&gt;&lt;pre&gt;openssl pkcs12 -in &lt;file&gt;.p12 -clcert&lt;/file&gt;&lt;/pre&gt;&lt;span class="anchor" id="line-493"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-494"&gt;&lt;/span&gt;&lt;p class="line874"&gt;You'll need to split the output into a .key file and a .crt file, most likely openssl will force you to set a password on your private key you will also need to remove this if you plan to use OpenVPN in any sort of automate manner. You will need to mark the client private key as read/write by root only. &lt;span class="anchor" id="line-495"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-496"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-497"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-498"&gt;&lt;/span&gt;&lt;/p&gt;&lt;pre&gt;openssl rsa -in client.pem -out client.key&lt;br /&gt;chmod 600 client.key&lt;/pre&gt;&lt;span class="anchor" id="line-499"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-500"&gt;&lt;/span&gt;&lt;p class="line874"&gt;To simplify things for myself, when my wireless interface is brought up on my laptop, I also trigger the vpn tunnel as well in /etc/network/interfaces: &lt;span class="anchor" id="line-501"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-502"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-503"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-504"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-505"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-506"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-507"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-508"&gt;&lt;/span&gt;&lt;/p&gt;&lt;pre&gt;auto eth0&lt;br /&gt;iface eth0 inet dhcp&lt;br /&gt;      wireless-mode managed&lt;br /&gt;      wireless-essid My_AP&lt;br /&gt;      post-up openvpn --config /etc/openvpn/openvpn.conf&lt;br /&gt;      pre-down killall -KILL openvpn&lt;/pre&gt;&lt;span class="anchor" id="line-509"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-510"&gt;&lt;/span&gt;&lt;p class="line867"&gt; &lt;/p&gt;&lt;h2 id="Gotchas"&gt;Gotchas&lt;/h2&gt; &lt;span class="anchor" id="line-511"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-512"&gt;&lt;/span&gt;&lt;p class="line867"&gt; &lt;/p&gt;&lt;h3 id="OutofSpace"&gt;Out of Space&lt;/h3&gt; &lt;span class="anchor" id="line-513"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-514"&gt;&lt;/span&gt;&lt;p class="line874"&gt;If you've used your OpenWRT and installed and removed packages or other things I found it doesn't release the space 100% of the time and I was forced to erase the jffs2 partition and reboot the device, upon reboot the squashfs partition will simply rebuild the jffs2 partition and you will be on your way again. &lt;span class="anchor" id="line-515"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-516"&gt;&lt;/span&gt;&lt;/p&gt;&lt;p class="line867"&gt;&lt;img alt="/!\" src="http://wiki.cacert.org/moin/rightsidebar/img/alert.png" title="/!\" width="15" height="15" /&gt; Another big fat warning, this will erase all changes you've made including any packages you've downloaded and installed, I'd suggest you backup anything you want to save !!!BEFORE!!! going any futher. &lt;span class="anchor" id="line-517"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-518"&gt;&lt;/span&gt;&lt;/p&gt;&lt;p class="line874"&gt;To backup the device you could do a dd and dump the entire file system, but this is difficult to extract one or 2 files from, instead I suggest you simple tarball files in any directory you've altered, for me I've only touched files in /etc and of course the nvram memory, so that's all I need to backup, although there is no harm in archiving too much, but it'll be too late once you erase it: &lt;span class="anchor" id="line-519"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-520"&gt;&lt;/span&gt;&lt;/p&gt;&lt;p class="line867"&gt;&lt;span class="anchor" id="line-521"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-522"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-523"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-524"&gt;&lt;/span&gt;&lt;/p&gt;&lt;pre&gt;cd /tmp&lt;br /&gt;nvram show &gt; /tmp/nvram-backup&lt;br /&gt;tar czvf backup.tgz /etc /tmp/nvram-backup&lt;/pre&gt;&lt;span class="anchor" id="line-525"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-526"&gt;&lt;/span&gt;&lt;p class="line874"&gt;You will need to download a copy of the file, the easiest way is via scp from another linux box: &lt;span class="anchor" id="line-527"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-528"&gt;&lt;/span&gt;&lt;/p&gt;&lt;p class="line867"&gt;&lt;span class="anchor" id="line-529"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-530"&gt;&lt;/span&gt;&lt;/p&gt;&lt;pre&gt;scp 172.16.1.1:/tmp/backup.tgz .&lt;/pre&gt;&lt;span class="anchor" id="line-531"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-532"&gt;&lt;/span&gt;&lt;p class="line874"&gt;Once you have that out of the way you are then able to erase your device and start over again: &lt;span class="anchor" id="line-533"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-534"&gt;&lt;/span&gt;&lt;/p&gt;&lt;p class="line867"&gt;&lt;span class="anchor" id="line-535"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-536"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-537"&gt;&lt;/span&gt;&lt;/p&gt;&lt;pre&gt;mtd erase nvram&lt;br /&gt;mtd -r erase mtd4&lt;/pre&gt;&lt;span class="anchor" id="line-538"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-539"&gt;&lt;/span&gt;&lt;p class="line874"&gt;If the device doesn't power cycle itself you will need to do it manually. Within a minute you should be back up and running. &lt;span class="anchor" id="line-540"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-541"&gt;&lt;/span&gt;&lt;/p&gt;&lt;p class="line867"&gt; &lt;/p&gt;&lt;h2 id="Moreinformation"&gt;More information&lt;/h2&gt; &lt;span class="anchor" id="line-542"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-543"&gt;&lt;/span&gt;&lt;p class="line867"&gt; &lt;/p&gt;&lt;h3 id="Notes"&gt;Notes&lt;/h3&gt; &lt;span class="anchor" id="line-544"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-545"&gt;&lt;/span&gt;&lt;p class="line862"&gt;The WRT54G and WRT54GS aren't the only products capable of running the OpenWRT firmware, but they are some of the most widely available, check out the &lt;a class="http" href="http://wiki.openwrt.org/TableOfHardware"&gt;OpenWRT documentation&lt;/a&gt; for a list of compatible routers. &lt;span class="anchor" id="line-546"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-547"&gt;&lt;/span&gt;&lt;/p&gt;&lt;p class="line867"&gt; &lt;/p&gt;&lt;h3 id="Links"&gt;Links&lt;/h3&gt; &lt;span class="anchor" id="line-548"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-549"&gt;&lt;/span&gt;&lt;ul&gt;&lt;li&gt;&lt;p class="line891"&gt;&lt;a class="http" href="http://www.openwrt.org/"&gt;OpenWRT&lt;/a&gt; &lt;span class="anchor" id="line-550"&gt;&lt;/span&gt;&lt;/p&gt;&lt;/li&gt;&lt;li&gt;&lt;p class="line891"&gt;&lt;a class="http" href="http://www.openvpn.org/"&gt;OpenVPN&lt;/a&gt; &lt;span class="anchor" id="line-551"&gt;&lt;/span&gt;&lt;/p&gt;&lt;/li&gt;&lt;li&gt;&lt;p class="line891"&gt;&lt;a href="http://wiki.cacert.org/wiki/openVPN"&gt;Using OpenVPN with CAcert&lt;/a&gt; &lt;span class="anchor" id="line-552"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-553"&gt;&lt;/span&gt;&lt;/p&gt;&lt;/li&gt;&lt;/ul&gt;&lt;p class="line867"&gt; &lt;/p&gt;&lt;h2 id="Simplewebinterface"&gt;Simple web interface&lt;/h2&gt; &lt;span class="anchor" id="line-554"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-555"&gt;&lt;/span&gt;&lt;p class="line867"&gt; &lt;/p&gt;&lt;h3 id="InstallingLighttpdandPHP"&gt;Installing Lighttpd and PHP&lt;/h3&gt; &lt;span class="anchor" id="line-556"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-557"&gt;&lt;/span&gt;&lt;p class="line874"&gt;You will need to edit your /etc/ipkg.conf: &lt;span class="anchor" id="line-558"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-559"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-560"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-561"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-562"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-563"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-564"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-565"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-566"&gt;&lt;/span&gt;&lt;/p&gt;&lt;pre&gt;rm /etc/ipkg.conf&lt;br /&gt;cp /rom/etc/ipkg.conf .&lt;br /&gt;echo "src nico http://openwrt.org/downloads/people/nico/testing/mipsel/packages" &gt;&gt; /etc/ipkg.conf&lt;br /&gt;ipkg update&lt;br /&gt;ipkg install php4-cgi lighttpd lighttpd-mod-cgi&lt;br /&gt;echo -n &gt; /etc/lighttpd.conf&lt;br /&gt;vi /etc/lighttpd.conf&lt;/pre&gt;&lt;span class="anchor" id="line-567"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-568"&gt;&lt;/span&gt;&lt;p class="line874"&gt;Press "i" and paste the following lines: &lt;span class="anchor" id="line-569"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-570"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-571"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-572"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-573"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-574"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-575"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-576"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-577"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-578"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-579"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-580"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-581"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-582"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-583"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-584"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-585"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-586"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-587"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-588"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-589"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-590"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-591"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-592"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-593"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-594"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-595"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-596"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-597"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-598"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-599"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-600"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-601"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-602"&gt;&lt;/span&gt;&lt;/p&gt;&lt;pre&gt;server.modules = (&lt;br /&gt;      "mod_cgi",&lt;br /&gt;)&lt;br /&gt;&lt;br /&gt;server.document-root = "/www/"&lt;br /&gt;server.errorlog = "/var/log/lighttpd/error.log"&lt;br /&gt;index-file.names = ( "index.php" )&lt;br /&gt;&lt;br /&gt;mimetype.assign = (&lt;br /&gt;      ".pdf"   =&gt; "application/pdf",&lt;br /&gt;      ".class" =&gt; "application/octet-stream",&lt;br /&gt;      ".pac"   =&gt; "application/x-ns-proxy-autoconfig",&lt;br /&gt;      ".swf"   =&gt; "application/x-shockwave-flash",&lt;br /&gt;      ".wav"   =&gt; "audio/x-wav",&lt;br /&gt;      ".gif"   =&gt; "image/gif",&lt;br /&gt;      ".jpg"   =&gt; "image/jpeg",&lt;br /&gt;      ".jpeg"  =&gt; "image/jpeg",&lt;br /&gt;      ".png"   =&gt; "image/png",&lt;br /&gt;      ".css"   =&gt; "text/css",&lt;br /&gt;      ".html"  =&gt; "text/html",&lt;br /&gt;      ".htm"   =&gt; "text/html",&lt;br /&gt;      ".js"    =&gt; "text/javascript",&lt;br /&gt;      ".txt"   =&gt; "text/plain",&lt;br /&gt;      ".dtd"   =&gt; "text/xml",&lt;br /&gt;      ".xml"   =&gt; "text/xml"&lt;br /&gt;)&lt;br /&gt;&lt;br /&gt;server.tag = "lighttpd"&lt;br /&gt;static-file.exclude-extensions = ( ".php" )&lt;br /&gt;server.pid-file = "/var/run/lighttpd.pid"&lt;br /&gt;server.dir-listing = "disable"&lt;br /&gt;cgi.assign = ( ".php" =&gt; "/usr/bin/php" )&lt;/pre&gt;&lt;span class="anchor" id="line-603"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-604"&gt;&lt;/span&gt;&lt;p class="line867"&gt; &lt;/p&gt;&lt;h3 id="ExampleWebInterface"&gt;Example Web Interface&lt;/h3&gt; &lt;span class="anchor" id="line-605"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-606"&gt;&lt;/span&gt;&lt;p class="line874"&gt;Do to the size of this file, rather then posting the file to this page, it's available as a download instead. Simply wget it and save it as /www/index.php &lt;span class="anchor" id="line-607"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-608"&gt;&lt;/span&gt;&lt;/p&gt;&lt;p class="line862"&gt;wget &lt;a class="attachment" href="http://wiki.cacert.org/wiki/OpenWRT?action=AttachFile&amp;amp;do=view&amp;amp;target=index.php" title="attachment:index.php"&gt;http://wiki.cacert.org/wiki/OpenWRT?action=AttachFile&amp;amp;do=get&amp;amp;target=index.php&lt;/a&gt; &lt;span class="anchor" id="line-609"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-610"&gt;&lt;/span&gt;&lt;/p&gt;&lt;p class="line874"&gt;Screenshots: &lt;span class="anchor" id="line-611"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-612"&gt;&lt;/span&gt;&lt;/p&gt;&lt;ul&gt;&lt;li&gt;&lt;p class="line891"&gt;&lt;a class="attachment" href="http://wiki.cacert.org/wiki/OpenWRT?action=AttachFile&amp;amp;do=view&amp;amp;target=Screenshot1.png" title="attachment:Screenshot1.png"&gt;Uplink Configuration&lt;/a&gt; &lt;span class="anchor" id="line-613"&gt;&lt;/span&gt;&lt;/p&gt;&lt;/li&gt;&lt;li&gt;&lt;p class="line891"&gt;&lt;a class="attachment" href="http://wiki.cacert.org/wiki/OpenWRT?action=AttachFile&amp;amp;do=view&amp;amp;target=Screenshot2.png" title="attachment:Screenshot2.png"&gt;Wifi Configuration&lt;/a&gt; &lt;span class="anchor" id="line-614"&gt;&lt;/span&gt;&lt;/p&gt;&lt;/li&gt;&lt;li&gt;&lt;p class="line891"&gt;&lt;a class="attachment" href="http://wiki.cacert.org/wiki/OpenWRT?action=AttachFile&amp;amp;do=view&amp;amp;target=Screenshot3.png" title="attachment:Screenshot3.png"&gt;OpenVPN Configuration&lt;/a&gt; &lt;span class="anchor" id="line-615"&gt;&lt;/span&gt;&lt;/p&gt;&lt;/li&gt;&lt;li&gt;&lt;p class="line891"&gt;&lt;a class="attachment" href="http://wiki.cacert.org/wiki/OpenWRT?action=AttachFile&amp;amp;do=view&amp;amp;target=Screenshot4.png" title="attachment:Screenshot4.png"&gt;Syslog Output&lt;/a&gt; &lt;span class="anchor" id="line-616"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-617"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-618"&gt;&lt;/span&gt;&lt;/p&gt;&lt;/li&gt;&lt;/ul&gt;&lt;p class="line867"&gt; &lt;/p&gt;&lt;h3 id="EnablingPPPoE"&gt;Enabling PPPoE&lt;/h3&gt; &lt;span class="anchor" id="line-619"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-620"&gt;&lt;/span&gt;&lt;p class="line874"&gt;You will need to install a couple of packages: &lt;span class="anchor" id="line-621"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-622"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-623"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-624"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-625"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-626"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-627"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-628"&gt;&lt;/span&gt;&lt;/p&gt;&lt;pre&gt;ipkg install kmod-ppp kmod-pppoe ppp ppp-mod-pppoe pppoe-client&lt;br /&gt;echo "slhc&lt;br /&gt;ppp_generic&lt;br /&gt;ppp_async&lt;br /&gt;pppox&lt;br /&gt;pppoe" &gt; /etc/modules.d/30-ppp&lt;/pre&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/4984480909360655633-8188230544039653692?l=worldinthenet.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://worldinthenet.blogspot.com/feeds/8188230544039653692/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://worldinthenet.blogspot.com/2009/07/zz-openwrt-howto.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/4984480909360655633/posts/default/8188230544039653692'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/4984480909360655633/posts/default/8188230544039653692'/><link rel='alternate' type='text/html' href='http://worldinthenet.blogspot.com/2009/07/zz-openwrt-howto.html' title='[zz] OpenWRT Howto'/><author><name>Taojun</name><uri>http://www.blogger.com/profile/12946690813153575136</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-4984480909360655633.post-1643143142885731580</id><published>2009-07-15T17:02:00.000-07:00</published><updated>2009-07-15T17:03:03.067-07:00</updated><title type='text'>[zz] Wireless Home Network</title><content type='html'>&lt;div id="preamble"&gt; &lt;div class="sectionbody"&gt; &lt;div class="paragraph"&gt;&lt;p&gt;This article describes how I set up two wireless routers in my apartment, to provide a PSK2 encrypted wireless connection for all my household equipment.  They are linked together using WDS (also PSK2). For software, I’m using &lt;a href="http://www.openwrt.org/"&gt;OpenWRT&lt;/a&gt;.  For hardware, I’m using two broadcom-based Asus WL-500G Premium boxes.&lt;/p&gt;&lt;/div&gt; &lt;div class="paragraph"&gt;&lt;p&gt;&lt;span class="image"&gt; &lt;img src="http://josefsson.org/openwrt/wlan.png" alt="Wireless Network Illustration" title="Wireless Network Illustration" /&gt; &lt;/span&gt;&lt;/p&gt;&lt;/div&gt; &lt;div class="paragraph"&gt;&lt;p&gt;If you need a 3G connection as well, you may find my &lt;a href="http://josefsson.org/openwrt/dongle.html"&gt;wireless router with 3G USB dongle&lt;/a&gt; or my &lt;a href="http://josefsson.org/openwrt/internet.html"&gt;summer house wireless+3g network&lt;/a&gt; writeup more relevant.&lt;/p&gt;&lt;/div&gt; &lt;div class="paragraph"&gt;&lt;p&gt;If you want to comment on this, please go to the &lt;a href="http://blog.josefsson.org/?p=44"&gt;blog entry&lt;/a&gt;.&lt;/p&gt;&lt;/div&gt; &lt;div class="paragraph"&gt;&lt;p&gt;Created by Simon Josefsson on 2008-05-08, updated for OpenWRT 8.09 on 2009-03-23 and for OpenWRT 8.09.1 on 2009-06-09.&lt;/p&gt;&lt;/div&gt; &lt;/div&gt; &lt;/div&gt; &lt;h2 id="_chosing_openwrt_image"&gt;Chosing OpenWRT Image&lt;/h2&gt; &lt;div class="sectionbody"&gt; &lt;div class="paragraph"&gt;&lt;p&gt;You may build your own OpenWRT image, or you may download one from openwrt.org.&lt;/p&gt;&lt;/div&gt; &lt;div class="paragraph"&gt;&lt;p&gt;For the ASUS WL-500gP device I chose the brcm-2.4 variant of OpenWRT for this device.  The plain brcm variant will work, and uses the newer 2.6 kernel, but wireless will not work.&lt;/p&gt;&lt;/div&gt; &lt;/div&gt; &lt;h2 id="_downloading_image"&gt;Downloading Image&lt;/h2&gt; &lt;div class="sectionbody"&gt; &lt;div class="paragraph"&gt;&lt;p&gt;To avoid building the image yourself, you may download it from openwrt.org.&lt;/p&gt;&lt;/div&gt; &lt;div class="listingblock"&gt; &lt;div class="content"&gt; &lt;pre&gt;&lt;tt&gt;$ wget --quiet http://downloads.openwrt.org/kamikaze/8.09.1/brcm-2.4/openwrt-brcm-2.4-squashfs.trx&lt;br /&gt;$ md5sum openwrt-brcm-2.4-squashfs.trx&lt;br /&gt;6ccb44d015a8477e2eb0fa81b9b83f1a  openwrt-brcm-2.4-squashfs.trx&lt;/tt&gt;&lt;/pre&gt; &lt;/div&gt;&lt;/div&gt; &lt;/div&gt; &lt;h2 id="_building_openwrt"&gt;Building OpenWRT&lt;/h2&gt; &lt;div class="sectionbody"&gt; &lt;div class="paragraph"&gt;&lt;p&gt;You may skip this section if you do not want to build your own image.&lt;/p&gt;&lt;/div&gt; &lt;div class="paragraph"&gt;&lt;p&gt;Building OpenWRT is quite easy these days.  I’m using Debian x86 lenny, and you will need to install gcc and other development tools. Here are the commands I used:&lt;/p&gt;&lt;/div&gt; &lt;div class="listingblock"&gt; &lt;div class="content"&gt; &lt;pre&gt;&lt;tt&gt;svn co https://svn.openwrt.org/openwrt/trunk/&lt;br /&gt;mv trunk openwrt&lt;br /&gt;cd openwrt&lt;br /&gt;make menuconfig&lt;br /&gt;#  toggle 'select all packages by default'&lt;br /&gt;#  quit and save config&lt;br /&gt;make&lt;/tt&gt;&lt;/pre&gt; &lt;/div&gt;&lt;/div&gt; &lt;div class="paragraph"&gt;&lt;p&gt;That’s it!  The complete build takes up about 2GB on my machine, and it will take quite some time to build (up to several hours).&lt;/p&gt;&lt;/div&gt; &lt;div class="paragraph"&gt;&lt;p&gt;The output files will be stored into the bin/ directory.&lt;/p&gt;&lt;/div&gt; &lt;/div&gt; &lt;h2 id="_installing_openwrt"&gt;Installing OpenWRT&lt;/h2&gt; &lt;div class="sectionbody"&gt; &lt;div class="paragraph"&gt;&lt;p&gt;There are generic &lt;a href="http://oldwiki.openwrt.org/OpenWrtDocs%282f%29Installation.html"&gt;Installation instructions&lt;/a&gt; on the the &lt;a href="http://oldwiki.openwrt.org/"&gt;OpenWRT Wiki&lt;/a&gt;.&lt;/p&gt;&lt;/div&gt; &lt;div class="paragraph"&gt;&lt;p&gt;You’ll have to use a ethernet cable at this point.  Connect it to LAN1-LAN4, not WAN.  Configure your local machine on the 192.168.1.x network, for example as 192.168.1.42.  The router will use 192.168.1.1.&lt;/p&gt;&lt;/div&gt; &lt;div class="paragraph"&gt;&lt;p&gt;On many routers, including the &lt;a href="http://oldwiki.openwrt.org/OpenWrtDocs%282f%29Hardware%282f%29Asus%282f%29WL500GP.html?highlight=%28OpenWrtDocs/Hardware%29"&gt;Asus WL-500g Premium&lt;/a&gt; that I use, you flash an image by disconnecting power, press and hold down the reset button, and connect the power again.  Wait a few seconds and the PWR led will start to blink. Release the reset button.  The device will now have a tftp server running on 192.168.1.1.&lt;/p&gt;&lt;/div&gt; &lt;div class="listingblock"&gt; &lt;div class="content"&gt; &lt;pre&gt;&lt;tt&gt;$ tftp 192.168.1.1&lt;br /&gt;tftp&gt; trace&lt;br /&gt;Packet tracing on.&lt;br /&gt;tftp&gt; binary&lt;br /&gt;tftp&gt; put openwrt-brcm-2.4-squashfs.trx&lt;br /&gt;...&lt;/tt&gt;&lt;/pre&gt; &lt;/div&gt;&lt;/div&gt; &lt;div class="paragraph"&gt;&lt;p&gt;Wait a minute and restart the box by disconnecting and reconnecting power.  Some documentations claim that the device should restart by itself but I have never seen this happen.&lt;/p&gt;&lt;/div&gt; &lt;/div&gt; &lt;h2 id="_configuring_openwrt"&gt;Configuring OpenWRT&lt;/h2&gt; &lt;div class="sectionbody"&gt; &lt;div class="paragraph"&gt;&lt;p&gt;When the router has restarted, it will have a telnet server running listening on 192.168.1.1.&lt;/p&gt;&lt;/div&gt; &lt;div class="listingblock"&gt; &lt;div class="content"&gt; &lt;pre&gt;&lt;tt&gt;$ telnet 192.168.1.1&lt;br /&gt;Trying 192.168.1.1...&lt;br /&gt;Connected to 192.168.1.1.&lt;br /&gt;Escape character is '^]'.&lt;br /&gt;=== IMPORTANT ============================&lt;br /&gt; Use 'passwd' to set your login password&lt;br /&gt; this will disable telnet and enable SSH&lt;br /&gt;------------------------------------------&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;BusyBox v1.11.2 (2009-05-28 19:38:17 UTC) built-in shell (ash)&lt;br /&gt;Enter 'help' for a list of built-in commands.&lt;br /&gt;&lt;br /&gt; _______                     ________        __&lt;br /&gt;|       |.-----.-----.-----.|  |  |  |.----.|  |_&lt;br /&gt;|   -   ||  _  |  -__|     ||  |  |  ||   _||   _|&lt;br /&gt;|_______||   __|_____|__|__||________||__|  |____|&lt;br /&gt;         |__| W I R E L E S S   F R E E D O M&lt;br /&gt;KAMIKAZE (8.09.1, r16278) ----------------------------&lt;br /&gt; * 10 oz Vodka       Shake well with ice and strain&lt;br /&gt; * 10 oz Triple sec  mixture into 10 shot glasses.&lt;br /&gt; * 10 oz lime juice  Salute!&lt;br /&gt;---------------------------------------------------&lt;br /&gt;root@OpenWrt:/#&lt;/tt&gt;&lt;/pre&gt; &lt;/div&gt;&lt;/div&gt; &lt;div class="paragraph"&gt;&lt;p&gt;Now you can configure OpenWRT.  I’ll go through each step I made, but obviously you may deviate from this description.&lt;/p&gt;&lt;/div&gt; &lt;h3 id="_set_hostname"&gt;Set hostname&lt;/h3&gt; &lt;div class="paragraph"&gt;&lt;p&gt;My first step was to set a hostname on the machine, use vi to edit &lt;em&gt;/etc/config/system&lt;/em&gt; to make it read:&lt;/p&gt;&lt;/div&gt; &lt;div class="listingblock"&gt; &lt;div class="content"&gt; &lt;pre&gt;&lt;tt&gt;config system&lt;br /&gt;       option hostname caramel&lt;/tt&gt;&lt;/pre&gt; &lt;/div&gt;&lt;/div&gt; &lt;div class="paragraph"&gt;&lt;p&gt;If you prefer to cut’n'paste a command line invocation to do this, try:&lt;/p&gt;&lt;/div&gt; &lt;div class="listingblock"&gt; &lt;div class="content"&gt; &lt;pre&gt;&lt;tt&gt;root@OpenWrt:~# cat /etc/config/system | sed -e 's/OpenWrt/caramel/' &gt; /etc/config/system&lt;/tt&gt;&lt;/pre&gt; &lt;/div&gt;&lt;/div&gt; &lt;div class="paragraph"&gt;&lt;p&gt;Setting a hostname will help when you have multiple OpenWRT boxes running, as the command prompt will show your hostname instead of &lt;em&gt;OpenWRT&lt;/em&gt; (after you have restarted the router).&lt;/p&gt;&lt;/div&gt; &lt;h3 id="_set_ip_address"&gt;Set IP address&lt;/h3&gt; &lt;div class="paragraph"&gt;&lt;p&gt;If you want the device to use another IP address than 192.168.1.1 you can modify /etc/config/network, in the LAN configuration section.  A quick command to do this:&lt;/p&gt;&lt;/div&gt; &lt;div class="listingblock"&gt; &lt;div class="content"&gt; &lt;pre&gt;&lt;tt&gt;root@OpenWrt:~# cat /etc/config/network | sed -e 's/192.168.1.1/192.168.1.15/' &gt; /etc/config/network&lt;/tt&gt;&lt;/pre&gt; &lt;/div&gt;&lt;/div&gt; &lt;h3 id="_replace_telnet_with_ssh"&gt;Replace telnet with SSH&lt;/h3&gt; &lt;div class="paragraph"&gt;&lt;p&gt;As you do not want to use insecure telnet, you will need to set up ssh.  You can type &lt;em&gt;passwd&lt;/em&gt; to set a root password, and this will disable telnet.  I dislike passwords, even if used over ssh, so I always set up public-key authentication instead.  For reference, there is a &lt;a href="http://wiki.openwrt.org/DropbearPublicKeyAuthenticationHowto"&gt;dropbear public key authentication howto for OpenWRT wiki page&lt;/a&gt;.&lt;/p&gt;&lt;/div&gt; &lt;div class="paragraph"&gt;&lt;p&gt;The command to make your ssh key authorized to login as root on the router is:&lt;/p&gt;&lt;/div&gt; &lt;div class="listingblock"&gt; &lt;div class="content"&gt; &lt;pre&gt;&lt;tt&gt;root@OpenWrt:/# echo 'PUBLICKEY'  &gt; /etc/dropbear/authorized_keys&lt;/tt&gt;&lt;/pre&gt; &lt;/div&gt;&lt;/div&gt; &lt;div class="paragraph"&gt;&lt;p&gt;Replace PUBLICKEY with the content of the ~/.ssh/id*.pub file on your own machine.&lt;/p&gt;&lt;/div&gt; &lt;div class="paragraph"&gt;&lt;p&gt;Disable password based login using:&lt;/p&gt;&lt;/div&gt; &lt;div class="listingblock"&gt; &lt;div class="content"&gt; &lt;pre&gt;&lt;tt&gt;root@OpenWrt:/# cat /etc/config/dropbear | sed -e "s/'on'/'off'/"  &gt; /etc/config/dropbear&lt;/tt&gt;&lt;/pre&gt; &lt;/div&gt;&lt;/div&gt; &lt;div class="paragraph"&gt;&lt;p&gt;Alternatively, edit /etc/config/dropbear to look like:&lt;/p&gt;&lt;/div&gt; &lt;div class="listingblock"&gt; &lt;div class="content"&gt; &lt;pre&gt;&lt;tt&gt;config dropbear&lt;br /&gt;       option PasswordAuth 'off'&lt;br /&gt;       option Port         '22'&lt;/tt&gt;&lt;/pre&gt; &lt;/div&gt;&lt;/div&gt; &lt;div class="paragraph"&gt;&lt;p&gt;At this point, you can print the ssh host key fingerprint using:&lt;/p&gt;&lt;/div&gt; &lt;div class="listingblock"&gt; &lt;div class="content"&gt; &lt;pre&gt;&lt;tt&gt;root@OpenWrt:~# dropbearkey -y -f /etc/dropbear/dropbear_rsa_host_key&lt;br /&gt;Public key portion is:&lt;br /&gt;ssh-rsa AAAA... root@OpenWrt&lt;br /&gt;Fingerprint: md5 b4:...&lt;/tt&gt;&lt;/pre&gt; &lt;/div&gt;&lt;/div&gt; &lt;div class="paragraph"&gt;&lt;p&gt;To use the web interface, you may want to set a root password.&lt;/p&gt;&lt;/div&gt; &lt;div class="listingblock"&gt; &lt;div class="content"&gt; &lt;pre&gt;&lt;tt&gt;root@OpenWrt:/# passwd&lt;br /&gt;Changing password for root&lt;br /&gt;New password:&lt;br /&gt;Retype password:&lt;br /&gt;Password for root changed by root&lt;br /&gt;root@OpenWrt:/#&lt;/tt&gt;&lt;/pre&gt; &lt;/div&gt;&lt;/div&gt; &lt;div class="paragraph"&gt;&lt;p&gt;If you do not set a root password, you will need to manually disable the telnet server as follows.&lt;/p&gt;&lt;/div&gt; &lt;div class="listingblock"&gt; &lt;div class="content"&gt; &lt;pre&gt;&lt;tt&gt;root@OpenWrt:~# rm /etc/rc.d/S50telnet&lt;/tt&gt;&lt;/pre&gt; &lt;/div&gt;&lt;/div&gt; &lt;div class="paragraph"&gt;&lt;p&gt;After you have made your changes, try the new configuration by rebooting both devices.&lt;/p&gt;&lt;/div&gt; &lt;div class="listingblock"&gt; &lt;div class="content"&gt; &lt;pre&gt;&lt;tt&gt;root@OpenWrt:/etc/config# reboot&lt;/tt&gt;&lt;/pre&gt; &lt;/div&gt;&lt;/div&gt; &lt;div class="paragraph"&gt;&lt;p&gt;You should now be able to login as root using SSH.  Try it from your machine.  The SSH fingerprint should match what was printed by &lt;em&gt;dropbearkey&lt;/em&gt; earlier.&lt;/p&gt;&lt;/div&gt; &lt;div class="listingblock"&gt; &lt;div class="content"&gt; &lt;pre&gt;&lt;tt&gt;jas@mocca:~$ ssh -l root 192.168.1.15&lt;br /&gt;The authenticity of host '192.168.1.15 (192.168.1.15)' can't be established.&lt;br /&gt;RSA key fingerprint is b4:...&lt;br /&gt;Are you sure you want to continue connecting (yes/no)? yes&lt;br /&gt;Warning: Permanently added '192.168.1.15' (RSA) to the list of known hosts.&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;BusyBox v1.11.2 (2009-05-28 19:38:17 UTC) built-in shell (ash)&lt;br /&gt;Enter 'help' for a list of built-in commands.&lt;br /&gt;&lt;br /&gt; _______                     ________        __&lt;br /&gt;|       |.-----.-----.-----.|  |  |  |.----.|  |_&lt;br /&gt;|   -   ||  _  |  -__|     ||  |  |  ||   _||   _|&lt;br /&gt;|_______||   __|_____|__|__||________||__|  |____|&lt;br /&gt;         |__| W I R E L E S S   F R E E D O M&lt;br /&gt;KAMIKAZE (8.09.1, r16278) ----------------------------&lt;br /&gt; * 10 oz Vodka       Shake well with ice and strain&lt;br /&gt; * 10 oz Triple sec  mixture into 10 shot glasses.&lt;br /&gt; * 10 oz lime juice  Salute!&lt;br /&gt;---------------------------------------------------&lt;br /&gt;root@caramel:~#&lt;/tt&gt;&lt;/pre&gt; &lt;/div&gt;&lt;/div&gt; &lt;h3 id="_setup_wireless"&gt;Setup wireless&lt;/h3&gt; &lt;div class="paragraph"&gt;&lt;p&gt;Wireless is disabled by default, and you will have to modify “/etc/config/wireless” to configure it.&lt;/p&gt;&lt;/div&gt; &lt;div class="paragraph"&gt;&lt;p&gt;A simple setup that use (insecure) WEP would be:&lt;/p&gt;&lt;/div&gt; &lt;div class="listingblock"&gt; &lt;div class="content"&gt; &lt;pre&gt;&lt;tt&gt;config wifi-device  wl0&lt;br /&gt;       option type     broadcom&lt;br /&gt;       option channel  5&lt;br /&gt;&lt;br /&gt;config wifi-iface&lt;br /&gt;       option device   wl0&lt;br /&gt;       option network  lan&lt;br /&gt;       option mode     ap&lt;br /&gt;       option ssid     YourNetworkName&lt;br /&gt;       option encryption wep&lt;br /&gt;       option key      DEADBEEF&lt;/tt&gt;&lt;/pre&gt; &lt;/div&gt;&lt;/div&gt; &lt;div class="paragraph"&gt;&lt;p&gt;A better setup that use shared secrets but the more secure PSK2 would be:&lt;/p&gt;&lt;/div&gt; &lt;div class="listingblock"&gt; &lt;div class="content"&gt; &lt;pre&gt;&lt;tt&gt;config wifi-device  wl0&lt;br /&gt;       option type     broadcom&lt;br /&gt;       option channel  5&lt;br /&gt;&lt;br /&gt;config wifi-iface&lt;br /&gt;       option device   wl0&lt;br /&gt;       option network  lan&lt;br /&gt;       option mode     ap&lt;br /&gt;       option ssid     YourNetworkName&lt;br /&gt;       option encryption psk2&lt;br /&gt;       option key      DEADBEEFDEADBEEFDEADBEEFDEADBEEF&lt;/tt&gt;&lt;/pre&gt; &lt;/div&gt;&lt;/div&gt; &lt;div class="paragraph"&gt;&lt;p&gt;Remember, your security is never better than your password.&lt;/p&gt;&lt;/div&gt; &lt;div class="paragraph"&gt;&lt;p&gt;As you may recall, the point of my exercise was to set up two routers with WDS and PSK2.  For discussion, let’s say the MAC address of box 1 is 12:34:56:78:89:ab and the MAC address of box 2 is cd:ef:01:23:45:67.  You can use &lt;em&gt;ifconfig&lt;/em&gt; on each of the routers to find out the MAC address.&lt;/p&gt;&lt;/div&gt; &lt;div class="paragraph"&gt;&lt;p&gt;On the first box, my /etc/config/wireless file looks like:&lt;/p&gt;&lt;/div&gt; &lt;div class="listingblock"&gt; &lt;div class="content"&gt; &lt;pre&gt;&lt;tt&gt;# /etc/config/wireless configuration for device 12:34:56:78:89:ab&lt;br /&gt;config wifi-device  wl0&lt;br /&gt;       option type     broadcom&lt;br /&gt;       option channel  5&lt;br /&gt;&lt;br /&gt;config wifi-iface&lt;br /&gt;       option device   wl0&lt;br /&gt;       option network  lan&lt;br /&gt;       option mode     ap&lt;br /&gt;       option ssid     YourNetworkName&lt;br /&gt;       option encryption psk2&lt;br /&gt;       option key      UserNetworkPassword&lt;br /&gt;&lt;br /&gt;config wifi-iface&lt;br /&gt;       option device   wl0&lt;br /&gt;       option network  lan&lt;br /&gt;       option mode     wds&lt;br /&gt;       option bssid    cd:ef:01:23:45:67&lt;br /&gt;       option encryption psk2&lt;br /&gt;       option ssid     WDSNetworkName&lt;br /&gt;       option key      InternalWDSPassword&lt;/tt&gt;&lt;/pre&gt; &lt;/div&gt;&lt;/div&gt; &lt;div class="paragraph"&gt;&lt;p&gt;Replace YourNetworkName and WDSNetworkName with something more appropriate.  You want to use a different SSID for the WDS than for the normal network.&lt;/p&gt;&lt;/div&gt; &lt;div class="paragraph"&gt;&lt;p&gt;On the second box, the /etc/config/wireless will look the same except that the BSSID will contain the MAC address of the first box.  Here is the file:&lt;/p&gt;&lt;/div&gt; &lt;div class="listingblock"&gt; &lt;div class="content"&gt; &lt;pre&gt;&lt;tt&gt;# /etc/config/wireless configuration for device cd:ef:01:23:45:67&lt;br /&gt;config wifi-device  wl0&lt;br /&gt;       option type     broadcom&lt;br /&gt;       option channel  5&lt;br /&gt;&lt;br /&gt;config wifi-iface&lt;br /&gt;       option device   wl0&lt;br /&gt;       option network  lan&lt;br /&gt;       option mode     ap&lt;br /&gt;       option ssid     YourNetworkName&lt;br /&gt;       option encryption psk2&lt;br /&gt;       option key      UserNetworkPassword&lt;br /&gt;&lt;br /&gt;config wifi-iface&lt;br /&gt;       option device   wl0&lt;br /&gt;       option network  lan&lt;br /&gt;       option mode     wds&lt;br /&gt;       option bssid    12:34:56:78:89:ab&lt;br /&gt;       option encryption psk2&lt;br /&gt;       option ssid     WDSNetworkName&lt;br /&gt;       option key      InternalWDSPassword&lt;/tt&gt;&lt;/pre&gt; &lt;/div&gt;&lt;/div&gt; &lt;h3 id="_disable_dhcp_on_one_router"&gt;Disable DHCP on one router&lt;/h3&gt; &lt;div class="paragraph"&gt;&lt;p&gt;Both routers will by default run a DHCP server.  You probably want to disable it on one of the boxes.&lt;/p&gt;&lt;/div&gt; &lt;div class="listingblock"&gt; &lt;div class="content"&gt; &lt;pre&gt;&lt;tt&gt;root@kladdkaka:~# /etc/init.d/dnsmasq disable&lt;br /&gt;root@kladdkaka:~#&lt;/tt&gt;&lt;/pre&gt; &lt;/div&gt;&lt;/div&gt; &lt;h3 id="_restart_router"&gt;Restart router&lt;/h3&gt; &lt;div class="paragraph"&gt;&lt;p&gt;After you have made your changes, try the new configuration by rebooting both devices.&lt;/p&gt;&lt;/div&gt; &lt;div class="listingblock"&gt; &lt;div class="content"&gt; &lt;pre&gt;&lt;tt&gt;root@kladdkaka:/etc/config# reboot&lt;/tt&gt;&lt;/pre&gt; &lt;/div&gt;&lt;/div&gt; &lt;div class="paragraph"&gt;&lt;p&gt;After 30 seconds or so, the devices should have connected via WDS and you should be able to ping the IP addresses of router A from router B and vice verse.&lt;/p&gt;&lt;/div&gt; &lt;div class="paragraph"&gt;&lt;p&gt;The default configuration is to bridge the wireless networks with the LAN ethernet sockets, so you can connect desktop machines etc and they should be able to reach all devices connected to the wireless network or the ethernet sockets on any of the two WDS connected routers.&lt;/p&gt;&lt;/div&gt; &lt;/div&gt; &lt;h2 id="_additional_software"&gt;Additional software&lt;/h2&gt; &lt;div class="sectionbody"&gt; &lt;div class="paragraph"&gt;&lt;p&gt;You can use &lt;em&gt;opkg&lt;/em&gt; to install additional tools easily.  First run &lt;em&gt;opkg update&lt;/em&gt; to update the package list:&lt;/p&gt;&lt;/div&gt; &lt;div class="listingblock"&gt; &lt;div class="content"&gt; &lt;pre&gt;&lt;tt&gt;root@caramel:~# opkg update&lt;br /&gt;Downloading http://downloads.openwrt.org/kamikaze/8.09.1/brcm-2.4/packages/Packages.gz&lt;br /&gt;Connecting to downloads.openwrt.org (195.56.146.238:80)&lt;br /&gt;Packages.gz          100% |*******************************|   130k 00:00:00 ETA&lt;br /&gt;Inflating http://downloads.openwrt.org/kamikaze/8.09.1/brcm-2.4/packages/Packages.gz&lt;br /&gt;Updated list of available packages in /var/opkg-lists/snapshots&lt;br /&gt;root@caramel:~#&lt;/tt&gt;&lt;/pre&gt; &lt;/div&gt;&lt;/div&gt; &lt;div class="paragraph"&gt;&lt;p&gt;Use &lt;em&gt;opkg list&lt;/em&gt; to list all available packages.&lt;/p&gt;&lt;/div&gt; &lt;div class="paragraph"&gt;&lt;p&gt;Useful tools to install on a typical router includes avahi-daemon, miniupnpd, and openntpd.&lt;/p&gt;&lt;/div&gt; &lt;div class="paragraph"&gt;&lt;p&gt;Avahi allows DNS based service discovery.  Install and enable as follows:&lt;/p&gt;&lt;/div&gt; &lt;div class="listingblock"&gt; &lt;div class="content"&gt; &lt;pre&gt;&lt;tt&gt;root@caramel:~# opkg install avahi-daemon&lt;br /&gt;Installing avahi-daemon (0.6.23-2) to root...&lt;br /&gt;Downloading http://downloads.openwrt.org/kamikaze/8.09.1/brcm-2.4/packages/avahi-daemon_0.6.23-2_mipsel.ipk&lt;br /&gt;Connecting to downloads.openwrt.org (195.56.146.238:80)&lt;br /&gt;avahi-daemon_0.6.23- 100% |*******************************| 19698  00:00:00 ETA&lt;br /&gt;Installing libavahi (0.6.23-2) to root...&lt;br /&gt;Downloading http://downloads.openwrt.org/kamikaze/8.09.1/brcm-2.4/packages/libavahi_0.6.23-2_mipsel.ipk&lt;br /&gt;Connecting to downloads.openwrt.org (195.56.146.238:80)&lt;br /&gt;libavahi_0.6.23-2_mi 100% |*******************************| 69773  00:00:00 ETA&lt;br /&gt;Installing libdaemon (0.12-1) to root...&lt;br /&gt;Downloading http://downloads.openwrt.org/kamikaze/8.09.1/brcm-2.4/packages/libdaemon_0.12-1_mipsel.ipk&lt;br /&gt;Connecting to downloads.openwrt.org (195.56.146.238:80)&lt;br /&gt;libdaemon_0.12-1_mip 100% |*******************************|  8352  --:--:-- ETA&lt;br /&gt;Installing libpthread (0.9.29-14.1) to root...&lt;br /&gt;Downloading http://downloads.openwrt.org/kamikaze/8.09.1/brcm-2.4/packages/libpthread_0.9.29-14.1_mipsel.ipk&lt;br /&gt;Connecting to downloads.openwrt.org (195.56.146.238:80)&lt;br /&gt;libpthread_0.9.29-14 100% |*******************************| 19278  00:00:00 ETA&lt;br /&gt;Installing libexpat (1.95.8-1) to root...&lt;br /&gt;Downloading http://downloads.openwrt.org/kamikaze/8.09.1/brcm-2.4/packages/libexpat_1.95.8-1_mipsel.ipk&lt;br /&gt;Connecting to downloads.openwrt.org (195.56.146.238:80)&lt;br /&gt;libexpat_1.95.8-1_mi 100% |*******************************| 47267  00:00:00 ETA&lt;br /&gt;Configuring avahi-daemon&lt;br /&gt;Configuring libavahi&lt;br /&gt;Configuring libdaemon&lt;br /&gt;Configuring libexpat&lt;br /&gt;Configuring libpthread&lt;br /&gt;root@caramel:~# /etc/init.d/avahi-daemon enable&lt;br /&gt;root@caramel:~#&lt;/tt&gt;&lt;/pre&gt; &lt;/div&gt;&lt;/div&gt; &lt;div class="paragraph"&gt;&lt;p&gt;Bittorrent clients, for example, can use UPnP to open up ports in the firewall.  For this to work, you need a UPnP server on your router:&lt;/p&gt;&lt;/div&gt; &lt;div class="listingblock"&gt; &lt;div class="content"&gt; &lt;pre&gt;&lt;tt&gt;root@caramel:~# opkg install miniupnpd luci-app-upnp&lt;br /&gt;Installing miniupnpd (1.1-5) to root...&lt;br /&gt;Downloading http://downloads.openwrt.org/kamikaze/8.09.1/brcm-2.4/packages/miniupnpd_1.1-5_mipsel.ipk&lt;br /&gt;Connecting to downloads.openwrt.org (195.56.146.238:80)&lt;br /&gt;miniupnpd_1.1-5_mips 100% |*******************************| 36923  00:00:00 ETA&lt;br /&gt;Installing luci-app-upnp (0.8.7-1) to root...&lt;br /&gt;Downloading http://downloads.openwrt.org/kamikaze/8.09.1/brcm-2.4/packages/luci-app-upnp_0.8.7-1_mipsel.ipk&lt;br /&gt;Connecting to downloads.openwrt.org (195.56.146.238:80)&lt;br /&gt;luci-app-upnp_0.8.7- 100% |*******************************|  2748  00:00:00 ETA&lt;br /&gt;Configuring luci-app-upnp&lt;br /&gt;Configuring miniupnpd&lt;br /&gt;root@caramel:~# /etc/init.d/miniupnpd enable&lt;br /&gt;root@caramel:~#&lt;/tt&gt;&lt;/pre&gt; &lt;/div&gt;&lt;/div&gt; &lt;div class="paragraph"&gt;&lt;p&gt;The clock will typically be way off unless you set it.  Install a NTP client to automate this.  (The package &lt;em&gt;openntpd&lt;/em&gt; also works but takes more space.)&lt;/p&gt;&lt;/div&gt; &lt;div class="listingblock"&gt; &lt;div class="content"&gt; &lt;pre&gt;&lt;tt&gt;root@caramel:~# opkg install luci-app-ntpc&lt;br /&gt;Installing luci-app-ntpc (0.8.7-1) to root...&lt;br /&gt;Downloading http://downloads.openwrt.org/kamikaze/8.09.1/brcm-2.4/packages/luci-app-ntpc_0.8.7-1_mipsel.ipk&lt;br /&gt;Connecting to downloads.openwrt.org (195.56.146.238:80)&lt;br /&gt;luci-app-ntpc_0.8.7- 100% |*******************************|  2894  00:00:00 ETA&lt;br /&gt;Installing ntpclient (2007_365-1) to root...&lt;br /&gt;Downloading http://downloads.openwrt.org/kamikaze/8.09.1/brcm-2.4/packages/ntpclient_2007_365-1_mipsel.ipk&lt;br /&gt;Connecting to downloads.openwrt.org (195.56.146.238:80)&lt;br /&gt;ntpclient_2007_365-1 100% |*******************************| 12512  00:00:00 ETA&lt;br /&gt;Configuring luci-app-ntpc&lt;br /&gt;Configuring ntpclient&lt;br /&gt;root@caramel:~#&lt;/tt&gt;&lt;/pre&gt;&lt;/div&gt;&lt;/div&gt;&lt;/div&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/4984480909360655633-1643143142885731580?l=worldinthenet.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://worldinthenet.blogspot.com/feeds/1643143142885731580/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://worldinthenet.blogspot.com/2009/07/zz-wireless-home-network.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/4984480909360655633/posts/default/1643143142885731580'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/4984480909360655633/posts/default/1643143142885731580'/><link rel='alternate' type='text/html' href='http://worldinthenet.blogspot.com/2009/07/zz-wireless-home-network.html' title='[zz] Wireless Home Network'/><author><name>Taojun</name><uri>http://www.blogger.com/profile/12946690813153575136</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-4984480909360655633.post-5690870061262256030</id><published>2009-07-15T15:38:00.000-07:00</published><updated>2009-07-15T15:39:51.871-07:00</updated><title type='text'>[zz] Running Debian on ASUS WL-500W</title><content type='html'>http://wpkg.org/Running_Debian_on_ASUS_WL-500W&lt;br /&gt;      &lt;h3 id="siteSub"&gt;From WPKG | Open Source Software Deployment and Distribution&lt;/h3&gt;&lt;p&gt;This initial page is based on &lt;a href="http://wpkg.org/Running_Debian_on_ASUS_WL-500G_deluxe" title="Running Debian on ASUS WL-500G deluxe"&gt;Running_Debian_on_ASUS_WL-500G_deluxe&lt;/a&gt;.&lt;br /&gt;Please bear in mind this page is under construction and depends also on other enthousiasts who contribute to make this page in final stage&lt;br /&gt;It would be nice to see detailed instructions to get the wireless to work properly and to include a good web frontend&lt;br /&gt;&lt;/p&gt;&lt;p&gt; &lt;/p&gt; &lt;table id="toc" class="toc" summary="Contents"&gt;&lt;tbody&gt;&lt;tr&gt;&lt;td&gt;&lt;div id="toctitle"&gt;&lt;h2&gt;Contents&lt;/h2&gt; &lt;span class="toctoggle"&gt;[&lt;a href="javascript:toggleToc()" class="internal" id="togglelink"&gt;hide&lt;/a&gt;]&lt;/span&gt;&lt;/div&gt; &lt;ul&gt;&lt;li class="toclevel-1"&gt;&lt;a href="http://wpkg.org/Running_Debian_on_ASUS_WL-500W#Installing_Ubuntu_linux"&gt;&lt;span class="tocnumber"&gt;1&lt;/span&gt; &lt;span class="toctext"&gt;Installing Ubuntu linux&lt;/span&gt;&lt;/a&gt;&lt;/li&gt;&lt;li class="toclevel-1"&gt;&lt;a href="http://wpkg.org/Running_Debian_on_ASUS_WL-500W#Flashing_the_kernel"&gt;&lt;span class="tocnumber"&gt;2&lt;/span&gt; &lt;span class="toctext"&gt;Flashing the kernel&lt;/span&gt;&lt;/a&gt;&lt;/li&gt;&lt;li class="toclevel-1"&gt;&lt;a href="http://wpkg.org/Running_Debian_on_ASUS_WL-500W#Writing_Debian_on_your_USB_device"&gt;&lt;span class="tocnumber"&gt;3&lt;/span&gt; &lt;span class="toctext"&gt;Writing Debian on your USB device&lt;/span&gt;&lt;/a&gt;&lt;/li&gt;&lt;li class="toclevel-1"&gt;&lt;a href="http://wpkg.org/Running_Debian_on_ASUS_WL-500W#Configuring_network"&gt;&lt;span class="tocnumber"&gt;4&lt;/span&gt; &lt;span class="toctext"&gt;Configuring network&lt;/span&gt;&lt;/a&gt;&lt;/li&gt;&lt;li class="toclevel-1"&gt;&lt;a href="http://wpkg.org/Running_Debian_on_ASUS_WL-500W#Booting"&gt;&lt;span class="tocnumber"&gt;5&lt;/span&gt; &lt;span class="toctext"&gt;Booting&lt;/span&gt;&lt;/a&gt;&lt;/li&gt;&lt;li class="toclevel-1"&gt;&lt;a href="http://wpkg.org/Running_Debian_on_ASUS_WL-500W#Building_your_own_kernel"&gt;&lt;span class="tocnumber"&gt;6&lt;/span&gt; &lt;span class="toctext"&gt;Building your own kernel&lt;/span&gt;&lt;/a&gt;&lt;/li&gt;&lt;/ul&gt; &lt;/td&gt;&lt;/tr&gt;&lt;/tbody&gt;&lt;/table&gt;&lt;script type="text/javascript"&gt; if (window.showTocToggle) { var tocShowText = "show"; var tocHideText = "hide"; showTocToggle(); } &lt;/script&gt; &lt;a name="Installing_Ubuntu_linux"&gt;&lt;/a&gt;&lt;h2&gt;&lt;span class="editsection"&gt;[&lt;a href="http://wpkg.org/index.php?title=Running_Debian_on_ASUS_WL-500W&amp;amp;action=edit&amp;amp;section=1" title="Edit section: Installing Ubuntu linux"&gt;edit&lt;/a&gt;]&lt;/span&gt; &lt;span class="mw-headline"&gt; Installing Ubuntu linux &lt;/span&gt;&lt;/h2&gt; &lt;p&gt;Install your favourite linux distro, but make sure you can compile and also Internet should be available; Below are instructions for ubuntu8.04 server &lt;/p&gt;&lt;p&gt;&lt;br /&gt;&lt;/p&gt; &lt;pre&gt;login with your username&lt;br /&gt;sudo su&lt;br /&gt;vi /etc/apt/sources.list and comment # all deb cdrom: entries and uncomment all deb http: ones&lt;br /&gt;:wq! to save file en exit&lt;br /&gt;&lt;/pre&gt; &lt;p&gt;run update/upgrade: &lt;/p&gt; &lt;pre&gt;apt-get update&lt;br /&gt;apt-get upgrade&lt;br /&gt;apt-get install tftp subversion make unzip flex patch autoconf bison zlib1g-dev libncurses5-dev gawk g++&lt;br /&gt;exit (to return from super user to user)&lt;br /&gt;&lt;/pre&gt; &lt;p&gt;&lt;br /&gt;&lt;/p&gt; &lt;a name="Flashing_the_kernel"&gt;&lt;/a&gt;&lt;h2&gt;&lt;span class="editsection"&gt;[&lt;a href="http://wpkg.org/index.php?title=Running_Debian_on_ASUS_WL-500W&amp;amp;action=edit&amp;amp;section=2" title="Edit section: Flashing the kernel"&gt;edit&lt;/a&gt;]&lt;/span&gt; &lt;span class="mw-headline"&gt; Flashing the kernel &lt;/span&gt;&lt;/h2&gt; &lt;p&gt;The kernel image was built using OpenWRT buildroot (kamikaze, revision 6580 from 2007-Apr-03). It is 2.6.19.2, and has built-in SCSI, USB and ext3 support (to be able to boot from USB devices). To flash the image, use tftp. Start tftp program and point it to the IP of your ASUS device (192.168.1.1). Press the "restore" button and power on your device. Next step is to upload the image "openwrt-brcm-2.6-jffs2-128k.trx". &lt;/p&gt; &lt;pre&gt;wget -P . &lt;a href="http://www1.wpkg.org/debian-asus/openwrt-brcm47xx-2.6-jffs2-128k.trx" class="external free" title="http://www1.wpkg.org/debian-asus/openwrt-brcm47xx-2.6-jffs2-128k.trx" rel="nofollow"&gt;http://www1.wpkg.org/debian-asus/openwrt-brcm47xx-2.6-jffs2-128k.trx&lt;/a&gt;&lt;br /&gt;&lt;/pre&gt; &lt;pre&gt;tftp 192.168.1.1&lt;br /&gt;tftp&gt; binary&lt;br /&gt;tftp&gt; trace&lt;br /&gt;Packet tracing on.&lt;br /&gt;tftp&gt; put openwrt-brcm-2.6-jffs2-128k.trx&lt;br /&gt;(...)&lt;br /&gt;&lt;/pre&gt; &lt;p&gt;&lt;br /&gt;&lt;/p&gt; &lt;a name="Writing_Debian_on_your_USB_device"&gt;&lt;/a&gt;&lt;h2&gt;&lt;span class="editsection"&gt;[&lt;a href="http://wpkg.org/index.php?title=Running_Debian_on_ASUS_WL-500W&amp;amp;action=edit&amp;amp;section=3" title="Edit section: Writing Debian on your USB device"&gt;edit&lt;/a&gt;]&lt;/span&gt; &lt;span class="mw-headline"&gt; Writing Debian on your USB device &lt;/span&gt;&lt;/h2&gt; &lt;p&gt;Download Debian base system and uncompress it to the /dev/sdb1, ext3-formatted partition, (so that you have /bin, /etc and all other directories at the top-dir of this partition). Make sure to use tune2fs on /dev/sda1 partition: &lt;/p&gt;&lt;p&gt;&lt;br /&gt;Plug in the USB stick &lt;/p&gt; &lt;pre&gt;sudo su&lt;br /&gt;fdisk -l&lt;br /&gt;fdisk /dev/sdb&lt;br /&gt;* d   delete a partition&lt;br /&gt;* n   add a new partition&lt;br /&gt;* p    primary partition (1-4)&lt;br /&gt;* 1    Partition number (1-4): 1&lt;br /&gt;* 1    First cylinder (1-1015, default 1):&lt;br /&gt;* 1015 Last cylinder or +size or +sizeM or +sizeK (1-1015, default 1015):&lt;br /&gt;* w   write table to disk and exit &lt;br /&gt;mkfs.ext3 /dev/sdb1&lt;br /&gt;&lt;/pre&gt; &lt;pre&gt;mkdir /media/usb-drive&lt;br /&gt;mount -t ext3 /dev/sdb1 /media/usb-drive&lt;br /&gt;df -h&lt;br /&gt;&lt;/pre&gt; &lt;pre&gt;cd $HOME&lt;br /&gt;mkdir debian&lt;br /&gt;cd debian&lt;br /&gt;wget -P . &lt;a href="http://www1.wpkg.org/debian-asus/debian-mipsel-2007-Apr-17.tar.bz2" class="external free" title="http://www1.wpkg.org/debian-asus/debian-mipsel-2007-Apr-17.tar.bz2" rel="nofollow"&gt;http://www1.wpkg.org/debian-asus/debian-mipsel-2007-Apr-17.tar.bz2&lt;/a&gt;&lt;br /&gt;tar xvfj debian-mipsel-2007-Apr-17.tar.bz2&lt;br /&gt;cp -R mnt/debian-asus/* /media/usb-drive&lt;br /&gt;&lt;br /&gt;&lt;/pre&gt; &lt;p&gt;Make sure the USB stick will not be checked by e2fsck - otherwise, the device might not boot at all! &lt;/p&gt; &lt;pre&gt;tune2fs -c0 -i0 /dev/sdb1&lt;br /&gt;&lt;/pre&gt; &lt;p&gt;&lt;br /&gt;&lt;b&gt;WARNING!&lt;/b&gt;&lt;br /&gt;&lt;b&gt;When I said use tune2fs, I meant it:&lt;/b&gt; &lt;/p&gt; &lt;pre&gt;Will now check root file system:fsck 1.40-WIP (14-Nov-2006)&lt;br /&gt;[/sbin/fsck.ext3 (1) -- /] fsck.ext3 -a -C0 /dev/sda1&lt;br /&gt;/dev/sda1: Superblock last mount time is in the future.  FIXED.&lt;br /&gt;/dev/sda1: Superblock last write time is in the future.  FIXED.&lt;br /&gt;/dev/sda1 has gone 49710 days without being checked, check forced.&lt;br /&gt;/dev/sda1: ***** REBOOT LINUX *****&lt;br /&gt;/dev/sda1: 9030/56224 files (0.6% non-contiguous), 167947/224876 blocks&lt;br /&gt;fsck died with exit status 3&lt;br /&gt;failed!&lt;br /&gt;* The file system check corrected errors on the root partition&lt;br /&gt;but requested that the system be restarted.&lt;br /&gt;* The system will be restarted in 5 seconds.&lt;br /&gt;&lt;/pre&gt; &lt;p&gt;This means, your system will loop endlessly after checking the filesystem. This is because these devices don't have a battery-backed clock/rtc. &lt;/p&gt;&lt;p&gt;&lt;br /&gt;&lt;/p&gt; &lt;a name="Configuring_network"&gt;&lt;/a&gt;&lt;h2&gt;&lt;span class="editsection"&gt;[&lt;a href="http://wpkg.org/index.php?title=Running_Debian_on_ASUS_WL-500W&amp;amp;action=edit&amp;amp;section=4" title="Edit section: Configuring network"&gt;edit&lt;/a&gt;]&lt;/span&gt; &lt;span class="mw-headline"&gt; Configuring network &lt;/span&gt;&lt;/h2&gt; &lt;p&gt;You will have to configure your network in the following files: &lt;/p&gt; &lt;ul&gt;&lt;li&gt; vi /media/usb-drive/etc/network/interfaces - to configure your network &lt;ul&gt;&lt;li&gt; &lt;b&gt;NOTE! By default, SSH listens on 192.168.10.55 and 192.168.11.178, so make sure to change the network settings appropriately.&lt;/b&gt; &lt;/li&gt;&lt;/ul&gt; &lt;/li&gt;&lt;li&gt; vi /media/usb-drive/etc/resolv.conf - configure DNS (either 192.168.1.1 or DNS from ISP) &lt;/li&gt;&lt;li&gt; vi /media/usb-drive/etc/hostname - the hostname of your machine &lt;/li&gt;&lt;/ul&gt; &lt;p&gt;&lt;br /&gt;&lt;/p&gt; &lt;a name="Booting"&gt;&lt;/a&gt;&lt;h2&gt;&lt;span class="editsection"&gt;[&lt;a href="http://wpkg.org/index.php?title=Running_Debian_on_ASUS_WL-500W&amp;amp;action=edit&amp;amp;section=5" title="Edit section: Booting"&gt;edit&lt;/a&gt;]&lt;/span&gt; &lt;span class="mw-headline"&gt; Booting &lt;/span&gt;&lt;/h2&gt; &lt;p&gt;When you completed previous steps you should be able to boot your ASUS to a fully-working Debian.&lt;br /&gt; It doesn't matter which USB port you choose (unless you connect more devices). &lt;/p&gt;&lt;p&gt;You can log in via SSH, or consoles: USB or serial (check &lt;code&gt;/etc/inittab&lt;/code&gt; to see console settings). If you didn't change the network settings, SSH listens on 192.168.10.55 and 192.168.11.178 (available via LAN or WAN interfaces, so check both before reporting problems).&lt;br /&gt;The default password for the "root" user is "toor", and of course you are encouraged to change it. &lt;/p&gt;&lt;p&gt;You should see something like:&lt;br /&gt;&lt;/p&gt;&lt;p&gt;login as: root&lt;br /&gt;root@192.168.10.55's password:&lt;br /&gt;Linux asus-debian 2.6.19.2 #9 Tue Apr 3 21:30:54 CEST 2007 mips&lt;br /&gt;&lt;br /&gt;&lt;/p&gt;&lt;p&gt;The programs included with the Debian GNU/Linux system are free software;&lt;br /&gt;the exact distribution terms for each program are described in the&lt;br /&gt;individual files in /usr/share/doc/*/copyright.&lt;br /&gt;&lt;br /&gt;&lt;/p&gt;&lt;p&gt;Debian GNU/Linux comes with ABSOLUTELY NO WARRANTY, to the extent&lt;br /&gt;permitted by applicable law.&lt;br /&gt;&lt;br /&gt;&lt;/p&gt;&lt;p&gt;asus-debian:~# df -h&lt;br /&gt;Filesystem Size Used Avail Use% Mounted on&lt;br /&gt;/dev/sda1  477M 164M  288M  37% /&lt;br /&gt;tmpfs       15M    0   15M   0% /lib/init/rw&lt;br /&gt;udev        10M  12K   10M   1% /dev&lt;br /&gt;tmpfs       15M 4.0K   15M   1% /dev/shm&lt;br /&gt;none        15M    0   15M   0% /tmp&lt;br /&gt;asus-debian:~#&lt;br /&gt;&lt;/p&gt; &lt;a name="Building_your_own_kernel"&gt;&lt;/a&gt;&lt;h2&gt;&lt;span class="editsection"&gt;[&lt;a href="http://wpkg.org/index.php?title=Running_Debian_on_ASUS_WL-500W&amp;amp;action=edit&amp;amp;section=6" title="Edit section: Building your own kernel"&gt;edit&lt;/a&gt;]&lt;/span&gt; &lt;span class="mw-headline"&gt; Building your own kernel &lt;/span&gt;&lt;/h2&gt; &lt;p&gt;The author used revision 6850, however since it does not contain the WiFi for Asus 500W in this tutorial the latest revision from subversion will be extracted to build your own MIPS kernel. This should work in the end with Asus WL500-W BroadCom's 4704 Ethernet and BroadCom's 4321 WiFi on kernel 2.6. &lt;/p&gt;&lt;p&gt;&lt;br /&gt;1. Go to $HOME and download openwrt build environment &lt;/p&gt; &lt;pre&gt;cd $HOME&lt;br /&gt;svn checkout &lt;a href="https://svn.openwrt.org/openwrt/trunk/" class="external free" title="https://svn.openwrt.org/openwrt/trunk/" rel="nofollow"&gt;https://svn.openwrt.org/openwrt/trunk/&lt;/a&gt;&lt;br /&gt;&lt;/pre&gt; &lt;p&gt;2. Go to &lt;code&gt;trunk/&lt;/code&gt; directory, and select all the required tools: &lt;/p&gt; &lt;pre&gt;cd trunk&lt;br /&gt;make menuconfig&lt;br /&gt;&lt;/pre&gt; &lt;p&gt;From this step onward I am currently testing with the original doc, please feel free to update accordingly!&lt;br /&gt;&lt;/p&gt;&lt;p&gt;Make sure the first three options will look like:&lt;br /&gt;&lt;/p&gt; &lt;ul&gt;&lt;li&gt;"Target System (Broadcom BCM947xx/953xx [2.6])"&lt;br /&gt;&lt;/li&gt;&lt;li&gt;"Target Profile (Broadcom BCM43xx WiFi)" and&lt;br /&gt;&lt;/li&gt;&lt;li&gt;"Target Images" needs be set to "jffs2".&lt;br /&gt;&lt;br /&gt;&lt;/li&gt;&lt;/ul&gt; &lt;p&gt;As we want to use Debian only we don't need any OpenWRT packages. This will make our .trx image build faster and it'll be smaller too; the next six options need to be deselected:&lt;br /&gt;&lt;/p&gt; &lt;ul&gt;&lt;li&gt;"Select all packages by default" &lt;/li&gt;&lt;li&gt;"Advanced configuration options" &lt;/li&gt;&lt;li&gt;"Buildsystem settings" &lt;/li&gt;&lt;li&gt;"Build the OpenWRT Image Builder" &lt;/li&gt;&lt;li&gt;"Build the OpenWRT SDK" &lt;/li&gt;&lt;li&gt;"Image Configuration"&lt;br /&gt;&lt;br /&gt;&lt;/li&gt;&lt;/ul&gt; &lt;p&gt;Leave one package enabled as it will be needed to build the .trx firmware (otherwise, .trx image will be "empty", and won't build)&lt;br /&gt;&lt;/p&gt; &lt;ul&gt;&lt;li&gt;"Base system -&gt; base-files"&lt;br /&gt;&lt;br /&gt;&lt;/li&gt;&lt;/ul&gt; &lt;p&gt;Deselect all packages in:&lt;br /&gt;&lt;/p&gt; &lt;ul&gt;&lt;li&gt;"Network"&lt;br /&gt;&lt;/li&gt;&lt;li&gt;"Libraries"&lt;br /&gt;&lt;/li&gt;&lt;li&gt;"IPv6"&lt;br /&gt;&lt;/li&gt;&lt;li&gt;"Kernel modules"&lt;br /&gt;&lt;/li&gt;&lt;li&gt;"Boot Loaders"&lt;br /&gt;&lt;/li&gt;&lt;li&gt;"Utilities"&lt;br /&gt;&lt;/li&gt;&lt;li&gt;"Languages"&lt;br /&gt;&lt;/li&gt;&lt;/ul&gt; &lt;p&gt;&lt;br /&gt;3. Now, Exit, build all the tools needed for cross-compilation, and a (not yet configured) kernel.&lt;br /&gt;This steps takes quite a while so go and do something else: &lt;/p&gt; &lt;pre&gt;make V=99&lt;br /&gt;&lt;/pre&gt; &lt;p&gt;&lt;br /&gt;4. When all the tools are made, copy the &lt;code&gt;.config&lt;/code&gt; file to &lt;code&gt;trunk/build_dir/linux-brcm47xx/linux-2.6.x&lt;/code&gt; executing &lt;/p&gt; &lt;pre&gt;cd $HOME/trunk/build_dir/linux-brcm47xx/linux-2.6.23.16&lt;br /&gt;mv .config .config.backup&lt;br /&gt;wget -P . &lt;a href="http://www1.wpkg.org/debian-asus/.config" class="external free" title="http://www1.wpkg.org/debian-asus/.config" rel="nofollow"&gt;http://www1.wpkg.org/debian-asus/.config&lt;/a&gt;&lt;br /&gt;&lt;/pre&gt; &lt;p&gt;&lt;br /&gt;5. Configure the kernel according to your preference: &lt;/p&gt; &lt;pre&gt;make ARCH=mips oldconfig&lt;br /&gt;&gt; 3. Support for BCM947xx based boards (BCM947XX)&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;Endianess selection&lt;br /&gt;&gt; 1. Little endian (CPU_LITTLE_ENDIAN)&lt;br /&gt;choice[1]: 1&lt;br /&gt;*&lt;br /&gt;* CPU selection&lt;br /&gt;*&lt;br /&gt;CPU type&lt;br /&gt;&gt; 1. MIPS32 Release 1 (CPU_MIPS32_R1)&lt;br /&gt;choice[1]: 1&lt;br /&gt;*&lt;br /&gt;* Kernel type&lt;br /&gt;*&lt;br /&gt;Kernel code model&lt;br /&gt;&gt; 1. 32-bit kernel (32BIT)&lt;br /&gt;choice[1]: 1&lt;br /&gt;Kernel page size&lt;br /&gt;&gt; 1. 4kB (PAGE_SIZE_4KB)&lt;br /&gt; 2. 16kB (PAGE_SIZE_16KB)&lt;br /&gt; 3. 64kB (PAGE_SIZE_64KB)&lt;br /&gt;choice[1-3]: 1&lt;br /&gt;MIPS MT options&lt;br /&gt;&gt; 1. Disable multithreading support. (MIPS_MT_DISABLED)&lt;br /&gt;choice[1]: 1&lt;br /&gt;Memory model&lt;br /&gt;&gt; 1. Flat Memory (FLATMEM_MANUAL)&lt;br /&gt;choice[1]: 1&lt;br /&gt;64 bit Memory and IO resources (EXPERIMENTAL) (RESOURCES_64BIT) [N/y/?] n&lt;br /&gt;Timer frequency&lt;br /&gt; 1. 100 HZ (HZ_100)&lt;br /&gt; 2. 128 HZ (HZ_128)&lt;br /&gt;&gt; 3. 250 HZ (HZ_250)&lt;br /&gt; 4. 256 HZ (HZ_256)&lt;br /&gt; 5. 1000 HZ (HZ_1000)&lt;br /&gt; 6. 1024 HZ (HZ_1024)&lt;br /&gt;choice[1-6?]: 3&lt;br /&gt;Preemption Model&lt;br /&gt;&gt; 1. No Forced Preemption (Server) (PREEMPT_NONE)&lt;br /&gt; 2. Voluntary Kernel Preemption (Desktop) (PREEMPT_VOLUNTARY)&lt;br /&gt; 3. Preemptible Kernel (Low-Latency Desktop) (PREEMPT)&lt;br /&gt;choice[1-3]: 1&lt;br /&gt;Kexec system call (EXPERIMENTAL) (KEXEC) [N/y/?] (NEW)&lt;br /&gt;&lt;/pre&gt; &lt;p&gt;Answer "n" on "Kexec system call (EXPERIMENTAL) (KEXEC) [N/y/?] (NEW)"&lt;br /&gt;Answer "y" on "Enable seccomp to safely compute untrusted bytecode (SECCOMP) [Y/n/?] (NEW)"&lt;br /&gt;&lt;/p&gt; &lt;pre&gt;*&lt;br /&gt;* General setup&lt;br /&gt;*&lt;br /&gt;Prompt for development and/or incomplete code/drivers (EXPERIMENTAL) [Y/n/?] y&lt;br /&gt;Local version - append to kernel release (LOCALVERSION) []&lt;br /&gt;Automatically append version information to the version string (LOCALVERSION_AUTO) [Y/n/?] y&lt;br /&gt;Support for paging of anonymous memory (swap) (SWAP) [Y/n/?] y&lt;br /&gt;System V IPC (SYSVIPC) [Y/n/?] y&lt;br /&gt;POSIX Message Queues (POSIX_MQUEUE) [N/y/?] n&lt;br /&gt;BSD Process Accounting (BSD_PROCESS_ACCT) [N/y/?] n&lt;br /&gt;Export task/process statistics through netlink (EXPERIMENTAL) (TASKSTATS) [N/y/?] n&lt;br /&gt;User Namespaces (EXPERIMENTAL) (USER_NS) [N/y/?] (NEW)&lt;br /&gt;&lt;/pre&gt; &lt;p&gt;Answer "n" on "User Namespaces (EXPERIMENTAL) (USER_NS) [N/y/?] (NEW)"&lt;br /&gt;&lt;/p&gt; &lt;pre&gt;Auditing support (AUDIT) [N/y/?] n&lt;br /&gt;Kernel .config support (IKCONFIG) [Y/n/m/?] y&lt;br /&gt;Enable access to .config through /proc/config.gz (IKCONFIG_PROC) [Y/n/?] y&lt;br /&gt;Kernel log buffer size (16 =&gt; 64KB, 17 =&gt; 128KB) (LOG_BUF_SHIFT) [14] 14&lt;br /&gt;Create deprecated sysfs files (SYSFS_DEPRECATED) [Y/n/?] (NEW)&lt;br /&gt;&lt;/pre&gt; &lt;p&gt;Answer "y" on "Create deprecated sysfs files (SYSFS_DEPRECATED) [Y/n/?] (NEW)"&lt;br /&gt;&lt;/p&gt; &lt;pre&gt;Kernel-&gt;user space relay support (formerly relayfs) (RELAY) [N/y/?] n&lt;br /&gt;Initial RAM filesystem and RAM disk (initramfs/initrd) support (BLK_DEV_INITRD) [Y/n/?] y&lt;br /&gt; Initramfs source file(s) (INITRAMFS_SOURCE) []&lt;br /&gt;Optimize for size (Look out for broken compilers!) (CC_OPTIMIZE_FOR_SIZE) [Y/n/?] y&lt;br /&gt;*&lt;br /&gt;* Configure standard kernel features (for small systems)&lt;br /&gt;*&lt;br /&gt;Configure standard kernel features (for small systems) (EMBEDDED) [Y/?] y&lt;br /&gt; Sysctl syscall support (SYSCTL_SYSCALL) [Y/n/?] y&lt;br /&gt; Load all symbols for debugging/ksymoops (KALLSYMS) [N/y/?] n&lt;br /&gt; Support for hot-pluggable devices (HOTPLUG) [Y/n/?] y&lt;br /&gt; Enable support for printk (PRINTK) [Y/n/?] y&lt;br /&gt; BUG() support (BUG) [Y/n/?] y&lt;br /&gt; Enable ELF core dumps (ELF_CORE) [N/y/?] n&lt;br /&gt; Enable full-sized data structures for core (BASE_FULL) [Y/n/?] y&lt;br /&gt; Enable futex support (FUTEX) [Y/n/?] y&lt;br /&gt;Enable eventpoll support (EPOLL) [Y/n/?] y&lt;br /&gt;Enable signalfd() system call (SIGNALFD) [Y/n/?] (NEW)&lt;br /&gt;&lt;/pre&gt; &lt;p&gt;Answer "y" on "Enable signalfd() system call (SIGNALFD) [Y/n/?] (NEW)"&lt;br /&gt;Answer "y" on "Enable eventfd() system call (EVENTFD) [Y/n/?] (NEW)"&lt;br /&gt;&lt;/p&gt; &lt;pre&gt;Use full shmem filesystem (SHMEM) [Y/n/?] y&lt;br /&gt;Enable VM event counters for /proc/vmstat (VM_EVENT_COUNTERS) [N/y/?] n&lt;br /&gt;Choose SLAB allocator&lt;br /&gt;&gt; 1. SLAB (SLAB)&lt;br /&gt; 2. SLUB (Unqueued Allocator) (SLUB) (NEW)&lt;br /&gt; 3. SLOB (Simple Allocator) (SLOB)&lt;br /&gt;&lt;/pre&gt; &lt;p&gt;Answer "1" to select "SLAB" &lt;/p&gt; &lt;pre&gt;*&lt;br /&gt;* Enable loadable module support&lt;br /&gt;*&lt;br /&gt;Enable loadable module support (MODULES) [Y/n/?] y&lt;br /&gt; Module unloading (MODULE_UNLOAD) [Y/n/?] y&lt;br /&gt;   Forced module unloading (MODULE_FORCE_UNLOAD) [N/y/?] n&lt;br /&gt; Module versioning support (MODVERSIONS) [N/y/?] n&lt;br /&gt; Source checksum for all modules (MODULE_SRCVERSION_ALL) [N/y/?] n&lt;br /&gt; Automatic kernel module loading (KMOD) [Y/n/?] y&lt;br /&gt;*&lt;br /&gt;* Enable the block layer&lt;br /&gt;*&lt;br /&gt;Enable the block layer (BLOCK) [Y/n/?] y&lt;br /&gt; Support for Large Block Devices (LBD) [N/y/?] n&lt;br /&gt; Support for tracing block io actions (BLK_DEV_IO_TRACE) [N/y/?] n&lt;br /&gt; Support for Large Single Files (LSF) [N/y/?] n&lt;br /&gt; Block layer SG support v4 (EXPERIMENTAL) (BLK_DEV_BSG) [N/y/?] (NEW)&lt;br /&gt;&lt;/pre&gt; &lt;p&gt;Answer "n" on "Block layer SG support v4 (EXPERIMENTAL) (BLK_DEV_BSG) [N/y/?] (NEW)"  &lt;/p&gt; &lt;pre&gt;*&lt;br /&gt;* Support for PCI Hotplug (EXPERIMENTAL)&lt;br /&gt;*&lt;br /&gt;Support for PCI Hotplug (EXPERIMENTAL) (HOTPLUG_PCI) [N/m/y/?] n&lt;br /&gt;*&lt;br /&gt;* Executable file formats&lt;br /&gt;*&lt;br /&gt;Kernel support for ELF binaries (BINFMT_ELF) [Y/n/?] y&lt;br /&gt;Kernel support for MISC binaries (BINFMT_MISC) [N/m/y/?] n&lt;br /&gt;*&lt;br /&gt;* Power management options&lt;br /&gt;*&lt;br /&gt;Power Management support (PM) [N/y/?] (NEW)&lt;br /&gt;&lt;/pre&gt; &lt;p&gt;Answer "y" on "Power Management support (PM) [N/y/?] (NEW)"&lt;br /&gt;Answer "y" on "Legacy Power Management API (DEPRECATED) (PM_LEGACY) [N/y/?] (NEW)"&lt;br /&gt;Answer "n" on "Power Management Debug Support (PM_DEBUG) [N/y/?] (NEW)"&lt;br /&gt;Answer "n" on "Suspend to RAM and standby (SUSPEND) [Y/n/?] (NEW)"&lt;br /&gt;&lt;/p&gt; &lt;pre&gt;*&lt;br /&gt;* Networking&lt;br /&gt;*&lt;br /&gt;Networking support (NET) [Y/n/?] y&lt;br /&gt; *&lt;br /&gt; * Networking options&lt;br /&gt; *&lt;br /&gt; Packet socket (PACKET) [Y/n/m/?] y&lt;br /&gt;   Packet socket: mmapped IO (PACKET_MMAP) [Y/n/?] y&lt;br /&gt; Unix domain sockets (UNIX) [Y/n/m/?] y&lt;br /&gt; PF_KEY sockets (NET_KEY) [N/m/y/?] n&lt;br /&gt; TCP/IP networking (INET) [Y/n/?] y&lt;br /&gt;   IP: multicasting (IP_MULTICAST) [N/y/?] n&lt;br /&gt;   IP: advanced router (IP_ADVANCED_ROUTER) [N/y/?] n&lt;br /&gt;   IP: kernel level autoconfiguration (IP_PNP) [N/y/?] n&lt;br /&gt;   IP: tunneling (NET_IPIP) [N/m/y/?] n&lt;br /&gt;   IP: GRE tunnels over IP (NET_IPGRE) [N/m/y/?] n&lt;br /&gt;   IPSEC NAT-Traversal (KLIPS compatible) (IPSEC_NAT_TRAVERSAL) [N/y/?] n&lt;br /&gt;   IP: ARP daemon support (EXPERIMENTAL) (ARPD) [N/y/?] n&lt;br /&gt;   IP: TCP syncookie support (disabled per default) (SYN_COOKIES) [N/y/?] n&lt;br /&gt;   IP: AH transformation (INET_AH) [N/m/y/?] n&lt;br /&gt;   IP: ESP transformation (INET_ESP) [N/m/y/?] n&lt;br /&gt;   IP: IPComp transformation (INET_IPCOMP) [N/m/y/?] n&lt;br /&gt;   IP: IPsec transport mode (INET_XFRM_MODE_TRANSPORT) [N/m/y/?] n&lt;br /&gt;   IP: IPsec tunnel mode (INET_XFRM_MODE_TUNNEL) [N/m/y/?] n&lt;br /&gt;   IP: IPsec BEET mode (INET_XFRM_MODE_BEET) [N/m/y/?] n&lt;br /&gt;   INET: socket monitoring interface (INET_DIAG) [M/n/y/?] m&lt;br /&gt;   *&lt;br /&gt;   * TCP: advanced congestion control&lt;br /&gt;   *&lt;br /&gt;   TCP: advanced congestion control (TCP_CONG_ADVANCED) [N/y/?] n&lt;br /&gt;   TCP: MD5 Signature Option support (RFC2385) (EXPERIMENTAL) (TCP_MD5SIG) [N/y/?] (NEW)&lt;br /&gt;&lt;/pre&gt; &lt;p&gt;Answer "n" on "TCP: MD5 Signature Option support (RFC2385) (EXPERIMENTAL) (TCP_MD5SIG) [N/y/?] (NEW)" &lt;/p&gt; &lt;pre&gt;    *&lt;br /&gt;   * IP virtual server support (EXPERIMENTAL)&lt;br /&gt;   *&lt;br /&gt;   IP virtual server support (EXPERIMENTAL) (IP_VS) [N/m/y/?] n&lt;br /&gt;   The IPv6 protocol (IPV6) [N/m/y/?] n&lt;br /&gt; Security Marking (NETWORK_SECMARK) [N/y/?] n&lt;br /&gt; *&lt;br /&gt; * Network packet filtering framework (Netfilter)&lt;br /&gt; *&lt;br /&gt; Network packet filtering framework (Netfilter) (NETFILTER) [Y/n/?] y&lt;br /&gt;   Network packet filtering debugging (NETFILTER_DEBUG) [N/y/?] n&lt;br /&gt;   Bridged IP/ARP packets filtering (BRIDGE_NETFILTER) [N/y/?] n&lt;br /&gt;   *&lt;br /&gt;   * Core Netfilter Configuration&lt;br /&gt;   *&lt;br /&gt;   Netfilter netlink interface (NETFILTER_NETLINK) [N/m/y/?] n&lt;br /&gt;   Netfilter connection tracking support (NF_CONNTRACK_ENABLED) [N/m/y/?] (NEW)&lt;br /&gt;&lt;/pre&gt; &lt;p&gt;Answer "m" on "Netfilter connection tracking support (NF_CONNTRACK_ENABLED) [N/m/y/?] (NEW)"&lt;br /&gt; Answer "n" on "Connection tracking flow accounting (NF_CT_ACCT) [N/y/?] (NEW)"&lt;br /&gt;Answer "n" on "Connection tracking events (EXPERIMENTAL) (NF_CONNTRACK_EVENTS) [N/y/?] (NEW)"&lt;br /&gt;Answer "n" on "SCTP protocol connection tracking support (EXPERIMENTAL) (NF_CT_PROTO_SCTP) [N/m/?] (NEW)"&lt;br /&gt;Answer "n" on "UDP-Lite protocol connection tracking support (EXPERIMENTAL) (NF_CT_PROTO_UDPLITE) [N/m/?] (NEW)"&lt;br /&gt;Answer "n" on "Amanda backup protocol support (NF_CONNTRACK_AMANDA) [N/m/?] (NEW)"&lt;br /&gt;Answer "m" on "FTP protocol support (NF_CONNTRACK_FTP) [N/m/?] (NEW)"&lt;br /&gt;Answer "m" on "H.323 protocol support (EXPERIMENTAL) (NF_CONNTRACK_H323) [N/m/?] (NEW)"&lt;br /&gt;Answer "m" on "IRC protocol support (NF_CONNTRACK_IRC) [N/m/?] (NEW)"&lt;br /&gt;Answer "n" on "NetBIOS name service protocol support (EXPERIMENTAL) (NF_CONNTRACK_NETBIOS_NS) [N/m/?] (NEW)"&lt;br /&gt;Answer "m" on "PPtP protocol support (NF_CONNTRACK_PPTP) [N/m/?] (NEW)"&lt;br /&gt;Answer "n" on "SANE protocol support (EXPERIMENTAL) (NF_CONNTRACK_SANE) [N/m/?] (NEW)"&lt;br /&gt;Answer "m" on "SIP protocol support (EXPERIMENTAL) (NF_CONNTRACK_SIP) [N/m/?] (NEW)"&lt;br /&gt;Answer "m" on "TFTP protocol support (NF_CONNTRACK_TFTP) [N/m/?] (NEW)"&lt;br /&gt;Answer "n" on "RTSP protocol support (NF_CONNTRACK_RTSP) [N/m/?] (NEW)"&lt;br /&gt;Answer "n" on "NFLOG" target support (NETFILTER_XT_TARGET_NFLOG) [N/m/y/?] (NEW)"&lt;br /&gt;Answer "n" on "TRACE" target support (NETFILTER_XT_TARGET_TRACE) [N/m/?] (NEW)"&lt;br /&gt;Answer "n" on "TARPIT" target support (NETFILTER_XT_TARGET_TARPIT) [N/m/y/?] (NEW)"&lt;br /&gt;Answer "n" on "TCPMSS" target support (NETFILTER_XT_TARGET_TCPMSS) [N/m/y/?] (NEW)"&lt;br /&gt;Answer "n" on "connlimit" match support" (NETFILTER_XT_MATCH_CONNLIMIT) [N/m/?] (NEW)"&lt;br /&gt;Answer "n" on "u32" match support (NETFILTER_XT_MATCH_U32) [N/m/y/?] (NEW)"&lt;br /&gt;Answer "n" on "hashlimit" match support (NETFILTER_XT_MATCH_HASHLIMIT) [N/m/y/?] (NEW)"&lt;br /&gt;Answer "m" on "IPv4 connection tracking support (required for NAT) (NF_CONNTRACK_IPV4) [N/m/?] (NEW)"&lt;br /&gt;Answer "y" on "proc/sysctl compatibility with old connection tracking (NF_CONNTRACK_PROC_COMPAT) [Y/n/?] (NEW)"&lt;br /&gt;Answer "m" on "Full NAT (NF_NAT) [N/m/?] (NEW)"&lt;br /&gt;Answer "n" on "Basic SNMP-ALG support (EXPERIMENTAL) (NF_NAT_SNMP_BASIC) [N/m/?] (NEW)"&lt;br /&gt;Answer "n" on "ipporthash set support (IP_NF_SET_IPPORTHASH) [N/m/?] (NEW)"&lt;br /&gt;Answer "n" on "iptreemap set support (IP_NF_SET_IPTREEMAP) [N/m/?] (NEW)"&lt;br /&gt;&lt;/p&gt; &lt;pre&gt;set match support (IP_NF_MATCH_SET) [M/n/?] m&lt;br /&gt;     SET target support (IP_NF_TARGET_SET) [M/n/?] m&lt;br /&gt;   ROUTE target support (IP_NF_TARGET_ROUTE) [M/n/y/?] m&lt;br /&gt;   *&lt;br /&gt;   * Bridge: Netfilter Configuration&lt;br /&gt;   *&lt;br /&gt;   Ethernet Bridge tables (ebtables) support (BRIDGE_NF_EBTABLES) [M/n/y/?] m&lt;br /&gt;     ebt: broute table support (BRIDGE_EBT_BROUTE) [M/n/?] m&lt;br /&gt;     ebt: filter table support (BRIDGE_EBT_T_FILTER) [M/n/?] m&lt;br /&gt;     ebt: nat table support (BRIDGE_EBT_T_NAT) [M/n/?] m&lt;br /&gt;     ebt: 802.3 filter support (BRIDGE_EBT_802_3) [M/n/?] m&lt;br /&gt;     ebt: among filter support (BRIDGE_EBT_AMONG) [M/n/?] m&lt;br /&gt;     ebt: ARP filter support (BRIDGE_EBT_ARP) [M/n/?] m&lt;br /&gt;     ebt: IP filter support (BRIDGE_EBT_IP) [M/n/?] m&lt;br /&gt;     ebt: limit match support (BRIDGE_EBT_LIMIT) [M/n/?] m&lt;br /&gt;     ebt: mark filter support (BRIDGE_EBT_MARK) [M/n/?] m&lt;br /&gt;     ebt: packet type filter support (BRIDGE_EBT_PKTTYPE) [M/n/?] m&lt;br /&gt;     ebt: STP filter support (BRIDGE_EBT_STP) [M/n/?] m&lt;br /&gt;     ebt: 802.1Q VLAN filter support (BRIDGE_EBT_VLAN) [M/n/?] m&lt;br /&gt;     ebt: arp reply target support (BRIDGE_EBT_ARPREPLY) [M/n/?] m&lt;br /&gt;     ebt: dnat target support (BRIDGE_EBT_DNAT) [M/n/?] m&lt;br /&gt;     ebt: mark target support (BRIDGE_EBT_MARK_T) [M/n/?] m&lt;br /&gt;     ebt: redirect target support (BRIDGE_EBT_REDIRECT) [M/n/?] m&lt;br /&gt;     ebt: snat target support (BRIDGE_EBT_SNAT) [M/n/?] m&lt;br /&gt;     ebt: log support (BRIDGE_EBT_LOG) [M/n/?] m&lt;br /&gt;     ebt: ulog support (OBSOLETE) (BRIDGE_EBT_ULOG) [M/n/?] m&lt;br /&gt; *&lt;br /&gt; * The DCCP Protocol (EXPERIMENTAL)&lt;br /&gt; *&lt;br /&gt; The DCCP Protocol (EXPERIMENTAL) (IP_DCCP) [N/m/y/?] n&lt;br /&gt; *&lt;br /&gt; * The SCTP Protocol (EXPERIMENTAL)&lt;br /&gt; *&lt;br /&gt; The SCTP Protocol (EXPERIMENTAL) (IP_SCTP) [N/m/y/?] n&lt;br /&gt; *&lt;br /&gt; * The TIPC Protocol (EXPERIMENTAL)&lt;br /&gt; *&lt;br /&gt; The TIPC Protocol (EXPERIMENTAL) (TIPC) [N/m/y/?] n&lt;br /&gt; Asynchronous Transfer Mode (ATM) (EXPERIMENTAL) (ATM) [M/n/y/?] m&lt;br /&gt;   Classical IP over ATM (EXPERIMENTAL) (ATM_CLIP) [M/n/?] m&lt;br /&gt;     Do NOT send ICMP if no neighbour (EXPERIMENTAL) (ATM_CLIP_NO_ICMP) [Y/n/?] y&lt;br /&gt;   LAN Emulation (LANE) support (EXPERIMENTAL) (ATM_LANE) [M/n/?] m&lt;br /&gt;     Multi-Protocol Over ATM (MPOA) support (EXPERIMENTAL) (ATM_MPOA) [M/n/?] m&lt;br /&gt;   RFC1483/2684 Bridged protocols (ATM_BR2684) [M/n/?] m&lt;br /&gt;     Per-VC IP filter kludge (ATM_BR2684_IPFILTER) [Y/n/?] y&lt;br /&gt; 802.1d Ethernet Bridging (BRIDGE) [Y/n/m/?] y&lt;br /&gt; 802.1Q VLAN Support (VLAN_8021Q) [Y/n/m/?] y&lt;br /&gt; DECnet Support (DECNET) [N/m/y/?] n&lt;br /&gt; ANSI/IEEE 802.2 LLC type 2 Support (LLC2) [N/m/y/?] n&lt;br /&gt; The IPX protocol (IPX) [N/m/y/?] n&lt;br /&gt; Appletalk protocol support (ATALK) [N/m/y/?] n&lt;br /&gt; CCITT X.25 Packet Layer (EXPERIMENTAL) (X25) [N/m/y/?] n&lt;br /&gt; LAPB Data Link Driver (EXPERIMENTAL) (LAPB) [N/m/y/?] n&lt;br /&gt; Acorn Econet/AUN protocols (EXPERIMENTAL) (ECONET) [N/m/y/?] n&lt;br /&gt; WAN router (WAN_ROUTER) [N/m/y/?] n&lt;br /&gt; *&lt;br /&gt; * QoS and/or fair queueing&lt;br /&gt; *&lt;br /&gt; QoS and/or fair queueing (NET_SCHED) [Y/n/?] y&lt;br /&gt; *&lt;br /&gt; * Queueing/Scheduling&lt;br /&gt; *&lt;br /&gt; Class Based Queueing (CBQ) (NET_SCH_CBQ) [M/n/y/?] m&lt;br /&gt; Hierarchical Token Bucket (HTB) (NET_SCH_HTB) [M/n/y/?] m&lt;br /&gt; Hierarchical Fair Service Curve (HFSC) (NET_SCH_HFSC) [M/n/y/?] m&lt;br /&gt; ATM Virtual Circuits (ATM) (NET_SCH_ATM) [M/n/?] m&lt;br /&gt; Multi Band Priority Queueing (PRIO) (NET_SCH_PRIO) [M/n/y/?] m&lt;br /&gt; Multi Band Round Robin Queuing (RR) (NET_SCH_RR) [N/m/y/?] (NEW)&lt;br /&gt;&lt;/pre&gt; &lt;p&gt;Answer "m" on "Multi Band Round Robin Queuing (RR) (NET_SCH_RR) [N/m/y/?] (NEW)"&lt;br /&gt;Answer "n" on "Connection Tracking Hash Types (NET_SCH_ESFQ_NFCT) [N/y/?] (NEW)"&lt;br /&gt;Answer "n" on "Generic actions (NET_ACT_GACT) [N/m/y/?] (NEW)"&lt;br /&gt;Answer "n" on "Redirecting and Mirroring (NET_ACT_MIRRED) [N/m/y/?] (NEW)"&lt;br /&gt;Answer "n" on "IPtables targets (NET_ACT_IPT) [N/m/y/?] (NEW)"&lt;br /&gt;Answer "n" on "Packet Editing (NET_ACT_PEDIT) [N/m/y/?] (NEW)"&lt;br /&gt;Answer "n" on "Simple Example (Debug) (NET_ACT_SIMP) [N/m/y/?] (NEW)"&lt;br /&gt;&lt;/p&gt; &lt;pre&gt; *&lt;br /&gt;* Classification&lt;br /&gt;*&lt;br /&gt; Elementary classification (BASIC) (NET_CLS_BASIC) [M/n/y/?] m&lt;br /&gt; Traffic-Control Index (TCINDEX) (NET_CLS_TCINDEX) [M/n/y/?] m&lt;br /&gt; Routing decision (ROUTE) (NET_CLS_ROUTE4) [M/n/y/?] m&lt;br /&gt; Netfilter mark (FW) (NET_CLS_FW) [M/n/y/?] m&lt;br /&gt; Universal 32bit comparisons w/ hashing (U32) (NET_CLS_U32) [M/n/y/?] m&lt;br /&gt;   Performance counters support (CLS_U32_PERF) [N/y/?] n&lt;br /&gt;   Netfilter marks support (CLS_U32_MARK) [N/y/?] n&lt;br /&gt; IPv4 Resource Reservation Protocol (RSVP) (NET_CLS_RSVP) [M/n/y/?] m&lt;br /&gt; IPv6 Resource Reservation Protocol (RSVP6) (NET_CLS_RSVP6) [M/n/y/?] m&lt;br /&gt; Extended Matches (NET_EMATCH) [N/y/?] n&lt;br /&gt; Actions (NET_CLS_ACT) [Y/?] y&lt;br /&gt;   Traffic Policing (NET_ACT_POLICE) [Y/?] (NEW) y&lt;br /&gt;   Generic actions (NET_ACT_GACT) [N/m/y/?] (NEW) n&lt;br /&gt;   Redirecting and Mirroring (NET_ACT_MIRRED) [N/m/y/?] (NEW) n&lt;br /&gt;   IPtables targets (NET_ACT_IPT) [N/m/y/?] (NEW) n&lt;br /&gt;   Packet Editing (NET_ACT_PEDIT) [N/m/y/?] (NEW) n&lt;br /&gt;   Simple Example (Debug) (NET_ACT_SIMP) [N/m/y/?] (NEW) n&lt;br /&gt; Traffic Policing (obsolete) (NET_CLS_POLICE) [Y/n/?] y&lt;br /&gt; Incoming device classification (NET_CLS_IND) [N/y/?] n&lt;br /&gt;*&lt;br /&gt;* Network testing&lt;br /&gt;*&lt;br /&gt; Packet Generator (USE WITH CAUTION) (NET_PKTGEN) [N/m/y/?] n&lt;br /&gt;*&lt;br /&gt;* Amateur Radio support&lt;br /&gt;*&lt;br /&gt; Amateur Radio support (HAMRADIO) [Y/n/?] y&lt;br /&gt;  *&lt;br /&gt;  * Packet Radio protocols&lt;br /&gt;  *&lt;br /&gt;   Amateur Radio AX.25 Level 2 protocol (AX25) [M/n/y/?] m&lt;br /&gt;     AX.25 DAMA Slave support (AX25_DAMA_SLAVE) [N/y/?] n&lt;br /&gt;     Amateur Radio NET/ROM protocol (NETROM) [N/m/?] n&lt;br /&gt;     Amateur Radio X.25 PLP (Rose) (ROSE) [N/m/?] n&lt;br /&gt;     *&lt;br /&gt;     * AX.25 network device drivers&lt;br /&gt;     *&lt;br /&gt;     Serial port KISS driver (MKISS) [M/n/?] m&lt;br /&gt;     Serial port 6PACK driver (6PACK) [N/m/?] n&lt;br /&gt;     BPQ Ethernet driver (BPQETHER) [N/m/?] n&lt;br /&gt;     BAYCOM ser12 fullduplex driver for AX.25 (BAYCOM_SER_FDX) [N/m/?] n&lt;br /&gt;     BAYCOM ser12 halfduplex driver for AX.25 (BAYCOM_SER_HDX) [N/m/?] n&lt;br /&gt;     YAM driver for AX.25 (YAM) [N/m/?] n&lt;br /&gt; *&lt;br /&gt; * IrDA (infrared) subsystem support&lt;br /&gt; *&lt;br /&gt; IrDA (infrared) subsystem support (IRDA) [N/m/y/?] n&lt;br /&gt; *&lt;br /&gt; * Bluetooth subsystem support&lt;br /&gt; *&lt;br /&gt; Bluetooth subsystem support (BT) [M/n/y/?] m&lt;br /&gt;   L2CAP protocol support (BT_L2CAP) [M/n/?] m&lt;br /&gt;   SCO links support (BT_SCO) [M/n/?] m&lt;br /&gt;   RFCOMM protocol support (BT_RFCOMM) [M/n/?] m&lt;br /&gt;     RFCOMM TTY support (BT_RFCOMM_TTY) [Y/n/?] y&lt;br /&gt;   BNEP protocol support (BT_BNEP) [M/n/?] m&lt;br /&gt;     Multicast filter support (BT_BNEP_MC_FILTER) [Y/n/?] y&lt;br /&gt;     Protocol filter support (BT_BNEP_PROTO_FILTER) [Y/n/?] y&lt;br /&gt;   *&lt;br /&gt;   * Bluetooth device drivers&lt;br /&gt;   *&lt;br /&gt;   HCI USB driver (BT_HCIUSB) [M/n/?] m&lt;br /&gt;     SCO (voice) support (BT_HCIUSB_SCO) [Y/n/?] y&lt;br /&gt;   HCI UART driver (BT_HCIUART) [M/n/?] m&lt;br /&gt;     UART (H4) protocol support (BT_HCIUART_H4) [Y/n/?] y&lt;br /&gt;     BCSP protocol support (BT_HCIUART_BCSP) [Y/n/?] y&lt;br /&gt;   HCI BCM203x USB driver (BT_HCIBCM203X) [N/m/?] n&lt;br /&gt;   HCI BPA10x USB driver (BT_HCIBPA10X) [N/m/?] n&lt;br /&gt;   HCI BlueFRITZ! USB driver (BT_HCIBFUSB) [N/m/?] n&lt;br /&gt;   HCI VHCI (Virtual HCI device) driver (BT_HCIVHCI) [N/m/?] n&lt;br /&gt; RxRPC session sockets (AF_RXRPC) [N/m/y/?] (NEW)&lt;br /&gt;&lt;/pre&gt; &lt;p&gt;Answer "n" on "RxRPC session sockets (AF_RXRPC) [N/m/y/?] (NEW)" &lt;/p&gt; &lt;pre&gt; *&lt;br /&gt;* Wireless&lt;br /&gt;*&lt;br /&gt;Improved wireless configuration API (CFG80211) [N/m/y] (NEW)&lt;br /&gt;&lt;/pre&gt; &lt;p&gt;Answer "y" on "Improved wireless configuration API (CFG80211) [N/m/y] (NEW)"&lt;br /&gt;Answer "n" on "Generic IEEE 802.11 Networking Stack (mac80211) (MAC80211) [N/m/y/?] (NEW)"&lt;br /&gt;&lt;/p&gt; &lt;pre&gt;  Generic IEEE 802.11 Networking Stack (IEEE80211) [M/n/y/?] m&lt;br /&gt;  Enable full debugging output (IEEE80211_DEBUG) [N/y/?] n&lt;br /&gt;  IEEE 802.11 WEP encryption (802.1x) (IEEE80211_CRYPT_WEP) [M/?] m&lt;br /&gt;  IEEE 802.11i CCMP support (IEEE80211_CRYPT_CCMP) [M/n/?] m&lt;br /&gt;  IEEE 802.11i TKIP encryption (IEEE80211_CRYPT_TKIP) [M/n/?] m&lt;br /&gt;  Software MAC add-on to the IEEE 802.11 networking stack (IEEE80211_SOFTMAC) [M/n/?] m&lt;br /&gt;    Enable full debugging output (IEEE80211_SOFTMAC_DEBUG) [N/y] n&lt;br /&gt;*&lt;br /&gt;* RF switch subsystem support&lt;br /&gt;*&lt;br /&gt;RF switch subsystem support (RFKILL) [N/m/y/?] (NEW)&lt;br /&gt;&lt;/pre&gt; &lt;p&gt;Answer "n" on "RF switch subsystem support (RFKILL) [N/m/y/?] (NEW)"&lt;br /&gt;Answer "n" on "Plan 9 Resource Sharing Support (9P2000) (Experimental) (NET_9P) [N/m/y/?] (NEW)"&lt;br /&gt;&lt;/p&gt; &lt;pre&gt;*&lt;br /&gt;* Device Drivers&lt;br /&gt;*&lt;br /&gt;*&lt;br /&gt;* Generic Driver Options&lt;br /&gt;*&lt;br /&gt;Select only drivers that don't need compile-time external firmware (STANDALONE) [Y/n/?] y&lt;br /&gt;Prevent firmware from being built (PREVENT_FIRMWARE_BUILD) [Y/n/?] y&lt;br /&gt;Userspace firmware loading support (FW_LOADER) [Y/m/?] y&lt;br /&gt;*&lt;br /&gt;* Connector - unified userspace &lt;-&gt; kernelspace linker&lt;br /&gt;*&lt;br /&gt;Connector - unified userspace &lt;-&gt; kernelspace linker (CONNECTOR) [M/n/y/?] m&lt;br /&gt;*&lt;br /&gt;* Memory Technology Device (MTD) support&lt;br /&gt;*&lt;br /&gt;Memory Technology Device (MTD) support (MTD) [Y/n/m/?] y&lt;br /&gt; Debugging (MTD_DEBUG) [N/y/?] n&lt;br /&gt; MTD concatenating support (MTD_CONCAT) [N/m/y/?] n&lt;br /&gt; MTD partitioning support (MTD_PARTITIONS) [Y/n/?] y&lt;br /&gt;  Automatically set 'rootfs' partition to be root filesystem (MTD_ROOTFS_ROOT_DEV) [Y/n] (NEW)&lt;br /&gt;&lt;/pre&gt; &lt;p&gt;Answer "y" on "Automatically set 'rootfs' partition to be root filesystem (MTD_ROOTFS_ROOT_DEV) [Y/n] (NEW)"&lt;br /&gt;Answer "y" on "Automatically split 'rootfs' partition for squashfs (MTD_ROOTFS_SPLIT) [Y/n] (NEW)"&lt;br /&gt;&lt;/p&gt;&lt;p&gt;&lt;br /&gt;&lt;/p&gt; &lt;pre&gt;   RedBoot partition table parsing (MTD_REDBOOT_PARTS) [N/m/y/?] n&lt;br /&gt;  Command line partition table parsing (MTD_CMDLINE_PARTS) [N/y/?] n&lt;br /&gt;*&lt;br /&gt;* User Modules And Translation Layers&lt;br /&gt;*&lt;br /&gt;Direct char device access to MTD devices (MTD_CHAR) [Y/n/m/?] y&lt;br /&gt;Common interface to block layer for MTD 'translation layers' (MTD_BLKDEVS) [Y] (NEW) y&lt;br /&gt;Caching block device access to MTD devices (MTD_BLOCK) [Y/n/m/?] y&lt;br /&gt;FTL (Flash Translation Layer) support (FTL) [N/m/y/?] n&lt;br /&gt;NFTL (NAND Flash Translation Layer) support (NFTL) [N/m/y/?] n&lt;br /&gt;INFTL (Inverse NAND Flash Translation Layer) support (INFTL) [N/m/y/?] n&lt;br /&gt;Resident Flash Disk (Flash Translation Layer) support (RFD_FTL) [N/m/y/?] n&lt;br /&gt;NAND SSFDC (SmartMedia) read only translation layer (SSFDC) [N/m/y/?] n&lt;br /&gt;*&lt;br /&gt;* RAM/ROM/Flash chip drivers&lt;br /&gt;*&lt;br /&gt;Detect flash chips by Common Flash Interface (CFI) probe (MTD_CFI) [Y/n/m/?] y&lt;br /&gt;Detect non-CFI AMD/JEDEC-compatible flash chips (MTD_JEDECPROBE) [N/m/y/?] n&lt;br /&gt;Flash chip driver advanced configuration options (MTD_CFI_ADV_OPTIONS) [N/y/?] n&lt;br /&gt;Support for Intel/Sharp flash chips (MTD_CFI_INTELEXT) [Y/n/m/?] y&lt;br /&gt;Support for AMD/Fujitsu flash chips (MTD_CFI_AMDSTD) [Y/n/m/?] y&lt;br /&gt;Support for ST (Advanced Architecture) flash chips (MTD_CFI_STAA) [N/m/y/?] n&lt;br /&gt;Support for RAM chips in bus mapping (MTD_RAM) [N/m/y/?] n&lt;br /&gt;Support for ROM chips in bus mapping (MTD_ROM) [N/m/y/?] n&lt;br /&gt;Support for absent chips in bus mapping (MTD_ABSENT) [N/m/y/?] n&lt;br /&gt;*&lt;br /&gt;* Mapping drivers for chip access&lt;br /&gt;*&lt;br /&gt;Support non-linear mappings of flash chips (MTD_COMPLEX_MAPPINGS) [Y/n/?] y&lt;br /&gt;CFI Flash device in physical memory map (MTD_PHYSMAP) [N/m/y/?] n&lt;br /&gt;BCM47xx flash device (MTD_BCM47XX) [Y/n/m/?] y&lt;br /&gt;PCI MTD driver (MTD_PCI) [N/m/y/?] n&lt;br /&gt;Map driver for platform device RAM (mtd-ram) (MTD_PLATRAM) [N/m/y/?] n&lt;br /&gt;*&lt;br /&gt;* Self-contained MTD device drivers&lt;br /&gt;*&lt;br /&gt;Ramix PMC551 PCI Mezzanine RAM card support (MTD_PMC551) [N/m/y/?] n&lt;br /&gt;Uncached system RAM (MTD_SLRAM) [N/m/y/?] n&lt;br /&gt;Physical system RAM (MTD_PHRAM) [N/m/y/?] n&lt;br /&gt;Test driver using RAM (MTD_MTDRAM) [N/m/y/?] n&lt;br /&gt;MTD using block device (MTD_BLOCK2MTD) [N/m/y/?] n&lt;br /&gt;*&lt;br /&gt;* Disk-On-Chip Device Drivers&lt;br /&gt;*&lt;br /&gt;M-Systems Disk-On-Chip 2000 and Millennium (DEPRECATED) (MTD_DOC2000) [N/m/y/?] n&lt;br /&gt;M-Systems Disk-On-Chip Millennium-only alternative driver (DEPRECATED) (MTD_DOC2001) [N/m/y/?] n&lt;br /&gt;M-Systems Disk-On-Chip Millennium Plus (MTD_DOC2001PLUS) [N/m/y/?] n&lt;br /&gt;*&lt;br /&gt;* NAND Device Support&lt;br /&gt;*&lt;br /&gt;NAND Device Support (MTD_NAND) [N/m/y/?] n&lt;br /&gt;*&lt;br /&gt;* OneNAND Device Support&lt;br /&gt;*&lt;br /&gt;OneNAND Device Support (MTD_ONENAND) [N/m/y/?] n&lt;br /&gt;*&lt;br /&gt;* UBI - Unsorted block images&lt;br /&gt;*&lt;br /&gt;Enable UBI (MTD_UBI) [N/m/y/?] (NEW)&lt;br /&gt;&lt;/pre&gt; &lt;p&gt;Answer "n" on "Enable UBI (MTD_UBI) [N/m/y/?] (NEW)" &lt;/p&gt;&lt;p&gt;&lt;br /&gt;&lt;/p&gt; &lt;pre&gt;*&lt;br /&gt;* Parallel port support&lt;br /&gt;*&lt;br /&gt;Parallel port support (PARPORT) [N/m/y/?] n&lt;br /&gt;*&lt;br /&gt;* Block devices&lt;br /&gt;*&lt;br /&gt;Block devices (BLK_DEV) [Y/n/?] (NEW)&lt;br /&gt;&lt;/pre&gt; &lt;p&gt;Answer "y" on "Block devices (BLK_DEV) [Y/n/?] (NEW)" &lt;/p&gt;&lt;p&gt;&lt;br /&gt;&lt;/p&gt; &lt;pre&gt;  Compaq SMART2 support (BLK_CPQ_DA) [N/m/y/?] n&lt;br /&gt; Compaq Smart Array 5xxx support (BLK_CPQ_CISS_DA) [N/m/y/?] n&lt;br /&gt; Mylex DAC960/DAC1100 PCI RAID Controller support (BLK_DEV_DAC960) [N/m/y/?] n&lt;br /&gt; Micro Memory MM5415 Battery Backed RAM support (EXPERIMENTAL) (BLK_DEV_UMEM) [N/m/y/?] n&lt;br /&gt; Loopback device support (BLK_DEV_LOOP) [M/n/y/?] m&lt;br /&gt;   Cryptoloop Support (BLK_DEV_CRYPTOLOOP) [M/n/?] m&lt;br /&gt; Network block device support (BLK_DEV_NBD) [M/n/y/?] m&lt;br /&gt; Promise SATA SX8 support (BLK_DEV_SX8) [N/m/y/?] n&lt;br /&gt; Low Performance USB Block driver (BLK_DEV_UB) [N/m/y/?] n&lt;br /&gt; RAM disk support (BLK_DEV_RAM) [N/m/y/?] n&lt;br /&gt; Packet writing on CD/DVD media (CDROM_PKTCDVD) [N/m/y/?] n&lt;br /&gt; ATA over Ethernet support (ATA_OVER_ETH) [N/m/y/?] n&lt;br /&gt;*&lt;br /&gt;* Misc devices&lt;br /&gt;*&lt;br /&gt;Misc devices (MISC_DEVICES) [Y/n/?] (NEW)&lt;br /&gt;&lt;/pre&gt; &lt;p&gt;Answer "y" on "Misc devices (MISC_DEVICES) [Y/n/?] (NEW)"&lt;br /&gt;Answer "n" on "Sensable PHANToM (PHANTOM) [N/m/y/?] (NEW)"&lt;br /&gt;Answer "n" on "EEPROM 93CX6 support (EEPROM_93CX6) [N/m/y/?] (NEW)"&lt;br /&gt;&lt;/p&gt;&lt;p&gt;&lt;br /&gt;&lt;/p&gt; &lt;pre&gt;SGI IOC4 Base IO support (SGI_IOC4) [N/m/y/?] n&lt;br /&gt; TI Flash Media interface support (EXPERIMENTAL) (TIFM_CORE) [N/m/y/?] n&lt;br /&gt;*&lt;br /&gt;* ATA/ATAPI/MFM/RLL support&lt;br /&gt;*&lt;br /&gt;ATA/ATAPI/MFM/RLL support (IDE) [N/m/y/?] n&lt;br /&gt;*&lt;br /&gt;* SCSI device support&lt;br /&gt;*&lt;br /&gt;RAID Transport Class (RAID_ATTRS) [N/m/y/?] n&lt;br /&gt;SCSI device support (SCSI) [Y/n/m/?] y&lt;br /&gt;SCSI target support (SCSI_TGT) [N/m/y/?] (NEW)&lt;br /&gt;&lt;/pre&gt; &lt;p&gt;Answer "m" on "SCSI target support (SCSI_TGT) [N/m/y/?] (NEW)"&lt;br /&gt;Answer "n" on "Asynchronous SCSI scanning (SCSI_SCAN_ASYNC) [N/y/?] (NEW)"&lt;br /&gt;Answer "y" on "SCSI low-level drivers (SCSI_LOWLEVEL) [Y/n] (NEW)"&lt;br /&gt;Answer "n" on "SCSI RDMA Protocol helper library (SCSI_SRP) [N/m/y/?] (NEW)"&lt;br /&gt;&lt;/p&gt;&lt;p&gt;&lt;br /&gt;&lt;/p&gt; &lt;pre&gt;*&lt;br /&gt;* Serial ATA (prod) and Parallel ATA (experimental) drivers&lt;br /&gt;*&lt;br /&gt;Serial ATA (prod) and Parallel ATA (experimental) drivers (ATA) [N/m/y/?] n&lt;br /&gt;*&lt;br /&gt;* Multiple devices driver support (RAID and LVM)&lt;br /&gt;*&lt;br /&gt;Multiple devices driver support (RAID and LVM) (MD) [N/y/?] n&lt;br /&gt;*&lt;br /&gt;* Fusion MPT device support&lt;br /&gt;*&lt;br /&gt;Fusion MPT ScsiHost drivers for SPI (FUSION_SPI) [N/m/y/?] n&lt;br /&gt;Fusion MPT ScsiHost drivers for FC (FUSION_FC) [N/m/y/?] n&lt;br /&gt;Fusion MPT ScsiHost drivers for SAS (FUSION_SAS) [N/m/y/?] n&lt;br /&gt;*&lt;br /&gt;* IEEE 1394 (FireWire) support&lt;br /&gt;*&lt;br /&gt;IEEE 1394 (FireWire) support - alternative stack, EXPERIMENTAL (FIREWIRE) [N/m/y/?] (NEW)&lt;br /&gt;&lt;/pre&gt; &lt;p&gt;Answer "n" on "IEEE 1394 (FireWire) support - alternative stack, EXPERIMENTAL (FIREWIRE) [N/m/y/?] (NEW)" &lt;/p&gt;&lt;p&gt;&lt;br /&gt;&lt;/p&gt; &lt;pre&gt;*&lt;br /&gt;* I2O device support&lt;br /&gt;*&lt;br /&gt;I2O device support (I2O) [N/m/y/?] n&lt;br /&gt;*&lt;br /&gt;* Network device support&lt;br /&gt;*&lt;br /&gt;Network device support (NETDEVICES) [Y/n/?] y&lt;br /&gt; Netdevice multiple hardware queue support (NETDEVICES_MULTIQUEUE) [N/y/?] (NEW)&lt;br /&gt;&lt;/pre&gt; &lt;p&gt;Answer "n" on "Netdevice multiple hardware queue support (NETDEVICES_MULTIQUEUE) [N/y/?] (NEW)"&lt;br /&gt;Answer "n" on "Intermediate Functional Block support (IFB) [N/m/y/?] (NEW)"&lt;br /&gt;Answer "n" on "MAC-VLAN support (EXPERIMENTAL) (MACVLAN) [N/m/y/?] (NEW)"&lt;br /&gt;&lt;/p&gt;&lt;p&gt;&lt;br /&gt;&lt;/p&gt; &lt;pre&gt;EQL (serial line load balancing) support (EQUALIZER) [N/m/y/?] n&lt;br /&gt; IMQ (intermediate queueing device) support (IMQ) [M/n/y/?] m&lt;br /&gt;   IMQ behavior (PRE/POSTROUTING)&lt;br /&gt;     1. IMQ AA (IMQ_BEHAVIOR_AA)&lt;br /&gt;     2. IMQ AB (IMQ_BEHAVIOR_AB)&lt;br /&gt;   &gt; 3. IMQ BA (IMQ_BEHAVIOR_BA)&lt;br /&gt;     4. IMQ BB (IMQ_BEHAVIOR_BB)&lt;br /&gt;   choice[1-4?]: 3&lt;br /&gt;   Number of IMQ devices (IMQ_NUM_DEVS) [2] 2&lt;br /&gt; Universal TUN/TAP device driver support (TUN) [M/n/y/?] m&lt;br /&gt; *&lt;br /&gt; * ARCnet support&lt;br /&gt; *&lt;br /&gt; ARCnet support (ARCNET) [N/m/y/?] n&lt;br /&gt; *&lt;br /&gt; * PHY Device support and infrastructure&lt;br /&gt; *&lt;br /&gt; PHY Device support and infrastructure (PHYLIB) [N/m/y/?] n&lt;br /&gt; *&lt;br /&gt; * Ethernet (10 or 100Mbit)&lt;br /&gt; *&lt;br /&gt; Ethernet (10 or 100Mbit) (NET_ETHERNET) [Y/n/?] y&lt;br /&gt;   Generic Media Independent Interface device support (MII) [Y/?] y&lt;br /&gt;   ASIX AX88796 NE2000 clone support (AX88796) [N/m/y/?] (NEW)&lt;br /&gt;&lt;/pre&gt; &lt;p&gt;Answer "n" on "ASIX AX88796 NE2000 clone support (AX88796) [N/m/y/?] (NEW)"&lt;br /&gt;Answer "n" on "TOSHIBA TC35815 Ethernet support (TC35815) [N/m/y] (NEW)"&lt;br /&gt;Answer "n" on "Silan SC92031 PCI Fast Ethernet Adapter driver (EXPERIMENTAL) (SC92031) [N/m/y/?] (NEW)"&lt;br /&gt;&lt;/p&gt;&lt;p&gt;&lt;br /&gt;&lt;/p&gt; &lt;pre&gt;*&lt;br /&gt;* Ethernet (1000 Mbit)&lt;br /&gt;*&lt;br /&gt;Ethernet (1000 Mbit) (NETDEV_1000) [Y/n/?] (NEW)&lt;br /&gt;&lt;/pre&gt; &lt;p&gt;Answer "n" on "Ethernet (1000 Mbit) (NETDEV_1000) [Y/n/?] (NEW)" Answer "n" on "Ethernet (10000 Mbit) (NETDEV_10000) [Y/n/?] (NEW)" &lt;/p&gt;&lt;p&gt;&lt;br /&gt;&lt;/p&gt; &lt;pre&gt;*&lt;br /&gt;* Ethernet (10000 Mbit)&lt;br /&gt;*&lt;br /&gt;Ethernet (10000 Mbit) (NETDEV_10000) [Y/n/?] (NEW) n&lt;br /&gt;*&lt;br /&gt;* Token Ring driver support&lt;br /&gt;*&lt;br /&gt;Token Ring driver support (TR) [N/y/?] n&lt;br /&gt;*&lt;br /&gt;* Wireless LAN&lt;br /&gt;*&lt;br /&gt;Wireless LAN (pre-802.11) (WLAN_PRE80211) [N/y/?] (NEW)&lt;br /&gt;&lt;/pre&gt; &lt;p&gt;Answer "y" on "Wireless LAN (pre-802.11) (WLAN_PRE80211) [N/y/?] (NEW)"&lt;br /&gt;Answer "n" on "Wireless LAN (IEEE 802.11) (WLAN_80211) [N/y/?] (NEW)"&lt;br /&gt;&lt;/p&gt; &lt;pre&gt;*&lt;br /&gt;* USB Network Adapters&lt;br /&gt;*&lt;br /&gt;USB CATC NetMate-based Ethernet device support (EXPERIMENTAL) (USB_CATC) [N/m/y/?] n&lt;br /&gt;USB KLSI KL5USB101-based ethernet device support (USB_KAWETH) [N/m/y/?] n&lt;br /&gt;USB Pegasus/Pegasus-II based ethernet device support (USB_PEGASUS) [N/m/y/?] n&lt;br /&gt;USB RTL8150 based ethernet device support (EXPERIMENTAL) (USB_RTL8150) [N/m/y/?] n&lt;br /&gt;Multi-purpose USB Networking Framework (USB_USBNET) [N/m/y/?] n&lt;br /&gt;*&lt;br /&gt;* Wan interfaces support&lt;br /&gt;*&lt;br /&gt;Wan interfaces support (WAN) [N/y/?] n&lt;br /&gt;*&lt;br /&gt;* ATM drivers&lt;br /&gt;*&lt;br /&gt;ATM drivers (ATM_DRIVERS) [Y/n/?] (NEW)&lt;br /&gt;&lt;/pre&gt; &lt;p&gt;Answer "n" on "ATM drivers (ATM_DRIVERS) [Y/n/?] (NEW)"&lt;br /&gt;Answer "n" on "PPP over L2TP (EXPERIMENTAL) (PPPOL2TP) [N/m/?] (NEW)"&lt;br /&gt;&lt;/p&gt; &lt;pre&gt;  SLIP (serial line) support (SLIP) [N/m/y/?] n&lt;br /&gt; Fibre Channel driver support (NET_FC) [N/y/?] n&lt;br /&gt; Traffic Shaper (OBSOLETE) (SHAPER) [N/m/y/?] n&lt;br /&gt; Network console logging support (EXPERIMENTAL) (NETCONSOLE) [N/m/y/?] n&lt;br /&gt;*&lt;br /&gt;* ISDN support&lt;br /&gt;*&lt;br /&gt;ISDN support (ISDN) [N/m/y/?] n&lt;br /&gt;*&lt;br /&gt;* Telephony support&lt;br /&gt;*&lt;br /&gt;Telephony support (PHONE) [N/m/y/?] n&lt;br /&gt;*&lt;br /&gt;* Input device support&lt;br /&gt;*&lt;br /&gt;Generic input layer (needed for keyboard, mouse, ...) (INPUT) [N/m/y/?] n&lt;br /&gt;*&lt;br /&gt;* Hardware I/O ports&lt;br /&gt;*&lt;br /&gt;Serial I/O support (SERIO) [N/m/y/?] n&lt;br /&gt;Gameport support (GAMEPORT) [N/m/y/?] n&lt;br /&gt;*&lt;br /&gt;* Character devices&lt;br /&gt;*&lt;br /&gt;Virtual terminal (VT) [N/y/?] n&lt;br /&gt;Non-standard serial port support (SERIAL_NONSTANDARD) [N/y/?] n&lt;br /&gt;*&lt;br /&gt;* Serial drivers&lt;br /&gt;*&lt;br /&gt;8250/16550 and compatible serial support (SERIAL_8250) [Y/n/m/?] y&lt;br /&gt; Console on 8250/16550 and compatible serial port (SERIAL_8250_CONSOLE) [Y/n/?] y&lt;br /&gt;8250/16550 PCI device support (SERIAL_8250_PCI) [N/m/y/?] n&lt;br /&gt;Maximum number of 8250/16550 serial ports (SERIAL_8250_NR_UARTS) [2] 2&lt;br /&gt;Number of 8250/16550 serial ports to register at runtime (SERIAL_8250_RUNTIME_UARTS) [2] 2&lt;br /&gt;Extended 8250/16550 serial driver options (SERIAL_8250_EXTENDED) [Y/n/?] y&lt;br /&gt; Support more than 4 legacy serial ports (SERIAL_8250_MANY_PORTS) [N/y/?] n&lt;br /&gt; Support for sharing serial interrupts (SERIAL_8250_SHARE_IRQ) [Y/n/?] y&lt;br /&gt; Autodetect IRQ on standard ports (unsafe) (SERIAL_8250_DETECT_IRQ) [N/y/?] n&lt;br /&gt; Support RSA serial ports (SERIAL_8250_RSA) [N/y/?] n&lt;br /&gt;*&lt;br /&gt;* Non-8250 serial port support&lt;br /&gt;*&lt;br /&gt;Digi International NEO PCI Support (SERIAL_JSM) [N/m/y/?] n&lt;br /&gt;Unix98 PTY support (UNIX98_PTYS) [Y/n/?] y&lt;br /&gt;Legacy (BSD) PTY support (LEGACY_PTYS) [N/y/?] n&lt;br /&gt;*&lt;br /&gt;* IPMI top-level message handler&lt;br /&gt;*&lt;br /&gt;IPMI top-level message handler (IPMI_HANDLER) [N/m/y/?] n&lt;br /&gt;*&lt;br /&gt;* Watchdog Timer Support&lt;br /&gt;*&lt;br /&gt;Watchdog Timer Support (WATCHDOG) [N/y/?] n&lt;br /&gt;Hardware Random Number Generator Core support (HW_RANDOM) [Y/n/m/?] y&lt;br /&gt;Enhanced Real Time Clock Support (RTC) [N/m/y/?] n&lt;br /&gt;Siemens R3964 line discipline (R3964) [N/m/y/?] n&lt;br /&gt;Applicom intelligent fieldbus card support (APPLICOM) [N/m/y/?] n&lt;br /&gt;Direct Rendering Manager (XFree86 4.1.0 and higher DRI support) (DRM) [N/m/y/?] n&lt;br /&gt;RAW driver (/dev/raw/rawN) (RAW_DRIVER) [N/m/y/?] n&lt;br /&gt;*&lt;br /&gt;* TPM Hardware Support&lt;br /&gt;*&lt;br /&gt;TPM Hardware Support (TCG_TPM) [N/m/y/?] n&lt;br /&gt;*&lt;br /&gt;* I2C support&lt;br /&gt;*&lt;br /&gt;I2C support (I2C) [N/m/y/?] n&lt;br /&gt;*&lt;br /&gt;* SPI support&lt;br /&gt;*&lt;br /&gt;SPI support (SPI) [N/y/?] n&lt;br /&gt;*&lt;br /&gt;* PPS support&lt;br /&gt;*&lt;br /&gt;PPS support (PPS) [N/m/y/?] (NEW)&lt;br /&gt;&lt;/pre&gt; &lt;p&gt;Answer "n" on "PPS support (PPS) [N/m/y/?] (NEW)" &lt;/p&gt;&lt;p&gt;&lt;br /&gt;&lt;/p&gt; &lt;pre&gt;*&lt;br /&gt;* Dallas's 1-wire support&lt;br /&gt;*&lt;br /&gt;Dallas's 1-wire support (W1) [N/m/y/?] n&lt;br /&gt;*&lt;br /&gt;* Power supply class support&lt;br /&gt;*&lt;br /&gt;Power supply class support (POWER_SUPPLY) [N/m/y/?] (NEW)&lt;br /&gt;&lt;/pre&gt; &lt;p&gt;Answer "n" on "Power supply class support (POWER_SUPPLY) [N/m/y/?] (NEW)" &lt;/p&gt;&lt;p&gt;&lt;br /&gt;&lt;/p&gt; &lt;pre&gt;*&lt;br /&gt;* Hardware Monitoring support&lt;br /&gt;*&lt;br /&gt;Hardware Monitoring support (HWMON) [N/m/y/?] n&lt;br /&gt;*&lt;br /&gt;* Sonics Silicon Backplane&lt;br /&gt;*&lt;br /&gt;Sonics Silicon Backplane support (SSB) [Y/?] y&lt;br /&gt; Support for SSB on PCI-bus host (SSB_PCIHOST) [N/y/?] n&lt;br /&gt; No SSB kernel messages (SSB_SILENT) [N/y/?] n&lt;br /&gt; SSB debugging (SSB_DEBUG) [N/y/?] n&lt;br /&gt;SSB Broadcom MIPS core driver (EXPERIMENTAL) (SSB_DRIVER_MIPS) [N/y/?] (NEW)&lt;br /&gt;&lt;/pre&gt; &lt;p&gt;Answer "n" on "SSB Broadcom MIPS core driver (EXPERIMENTAL) (SSB_DRIVER_MIPS) [N/y/?] (NEW)" &lt;/p&gt;&lt;p&gt;&lt;br /&gt;&lt;/p&gt; &lt;pre&gt;*&lt;br /&gt;* Multifunction device drivers&lt;br /&gt;*&lt;br /&gt;Support for Silicon Motion SM501 (MFD_SM501) [N/m/y/?] (NEW)&lt;br /&gt;&lt;/pre&gt; &lt;p&gt;Answer "n" on "Support for Silicon Motion SM501 (MFD_SM501) [N/m/y/?] (NEW)" &lt;/p&gt;&lt;p&gt;&lt;br /&gt;&lt;/p&gt; &lt;pre&gt;*&lt;br /&gt;* Multimedia devices&lt;br /&gt;*&lt;br /&gt;Video For Linux (VIDEO_DEV) [N/m/y/?] n&lt;br /&gt;DVB for Linux (DVB_CORE) [N/m/y/?] (NEW)&lt;br /&gt;&lt;/pre&gt; &lt;p&gt;Answer "n" on "DVB for Linux (DVB_CORE) [N/m/y/?] (NEW)"&lt;br /&gt;Answer "n" on "DAB adapters (DAB) [Y/n/?] (NEW)"&lt;br /&gt;&lt;/p&gt;&lt;p&gt;&lt;br /&gt;&lt;/p&gt; &lt;pre&gt;*&lt;br /&gt;* Graphics support&lt;br /&gt;*&lt;br /&gt;*&lt;br /&gt;* Backlight &amp;amp; LCD device support&lt;br /&gt;*&lt;br /&gt;Backlight &amp;amp; LCD device support (BACKLIGHT_LCD_SUPPORT) [N/y/?] n&lt;br /&gt;*&lt;br /&gt;* Display device support&lt;br /&gt;*&lt;br /&gt;Display panel/monitor support (DISPLAY_SUPPORT) [N/m/y/?] (NEW)&lt;br /&gt;&lt;/pre&gt; &lt;p&gt;Answer "n" on "Display panel/monitor support (DISPLAY_SUPPORT) [N/m/y/?] (NEW)"&lt;br /&gt;Answer "n" on "Lowlevel video output switch controls (VIDEO_OUTPUT_CONTROL) [M/n/y/?] (NEW)"&lt;br /&gt;&lt;/p&gt;&lt;p&gt;&lt;br /&gt;&lt;/p&gt; &lt;pre&gt;Support for frame buffer devices (FB) [N/m/y/?] n&lt;br /&gt;*&lt;br /&gt;* Sound&lt;br /&gt;*&lt;br /&gt;Sound card support (SOUND) [N/m/y/?] n&lt;br /&gt;*&lt;br /&gt;* USB support&lt;br /&gt;*&lt;br /&gt;USB support (USB_SUPPORT) [Y/n/?] (NEW)&lt;br /&gt;&lt;/pre&gt; &lt;p&gt;Answer "y" on "USB support (USB_SUPPORT) [Y/n/?] (NEW)"&lt;br /&gt;Answer "y" on "USB device class-devices (DEPRECATED) (USB_DEVICE_CLASS) [Y/n/?] (NEW)"&lt;br /&gt;Answer "n" on "USB selective suspend/resume and wakeup (EXPERIMENTAL) (USB_SUSPEND) [N/y/?] (NEW)"&lt;br /&gt;Answer "n" on "USB device persistence during system suspend (DANGEROUS) (USB_PERSIST) [N/y/?] (NEW)"&lt;br /&gt;Answer "n" on "OHCI support for Broadcom SSB OHCI core (USB_OHCI_HCD_SSB) [N/y/?] (NEW)"&lt;br /&gt;Answer "n" on "R8A66597 HCD support (USB_R8A66597_HCD) [N/m/y/?] (NEW)"&lt;br /&gt;Answer "m" on "USB Ours Technology Inc. OTi-6858 USB To RS232 Bridge Controller (EXPERIMENTAL) (USB_SERIAL_OTI6858) [N/m/?] (NEW)"&lt;br /&gt;Answer "n" on "USB Debugging Device (USB_SERIAL_DEBUG) [N/m/?] (NEW)"&lt;br /&gt;Answer "n" on "USB BlackBerry recharge support (USB_BERRY_CHARGE) [N/m/y/?] (NEW)"&lt;br /&gt;Answer "n" on "IO Warrior driver support (USB_IOWARRIOR) [N/m/y/?] (NEW)"&lt;br /&gt;&lt;/p&gt;&lt;p&gt;&lt;br /&gt;&lt;/p&gt; &lt;pre&gt;USB testing driver (DEVELOPMENT) (USB_TEST) [N/m/y/?] n&lt;br /&gt;*&lt;br /&gt;* USB DSL modem support&lt;br /&gt;*&lt;br /&gt;USB DSL modem support (USB_ATM) [M/n/?] m&lt;br /&gt;  Speedtouch USB support (USB_SPEEDTOUCH) [M/n/?] m&lt;br /&gt;  Conexant AccessRunner USB support (USB_CXACRU) [M/n/?] m&lt;br /&gt;  ADI 930 and eagle USB DSL modem (USB_UEAGLEATM) [M/n/?] m&lt;br /&gt;  Other USB DSL modem support (USB_XUSBATM) [M/n/?] m&lt;br /&gt;*&lt;br /&gt;* USB Gadget Support&lt;br /&gt;*&lt;br /&gt;Support for USB Gadgets (USB_GADGET) [N/m/y/?] n&lt;br /&gt;*&lt;br /&gt;* MMC/SD card support&lt;br /&gt;*&lt;br /&gt;MMC/SD card support (MMC) [N/m/y/?] n&lt;br /&gt;*&lt;br /&gt;* LED Support&lt;br /&gt;*&lt;br /&gt;LED Support (NEW_LEDS) [N/y/?] n&lt;br /&gt;*&lt;br /&gt;* GPIO Support&lt;br /&gt;*&lt;br /&gt;GPIO Support (NEW_GPIO) [N/y/?] (NEW)&lt;br /&gt;&lt;/pre&gt; &lt;p&gt;Answer "n" on "GPIO Support (NEW_GPIO) [N/y/?] (NEW)" &lt;/p&gt;&lt;p&gt;&lt;br /&gt;&lt;/p&gt; &lt;pre&gt;*&lt;br /&gt;* InfiniBand support&lt;br /&gt;*&lt;br /&gt;InfiniBand support (INFINIBAND) [N/m/y/?] n&lt;br /&gt;*&lt;br /&gt;* Real Time Clock&lt;br /&gt;*&lt;br /&gt;Real Time Clock (RTC_CLASS) [N/m/y/?] n&lt;br /&gt;*&lt;br /&gt;* DMA Engine support&lt;br /&gt;*&lt;br /&gt;Support for DMA engines (DMA_ENGINE) [N/y/?] n&lt;br /&gt;*&lt;br /&gt;* DMA Clients&lt;br /&gt;*&lt;br /&gt;*&lt;br /&gt;* DMA Devices&lt;br /&gt;*&lt;br /&gt;*&lt;br /&gt;* Userspace I/O&lt;br /&gt;*&lt;br /&gt;Userspace I/O drivers (UIO) [N/m/y/?] (NEW)&lt;br /&gt;&lt;/pre&gt; &lt;p&gt;Answer "n" on "Userspace I/O drivers (UIO) [N/m/y/?] (NEW)" &lt;/p&gt;&lt;p&gt;&lt;br /&gt;&lt;/p&gt; &lt;pre&gt;*&lt;br /&gt;* File systems&lt;br /&gt;*&lt;br /&gt;Second extended fs support (EXT2_FS) [N/m/y/?] n&lt;br /&gt;Ext3 journalling file system support (EXT3_FS) [Y/n/m/?] y&lt;br /&gt; Ext3 extended attributes (EXT3_FS_XATTR) [N/y/?] n&lt;br /&gt;Ext4dev/ext4 extended fs support development (EXPERIMENTAL) (EXT4DEV_FS) [N/m/y/?] n&lt;br /&gt;JBD (ext3) debugging support (JBD_DEBUG) [N/y/?] n&lt;br /&gt;Reiserfs support (REISERFS_FS) [N/m/y/?] n&lt;br /&gt;JFS filesystem support (JFS_FS) [N/m/y/?] n&lt;br /&gt;XFS filesystem support (XFS_FS) [N/m/y/?] n&lt;br /&gt;GFS2 file system support (GFS2_FS) [N/m/y/?] n&lt;br /&gt;YAFFS2 file system support (YAFFS_FS) [N/m/y/?] n&lt;br /&gt;OCFS2 file system support (OCFS2_FS) [N/m/y/?] n&lt;br /&gt;Mini fanout overlay filesystem (MINI_FO) [N/m/y] n&lt;br /&gt;Minix fs support (MINIX_FS) [N/m/y/?] n&lt;br /&gt;ROM file system support (ROMFS_FS) [N/m/y/?] n&lt;br /&gt;Inotify file change notification support (INOTIFY) [Y/n/?] y&lt;br /&gt; Inotify support for userspace (INOTIFY_USER) [Y/n/?] y&lt;br /&gt;Quota support (QUOTA) [N/y/?] n&lt;br /&gt;Dnotify support (DNOTIFY) [N/y/?] n&lt;br /&gt;Kernel automounter support (AUTOFS_FS) [N/m/y/?] n&lt;br /&gt;Kernel automounter version 4 support (also supports v3) (AUTOFS4_FS) [N/m/y/?] n&lt;br /&gt;Filesystem in Userspace support (FUSE_FS) [N/m/y/?] n&lt;br /&gt;*&lt;br /&gt;* CD-ROM/DVD Filesystems&lt;br /&gt;*&lt;br /&gt;ISO 9660 CDROM file system support (ISO9660_FS) [N/m/y/?] n&lt;br /&gt;UDF file system support (UDF_FS) [N/m/y/?] n&lt;br /&gt;*&lt;br /&gt;* DOS/FAT/NT Filesystems&lt;br /&gt;*&lt;br /&gt;MSDOS fs support (MSDOS_FS) [N/m/y/?] n&lt;br /&gt;VFAT (Windows-95) fs support (VFAT_FS) [N/m/y/?] n&lt;br /&gt;NTFS file system support (NTFS_FS) [N/m/y/?] n&lt;br /&gt;*&lt;br /&gt;* Pseudo filesystems&lt;br /&gt;*&lt;br /&gt;/proc file system support (PROC_FS) [Y/n/?] y&lt;br /&gt; /proc/kcore support (PROC_KCORE) [N/y] n&lt;br /&gt; Sysctl support (/proc/sys) (PROC_SYSCTL) [Y/n/?] y&lt;br /&gt;sysfs file system support (SYSFS) [Y/n/?] y&lt;br /&gt;Virtual memory file system support (former shm fs) (TMPFS) [Y/n/?] y&lt;br /&gt; Tmpfs POSIX Access Control Lists (TMPFS_POSIX_ACL) [N/y/?] n&lt;br /&gt;Userspace-driven configuration filesystem (EXPERIMENTAL) (CONFIGFS_FS) [N/m/y/?] n&lt;br /&gt;*&lt;br /&gt;* Miscellaneous filesystems&lt;br /&gt;*&lt;br /&gt;ADFS file system support (EXPERIMENTAL) (ADFS_FS) [N/m/y/?] n&lt;br /&gt;Amiga FFS file system support (EXPERIMENTAL) (AFFS_FS) [N/m/y/?] n&lt;br /&gt;Apple Macintosh file system support (EXPERIMENTAL) (HFS_FS) [N/m/y/?] n&lt;br /&gt;Apple Extended HFS file system support (HFSPLUS_FS) [N/m/y/?] n&lt;br /&gt;BeOS file system (BeFS) support (read only) (EXPERIMENTAL) (BEFS_FS) [N/m/y/?] n&lt;br /&gt;BFS file system support (EXPERIMENTAL) (BFS_FS) [N/m/y/?] n&lt;br /&gt;EFS file system support (read only) (EXPERIMENTAL) (EFS_FS) [N/m/y/?] n&lt;br /&gt;Journalling Flash File System v2 (JFFS2) support (JFFS2_FS) [Y/n/m/?] y&lt;br /&gt; JFFS2 debugging verbosity (0 = quiet, 2 = noisy) (JFFS2_FS_DEBUG) [0] 0&lt;br /&gt; JFFS2 write-buffering support (JFFS2_FS_WRITEBUFFER) [Y/n/?] y&lt;br /&gt; JFFS2 summary support (EXPERIMENTAL) (JFFS2_SUMMARY) [N/y/?] n&lt;br /&gt; JFFS2 XATTR support (EXPERIMENTAL) (JFFS2_FS_XATTR) [N/y/?] n&lt;br /&gt; Advanced compression options for JFFS2 (JFFS2_COMPRESSION_OPTIONS) [Y/n/?] y&lt;br /&gt;   JFFS2 ZLIB compression support (JFFS2_ZLIB) [Y/n/?] y&lt;br /&gt;   JFFS2 RTIME compression support (JFFS2_RTIME) [Y/n/?] y&lt;br /&gt;   JFFS2 RUBIN compression support (JFFS2_RUBIN) [N/y/?] n&lt;br /&gt;   JFFS2 default compression mode&lt;br /&gt;     1. no compression (JFFS2_CMODE_NONE)&lt;br /&gt;   &gt; 2. priority (JFFS2_CMODE_PRIORITY)&lt;br /&gt;     3. size (EXPERIMENTAL) (JFFS2_CMODE_SIZE)&lt;br /&gt;   choice[1-3?]: 2&lt;br /&gt;Compressed ROM file system support (cramfs) (CRAMFS) [N/m/y/?] n&lt;br /&gt;SquashFS 3.0 - Squashed file system support (SQUASHFS) [N/m/y/?] n&lt;br /&gt;FreeVxFS file system support (VERITAS VxFS(TM) compatible) (VXFS_FS) [N/m/y/?] n&lt;br /&gt;OS/2 HPFS file system support (HPFS_FS) [N/m/y/?] n&lt;br /&gt;QNX4 file system support (read only) (QNX4FS_FS) [N/m/y/?] n&lt;br /&gt;System V/Xenix/V7/Coherent file system support (SYSV_FS) [N/m/y/?] n&lt;br /&gt;UFS file system support (read only) (UFS_FS) [N/m/y/?] n&lt;br /&gt;*&lt;br /&gt;* Network File Systems&lt;br /&gt;*&lt;br /&gt;NFS file system support (NFS_FS) [N/m/y/?] n&lt;br /&gt;NFS server support (NFSD) [N/m/y/?] n&lt;br /&gt;SMB file system support (to mount Windows shares etc.) (SMB_FS) [N/m/y/?] n&lt;br /&gt;CIFS support (advanced network filesystem for Samba, Window and other CIFS compliant servers) (CIFS) [M/n/y/?] m&lt;br /&gt; CIFS statistics (CIFS_STATS) [N/y/?] n&lt;br /&gt; Support legacy servers which use weaker LANMAN security (CIFS_WEAK_PW_HASH) [N/y/?] n&lt;br /&gt; CIFS extended attributes (CIFS_XATTR) [N/y/?] n&lt;br /&gt; Enable additional CIFS debugging routines (CIFS_DEBUG2) [N/y/?] n&lt;br /&gt; CIFS Experimental Features (EXPERIMENTAL) (CIFS_EXPERIMENTAL) [N/y/?] n&lt;br /&gt;NCP file system support (to mount NetWare volumes) (NCP_FS) [N/m/y/?] n&lt;br /&gt;Coda file system support (advanced network fs) (CODA_FS) [N/m/y/?] n&lt;br /&gt;Andrew File System support (AFS) (EXPERIMENTAL) (AFS_FS) [N/m/y/?] n&lt;br /&gt;*&lt;br /&gt;* Partition Types&lt;br /&gt;*&lt;br /&gt;Advanced partition selection (PARTITION_ADVANCED) [Y/n/?] y&lt;br /&gt; Acorn partition support (ACORN_PARTITION) [N/y/?] n&lt;br /&gt; Alpha OSF partition support (OSF_PARTITION) [N/y/?] n&lt;br /&gt; Amiga partition table support (AMIGA_PARTITION) [N/y/?] n&lt;br /&gt; Atari partition table support (ATARI_PARTITION) [N/y/?] n&lt;br /&gt; Macintosh partition map support (MAC_PARTITION) [N/y/?] n&lt;br /&gt; PC BIOS (MSDOS partition tables) support (MSDOS_PARTITION) [Y/n/?] y&lt;br /&gt;   BSD disklabel (FreeBSD partition tables) support (BSD_DISKLABEL) [N/y/?] n&lt;br /&gt;   Minix subpartition support (MINIX_SUBPARTITION) [N/y/?] n&lt;br /&gt;   Solaris (x86) partition table support (SOLARIS_X86_PARTITION) [N/y/?] n&lt;br /&gt;   Unixware slices support (UNIXWARE_DISKLABEL) [N/y/?] n&lt;br /&gt; Windows Logical Disk Manager (Dynamic Disk) support (LDM_PARTITION) [N/y/?] n&lt;br /&gt; SGI partition support (SGI_PARTITION) [N/y/?] n&lt;br /&gt; Ultrix partition table support (ULTRIX_PARTITION) [N/y/?] n&lt;br /&gt; Sun partition tables support (SUN_PARTITION) [N/y/?] n&lt;br /&gt; Karma Partition support (KARMA_PARTITION) [N/y/?] n&lt;br /&gt; EFI GUID Partition support (EFI_PARTITION) [N/y/?] n&lt;br /&gt; SYSV68 partition table support (SYSV68_PARTITION) [N/y/?] (NEW)&lt;br /&gt;&lt;/pre&gt; &lt;p&gt;Answer "n" on "SYSV68 partition table support (SYSV68_PARTITION) [N/y/?] (NEW)" &lt;/p&gt;&lt;p&gt;&lt;br /&gt;&lt;/p&gt; &lt;pre&gt;*&lt;br /&gt;* Native Language Support&lt;br /&gt;*&lt;br /&gt;Base native language support (NLS) [M/y/?] m&lt;br /&gt; Default NLS Option (NLS_DEFAULT) [iso8859-1] iso8859-1&lt;br /&gt; Codepage 437 (United States, Canada) (NLS_CODEPAGE_437) [N/m/?] n&lt;br /&gt; Codepage 737 (Greek) (NLS_CODEPAGE_737) [N/m/?] n&lt;br /&gt; Codepage 775 (Baltic Rim) (NLS_CODEPAGE_775) [N/m/?] n&lt;br /&gt; Codepage 850 (Europe) (NLS_CODEPAGE_850) [N/m/?] n&lt;br /&gt; Codepage 852 (Central/Eastern Europe) (NLS_CODEPAGE_852) [N/m/?] n&lt;br /&gt; Codepage 855 (Cyrillic) (NLS_CODEPAGE_855) [N/m/?] n&lt;br /&gt; Codepage 857 (Turkish) (NLS_CODEPAGE_857) [N/m/?] n&lt;br /&gt; Codepage 860 (Portuguese) (NLS_CODEPAGE_860) [N/m/?] n&lt;br /&gt; Codepage 861 (Icelandic) (NLS_CODEPAGE_861) [N/m/?] n&lt;br /&gt; Codepage 862 (Hebrew) (NLS_CODEPAGE_862) [N/m/?] n&lt;br /&gt; Codepage 863 (Canadian French) (NLS_CODEPAGE_863) [N/m/?] n&lt;br /&gt; Codepage 864 (Arabic) (NLS_CODEPAGE_864) [N/m/?] n&lt;br /&gt; Codepage 865 (Norwegian, Danish) (NLS_CODEPAGE_865) [N/m/?] n&lt;br /&gt; Codepage 866 (Cyrillic/Russian) (NLS_CODEPAGE_866) [N/m/?] n&lt;br /&gt; Codepage 869 (Greek) (NLS_CODEPAGE_869) [N/m/?] n&lt;br /&gt; Simplified Chinese charset (CP936, GB2312) (NLS_CODEPAGE_936) [N/m/?] n&lt;br /&gt; Traditional Chinese charset (Big5) (NLS_CODEPAGE_950) [N/m/?] n&lt;br /&gt; Japanese charsets (Shift-JIS, EUC-JP) (NLS_CODEPAGE_932) [N/m/?] n&lt;br /&gt; Korean charset (CP949, EUC-KR) (NLS_CODEPAGE_949) [N/m/?] n&lt;br /&gt; Thai charset (CP874, TIS-620) (NLS_CODEPAGE_874) [N/m/?] n&lt;br /&gt; Hebrew charsets (ISO-8859-8, CP1255) (NLS_ISO8859_8) [N/m/?] n&lt;br /&gt; Windows CP1250 (Slavic/Central European Languages) (NLS_CODEPAGE_1250) [N/m/?] n&lt;br /&gt; Windows CP1251 (Bulgarian, Belarusian) (NLS_CODEPAGE_1251) [N/m/?] n&lt;br /&gt; ASCII (United States) (NLS_ASCII) [N/m/?] n&lt;br /&gt; NLS ISO 8859-1  (Latin 1; Western European Languages) (NLS_ISO8859_1) [N/m/?] n&lt;br /&gt; NLS ISO 8859-2  (Latin 2; Slavic/Central European Languages) (NLS_ISO8859_2) [N/m/?] n&lt;br /&gt; NLS ISO 8859-3  (Latin 3; Esperanto, Galician, Maltese, Turkish) (NLS_ISO8859_3) [N/m/?] n&lt;br /&gt; NLS ISO 8859-4  (Latin 4; old Baltic charset) (NLS_ISO8859_4) [N/m/?] n&lt;br /&gt; NLS ISO 8859-5  (Cyrillic) (NLS_ISO8859_5) [N/m/?] n&lt;br /&gt; NLS ISO 8859-6  (Arabic) (NLS_ISO8859_6) [N/m/?] n&lt;br /&gt; NLS ISO 8859-7  (Modern Greek) (NLS_ISO8859_7) [N/m/?] n&lt;br /&gt; NLS ISO 8859-9  (Latin 5; Turkish) (NLS_ISO8859_9) [N/m/?] n&lt;br /&gt; NLS ISO 8859-13 (Latin 7; Baltic) (NLS_ISO8859_13) [N/m/?] n&lt;br /&gt; NLS ISO 8859-14 (Latin 8; Celtic) (NLS_ISO8859_14) [N/m/?] n&lt;br /&gt; NLS ISO 8859-15 (Latin 9; Western European Languages with Euro) (NLS_ISO8859_15) [N/m/?] n&lt;br /&gt; NLS KOI8-R (Russian) (NLS_KOI8_R) [N/m/?] n&lt;br /&gt; NLS KOI8-U/RU (Ukrainian, Belarusian) (NLS_KOI8_U) [N/m/?] n&lt;br /&gt; NLS UTF-8 (NLS_UTF8) [N/m/?] n&lt;br /&gt;*&lt;br /&gt;* Distributed Lock Manager&lt;br /&gt;*&lt;br /&gt;Distributed Lock Manager (DLM) (DLM) [N/m/y/?] (NEW)&lt;br /&gt;&lt;/pre&gt; &lt;p&gt;Answer "n" on "Distributed Lock Manager (DLM) (DLM) [N/m/y/?] (NEW)" &lt;/p&gt;&lt;p&gt;&lt;br /&gt;&lt;/p&gt; &lt;pre&gt;*&lt;br /&gt;* Profiling support&lt;br /&gt;*&lt;br /&gt;Profiling support (EXPERIMENTAL) (PROFILING) [N/y/?] n&lt;br /&gt;*&lt;br /&gt;* Kernel hacking&lt;br /&gt;*&lt;br /&gt;Show timing information on printks (PRINTK_TIME) [N/y/?] n&lt;br /&gt;Enable __must_check logic (ENABLE_MUST_CHECK) [N/y/?] n&lt;br /&gt;Magic SysRq key (MAGIC_SYSRQ) [N/y/?] n&lt;br /&gt;Enable unused/obsolete exported symbols (UNUSED_SYMBOLS) [N/y/?] n&lt;br /&gt;Debug Filesystem (DEBUG_FS) [N/y/?] n&lt;br /&gt;Run 'make headers_check' when building vmlinux (HEADERS_CHECK) [N/y/?] n&lt;br /&gt;Kernel debugging (DEBUG_KERNEL) [N/y/?] n&lt;br /&gt;Are you using a crosscompiler (CROSSCOMPILE) [Y/n/?] y&lt;br /&gt;Default kernel command string (CMDLINE) [root=/dev/sda1 rootdelay=10 console=ttyS0,115200] root=/dev/sda1 rootdelay=10 console=ttyS0,115200&lt;br /&gt;*&lt;br /&gt;* Security options&lt;br /&gt;*&lt;br /&gt;Enable access key retention support (KEYS) [N/y/?] n&lt;br /&gt;Enable different security models (SECURITY) [N/y/?] n&lt;br /&gt;*&lt;br /&gt;* Cryptographic API&lt;br /&gt;*&lt;br /&gt;Cryptographic API (CRYPTO) [Y/?] y&lt;br /&gt; Cryptographic algorithm manager (CRYPTO_MANAGER) [M/y/?] m&lt;br /&gt; HMAC support (CRYPTO_HMAC) [N/m/y/?] n&lt;br /&gt; XCBC support (CRYPTO_XCBC) [N/m/y/?] (NEW)&lt;br /&gt;&lt;/pre&gt; &lt;p&gt;Answer "n" on "XCBC support (CRYPTO_XCBC) [N/m/y/?] (NEW)"&lt;br /&gt;Answer "n" on "GF(2^128) multiplication functions (EXPERIMENTAL) (CRYPTO_GF128MUL) [N/m/y/?] (NEW)"&lt;br /&gt;Answer "m" on "PCBC support (CRYPTO_PCBC) [M/n/y/?] (NEW)"&lt;br /&gt;Answer "n" on "LRW support (EXPERIMENTAL) (CRYPTO_LRW) [N/m/y/?] (NEW)"&lt;br /&gt;Answer "n" on "Software async crypto daemon (CRYPTO_CRYPTD) [N/m/y/?] (NEW)"&lt;br /&gt;Answer "n" on "FCrypt cipher algorithm (CRYPTO_FCRYPT) [N/m/y/?] (NEW)"&lt;br /&gt;Answer "n" on "Camellia cipher algorithms (CRYPTO_CAMELLIA) [N/m/y/?] (NEW)"&lt;br /&gt;&lt;/p&gt; &lt;pre&gt;Testing module (CRYPTO_TEST) [N/m/?] n&lt;br /&gt;*&lt;br /&gt;* Hardware crypto devices&lt;br /&gt;*&lt;br /&gt;Hardware crypto devices (CRYPTO_HW) [Y/n/?] (NEW)&lt;br /&gt;&lt;/pre&gt; &lt;p&gt;Answer "n" on "Hardware crypto devices (CRYPTO_HW) [Y/n/?] (NEW)"&lt;br /&gt;Answer "m" on "CRC ITU-T V.41 functions (CRC_ITU_T) [N/m/y/?]"&lt;br /&gt;Answer "m" on "CRC7 functions (CRC7) [N/m/y/?] (NEW)"&lt;br /&gt;&lt;/p&gt;&lt;p&gt;&lt;br /&gt;6. Rerun menuconfig although nothing will be changed, this step is needed to update some stamp files. On exit save the changes  &lt;/p&gt; &lt;pre&gt;cd $HOME/trunk&lt;br /&gt;make menuconfig&lt;br /&gt;&lt;/pre&gt; &lt;p&gt;&lt;br /&gt;7. Make a new image; this step won't be so time consuming  &lt;/p&gt; &lt;pre&gt;make V=99&lt;br /&gt;&lt;/pre&gt; &lt;p&gt;&lt;br /&gt;8. You will have new images in &lt;code&gt;trunk/bin/&lt;/code&gt; &lt;/p&gt;&lt;p&gt;&lt;br /&gt;Now we have to build modules for our new kernel: &lt;/p&gt;&lt;p&gt;&lt;br /&gt;9. Remove &lt;code&gt;.image&lt;/code&gt; and &lt;code&gt;.modules&lt;/code&gt; in &lt;code&gt;build_mipsel/linux/&lt;/code&gt;  &lt;/p&gt; &lt;pre&gt;cd $HOME/trunk/build_dir/linux-brcm47xx/linux-2.6.23.16&lt;br /&gt;rm .image .modules&lt;br /&gt;&lt;/pre&gt; &lt;p&gt;&lt;br /&gt;10. Go back to &lt;code&gt;trunk/&lt;/code&gt; directory and run make again (now it compiles also the modules we want) &lt;/p&gt; &lt;pre&gt;cd ../../..&lt;br /&gt;make&lt;br /&gt;&lt;/pre&gt; &lt;p&gt;&lt;br /&gt;11. Put modules temporary somewhere (INSTALL_MOD_PATH is where we want to temporary put modules) &lt;/p&gt; &lt;pre&gt;cd $HOME/trunk/build_dir/linux-brcm47xx/linux-2.6.23.16&lt;br /&gt;INSTALL_MOD_PATH=/tmp/ make modules_install&lt;br /&gt;&lt;/pre&gt; &lt;p&gt;&lt;br /&gt;12. Now we have in &lt;code&gt;/tmp/lib/modules/$our_kernel_version&lt;/code&gt; our modules and these need to be copied on the router in &lt;code&gt;/usr/lib/&lt;/code&gt; &lt;/p&gt; &lt;pre&gt;# ls /tmp/lib/modules/$our_kernel_version/&lt;br /&gt;kernel         modules.ccwmap  modules.ieee1394map  modules.isapnpmap  modules.pcimap    modules.symbols&lt;br /&gt;modules.alias  modules.dep     modules.inputmap     modules.ofmap      modules.seriomap  modules.usbmap&lt;br /&gt;# scp -r /tmp/lib/modules/$our_kernel_version/ router_IP:/lib/modules/&lt;br /&gt;&lt;/pre&gt; &lt;p&gt;&lt;br /&gt;13. Log as root on the router and adjust permissions &lt;/p&gt; &lt;pre&gt;# chown -R root:root /lib/modules/2.6.19.2/&lt;br /&gt;&lt;/pre&gt; &lt;p&gt;&lt;br /&gt;14. Flash the image as explained before and that's it &lt;/p&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/4984480909360655633-5690870061262256030?l=worldinthenet.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://worldinthenet.blogspot.com/feeds/5690870061262256030/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://worldinthenet.blogspot.com/2009/07/zz-running-debian-on-asus-wl-500w.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/4984480909360655633/posts/default/5690870061262256030'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/4984480909360655633/posts/default/5690870061262256030'/><link rel='alternate' type='text/html' href='http://worldinthenet.blogspot.com/2009/07/zz-running-debian-on-asus-wl-500w.html' title='[zz] Running Debian on ASUS WL-500W'/><author><name>Taojun</name><uri>http://www.blogger.com/profile/12946690813153575136</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-4984480909360655633.post-4600529094361217351</id><published>2009-07-14T18:48:00.000-07:00</published><updated>2009-07-14T18:52:47.762-07:00</updated><title type='text'>Ubuntu/XP dual boot mini howto</title><content type='html'>* prepare linux partitions inside Windows, using Acronis Disk Director Suite. No Partition Magic&lt;br /&gt;- root&lt;br /&gt;- swap&lt;br /&gt;* install Ubuntu with CD-Rom&lt;br /&gt;- keep grub boot loader at root partition&lt;br /&gt;- leave XP loader at MBR untouched&lt;br /&gt;- chain load linux, with bootpart&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/4984480909360655633-4600529094361217351?l=worldinthenet.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://worldinthenet.blogspot.com/feeds/4600529094361217351/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://worldinthenet.blogspot.com/2009/07/ubuntuxp-dual-boot-mini-howto.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/4984480909360655633/posts/default/4600529094361217351'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/4984480909360655633/posts/default/4600529094361217351'/><link rel='alternate' type='text/html' href='http://worldinthenet.blogspot.com/2009/07/ubuntuxp-dual-boot-mini-howto.html' title='Ubuntu/XP dual boot mini howto'/><author><name>Taojun</name><uri>http://www.blogger.com/profile/12946690813153575136</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-4984480909360655633.post-3407066610058046030</id><published>2009-07-14T07:33:00.001-07:00</published><updated>2009-07-14T07:33:17.281-07:00</updated><title type='text'>[zz] 泛仪器接口－－网络接口</title><content type='html'>发信人: goofegg (混蛋), 信区: Linux&lt;br /&gt;标  题: 泛仪器接口－－网络接口&lt;br /&gt;发信站: BBS 未名空间站 (Wed Jul  1 09:41:06 2009, 北京)&lt;br /&gt;&lt;br /&gt;一看这题目外行人也许感觉莫名其妙，不过咱拉的通俗易懂，定会让您理解俺要说什么&lt;br /&gt;，容咱慢慢道来。&lt;br /&gt;内行人也许一搭眼就能大致猜到俺想说什么，咱属于只会空想不会做实事的半吊子，但&lt;br /&gt;愿您能从后文中畅想出更细节深入的实现和以后应用的前景。&lt;br /&gt;就不过多回顾过去了，电子技术的发展，仪器测控领域，开始一台台孤零零的仪器，后&lt;br /&gt;来有了计算机，各种各样的外围总线接口，仪器接口随之出现，日常见到的串口，并口&lt;br /&gt;，PCI，PCIe，USB，IDE，SATA，D-Sub，DVI，HDMI。。。等等都属于接口，仪器广泛&lt;br /&gt;应用的接口也是五花八门：GPIB，VME，VXI，PXI。。。，有的属于机箱内的总线标准&lt;br /&gt;，有的是外围的互联之间的标准，随着发展，有些机箱内的较快的总线又向外扩展，使&lt;br /&gt;仪器之间或者和计算机之间可以更快的连接。所有这些连接都为了什么？通讯！说到通&lt;br /&gt;讯，人们印象最深刻的估计就是网络了，那为什么这样的通讯接口不采用网络接口的标&lt;br /&gt;准呢？&lt;br /&gt;仪器之间的连接以及和计算机之间的连接，最底层实际上就归结为控制和数据采集。曾&lt;br /&gt;有公司提出的虚拟仪器的思想也是根基于此，其开发的通用的AD板卡、多功能数字IO卡&lt;br /&gt;等等再配合上层的软件，就可以自己定制出各种各样的应用，不再像从前需要很多仪器&lt;br /&gt;的搭配，但是其最终还是需要计算机连接。现在市面上有了很多的直接有网络接口的仪&lt;br /&gt;器，有些内嵌了通用的计算机，有些内嵌专用的DSP电路和网络接口芯片。相信这种带&lt;br /&gt;有网络接口的仪器将会越来越普遍，既然各种各样的仪器接口需要各自的接口芯片和电&lt;br /&gt;路，为什么就不用很通用的网络接口代替呢？同样是互联，现在的技术完全可以集成个&lt;br /&gt;嵌入式CPU，用网络协议和通讯代替各种各样的仪器通讯标准。这样的仪器如果再留有&lt;br /&gt;用户可自定制的软件接口，根本就不再需要再联个计算机。比如从一个万用表采个电压&lt;br /&gt;上网，从前需要一个有仪器接口的万用表，还有台电脑通过专用接口电缆和仪器连接，&lt;br /&gt;电脑通过接口和仪器通讯，再处理送向网络；内嵌网口的仪器插上网线就连上网了，需&lt;br /&gt;要电压信号的客户端通过网络直接就能从仪器读到。&lt;br /&gt;这样的硬件接口用通用的网络接口替代，优势就不说了；对于软件协议，也有现成的业&lt;br /&gt;界广泛应用的－－EPICS。&lt;br /&gt;EPICS－实验物理和工业控制系统，起源于欧美的一些大科学装置，后来广泛应用于工&lt;br /&gt;业控制领域，并且是开源的。其核心是把所有控制和采集的东西当作一个PV－－过程变&lt;br /&gt;量，都有一个变量名，不知以后浏览器是否会有这样的插件，就像通常的http协议一样&lt;br /&gt;，可以通过这样的访问：epics://goofegg.com:goofegg:wife:name，就可以在页面上&lt;br /&gt;显示出goofegg先生老婆的名字，当然，如果在局域网里完全可以把主机去掉，变成这&lt;br /&gt;样：epics://:goofegg:wife:name。带网络接口的仪器，完全可以把能采集的各种变量&lt;br /&gt;和需要被控的各种变量做成这样的EPICS通道，代替各种复杂的接口通讯。&lt;br /&gt;当然，硬件做好，这样的软件接口完全可以根据情况定制并能很方便的升级以适应各种&lt;br /&gt;各样的控制系统。&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/4984480909360655633-3407066610058046030?l=worldinthenet.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://worldinthenet.blogspot.com/feeds/3407066610058046030/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://worldinthenet.blogspot.com/2009/07/zz.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/4984480909360655633/posts/default/3407066610058046030'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/4984480909360655633/posts/default/3407066610058046030'/><link rel='alternate' type='text/html' href='http://worldinthenet.blogspot.com/2009/07/zz.html' title='[zz] 泛仪器接口－－网络接口'/><author><name>Taojun</name><uri>http://www.blogger.com/profile/12946690813153575136</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-4984480909360655633.post-4176698050932706069</id><published>2009-07-13T20:45:00.000-07:00</published><updated>2009-07-14T18:19:08.271-07:00</updated><title type='text'>[zz] Use a PSP as an extended display</title><content type='html'>&lt;div class="post" id="post-"&gt;         posted Oct 6th 2008 1:49pm by &lt;a href="http://hackaday.com/author/calebkraft/" title="Posts by Caleb Kraft"&gt;Caleb Kraft&lt;/a&gt;&lt;br /&gt; filed under: &lt;a href="http://hackaday.com/category/daily/" title="View all posts in daily" rel="category tag"&gt;daily&lt;/a&gt;,  &lt;a href="http://hackaday.com/category/handhelds-hacks/" title="View all posts in handhelds hacks" rel="category tag"&gt;handhelds hacks&lt;/a&gt;,  &lt;a href="http://hackaday.com/category/playstation-hacks/" title="View all posts in playstation hacks" rel="category tag"&gt;playstation hacks&lt;/a&gt;,  &lt;a href="http://hackaday.com/category/psp-hacks/" title="View all posts in psp hacks" rel="category tag"&gt;psp hacks&lt;/a&gt;&lt;br /&gt; &lt;div class="entry"&gt;     &lt;div class="snap_preview"&gt;&lt;p&gt;&lt;img class="alignnone size-full wp-image-4384" title="psp_external" src="http://hackadaycom.files.wordpress.com/2008/10/psp_external.jpg?w=450&amp;amp;h=325" alt="" width="450" height="325" /&gt;&lt;/p&gt; &lt;p&gt;Follow along with this project and you could &lt;a href="http://jjs.at/software/pspdisp.html"&gt;use your PSP as a display&lt;/a&gt; for your computer. The software, available for download on the site, gives you a 960×544 display. The data is compressed, sent to the &lt;a title="PSP Hacks - Mahalo" href="http://www.mahalo.com/PSP_Hacks"&gt;PSP&lt;/a&gt;, then decompressed for display. Though that sounds clunky, the video after the break shows it working pretty smoothly with some &lt;a title="Winamp - Mahalo" href="http://www.mahalo.com/Winamp"&gt;Winamp&lt;/a&gt; visualization. Only 32 bit Windows XP or older is supported currently.&lt;/p&gt; &lt;p&gt;&lt;span id="more-4382"&gt;&lt;/span&gt;&lt;/p&gt; &lt;p&gt;&lt;span style="text-align: center; display: block;"&gt;&lt;object width="425" height="350"&gt;&lt;param name="movie" value="http://www.youtube.com/v/IqX-8ckC6J4&amp;amp;rel=1&amp;amp;fs=1&amp;amp;showsearch=0&amp;amp;hd=0"&gt; &lt;param name="allowfullscreen" value="true"&gt; &lt;param name="wmode" value="transparent"&gt; &lt;embed src="http://www.youtube.com/v/IqX-8ckC6J4&amp;amp;rel=1&amp;amp;fs=1&amp;amp;showsearch=0&amp;amp;hd=0" type="application/x-shockwave-flash" allowfullscreen="true" wmode="transparent" width="425" height="350"&gt;&lt;/embed&gt; &lt;/object&gt;&lt;/span&gt;&lt;/p&gt; &lt;p&gt;[thanks carlos]&lt;/p&gt; &lt;/div&gt;    &lt;/div&gt;&lt;/div&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/4984480909360655633-4176698050932706069?l=worldinthenet.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://worldinthenet.blogspot.com/feeds/4176698050932706069/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://worldinthenet.blogspot.com/2009/07/use-psp-as-extended-display-posted-oct.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/4984480909360655633/posts/default/4176698050932706069'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/4984480909360655633/posts/default/4176698050932706069'/><link rel='alternate' type='text/html' href='http://worldinthenet.blogspot.com/2009/07/use-psp-as-extended-display-posted-oct.html' title='[zz] Use a PSP as an extended display'/><author><name>Taojun</name><uri>http://www.blogger.com/profile/12946690813153575136</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-4984480909360655633.post-6509293323374567485</id><published>2009-07-12T21:38:00.003-07:00</published><updated>2009-07-13T16:57:28.948-07:00</updated><title type='text'>[zz] Running Kamikaze On QEMU HowTo</title><content type='html'>&lt;p class="line867"&gt; &lt;/p&gt;&lt;h1 id="head-6c8f9a7d3e0ff44a23eadd31092bd6e92caa0466"&gt;Running Kamikaze images under qemu&lt;/h1&gt; &lt;span class="anchor" id="line-2"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-3"&gt;&lt;/span&gt;&lt;p class="line874"&gt;The Kamikaze x86 images run directly under qemu; all you need to do is to grow them &lt;span class="anchor" id="line-4"&gt;&lt;/span&gt;to the full size that the partition table defines. This will be roughly &lt;span class="anchor" id="line-5"&gt;&lt;/span&gt;20MB, since the default configuration is 4MB for the boot partition and 16MB &lt;span class="anchor" id="line-6"&gt;&lt;/span&gt;for the data partition, but will be a bit larger than this due to rounding &lt;span class="anchor" id="line-7"&gt;&lt;/span&gt;up to whole numbers of cylinders. &lt;span class="anchor" id="line-8"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-9"&gt;&lt;/span&gt;&lt;/p&gt;&lt;p class="line874"&gt;Work out the exact number of sectors that the image should be by looking at &lt;span class="anchor" id="line-10"&gt;&lt;/span&gt;the partition table, and multiplying the highest cylinder number by the &lt;span class="anchor" id="line-11"&gt;&lt;/span&gt;sectors per cylinder: &lt;span class="anchor" id="line-12"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-13"&gt;&lt;/span&gt;&lt;/p&gt;&lt;p class="line867"&gt;&lt;span class="anchor" id="line-14"&gt;&lt;/span&gt;&lt;/p&gt;&lt;pre&gt;$ fdisk openwrt-x86-2.6-jffs2-128k.image&lt;br /&gt;&lt;span class="anchor" id="line-15"&gt;&lt;/span&gt;You must set cylinders.&lt;br /&gt;&lt;span class="anchor" id="line-16"&gt;&lt;/span&gt;You can do this from the extra functions menu.&lt;br /&gt;&lt;span class="anchor" id="line-17"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span class="anchor" id="line-18"&gt;&lt;/span&gt;Command (m for help): p&lt;br /&gt;&lt;span class="anchor" id="line-19"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span class="anchor" id="line-20"&gt;&lt;/span&gt;Disk openwrt-x86-2.6-jffs2-128k.image: 0 MB, 0 bytes&lt;br /&gt;&lt;span class="anchor" id="line-21"&gt;&lt;/span&gt;16 heads, 63 sectors/track, 0 cylinders&lt;br /&gt;&lt;span class="anchor" id="line-22"&gt;&lt;/span&gt;Units = cylinders of 1008 * 512 = 516096 bytes&lt;br /&gt;&lt;span class="anchor" id="line-23"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span class="anchor" id="line-24"&gt;&lt;/span&gt;                           Device Boot      Start         End      Blocks   Id System&lt;br /&gt;&lt;span class="anchor" id="line-25"&gt;&lt;/span&gt;openwrt-x86-2.6-jffs2-128k.image1   *           1           9        4504+  83 Linux&lt;br /&gt;&lt;span class="anchor" id="line-26"&gt;&lt;/span&gt;openwrt-x86-2.6-jffs2-128k.image2              10          42       16600+  83 Linux&lt;br /&gt;&lt;span class="anchor" id="line-27"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span class="anchor" id="line-28"&gt;&lt;/span&gt;Command (m for help): q&lt;br /&gt;&lt;span class="anchor" id="line-29"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span class="anchor" id="line-30"&gt;&lt;/span&gt;$ bc&lt;br /&gt;&lt;span class="anchor" id="line-31"&gt;&lt;/span&gt;bc 1.06&lt;br /&gt;&lt;span class="anchor" id="line-32"&gt;&lt;/span&gt;Copyright 1991-1994, 1997, 1998, 2000 Free Software Foundation, Inc.&lt;br /&gt;&lt;span class="anchor" id="line-33"&gt;&lt;/span&gt;This is free software with ABSOLUTELY NO WARRANTY.&lt;br /&gt;&lt;span class="anchor" id="line-34"&gt;&lt;/span&gt;For details type `warranty'.&lt;br /&gt;&lt;span class="anchor" id="line-35"&gt;&lt;/span&gt;42*1008&lt;br /&gt;&lt;span class="anchor" id="line-36"&gt;&lt;/span&gt;42336&lt;br /&gt;&lt;span class="anchor" id="line-37"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span class="anchor" id="line-38"&gt;&lt;/span&gt;$ dd if=/dev/null of=openwrt-x86-2.6-jffs2-128k.image seek=42336&lt;br /&gt;&lt;span class="anchor" id="line-39"&gt;&lt;/span&gt;0+0 records in&lt;br /&gt;&lt;span class="anchor" id="line-40"&gt;&lt;/span&gt;0+0 records out&lt;br /&gt;&lt;span class="anchor" id="line-41"&gt;&lt;/span&gt;0 bytes (0 B) copied, 2.5e-05 seconds, 0 B/s&lt;br /&gt;&lt;span class="anchor" id="line-42"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span class="anchor" id="line-43"&gt;&lt;/span&gt;$ ls -l openwrt-x86-2.6-jffs2-128k.image&lt;br /&gt;&lt;span class="anchor" id="line-44"&gt;&lt;/span&gt;-rw-r--r-- 1 yourname yourname 21676032 2007-10-23 11:20&lt;br /&gt;&lt;span class="anchor" id="line-45"&gt;&lt;/span&gt;&lt;/pre&gt;&lt;span class="anchor" id="line-46"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-47"&gt;&lt;/span&gt;&lt;p class="line874"&gt;Now you can boot this image directly: &lt;span class="anchor" id="line-48"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-49"&gt;&lt;/span&gt;&lt;/p&gt;&lt;p class="line867"&gt;&lt;span class="anchor" id="line-50"&gt;&lt;/span&gt;&lt;/p&gt;&lt;pre&gt;$ sudo apt-get install qemu    # for Ubuntu&lt;br /&gt;&lt;span class="anchor" id="line-51"&gt;&lt;/span&gt;$ qemu openwrt-x86-2.6-jffs2-128k.image&lt;br /&gt;&lt;span class="anchor" id="line-52"&gt;&lt;/span&gt;&lt;/pre&gt;&lt;span class="anchor" id="line-53"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-54"&gt;&lt;/span&gt;&lt;p class="line874"&gt;Type 'qemu' by itself to get a list of options. Useful ones are '-snapshot' &lt;span class="anchor" id="line-55"&gt;&lt;/span&gt;which keeps your image pristine (writes are made to temporary files); '-k &lt;span class="anchor" id="line-56"&gt;&lt;/span&gt;en-gb' to set the keyboard layout; and '-m 64' to set the available memory &lt;span class="anchor" id="line-57"&gt;&lt;/span&gt;to 64MB (defaults to 128MB) &lt;span class="anchor" id="line-58"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-59"&gt;&lt;/span&gt;&lt;/p&gt;&lt;p class="line874"&gt;Inside the VGA window, use Ctrl-Alt to release the mouse, and Ctrl-Alt-1/2/3 &lt;span class="anchor" id="line-60"&gt;&lt;/span&gt;to switch between guest VGA, qemu monitor (where you can manage qemu &lt;span class="anchor" id="line-61"&gt;&lt;/span&gt;itself), and serial port. &lt;span class="anchor" id="line-62"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-63"&gt;&lt;/span&gt;&lt;/p&gt;&lt;p class="line874"&gt;The '-nographic' option disables the VGA window display entirely and redirects &lt;span class="anchor" id="line-64"&gt;&lt;/span&gt;the serial console to stdin/stdout. There are some special key sequences here &lt;span class="anchor" id="line-65"&gt;&lt;/span&gt;for getting access to the monitor - type Ctrl-a h for help on these. &lt;span class="anchor" id="line-66"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-67"&gt;&lt;/span&gt;&lt;/p&gt;&lt;p class="line867"&gt; &lt;/p&gt;&lt;h1 id="head-fc026cf77d84f3319085a571b2aca01679b34428"&gt;&lt;span style="font-size:180%;"&gt;Networking&lt;/span&gt;&lt;/h1&gt; &lt;span class="anchor" id="line-68"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-69"&gt;&lt;/span&gt;&lt;p class="line874"&gt;Network access to your image is provided by a virtual NE2000-type network &lt;span class="anchor" id="line-70"&gt;&lt;/span&gt;card in the emulated guest environment. To access this you will need the &lt;span class="anchor" id="line-71"&gt;&lt;/span&gt;&lt;em&gt;kmod-ne2k-pci&lt;/em&gt; package, which is included by default in the x86 image. &lt;span class="anchor" id="line-72"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-73"&gt;&lt;/span&gt;&lt;/p&gt;&lt;p class="line867"&gt; &lt;/p&gt;&lt;h2 id="head-e512af3b1b5920bac3e16b380951857f0c427164"&gt;&lt;span style="font-size:130%;"&gt;User-mode networking&lt;/span&gt;&lt;/h2&gt; &lt;span class="anchor" id="line-74"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-75"&gt;&lt;/span&gt;&lt;p class="line874"&gt;"User-mode" networking is enabled by default. Within the guest, if you edit &lt;span class="anchor" id="line-76"&gt;&lt;/span&gt;/etc/config/network, set "option proto dhcp", then run "ifup lan", the &lt;span class="anchor" id="line-77"&gt;&lt;/span&gt;br-lan interface will pick up an IP address from an internal private &lt;span class="anchor" id="line-78"&gt;&lt;/span&gt;network, 10.0.2.x. &lt;span class="anchor" id="line-79"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-80"&gt;&lt;/span&gt;&lt;/p&gt;&lt;p class="line874"&gt;It then has outbound access to the Internet via your host machine, which &lt;span class="anchor" id="line-81"&gt;&lt;/span&gt;appears to be a NAT firewall. You won't be able to send an ICMP ping &lt;span class="anchor" id="line-82"&gt;&lt;/span&gt;(qemu would need to run as root to provide that), but you can open TCP &lt;span class="anchor" id="line-83"&gt;&lt;/span&gt;connections and perform DNS lookups. For example, "ipkg update" works as expected.  &lt;span class="anchor" id="line-84"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-85"&gt;&lt;/span&gt;&lt;/p&gt;&lt;p class="line874"&gt;No root privileges are needed to run qemu this way. However, if you wish to &lt;span class="anchor" id="line-86"&gt;&lt;/span&gt;allow incoming connections then this has to be done via port forwarding &lt;span class="anchor" id="line-87"&gt;&lt;/span&gt;(see the -redir option), just like on a real NAT firewall. &lt;span class="anchor" id="line-88"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-89"&gt;&lt;/span&gt;&lt;/p&gt;&lt;p class="line867"&gt; &lt;/p&gt;&lt;h2 id="head-e4da08ea825005ab7b02cfaed7f863efc59cf979"&gt;&lt;span style="font-size:130%;"&gt;Bridged networking&lt;/span&gt;&lt;/h2&gt; &lt;span class="anchor" id="line-90"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-91"&gt;&lt;/span&gt;&lt;p class="line874"&gt;A more powerful solution is to bridge your host adaptor's ethernet &lt;span class="anchor" id="line-92"&gt;&lt;/span&gt;directly with the virtual ethernet NIC(s) of your QEMU guest(s). This &lt;span class="anchor" id="line-93"&gt;&lt;/span&gt;gives them full access to your LAN as peers, and can pick up their own &lt;span class="anchor" id="line-94"&gt;&lt;/span&gt;IP addresses using your LAN's existing DHCP server. &lt;span class="anchor" id="line-95"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-96"&gt;&lt;/span&gt;&lt;/p&gt;&lt;p class="line874"&gt;To do this involves setting up software bridging on the host, and adding the &lt;span class="anchor" id="line-97"&gt;&lt;/span&gt;'tap' device to this same bridge. The following instructions are for &lt;span class="anchor" id="line-98"&gt;&lt;/span&gt;Ubuntu Linux. &lt;span class="anchor" id="line-99"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-100"&gt;&lt;/span&gt;&lt;/p&gt;&lt;p class="line862"&gt;Install the 'bridge-utils' package to get the &lt;strong&gt;brctl&lt;/strong&gt; utility. &lt;span class="anchor" id="line-101"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-102"&gt;&lt;/span&gt;&lt;/p&gt;&lt;p class="line874"&gt;Now, you need to link your host PC's network port into &lt;span class="anchor" id="line-103"&gt;&lt;/span&gt;a software bridge. Let's say your existing 'outside' Internet connection &lt;span class="anchor" id="line-104"&gt;&lt;/span&gt;is via eth1, and you wish to bridge QEMU guests onto this. Firstly, &lt;span class="anchor" id="line-105"&gt;&lt;/span&gt;unconfigure your network using &lt;strong&gt;ifdown eth1&lt;/strong&gt;. Now edit &lt;span class="anchor" id="line-106"&gt;&lt;/span&gt;/etc/network/interfaces and change &lt;span class="anchor" id="line-107"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-108"&gt;&lt;/span&gt;&lt;/p&gt;&lt;pre&gt;auto eth1&lt;br /&gt;&lt;span class="anchor" id="line-109"&gt;&lt;/span&gt;iface eth1 inet dhcp&lt;br /&gt;&lt;span class="anchor" id="line-110"&gt;&lt;/span&gt;&lt;/pre&gt;&lt;span class="anchor" id="line-111"&gt;&lt;/span&gt;&lt;p class="line874"&gt;to &lt;span class="anchor" id="line-112"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-113"&gt;&lt;/span&gt;&lt;/p&gt;&lt;pre&gt;auto br1&lt;br /&gt;&lt;span class="anchor" id="line-114"&gt;&lt;/span&gt;iface br1 inet dhcp&lt;br /&gt;&lt;span class="anchor" id="line-115"&gt;&lt;/span&gt;      bridge_ports eth1&lt;br /&gt;&lt;span class="anchor" id="line-116"&gt;&lt;/span&gt;&lt;/pre&gt;&lt;span class="anchor" id="line-117"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-118"&gt;&lt;/span&gt;&lt;p class="line862"&gt;Finally bring the interface back up using &lt;strong&gt;ifup br1&lt;/strong&gt;. From now on, &lt;span class="anchor" id="line-119"&gt;&lt;/span&gt;your outside connection is via br1, which is linked to eth1. Use &lt;span class="anchor" id="line-120"&gt;&lt;/span&gt;&lt;strong&gt;brctl show&lt;/strong&gt; to see this. &lt;span class="anchor" id="line-121"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-122"&gt;&lt;/span&gt;&lt;/p&gt;&lt;p class="line862"&gt;Next you need to edit &lt;strong&gt;/etc/qemu-ifup&lt;/strong&gt;, which is the script run by &lt;span class="anchor" id="line-123"&gt;&lt;/span&gt;qemu when it needs to access the interface, so that it can add itself &lt;span class="anchor" id="line-124"&gt;&lt;/span&gt;into the bridge. &lt;span class="anchor" id="line-125"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-126"&gt;&lt;/span&gt;&lt;/p&gt;&lt;p class="line867"&gt;&lt;span class="anchor" id="line-127"&gt;&lt;/span&gt;&lt;/p&gt;&lt;pre&gt;#!/bin/sh&lt;br /&gt;&lt;span class="anchor" id="line-128"&gt;&lt;/span&gt;sudo -p "Password for $0:" /sbin/ifconfig $1 0.0.0.0 promisc up&lt;br /&gt;&lt;span class="anchor" id="line-129"&gt;&lt;/span&gt;sudo /usr/sbin/brctl addif br1 $1&lt;br /&gt;&lt;span class="anchor" id="line-130"&gt;&lt;/span&gt;&lt;/pre&gt;&lt;span class="anchor" id="line-131"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-132"&gt;&lt;/span&gt;&lt;p class="line874"&gt;Finally, start qemu like this: &lt;span class="anchor" id="line-133"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-134"&gt;&lt;/span&gt;&lt;/p&gt;&lt;p class="line867"&gt;&lt;span class="anchor" id="line-135"&gt;&lt;/span&gt;&lt;/p&gt;&lt;pre&gt;qemu -net tap -net nic -hda openwrt-x86-2.6-squashfs.image&lt;br /&gt;&lt;span class="anchor" id="line-136"&gt;&lt;/span&gt;&lt;/pre&gt;&lt;span class="anchor" id="line-137"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-138"&gt;&lt;/span&gt;&lt;p class="line874"&gt;What happens is that qemu creates a new 'tap' interface, e.g. tap0, &lt;span class="anchor" id="line-139"&gt;&lt;/span&gt;connects this to the virtual NIC within the guest environment, and &lt;span class="anchor" id="line-140"&gt;&lt;/span&gt;the qemu-ifup script connects this to the software bridge in the host &lt;span class="anchor" id="line-141"&gt;&lt;/span&gt;environment. &lt;span class="anchor" id="line-142"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-143"&gt;&lt;/span&gt;&lt;/p&gt;&lt;p class="line874"&gt;If you get the following permission error: &lt;span class="anchor" id="line-144"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-145"&gt;&lt;/span&gt;&lt;/p&gt;&lt;pre&gt;warning: could not open /dev/net/tun: no virtual network emulation&lt;br /&gt;&lt;span class="anchor" id="line-146"&gt;&lt;/span&gt;Could not initialize device 'tap'&lt;br /&gt;&lt;span class="anchor" id="line-147"&gt;&lt;/span&gt;&lt;/pre&gt;&lt;span class="anchor" id="line-148"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-149"&gt;&lt;/span&gt;&lt;p class="line874"&gt;then you can chown /dev/net/tun to your own userid, or else run qemu as root. &lt;span class="anchor" id="line-150"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-151"&gt;&lt;/span&gt;&lt;/p&gt;&lt;p class="line874"&gt;If you are running multiple qemu instances simultaneously then each one will need &lt;span class="anchor" id="line-152"&gt;&lt;/span&gt;to have a unique MAC address assigned to it: e.g. &lt;span class="anchor" id="line-153"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-154"&gt;&lt;/span&gt;&lt;/p&gt;&lt;p class="line867"&gt;&lt;span class="anchor" id="line-155"&gt;&lt;/span&gt;&lt;/p&gt;&lt;pre&gt;qemu -net tap -net nic,macaddr=52:54:0:0:0:1 -hda openwrt-x86-2.6-squashfs.image1&lt;br /&gt;&lt;span class="anchor" id="line-156"&gt;&lt;/span&gt;qemu -net tap -net nic,macaddr=52:54:0:0:0:2 -hda openwrt-x86-2.6-squashfs.image2&lt;br /&gt;&lt;span class="anchor" id="line-157"&gt;&lt;/span&gt;...&lt;br /&gt;&lt;span class="anchor" id="line-158"&gt;&lt;/span&gt;&lt;/pre&gt;&lt;span class="anchor" id="line-159"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-160"&gt;&lt;/span&gt;&lt;p class="line874"&gt;Conversely, it's possible to connect a single qemu instance to multiple software bridges &lt;span class="anchor" id="line-161"&gt;&lt;/span&gt;(and hence external NICs) on the host. This can be done by using a separate qemu-ifup &lt;span class="anchor" id="line-162"&gt;&lt;/span&gt;script for each one, linking to a separate software bridge instance. &lt;span class="anchor" id="line-163"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-164"&gt;&lt;/span&gt;&lt;/p&gt;&lt;p class="line867"&gt;&lt;span class="anchor" id="line-165"&gt;&lt;/span&gt;&lt;/p&gt;&lt;pre&gt;qemu -net nic,vlan=1 -net nic,vlan=2 \&lt;br /&gt;&lt;span class="anchor" id="line-166"&gt;&lt;/span&gt;     -net tap,vlan=1,script=/etc/qemu-ifup -net tap,vlan=2,script=/etc/qemu-ifup2 \&lt;br /&gt;&lt;span class="anchor" id="line-167"&gt;&lt;/span&gt;     -hda openwrt-x86-2.6-squashfs.image&lt;br /&gt;&lt;span class="anchor" id="line-168"&gt;&lt;/span&gt;&lt;/pre&gt;&lt;span class="anchor" id="line-169"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-170"&gt;&lt;/span&gt;&lt;p class="line874"&gt;Now within the guest, eth0 connects to one bridge and eth1 connects to another. &lt;span class="anchor" id="line-171"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-172"&gt;&lt;/span&gt;&lt;/p&gt;&lt;p class="line867"&gt; &lt;/p&gt;&lt;h2 id="head-3c52642673b5387c4f9d4c7617f57b200b9d0a2c"&gt;&lt;span style="font-size:130%;"&gt;Other options&lt;/span&gt;&lt;/h2&gt; &lt;span class="anchor" id="line-173"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-174"&gt;&lt;/span&gt;&lt;p class="line874"&gt;There are many other qemu networking possibilities, such as setting up IP-over-TCP &lt;span class="anchor" id="line-175"&gt;&lt;/span&gt;encapsulation for point-to-point links between qemus, or IP-over-UDP multicast. &lt;span class="anchor" id="line-176"&gt;&lt;/span&gt;Read the qemu manpage or google for other examples, e.g. &lt;span class="anchor" id="line-177"&gt;&lt;/span&gt;&lt;a class="http" href="http://www.gnome.org/%7Emarkmc/qemu-networking.html"&gt;http://www.gnome.org/~markmc/qemu-networking.html&lt;/a&gt; and &lt;span class="anchor" id="line-178"&gt;&lt;/span&gt;&lt;a class="http" href="http://www.h7.dion.ne.jp/%7Eqemu-win/HowToNetwork-en.html"&gt;http://www.h7.dion.ne.jp/~qemu-win/HowToNetwork-en.html&lt;/a&gt; &lt;span class="anchor" id="line-179"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-180"&gt;&lt;/span&gt;&lt;/p&gt;&lt;p class="line867"&gt; &lt;/p&gt;&lt;h1 id="head-81d47590cdc9ba601267aa48707b44c2ae2aec73"&gt;&lt;span style="font-size:130%;"&gt;See also&lt;/span&gt;&lt;/h1&gt; &lt;span class="anchor" id="line-181"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-182"&gt;&lt;/span&gt;&lt;ul&gt;&lt;li&gt;&lt;p class="line891"&gt;&lt;a href="http://oldwiki.openwrt.org/SoekrisPort.html"&gt;SoekrisPort&lt;/a&gt; (for more details about partitioning) &lt;span class="anchor" id="line-183"&gt;&lt;/span&gt;&lt;/p&gt;&lt;/li&gt;&lt;li&gt;&lt;p class="line891"&gt;&lt;a href="http://oldwiki.openwrt.org/Generic_x86%282d%29HowTo.html"&gt;Generic_x86-HowTo&lt;/a&gt; &lt;span class="anchor" id="line-184"&gt;&lt;/span&gt;&lt;/p&gt;&lt;/li&gt;&lt;li&gt;&lt;p class="line891"&gt;&lt;a href="http://oldwiki.openwrt.org/RunningKamikazeOnVMwareHowTo.html"&gt;RunningKamikazeOnVMwareHowTo&lt;/a&gt;&lt;/p&gt;&lt;/li&gt;&lt;/ul&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/4984480909360655633-6509293323374567485?l=worldinthenet.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://worldinthenet.blogspot.com/feeds/6509293323374567485/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://worldinthenet.blogspot.com/2009/07/zz-runningkamikazeonqemuhowto.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/4984480909360655633/posts/default/6509293323374567485'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/4984480909360655633/posts/default/6509293323374567485'/><link rel='alternate' type='text/html' href='http://worldinthenet.blogspot.com/2009/07/zz-runningkamikazeonqemuhowto.html' title='[zz] Running Kamikaze On QEMU HowTo'/><author><name>Taojun</name><uri>http://www.blogger.com/profile/12946690813153575136</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-4984480909360655633.post-5977703459909144505</id><published>2009-07-12T20:12:00.001-07:00</published><updated>2009-07-12T20:12:54.405-07:00</updated><title type='text'>[zz] OpenWrt configuration</title><content type='html'>&lt;div class="NAVHEADER"&gt;&lt;table summary="Header navigation table" width="100%" border="0" cellpadding="0" cellspacing="0"&gt;&lt;tbody&gt;&lt;tr&gt;&lt;th colspan="3" align="center"&gt;OpenWrt HOWTO&lt;/th&gt;&lt;/tr&gt;&lt;tr&gt;&lt;td valign="bottom" width="10%" align="left"&gt;&lt;a href="http://cyberforat.squat.net/openwrt/OpenWrt-HOWTO/x338.html" accesskey="P"&gt;Prev&lt;/a&gt;&lt;/td&gt;&lt;td valign="bottom" width="80%" align="center"&gt;&lt;br /&gt;&lt;/td&gt;&lt;td valign="bottom" width="10%" align="right"&gt;&lt;a href="http://cyberforat.squat.net/openwrt/OpenWrt-HOWTO/x830.html" accesskey="N"&gt;Next&lt;/a&gt;&lt;/td&gt;&lt;/tr&gt;&lt;/tbody&gt;&lt;/table&gt;&lt;hr width="100%" align="left"&gt;&lt;/div&gt;&lt;div class="sect1"&gt;&lt;h1 class="sect1"&gt;&lt;a name="openwrtconfig"&gt;5. OpenWrt configuration.&lt;/a&gt;&lt;/h1&gt;&lt;p&gt; The most of the configuration in OpenWrt is done by setting variables in the NVRAM,  even if you are a experienced linux user, this modell of configuration will be quit new  to you and you will have to get used to it.  &lt;/p&gt;&lt;p&gt; You should alwayes be aware of what you are doing when you change your NVRAM variables. But even when you have  bricked your router and can't gain access anymore, there is allwayes the failsafe mode (look in troubleshooting).  &lt;/p&gt;&lt;p&gt;  There is still no real webinterface for OpenWrt ( if you are searching for a openwrt with build in webinterface  have a look at &lt;a href="http://ff-firmware.sourceforge.net/" target="_top"&gt;&lt;i class="citetitle"&gt;ff-firmware.sourceforge.net&lt;/i&gt;&lt;/a&gt; ). You can find a couple of other open firmwares for the WRT54G and WRT54GS, which come with a build in webinterface if OpenWrt is not what you where looking for. But still i belive OpenWrt is the most powerfull distro if you want a full working linux operating system. &lt;/p&gt;&lt;div class="sect2"&gt;&lt;h2 class="sect2"&gt;&lt;a name="openwrtconfignvram"&gt;5.1. NVRAM&lt;/a&gt;&lt;/h2&gt;&lt;p&gt; NVRAM stands for Non-Volatile RAM, in this case the last 64K of the flash chip used to store various configuration information in a name=value format. &lt;/p&gt;&lt;p&gt; &lt;/p&gt;&lt;div class="table"&gt;&lt;a name="AEN413"&gt;&lt;/a&gt;&lt;p&gt;&lt;b&gt;Table 5. nvram command&lt;/b&gt;&lt;/p&gt;&lt;table class="CALSTABLE" rules="all" border="1" frame="border"&gt;&lt;col&gt;&lt;col&gt;&lt;thead&gt;&lt;tr&gt;&lt;th&gt;Command&lt;/th&gt;&lt;th&gt;Description&lt;/th&gt;&lt;/tr&gt;&lt;/thead&gt;&lt;tbody&gt;&lt;tr&gt;&lt;td&gt;&lt;b class="command"&gt;nvram show | less&lt;/b&gt;&lt;/td&gt;&lt;td&gt;Display everything in nvram&lt;/td&gt;&lt;/tr&gt;&lt;tr&gt;&lt;td&gt;&lt;b class="command"&gt;nvram get boot_wait&lt;/b&gt;&lt;/td&gt;&lt;td&gt; Get a specific variable ( in this case &lt;code class="varname"&gt;boot_wait&lt;/code&gt; )&lt;/td&gt;&lt;/tr&gt;&lt;tr&gt;&lt;td&gt;&lt;b class="command"&gt;nvram set boot_wait=on&lt;/b&gt;&lt;/td&gt;&lt;td&gt; Set a value&lt;/td&gt;&lt;/tr&gt;&lt;tr&gt;&lt;td&gt;&lt;b class="command"&gt;nvram set lan_ifnames="vlan0 vlan1 vlan2"&lt;/b&gt;&lt;/td&gt;&lt;td&gt;set multiple values to one param&lt;/td&gt;&lt;/tr&gt;&lt;tr&gt;&lt;td&gt;&lt;b class="command"&gt;nvram unset foo&lt;/b&gt;&lt;/td&gt;&lt;td&gt;Delete a variable&lt;/td&gt;&lt;/tr&gt;&lt;tr&gt;&lt;td&gt;&lt;b class="command"&gt;nvram commit&lt;/b&gt;&lt;/td&gt;&lt;td&gt;Write changes to the flash chip (otherwise only stored in RAM)&lt;/td&gt;&lt;/tr&gt;&lt;/tbody&gt;&lt;/table&gt;&lt;/div&gt;         &lt;p&gt; A complete list of nvram variables can be found &lt;a href="http://openwrt.org/OpenWrtNVRAM" target="_top"&gt;&lt;i class="citetitle"&gt; here&lt;/i&gt;&lt;/a&gt;.   &lt;/p&gt;&lt;/div&gt;&lt;div class="sect2"&gt;&lt;h2 class="sect2"&gt;&lt;a name="openwrtconfignetwork"&gt;5.2. Network configuration.&lt;/a&gt;&lt;/h2&gt;&lt;p&gt; The names of the network interfaces will depend largely on what hardware OpenWrt is run on.     &lt;/p&gt;&lt;pre class="screen"&gt;WRT54G V1.x&lt;br /&gt; LAN=vlan2&lt;br /&gt; WAN=vlan1&lt;br /&gt; WIFI=eth2&lt;br /&gt;&lt;br /&gt;WRT54G V2.x/WRT54GS V1.x&lt;br /&gt; LAN=vlan0&lt;br /&gt; WAN=vlan1&lt;br /&gt; WIFI=eth1&lt;br /&gt;&lt;br /&gt;ASUS WL-500g&lt;br /&gt; WAN=eth0&lt;br /&gt; LAN=eth1&lt;br /&gt; WIFI=eth2&lt;br /&gt;(LAN and WIFI are bridged together in br0 by default)&lt;br /&gt;&lt;br /&gt;   &lt;/pre&gt;   &lt;p&gt; The basic (802.3) network configuration is handled by a series of NVRAM variables:   &lt;/p&gt;&lt;p&gt; &lt;/p&gt;&lt;div class="table"&gt;&lt;a name="AEN455"&gt;&lt;/a&gt;&lt;p&gt;&lt;b&gt;Table 6. NVRAM variables&lt;/b&gt;&lt;/p&gt;&lt;table class="CALSTABLE" rules="all" border="1" frame="border"&gt;&lt;col&gt;&lt;col&gt;&lt;thead&gt;&lt;tr&gt;&lt;th&gt;NVRAM&lt;/th&gt;&lt;th&gt;Description&lt;/th&gt;&lt;/tr&gt;&lt;/thead&gt;&lt;tbody&gt;&lt;tr&gt;&lt;td&gt;&lt;code class="varname"&gt;[name]_ifname&lt;/code&gt;&lt;/td&gt;&lt;td&gt;The firmware image you're uploading was intended for a different model.&lt;/td&gt;&lt;/tr&gt;&lt;tr&gt;&lt;td&gt;&lt;code class="varname"&gt;[name]_ifnames&lt;/code&gt;&lt;/td&gt;&lt;td&gt;Devices to be added to the bridge (only if the above is a bridge)&lt;/td&gt;&lt;/tr&gt;&lt;tr&gt;&lt;td&gt;&lt;code class="varname"&gt;[name]_proto&lt;/code&gt;&lt;/td&gt;&lt;td&gt;The protocol which will be used to configure an IP&lt;/td&gt;&lt;/tr&gt;&lt;tr&gt;&lt;td&gt; &lt;/td&gt;&lt;td&gt;static: Manual configuration (see below)&lt;/td&gt;&lt;/tr&gt;&lt;tr&gt;&lt;td&gt; &lt;/td&gt;&lt;td&gt;dhcp: Perform a DHCP request&lt;/td&gt;&lt;/tr&gt;&lt;tr&gt;&lt;td&gt; &lt;/td&gt;&lt;td&gt;pppoe: Create a ppp tunnel (requires pppoecd package)&lt;/td&gt;&lt;/tr&gt;&lt;tr&gt;&lt;td&gt;&lt;code class="varname"&gt;[name]_ipaddr&lt;/code&gt;&lt;/td&gt;&lt;td&gt;ip address (x.x.x.x)&lt;/td&gt;&lt;/tr&gt;&lt;tr&gt;&lt;td&gt;&lt;code class="varname"&gt;[name]_netmask&lt;/code&gt;&lt;/td&gt;&lt;td&gt;netmask (x.x.x.x)&lt;/td&gt;&lt;/tr&gt;&lt;tr&gt;&lt;td&gt;&lt;code class="varname"&gt;[name]_gateway&lt;/code&gt;&lt;/td&gt;&lt;td&gt;Default Gateway (x.x.x.x)&lt;/td&gt;&lt;/tr&gt;&lt;tr&gt;&lt;td&gt;&lt;code class="varname"&gt;[name]_dns&lt;/code&gt;&lt;/td&gt;&lt;td&gt;DNS server (x.x.x.x)&lt;/td&gt;&lt;/tr&gt;&lt;/tbody&gt;&lt;/table&gt;&lt;/div&gt;        &lt;p&gt; The command &lt;b class="command"&gt;ifup [name] &lt;/b&gt;will configure the interface defined by [name]_ifname according  to the above variables. As an example, the /etc/init.d/S40network script will automatically run the following commands at boot:    &lt;/p&gt;&lt;pre class="screen"&gt;&lt;samp class="prompt"&gt;$&lt;/samp&gt;&lt;b class="command"&gt; ifup lan&lt;/b&gt;&lt;br /&gt;&lt;samp class="prompt"&gt;$&lt;/samp&gt;&lt;b class="command"&gt; ifup wan&lt;/b&gt;&lt;br /&gt;&lt;samp class="prompt"&gt;$&lt;/samp&gt;&lt;b class="command"&gt; ifup wifi&lt;/b&gt;&lt;br /&gt;   &lt;/pre&gt;   &lt;p&gt; The &lt;b class="command"&gt;ifup lan &lt;/b&gt;command will bring up the interface specified by &lt;code class="varname"&gt;lan_ifname&lt;/code&gt;.  Normally the &lt;code class="varname"&gt;lan_ifname&lt;/code&gt; is set to br0 which will cause it to create the bridge br0 and add the  the interfaces from &lt;code class="varname"&gt;lan_ifnames&lt;/code&gt; to the bridge; &lt;code class="varname"&gt;lan_proto&lt;/code&gt; is usually static  which means that br0 will have the ip address from &lt;code class="varname"&gt;lan_ipaddr&lt;/code&gt;, and so on for the rest of the  variables listed above.    &lt;/p&gt;&lt;p&gt; It's important to remember that it's the &lt;code class="varname"&gt;[name]_ifname&lt;/code&gt; that specifies the interfaces,  the [name] compontent itself has almost no value. This means that if you changed &lt;code class="varname"&gt;lan_ifname&lt;/code&gt; to  be the internet port, vlan1, then ifup lan would bring up the internet port, not the lan ports (despite using the  command ifup lan and using the &lt;code class="varname"&gt;lan_ variables&lt;/code&gt;). Also, it means that you can create any  [name] variables you want, &lt;code class="varname"&gt;foo_ifname&lt;/code&gt;, &lt;code class="varname"&gt;foo_proto&lt;/code&gt; .... and they would be used  by &lt;b class="command"&gt;ifup foo&lt;/b&gt;.   &lt;/p&gt;&lt;p&gt; The only [name] with any signfigance is wan, used by the &lt;tt class="filename"&gt;/etc/S45firewall&lt;/tt&gt; script. The firewall  script will NAT traffic through the &lt;code class="varname"&gt;wan_ifname&lt;/code&gt;, blocking connections to  &lt;code class="varname"&gt;wan_ifname&lt;/code&gt;.   &lt;/p&gt;&lt;p&gt; Further information about the variables used can be found at &lt;a href="http://openwrt.org/OpenWrtNVRAM" target="_top"&gt; &lt;i class="citetitle"&gt;OpenWrtNVRAM&lt;/i&gt;&lt;/a&gt;   &lt;/p&gt;&lt;/div&gt;&lt;div class="sect2"&gt;&lt;h2 class="sect2"&gt;&lt;a name="openwrtconfigwireless"&gt;5.3. Wireless Configuration&lt;/a&gt;&lt;/h2&gt;&lt;p&gt; Although the &lt;code class="varname"&gt;wifi_*&lt;/code&gt; variables can be used to configure the network settings of the wireless  interface, the default setting is to include the wireless interface in &lt;code class="varname"&gt;lan_ifnames&lt;/code&gt; and leave the  &lt;code class="varname"&gt;wifi_*&lt;/code&gt; variables unset. If you remove the wireless interface from the lan bridge you can use the  following settings:   &lt;/p&gt;&lt;p&gt; &lt;/p&gt;&lt;div class="table"&gt;&lt;a name="AEN537"&gt;&lt;/a&gt;&lt;p&gt;&lt;b&gt;Table 7. &lt;/b&gt;&lt;/p&gt;&lt;table class="CALSTABLE" rules="all" border="1" frame="border"&gt;&lt;col&gt;&lt;col&gt;&lt;tbody&gt;&lt;tr&gt;&lt;td&gt;&lt;code class="varname"&gt;wifi_ifname&lt;/code&gt;&lt;/td&gt;&lt;td&gt;The wireless interface (eth1 or eth2 depending on hardware revision)&lt;/td&gt;&lt;/tr&gt;&lt;tr&gt;&lt;td&gt;&lt;code class="varname"&gt;wifi_proto&lt;/code&gt;&lt;/td&gt;&lt;td&gt;&lt;span class="emphasis"&gt;&lt;i class="emphasis"&gt;static&lt;/i&gt;&lt;/span&gt; or &lt;span class="emphasis"&gt;&lt;i class="emphasis"&gt;dhcp&lt;/i&gt;&lt;/span&gt;, method used to configure the interface&lt;/td&gt;&lt;/tr&gt;&lt;tr&gt;&lt;td&gt;&lt;code class="varname"&gt;wifi_ipaddr&lt;/code&gt;&lt;/td&gt;&lt;td&gt;IP address to use if &lt;code class="varname"&gt;wifi_proto&lt;/code&gt; is static&lt;/td&gt;&lt;/tr&gt;&lt;tr&gt;&lt;td&gt;&lt;code class="varname"&gt;wifi_netmask&lt;/code&gt;&lt;/td&gt;&lt;td&gt;netmask to use if &lt;code class="varname"&gt;wifi_proto&lt;/code&gt; is static (X.X.X.X notation)&lt;/td&gt;&lt;/tr&gt;&lt;/tbody&gt;&lt;/table&gt;&lt;/div&gt;         &lt;div class="note"&gt;&lt;table class="note" width="100%" border="0"&gt;&lt;tbody&gt;&lt;tr&gt;&lt;td valign="top" width="25" align="center"&gt;&lt;img src="http://cyberforat.squat.net/openwrt/images/note.gif" alt="Note" hspace="5" /&gt;&lt;/td&gt;&lt;td valign="top" align="left"&gt;&lt;p&gt; Note: There are &lt;code class="varname"&gt;wl_*&lt;/code&gt; and &lt;code class="varname"&gt;wl0_*&lt;/code&gt; variables; the &lt;code class="varname"&gt;wl_*&lt;/code&gt;  variables are obsoleted and were replaced by &lt;code class="varname"&gt;wl0_*&lt;/code&gt;.    &lt;/p&gt;&lt;/td&gt;&lt;/tr&gt;&lt;/tbody&gt;&lt;/table&gt;&lt;/div&gt;&lt;p&gt; &lt;/p&gt;&lt;div class="table"&gt;&lt;a name="AEN568"&gt;&lt;/a&gt;&lt;p&gt;&lt;b&gt;Table 8. &lt;/b&gt;&lt;/p&gt;&lt;table class="CALSTABLE" rules="all" border="1" frame="border"&gt;&lt;col&gt;&lt;col&gt;&lt;thead&gt;&lt;tr&gt;&lt;th&gt;NVRAM Setting&lt;/th&gt;&lt;th&gt;Description&lt;/th&gt;&lt;/tr&gt;&lt;/thead&gt;&lt;tbody&gt;&lt;tr&gt;&lt;td&gt;&lt;code class="varname"&gt;wl0_ifname&lt;/code&gt;&lt;/td&gt;&lt;td&gt;Set by wlconf to the name of the ethernet interface (eth1, eth2)&lt;/td&gt;&lt;/tr&gt;&lt;tr&gt;&lt;td&gt;&lt;code cl
