# CWM Scripting Help, Mounting /system



## trparky (Sep 3, 2011)

I've seen this line used to mount /system in other CWM packages...
_run_program("/sbin/mount", "-t", "rfs", "-ollw,check=no,nosuid,nodev", "/dev/block/stl10", "/system");_

But, from the looks of it, it looks like it will only work with RFS-based file systems, not EXT4-based file systems for people who opted to enable Voodoo Lag Fix.

I've also seen lines that looks like this...
_run_program("/sbin/busybox", "mount", "/system");_
and
_mount("MTD", "system", "/system");_

What would be a good way to mount /system using one universal command that will work on both EXT4 and RFS? Why I ask is that I've seen CWM packages that try to automatically mount /system, some work, some don't; hence the reason why most people suggest to manually mount /system in the Mounts and Storage menu in CWM. But what I'm trying to go for is a, at least in the packages I've made which have been about three packages, is for a completely seamless routine. Select the ZIP, run, done.

I could make it so that when people use my CWM packages the instructions are that you must mount /system yourself manually but I'm trying to make it as seamless as possible for the complete n00b.


----------



## trparky (Sep 3, 2011)

mount("BML", "system", "/system");

That appears to be the command that's used in the EE4->EP4D update ZIP that was made by Samsung. Who am I to argue with the developers of the phone (Samsung)?


----------



## imnuts (Jun 9, 2011)

The reason the command is different is that in CWM, there is a wrapper script to replace the default functionality of mount.


----------



## trparky (Sep 3, 2011)

So which one should I use? The one used by Samsung?


----------

