<?xml version="1.0" encoding="utf-8"?>
<rss version="2.0" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:atom="http://www.w3.org/2005/Atom">
	<channel>
		<title>Mount an external USB media as root fs on OpenWRT</title>
		<description>Discuss Mount an external USB media as root fs on OpenWRT</description>
		<link>http://www.rooot.net/en/geek-stuff/openwrt/36-mount-external-usb-root-partition-openwrt.html</link>
		<lastBuildDate>Sat, 11 Apr 2026 08:01:00 +0000</lastBuildDate>
		<generator>JComments</generator>
		<atom:link href="http://www.rooot.net/en/component/jcomments/feed/com_content/36.html" rel="self" type="application/rss+xml" />
		<item>
			<title>Thanks</title>
			<link>http://www.rooot.net/en/geek-stuff/openwrt/36-mount-external-usb-root-partition-openwrt.html#comment-823</link>
			<description><![CDATA[Thank you for pointing out this mistake!
This method should still work on newer versions of OpenWRT. You can also check alternative ways to mount rootfs on external storage at http://wiki.openwrt.org/doc/howto/extroot.]]></description>
			<dc:creator>neo73</dc:creator>
			<pubDate>Sun, 01 Dec 2013 13:18:56 +0000</pubDate>
			<guid>http://www.rooot.net/en/geek-stuff/openwrt/36-mount-external-usb-root-partition-openwrt.html#comment-823</guid>
		</item>
		<item>
			<title>Mistake?</title>
			<link>http://www.rooot.net/en/geek-stuff/openwrt/36-mount-external-usb-root-partition-openwrt.html#comment-601</link>
			<description><![CDATA[Will this work on the current versions of openWRT?
BTW, is this
actually:
opkg install cfdisk e2fsprogs swap-utils]]></description>
			<dc:creator>Saurabh</dc:creator>
			<pubDate>Sun, 01 Sep 2013 15:03:23 +0000</pubDate>
			<guid>http://www.rooot.net/en/geek-stuff/openwrt/36-mount-external-usb-root-partition-openwrt.html#comment-601</guid>
		</item>
		<item>
			<title>Ta! says:</title>
			<link>http://www.rooot.net/en/geek-stuff/openwrt/36-mount-external-usb-root-partition-openwrt.html#comment-547</link>
			<description><![CDATA[Thank you!
This is one of the best written tutorials if have sseen in a while! You Realy saved my day.]]></description>
			<dc:creator>Ta!</dc:creator>
			<pubDate>Thu, 15 Mar 2012 20:18:33 +0000</pubDate>
			<guid>http://www.rooot.net/en/geek-stuff/openwrt/36-mount-external-usb-root-partition-openwrt.html#comment-547</guid>
		</item>
		<item>
			<title>order of scripts</title>
			<link>http://www.rooot.net/en/geek-stuff/openwrt/36-mount-external-usb-root-partition-openwrt.html#comment-531</link>
			<description><![CDATA[neo73 & guys here thanks for this guide & infos
in my case (Backfire) had to modify the script \"START\" & rc.d file to get it to start at a later phase through the inits after the usb was ready ... then all worked very well plenty of new flash space to install new apps packages !
Thanks]]></description>
			<dc:creator>MrTea</dc:creator>
			<pubDate>Sun, 08 Jan 2012 22:00:12 +0000</pubDate>
			<guid>http://www.rooot.net/en/geek-stuff/openwrt/36-mount-external-usb-root-partition-openwrt.html#comment-531</guid>
		</item>
		<item>
			<title>re: mountusb script is not running or is exiting e</title>
			<link>http://www.rooot.net/en/geek-stuff/openwrt/36-mount-external-usb-root-partition-openwrt.html#comment-489</link>
			<description><![CDATA[When booting your system looks for scripts in /etc/rc.d/. You should have a symlink /etc/rc.d/S06mountusb pointing to /etc/init.d/mountusb.
When running the pivot_root command the /etc/rc.d will be replaced by the one in /mnt/root/etc/rc.d/.
This implies all scripts running *after* S06mountusb will be read from /mnt/root/etc/rc.d/. If you want to change a script being executed prior to S06 you have to do it in /etc/rc.d/. If you want to change a script executed after S06 (let\'s say S20fstab) you have to edit the script in /mnt/root/etc/rc.d/.
There\'s no reason this script can\'t be executed. Please double check your permissions & symlink.
I\'m seeing a space in \"START =06\", I hope it\'s a typo in your message (would cause an error in shell script).
You may also read other script in /etc/init.d. My OpenWRT version (Kamikaze 8.09.2 r18961) uses \"START=06\" to define the order of script execution but things may be differents with other versions.]]></description>
			<dc:creator>Guest</dc:creator>
			<pubDate>Wed, 24 Aug 2011 09:36:23 +0000</pubDate>
			<guid>http://www.rooot.net/en/geek-stuff/openwrt/36-mount-external-usb-root-partition-openwrt.html#comment-489</guid>
		</item>
		<item>
			<title>Guest says:</title>
			<link>http://www.rooot.net/en/geek-stuff/openwrt/36-mount-external-usb-root-partition-openwrt.html#comment-475</link>
			<description><![CDATA[At startup, your linux system will execute all scripts found in /etc/rc.d/S*. The mount script is usually named S20fstab which means the S06mountusb script will be executed first (the numbers after S define the order of script execution)
Replacing your root filesystem is not a common mount operation as it require a pivot_root so you won\\\'t be able to do this with a new entry in /etc/config/fstab.
The /etc/localrc script is executed at the very end of system startup so at this point it is too late to replace the root filesystem.
Few tips to track your issue:
First make sure your /etc/init.d/mountusb script has execution permission.
Then change your script so all commands get logged. For example you can change the insmod line to:
insmod $module 2&>1 >> /tmp/usbmount_log
so you\\\'ll get all messages from module loading in a log file. Do the same for all mount commands in the script.
Hope this helps.]]></description>
			<dc:creator>Guest</dc:creator>
			<pubDate>Wed, 24 Aug 2011 09:12:06 +0000</pubDate>
			<guid>http://www.rooot.net/en/geek-stuff/openwrt/36-mount-external-usb-root-partition-openwrt.html#comment-475</guid>
		</item>
		<item>
			<title>mountusb script is not running or is exiting early</title>
			<link>http://www.rooot.net/en/geek-stuff/openwrt/36-mount-external-usb-root-partition-openwrt.html#comment-487</link>
			<description><![CDATA[Hi there,
I added the logging commands like you suggested, but /tmp/mountusb_log is not even being created.
/etc/init.d/mountusb is definitely executable. My only question is, are we talking about /etc/init.d/ in the root filesystem before the reboot or the root filesystem we create in the guide? (ie: /mnt/root/etc/init.d)
I added some lines to echo a message that we are trying to mount the filesystems but these messages do not show up in the startup messages either. therefore, either mountusb is not running or is exiting before it gets to those lines to echo the information.
The only lines before the echo are:
#!/bin/sh /etc/rc.common
EXTERNAL_PARTITION=/dev/sda1
START=06
start() {
echo \"loading USB and ext3 modules\"
etc.]]></description>
			<dc:creator>Catfish</dc:creator>
			<pubDate>Sat, 20 Aug 2011 09:59:17 +0000</pubDate>
			<guid>http://www.rooot.net/en/geek-stuff/openwrt/36-mount-external-usb-root-partition-openwrt.html#comment-487</guid>
		</item>
		<item>
			<title>Trouble having this work</title>
			<link>http://www.rooot.net/en/geek-stuff/openwrt/36-mount-external-usb-root-partition-openwrt.html#comment-474</link>
			<description><![CDATA[I am trying to make my Netgear WGT634U load openwrt from the USB stick. The USB drive is /dev/sda.
I partitioned the drive so Linux ext3 is sda1 and swap sda2.
I have all the packages installed as listed above and can manually mount the drive. I cannot make it mount the swap partition.
I have followed the instructions from \"Copy all fs into new mounted partition.\" onwards but the device will not boot from the USB drive. It actually doesn\'t auto mount the device on start up. I edited /etc/config/fstab with settings to automount the drive but it doesn\'t.
I am unsure when the mountusb script runs, i assume at runtime at some point but I can\'t see any output from it in the system logs via the web interface. The only way I can see it in the log is if I add a command to run it in /etc/rc.local
Is there a way to know when this is being started or if it is running and failing?]]></description>
			<dc:creator>Catfish</dc:creator>
			<pubDate>Sat, 02 Jul 2011 11:14:42 +0000</pubDate>
			<guid>http://www.rooot.net/en/geek-stuff/openwrt/36-mount-external-usb-root-partition-openwrt.html#comment-474</guid>
		</item>
		<item>
			<title>device is probably different</title>
			<link>http://www.rooot.net/en/geek-stuff/openwrt/36-mount-external-usb-root-partition-openwrt.html#comment-473</link>
			<description><![CDATA[i have found my device is usually something like /dev/sda and not the long scsi device names in this guide. if you are able to already mount your usb device manually, use the device name you use to mount it. mine is /dev/sda1 so i mount like:
mount /dev/sda1 /mnt/root
so i would use: cfdisk /dev/sda
note to use just the device name, not the partition number when you run cfdisk (because you are working on an entire device, not a single partition).]]></description>
			<dc:creator>Catfish</dc:creator>
			<pubDate>Sat, 02 Jul 2011 05:50:46 +0000</pubDate>
			<guid>http://www.rooot.net/en/geek-stuff/openwrt/36-mount-external-usb-root-partition-openwrt.html#comment-473</guid>
		</item>
		<item>
			<title>Guest says:</title>
			<link>http://www.rooot.net/en/geek-stuff/openwrt/36-mount-external-usb-root-partition-openwrt.html#comment-468</link>
			<description><![CDATA[Hi, I\'m running Kamikaze 8.09.2 (r18961). What\'s the output of dmesg when you plug your usb drive?]]></description>
			<dc:creator>Guest</dc:creator>
			<pubDate>Fri, 17 Jun 2011 18:40:49 +0000</pubDate>
			<guid>http://www.rooot.net/en/geek-stuff/openwrt/36-mount-external-usb-root-partition-openwrt.html#comment-468</guid>
		</item>
		<item>
			<title>Which version/build/revision of openwrt you are us</title>
			<link>http://www.rooot.net/en/geek-stuff/openwrt/36-mount-external-usb-root-partition-openwrt.html#comment-467</link>
			<description><![CDATA[Hi, Your guide is nice, but i stuck at ~$ cfdisk /dev/scsi/host1/bus0/target0/lun0/disc
I cannot see scsi in /dev/ can you please help ?]]></description>
			<dc:creator>barshad</dc:creator>
			<pubDate>Fri, 17 Jun 2011 18:28:44 +0000</pubDate>
			<guid>http://www.rooot.net/en/geek-stuff/openwrt/36-mount-external-usb-root-partition-openwrt.html#comment-467</guid>
		</item>
	</channel>
</rss>
