[Q] SD wrong size ... - Nook Color Q&A, Help & Troubleshooting

I have a 2GB card in my NC, and it's only showing 1.00GB size on the NC.
When I plug it into the computer over USB, it shows only 1.00GB.
When I pull the card and put it in the computer using the builtin card reader, it shows 2GB as it should.
What gives?
I have a new card on the way, 32GB, don't want to wind up with the same issue. Help?

?s
1. did you use it to nooter/install CWM? Some of the SD card CWM installers reformat the sd card to 1gb
Use easus partition to format the entire SD card and fix this...
2. did you get it off ebay? some people have reported getting fake cards there (where the actual capacity of the card is less than reported) though typically they can get it to fake the higher capacity until you write to it above its actual capacity.

I formatted it to 2GB in my computer. I can put the card directly into my computer and write 2GB on it. The problem with the card only occurs when it is in the NC.
??

and with file explorer can you see the 2gb of files on the sd when it's in the NC?
what happens when you connect to the NC as a flash drive? can you see the 2gb of files then? Do you also see your media partition?
The nook color internal memory has two partitions. A system partition and a media partition that you can connect to over usb. Some versions of Nook color had the media partition formatted to be 1gb.

gallahad2000 said:
and with file explorer can you see the 2gb of files on the sd when it's in the NC?
what happens when you connect to the NC as a flash drive? can you see the 2gb of files then? Do you also see your media directory?
The nook color has two partitions. A system partition and a media partition that you can connect to over usb. Some versions of Nook color had the media partition formatted to be 1gb.
Click to expand...
Click to collapse
{
"lightbox_close": "Close",
"lightbox_next": "Next",
"lightbox_previous": "Previous",
"lightbox_error": "The requested content cannot be loaded. Please try again later.",
"lightbox_start_slideshow": "Start slideshow",
"lightbox_stop_slideshow": "Stop slideshow",
"lightbox_full_screen": "Full screen",
"lightbox_thumbnails": "Thumbnails",
"lightbox_download": "Download",
"lightbox_share": "Share",
"lightbox_zoom": "Zoom",
"lightbox_new_window": "New window",
"lightbox_toggle_sidebar": "Toggle sidebar"
}
1.00 Gb according to the NC.
As I said, when I connect the NC to the computer over USB it also appears as 1 gb. When I remove the card and put it directly into the computer it is 2 gb.
There is no media directory.
It appears the NC doesn't correctly recognize the card.

mr72 said:
It appears the NC doesn't correctly recognize the card.
Click to expand...
Click to collapse
If you remove the SD card does the 1.0gb or 1.88gb partition disappear?

Some things don't look right in there, in your posted image.
You got Internal storage of 5.09GB (it is the first weird one), then you got Additional storage (/mnt/emmc) of 1.86GB (it is another weird one).
Normally, we have either
1. old scheme: 1GB /data, 5GB /media
2. new scheme: 5GB /data, 1GB /media
3. custom scheme: 1.96GB /data, 4+GB /media.
Yours doesn't look right.

votinh said:
Some things don't look right in there, in your posted image.
You got Internal storage of 5.09GB (it is the first weird one), then you got Additional storage (/mnt/emmc) of 1.86GB (it is another weird one).
Normally, we have either
1. old scheme: 1GB /data, 5GB /media
2. new scheme: 5GB /data, 1GB /media
3. custom scheme: 1.96GB /data, 4+GB /media.
Yours doesn't look right.
Click to expand...
Click to collapse
Well I just did the normal install of cm 7.10 stable and no partitioning. However my problem is the SD. I am not particularly worried about the internal flash partitioning.
Any ideas why I can't use more than 1gb of SD? I have a 32gb SD card arriving today. I really would like to get to the bottom of this.

There is no /media partition mounted on my nook color.
$ export PATH=/data/local/bin:$PATH
$ mount
rootfs on / type rootfs (ro,relatime)
tmpfs on /dev type tmpfs (rw,relatime,mode=755)
devpts on /dev/pts type devpts (rw,relatime,mode=600)
proc on /proc type proc (rw,relatime)
sysfs on /sys type sysfs (rw,relatime)
tmpfs on /mnt/asec type tmpfs (rw,relatime,mode=755,gid=1000)
tmpfs on /mnt/obb type tmpfs (rw,relatime,mode=755,gid=1000)
none on /dev/cpuctl type cgroup (rw,relatime,cpu)
/dev/block/mmcblk0p2 on /rom type vfat (rw,noatime,nodiratime,uid=1000,gid=1000,fmask=0117,dmask=0007,allow_utime=0020,codepage=cp437,iocharset=iso8859-1,shortname=mixed,errors=remount-ro)
/dev/block/mmcblk0p5 on /system type ext4 (ro,relatime,barrier=1,data=ordered)
/dev/block/mmcblk0p6 on /data type ext4 (rw,nosuid,nodev,noatime,barrier=1,data=ordered,noauto_da_alloc)
/dev/block/mmcblk0p7 on /cache type ext4 (rw,nosuid,nodev,noatime,barrier=1,data=ordered)
/sys/kernel/debug on /sys/kernel/debug type debugfs (rw,relatime)
/dev/block/vold/179:8 on /mnt/sdcard type vfat (rw,dirsync,nosuid,nodev,noexec,relatime,uid=1000,gid=1015,fmask=0602,dmask=0602,allow_utime=0020,codepage=cp437,iocharset=iso8859-1,shortname=mixed,utf8,errors=remount-ro)
/dev/block/vold/179:8 on /mnt/secure/asec type vfat (rw,dirsync,nosuid,nodev,noexec,relatime,uid=1000,gid=1015,fmask=0602,dmask=0602,allow_utime=0020,codepage=cp437,iocharset=iso8859-1,shortname=mixed,utf8,errors=remount-ro)
tmpfs on /mnt/sdcard/.android_secure type tmpfs (ro,relatime,size=0k,mode=000)
/dev/block/vold/179:17 on /mnt/emmc type vfat (rw,dirsync,nosuid,nodev,noexec,relatime,uid=1000,gid=1015,fmask=0602,dmask=0602,allow_utime=0020,codepage=cp437,iocharset=iso8859-1,shortname=mixed,utf8,errors=remount-ro)
/dev/block/dm-0 on /mnt/asec/pl.idreams.jellydefense-1 type vfat (ro,dirsync,nosuid,nodev,relatime,uid=1000,fmask=0222,dmask=0222,codepage=cp437,iocharset=iso8859-1,shortname=mixed,utf8,errors=remount-ro)
/dev/block/dm-1 on /mnt/asec/com.devolver.sska-2 type vfat (ro,dirsync,nosuid,nodev,relatime,uid=1000,fmask=0222,dmask=0222,codepage=cp437,iocharset=iso8859-1,shortname=mixed,utf8,errors=remount-ro)
$ mount |grep media
$cd /media
cd: can't cd to /media
$

mr72 said:
Well I just did the normal install of cm 7.10 stable and no partitioning. However my problem is the SD. I am not particularly worried about the internal flash partitioning.
Any ideas why I can't use more than 1gb of SD? I have a 32gb SD card arriving today. I really would like to get to the bottom of this.
Click to expand...
Click to collapse
Just a stab in the dark but I have found most of my issues with uSD (and quality brands such as SanDisc) cards have gone back to how the card was formatted. I now never format in the device, nor do I use Windows to format. I've mentioned this before but it bears mentioning again, this free utility has never failed giving me a good intact format on cards of sizes 1G to 32G. Try it out here.
HTH

My NC is partitioned like this:
Code:
Disk /dev/block/mmcblk0: 7944 MB, 7944011776 bytes
255 heads, 63 sectors/track, 965 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes
Device Boot Start End Blocks Id System
/dev/block/mmcblk0p1 * 1 9 72261 c Win95 FAT32 (LBA)
/dev/block/mmcblk0p2 10 18 72292+ c Win95 FAT32 (LBA)
/dev/block/mmcblk0p3 19 56 305235 83 Linux
/dev/block/mmcblk0p4 57 965 7301542+ 5 Extended
/dev/block/mmcblk0p5 57 114 465853+ 83 Linux
/dev/block/mmcblk0p6 115 789 5421906 83 Linux
/dev/block/mmcblk0p7 790 834 361431 83 Linux
/dev/block/mmcblk0p8 835 965 1052226 c Win95 FAT32 (LBA)
I think this is default for the "new" partition style (which I will soon change).
However this is not affecting my SD card.
I should get my 32GB SD in the mail today or tomorrow. I suppose I will know soon enough whether I can use more than 1G on THAT card.

While trying to poke around on this NC and figure out exactly how the partitions are working, I discovered another thing which may be normal but sure seems odd to me.
The /emmc and /sdcard contents (directory names) are nearly identical.
Code:
ls /emmc
Android Music clockworkmod
B&N Downloads My Files com.maildroid
Books Nook data
DCIM OverDrive dropbox
Digital Editions ReceivedFiles eBooks
Download TempAudio fix_permissions.log
Evernote TunnyBrowser opera
GOLauncherEX Videos tmp
GoStore adobe
LOST.DIR backups
# ls /sdcard
ls /sdcard
Android My Files com.maildroid
B&N Downloads Nook data
Books OverDrive dropbox
DCIM ReceivedFiles eBooks
Digital Editions TempAudio fix_permissions.log
Download TunnyBrowser notes
GOLauncherEX Videos opera
GoStore adobe tmp
LOST.DIR backups
Music clockworkmod
#
Creating a file on one does not create it on the other. But some of the directories have identical files. For example the Titaniumbackup files in the /data dir on both /emmc and /sdcard are identical. I didn't check any others.
This seems quite odd. Comments?

OK, I think maybe I am getting to the bottom of this!
on my NC, when I take the SD card completely OUT, I can still view files mounted on /sdcard
So I am not convinced that my /sdcard mountpoint is actually reflecting the SD card directly.
When I unmount the SD card in the "Storage" settings, and I get the "Safe to remove..." notification, I presume the actual SD card is not mounted.
I removed the SD card from the NC and reformatted it using Panasonic SDFormatter. It's 1.86GB and has no files on it.
Without the SD card in my NC, it operates normally and still thinks it's writing to the /mnt/sdcard for things like downloading files.
My suspicion is that the partition normally mounted to /media is mounted to /mnt/sdcard
Code:
# df
df
Filesystem 1K-blocks Used Available Use% Mounted on
tmpfs 245892 32 245860 0% /dev
tmpfs 245892 0 245892 0% /mnt/asec
tmpfs 245892 0 245892 0% /mnt/obb
/dev/block/mmcblk0p2 71164 108 71056 0% /rom
/dev/block/mmcblk0p5 458532 169376 289156 37% /system
/dev/block/mmcblk0p6 5336664 688980 4376592 14% /data
/dev/block/mmcblk0p7 350018 42216 289731 13% /cache
/dev/block/vold/179:8 1050156 1029924 20232 98% /mnt/sdcard
/dev/block/vold/179:8 1050156 1029924 20232 98% /mnt/secure/asec
THERE IS NO SD CARD IN THE NC.
Looks like the NC still THINKS the sd card is mounted.
Notice there also is no mount point for /media
The partition I'd expect to be mounted at /media (/dev/block/mmcblk0p8) is not mounted.
Please, someone explain this to me! Seriously, what's the Nook Color's partition scheme?

mr72 said:
OK, I think maybe I am getting to the bottom of this!
on my NC, when I take the SD card completely OUT, I can still view files mounted on /sdcard
So I am not convinced that my /sdcard mountpoint is actually reflecting the SD card directly.
When I unmount the SD card in the "Storage" settings, and I get the "Safe to remove..." notification, I presume the actual SD card is not mounted.
I removed the SD card from the NC and reformatted it using Panasonic SDFormatter. It's 1.86GB and has no files on it.
Without the SD card in my NC, it operates normally and still thinks it's writing to the /mnt/sdcard for things like downloading files.
My suspicion is that the partition normally mounted to /media is mounted to /mnt/sdcard
Code:
# df
df
Filesystem 1K-blocks Used Available Use% Mounted on
tmpfs 245892 32 245860 0% /dev
tmpfs 245892 0 245892 0% /mnt/asec
tmpfs 245892 0 245892 0% /mnt/obb
/dev/block/mmcblk0p2 71164 108 71056 0% /rom
/dev/block/mmcblk0p5 458532 169376 289156 37% /system
/dev/block/mmcblk0p6 5336664 688980 4376592 14% /data
/dev/block/mmcblk0p7 350018 42216 289731 13% /cache
/dev/block/vold/179:8 1050156 1029924 20232 98% /mnt/sdcard
/dev/block/vold/179:8 1050156 1029924 20232 98% /mnt/secure/asec
THERE IS NO SD CARD IN THE NC.
Looks like the NC still THINKS the sd card is mounted.
Notice there also is no mount point for /media
The partition I'd expect to be mounted at /media (/dev/block/mmcblk0p8) is not mounted.
Please, someone explain this to me! Seriously, what's the Nook Color's partition scheme?
Click to expand...
Click to collapse
If there is no SD in... the vold.conf is setup to mount /dev/block/mmcblk0p8 as /sdcard...
Code:
## vold configuration file for zoom2
# modified for encore
volume_sdcard {
## This is the direct uevent device path to the SD slot on the device
media_path /devices/platform/mmci-omap-hs.1/mmc_host/mmc0
partition 8
media_type mmc
##mount_point /sdcard
mount_point /media
ums_path /devices/platform/usb_mass_storage/lun0
}
volume_sdcard2 {
## Currently points to internal eMMC, assumes eMMC is formatted as FAT32
media_path /devices/platform/mmci-omap-hs.0/mmc_host/mmc1
media_type mmc
partition 4
##mount_point /media
mount_point /sdcard
ums_path /devices/platform/usb_mass_storage/lun1
}

That doesn't seem to be the case, although it would make sense.
Looks like my sdcard is mounted at /mnt/emmc.
Rebooting into CWM after reformatting my SD card and putting it back in blank, putting a couple of files on it, it is found in CWM as /sdcard.
Once I boot, I find that content in /mnt/emmc.

Perhaps this explains it:
http://forum.cyanogenmod.com/topic/36236-help-sd-card-and-emmc-changed-places/

I've had the same issue as the OP since installing CM7 a few weeks ago. It really had me baffled, but I tried the fix linked above just now and it did the trick thank you mr72!
Sent from my NookColor using xda premium

CountKrzysztof said:
I've had the same issue as the OP since installing CM7 a few weeks ago. It really had me baffled, but I tried the fix linked above just now and it did the trick thank you mr72!
Sent from my NookColor using xda premium
Click to expand...
Click to collapse
OK, so to reiterate:
If you have CM7 installed, and in Settings -> Cyanogenmod Settings -> Application Settings, you check "Use internal storage", then CM7 will SWAP the SD card and the internal 1G (default) "Additional storage:/mnt/emmc" partition. The result is that your SD card will be mounted at /mnt/emmc and your internal memory 1G partition will be mounted at /mnt/sdcard.
Also, when you plug the NC into the computer if you have these swapped, then the 1G "internal memory" will be mounted on your computer, rather than the sdcard.
In actuality, this is a good thing, and there is a hack out there to swap these, therefore making use of the normally unused partition that by default in CM7 would be mounted at /mnt/emmc.

I'm lost following your posts but I know
/mnt/emmc is the additional internal storage and /mnt/sdard is the external uSD card.
That's the case when running CM7 off eMMC.
It's set by default, otherwise, maybe I have to set something to twist around.
Also, when having uSD plugged in, connecting to PC (Windows), both mounted as you would see the 1G internal AND the CM7SDCARD

Related

reformat whole sdcard as ext2/3/4

Hi,
There are a couple of threads asking this, but as far as I can see the problems are different on the DHD.
I use Linux pretty-much everywhere so have no need to read fat filesystems.
From what I can see by doing a mount, ext3 support is builtin
Code:
$mount | grep ext
/dev/block/mmcblk0p25 /system ext3 ro,relatime,errors=continue,data=ordered 0 0
/dev/block/mmcblk0p26 /data ext3 rw,nosuid,nodev,relatime,errors=continue,data=ordered 0 0
/dev/block/mmcblk0p27 /cache ext3 rw,nosuid,nodev,relatime,errors=continue,data=ordered 0 0
/dev/block/mmcblk0p28 /devlog ext3 rw,nosuid,nodev,relatime,errors=continue,data=ordered 0
So no custom kernel should be needed.
I tried re-creating the filesystem as ext3, but the phone wouldn't mount the partition. As there's no /etc/fstab in Android, I'm guessing the filesystems are listed somewhere else. Can anyone say where?
Second question: Journalling will write to the card more than I'd like, but I'm guessing ext3 or 4 with the journalling moved to the internal memory would be faster than ext2??
Anyone know of any drawbacks? What about ext4 support on the DHD, anyone know if it's there?

Alternative to Apps2SD

After looking at the file system of the X10 and noticing lots of empty space on the /system partition and the fact I wanted more space for apps but didn't want to use my class 2 SD card (that is already pretty full!), I decided to try moving some of my larger apps and pointing to the new location using symlinks (like what apps2sd does). Got over 70mb extra space and no probs no far. New apps will just be installed in /data/app/ as before.
Goes without saying that you do this at your own risk and to make a backup first!
This hack of course requires root! And busybox installed.
First copy the apk file to /system/app2/ say (/system/app/ is already used for some system apps so I decided not to copy their so I could keep them separate.)
Check this is done correctly (I used root explorer) but if the command completed with no errors it should be ok. May need to mount /system as read/write.
Then delete the original file and create a symlink to the new file. (If the first step was done incorrectly this step will remove the app!)
I used an app called Scripter to read QR codes I generated from http://qrcode.kaywa.com/ (use text mode) with the code I wrote on my PC, just scan your comp screen with phone camera and it gives you the option to execute the text. (Or you could spend hours typing it in by hand.) adb didn't work for step 2 when I tried it (access denied).
If step 1 says access denied use root explorer to mount /system as read write and try again or use adb to copy the apps ("adb shell" then use the "busybox cp /data/app/com.rovio.angrybirds.apk /system/app2/com.rovio.angrybirds.apk" command)
Example with angrybirds:
First find the name of the .apk file (I used root explorer and navagated to /data/app/ and ordered by size) in this case "com.rovio.angrybirds.apk"
Copy it:
busybox cp /data/app/com.rovio.angrybirds.apk /system/app2/com.rovio.angrybirds.apk
Delete old file and create symlink:
busybox rm /data/app/com.rovio.angrybirds.apk
busybox ln -s /system/app2/com.rovio.angrybirds.apk /data/app/com.rovio.angrybirds.apk
I used notepad "find and replace" to change "com.rovio.angrybirds.apk" to the name of a different app and repeated.
Here are the names of the apps I moved (to save you typing out the names, all near the top of the list in terms of size).
com.polarbit.krazyracers.apk
com.rovio.angrybirds.apk
com.skype.raider.apk
com.fring.apk
com.qype.radar.apk
com.galcon.igalcon.apk
Hope this helps people who like me want more space for apps without using their SD card. Any probs ask here and hopefully I or someone else can help.
Shaun
i wonder if this really works
not calling into question what you say but I think in the long run is able to consume more resources (or at least the same) due to the fact that they also use a folder within the system...
just a thought
but hey, if it works ... WOW
I'd like to see it implemented in a sh script, accepting app name to move as a command line argument.
Or, even better - an apk, which lists all apps installed, and does moving selected ones. Should not be difficult to implement.
thanks for this, but can i do it on HTC Wildfire where it could actually matter?
and btw, currently my system folder has 175MB free space, how low do you think would be too low? how much free space really has to be free?
If by more resources you mean phone memory? Then yes it consumes the same amount of memory but as /system is on a different partition it consumes the memory in a different place (kind of like a different hard drive in your comp, google partitioning).
I'd love to make this into an app but have no idea where to start, prob wouldn't be too hard though, just a gui that passes busybox commands to the shell, with maybe some safe guards, say leave 50meg free, check its copied correctly ect, wonder if other phones have free space in /system as well? No idea with the script either or how to build a safeguard if command 1 fails don't do 2 and 3, but if someone can run a script they can prob do this.
Yeah should work on other phones if /system is mounted on a different partition and has free space. Run "df" (without quotes) in terminal or using adb run "adb shell" after you've connected to your phone and then "df" and post your output here and I'll let you know. My phone starts to complain (memory low message in status bar) and drop sms messages (really bad bug/feature!) when I get below 50meg, hence the reason for me doing this.
I tried to do the same thing but use /nand (internal storage) and link is created in /data/app but doesnt appear in drawer
It looks permission are the problem
have you tried Link2SD?
This is the only thing that is simple enough for everyone
Adolf1994 said:
have you tried Link2SD?
This is the only thing that is simple enough for everyone
Click to expand...
Click to collapse
Tried and couldnt have my SD recognize by my tablet after making the second partition.
I really like to make link2sd work but as soon I create the secont FAT32 or ext2 or ext3 card disapear
enotar said:
Tried and couldnt have my SD recognize by my tablet after making the second partition.
I really like to make link2sd work but as soon I create the secont FAT32 or ext2 or ext3 card disapear
Click to expand...
Click to collapse
tablet? what kind of tablet? if you partitioned the card wrong, it could cause unexpected things. I prefer to do it with SuperOS(formerly Super Ubuntu) distro or any kind of Ubuntu.
if that tablet is 2.1 then this should work, but if it's 2.2+ then app2sd is exactly you need.
Adolf1994 said:
tablet? what kind of tablet? if you partitioned the card wrong, it could cause unexpected things. I prefer to do it with SuperOS(formerly Super Ubuntu) distro or any kind of Ubuntu.
if that tablet is 2.1 then this should work, but if it's 2.2+ then app2sd is exactly you need.
Click to expand...
Click to collapse
Tablet: HSG-X5A-G 2.1
I format with a PC with Ubuntu and not recognize I even try with minitool on another PC
I did on ubuntu with 8gb SD Card X6 and gparted:
delete all partition on SD card apply
create a partition (1) of 8gb primary FAT32 apply
resize to 7.5gb this partition apply
create 0.5gb partition (2) with the free space after resize primary FAT32 apply.
set partition (1) active
put the card in tablet
and no detection of the card.
If I delete the 500 meg (2) partition the sdcard is imediately recognize after putting back in the tablet.
I even try second partition with ext2 or ext3 try too formating with clockwork recovery menu.I try too to copy to the new formated SD the dir Android, Android-secure and Lost.Dir...... Nothing work.
The second partition make my SD unrecognizable.
I even try to create a linux swap file of 32 meg and no chance too.
If someone can explain me why?
did you use cwm to format things? for now avoid things like this
if you have root(have you?), then please download irssi connectbot from market, open it, set the pulldown list to 'local' at the bottom and give it a name, enter.
then open the newly created connection, issue these commands and post the results here(with the sd card working):
Code:
$ su <- after this allow superuser access
# mount
Adolf1994 said:
did you use cwm to format things? YES
if you have root(have you?), YES
Click to expand...
Click to collapse
Result with my working 16gb card:
rootfs / rootfs ro 0 0tmpfs /dev tmpfs rw,mode=755 0 0
devpts /dev/pts devpts rw,mode=600 0 0
proc /proc proc rw 0 0
sysfs /sys sysfs rw 0 0
tmpfs /sqlite_stmt_journals tmpfs rw,size=4096k 0 0
tmpfs /broadcasting tmpfs rw,size=1024k 0 0
/dev/block/mtdblock2 /system yaffs2 ro 0 0
/dev/block/mtdblock5 /data yaffs2 rw,nosuid,nodev 0 0
/dev/block/mtdblock4 /cache yaffs2 rw,nosuid,nodev 0 0
/dev/block/ndda1 /nand vfat rw,dirsync,nosuid,nodev,noexec,uid=1000,gid=1015,fma
sk=0702,dmask=0702,allow_utime=0020,codepage=cp437,iocharset=iso8859-1,shortname=mixed,utf8,errors=remount-ro 0 0
/dev/block//vold/179:1 /sdcard vfat rw,dirsync,nosuid,nodev,noexec,uid=1000,gid=1015,fmask=0702,dmask=0702,allow_utime=0020,codepage=cp437,iocharset=iso8859-1,shortname=mixed,utf8,errors=remount-ro 0 0
if you put in the partitioned card, does Android notifies you to format it or doesn't even do that?
if it notifies you, please try to issue this command as superuser:
Code:
mount /dev/block//vold/179:1 /sdcard -t vfat -o rw,dirsync,nosuid,nodev,noexec,uid=1000,gid=1015,fmask=0702,dmask=0702,allow_utime=0020,codepage=cp437,iocharset=iso8859-1,shortname=mixed,utf8,errors=remount-ro
Adolf1994 said:
if you put in the partitioned card, does Android notifies you to format it or doesn't even do that?
Click to expand...
Click to collapse
Dont even do that, no message at all
then issue the command anyway, and see if it works, if not, then post the results here
I create the second partition on the card (space was free) as primary and FAT32 put back the card in the tablet.
As the card was not recognize i use PC with adb:
adb remount
adb shell
su
mount /dev/block//vold/179:1 /sdcard -t vfat -o rw,dirsync,nosuid,nodev,noexec,uid=1000,gid=1015,fmask=0702,dmask=0702,allow_utime=0020,codepage=cp437,iocharset=iso8859-1,shortname=mixed,utf8,errors=remount-ro
I get :
mount /dev/block//vold/179:1 /sdcard -t vfat -o rw,dirsync,nosuid,nodev,noexec,u
id=1000,gid=1015,fmask=0702,dmask=0702,allow_utime=0020,codepage=cp437,iocharset
=iso8859-1,shortname=mixed,utf8,errors=remount-ro
Usage: mount [-r] [-w] [-o options] [-t type] device directory
oh, the sequence that matters!
then type this:
Code:
mount -o rw,dirsync,nosuid,nodev,noexec,uid=1000,gid=1015,fmask=0702,dmask=0702,allow_utime=0020,codepage=cp437,iocharset=iso8859-1,shortname=mixed,utf8,errors=remount-ro -t vfat /dev/block//vold/179:1 /sdcard
Adolf1994 said:
oh, the sequence that matters!
then type this:
Code:
mount -o rw,dirsync,nosuid,nodev,noexec,uid=1000,gid=1015,fmask=0702,dmask=0702,allow_utime=0020,codepage=cp437,iocharset=iso8859-1,shortname=mixed,utf8,errors=remount-ro -t vfat /dev/block//vold/179:1 /sdcard
Click to expand...
Click to collapse
Result:
Usage: mount [-r] [-w] [-o options] [-t type] device directorymount -o rw,dirsyn
c,nosuid,nodev,noexec,uid=1000,gid=1015,fmask=0702,dmask=0702,allow_utime=0020,c
odepage=cp437,iocharset=iso8859-1,shortname=mixed,utf8,errors=remount-ro -t vfat
/dev/block//vold/179:1 /sdcard
Usage:: not found
Re runing give me this now:
mount -o rw,dirsync,nosuid,nodev,noexec,uid=1000,gid=1015,fmask=0702,dmask=0702,
allow_utime=0020,codepage=cp437,iocharset=iso8859-1,shortname=mixed,utf8,errors=
remount-ro -t vfat /dev/block//vold/179:1 /sdcard
[1] + Stopped (signal) mount -o rw,dirsync,nosuid,nodev,noexec,uid=1000,g
id=1015,fmask=0702,dmask=0702,allow_utime=0020,codepage=cp437,iocharset=iso8859-
1,shortname=mixed,utf8,errors=remount-ro -t vfat /dev/block//vold/...
well, it looks like it's too high for me.
try to find the tablet's subforum and/or another senior member with the same tablet.
hope you can solve it
and please post here the things you found
Thank you very much to try....

File System Diagram?

My brother and I are curious as to what is up with the File System in these phones involving the internal Memory and SD Card. He has a different GS and his file system is soo much stranger. However I'm more interested in how this Fascinate works
It claims 2gb internal memory But where in the file system is this internal memory? Where is the A2SD Memory? Where is all this stuff, say in like Root Explorer?
Here's a screen shot of the Fascinate with a 8gb SD Card
{
"lightbox_close": "Close",
"lightbox_next": "Next",
"lightbox_previous": "Previous",
"lightbox_error": "The requested content cannot be loaded. Please try again later.",
"lightbox_start_slideshow": "Start slideshow",
"lightbox_stop_slideshow": "Stop slideshow",
"lightbox_full_screen": "Full screen",
"lightbox_thumbnails": "Thumbnails",
"lightbox_download": "Download",
"lightbox_share": "Share",
"lightbox_zoom": "Zoom",
"lightbox_new_window": "New window",
"lightbox_toggle_sidebar": "Toggle sidebar"
}
It shows the SD Card, which I get that, in Root Explorer its /sdcard/. However where is the 191mb that is completely empty of A2SD? Where is the 1.53gb of Internal Storage?
I know on my Inc, Internal memory is /emmc/ and sd is /sdcard/
Not one person on this forum knows how this phones file system is setup?
Its RFS file system, voodoo converts it to ext4. Apparently ext4 is more efficient/effective, specifically write operations. I'm no programmer so that's the extent of my knowledge.
Sent from my SCH-I500
nFiniti said:
It shows the SD Card, which I get that, in Root Explorer its /sdcard/. However where is the 191mb that is completely empty of A2SD? Where is the 1.53gb of Internal Storage?
Click to expand...
Click to collapse
I think Internal storage is /data, System storage is /system, System cache is /cache, and A2SD storage is /mnt/asec.
skreeves said:
I think Internal storage is /data, System storage is /system, System cache is /cache, and A2SD storage is /mnt/asec.
Click to expand...
Click to collapse
Thanks. Stupid Verizon claiming 2gb internal storage but there isn't any real internal storage. You must have a SD Card to do anything on the phone.
mrodsunshine said:
Its RFS file system, voodoo converts it to ext4. Apparently ext4 is more efficient/effective, specifically write operations. I'm no programmer so that's the extent of my knowledge.
Sent from my SCH-I500
Click to expand...
Click to collapse
Its slower, but more efficient and safer. But not what I was asking. I was asking for some kinda Diagram of the Storage Locations and what not like
IE: /mnt/sdcard = External SD Card.
No, there is internal storage. Take your microSD out and see if it still works... It might be an internal permanent SD card for all I know but it's there. Some of the other Galaxy S phones have both internal 16GB SD and an empty slot though which would have been nice to have.
I'm pretty sure RFS is not safer and definitely not more efficient... but by the way, most mount points are on the internal storage. Only /mnt/sdcard is on the sd card (big surprise).
If you want exact mount points for everything, run mount in a terminal emulator.
nFiniti said:
Thanks. Stupid Verizon claiming 2gb internal storage but there isn't any real internal storage. You must have a SD Card to do anything on the phone.
Click to expand...
Click to collapse
Yeah. There totally is internal storage. It's 2GB NAND flash storage. Totally not removeable.
Sent from my SCH-I500 using XDA App
here is eb16 with voodoo:
Code:
# mount
rootfs / rootfs rw 0 0
proc /proc proc rw,relatime 0 0
sys /sys sysfs rw,relatime 0 0
/dev/block/stl9 /system ext4 rw,noatime,barrier=0,data=writeback,noauto_da_alloc 0 0
/dev/block/stl11 /cache ext4 rw,noatime,barrier=0,data=writeback,noauto_da_alloc 0 0
/dev/block/stl10 /dbdata ext4 rw,noatime,barrier=0,nodelalloc,data=ordered,noauto_da_alloc 0 0
/dev/block/mmcblk0p1 /data ext4 rw,noatime,barrier=1,data=ordered,noauto_da_alloc 0 0
tmpfs /dev tmpfs rw,relatime,mode=755 0 0
devpts /dev/pts devpts rw,relatime,mode=600 0 0
/dev/block/stl6 /mnt/.lfs j4fs rw,relatime 0 0
tmpfs /mnt/asec tmpfs rw,relatime,mode=755,gid=1000 0 0
tmpfs /sqlite_stmt_journals tmpfs rw,relatime,size=4096k 0 0
none /dev/cpuctl cgroup rw,relatime,cpu 0 0
/dev/block/mmcblk0p2 /data/fota rfs rw,nosuid,nodev,relatime,vfat,llw,check=no,gid/uid/rwx,iocharset=utf8 0 0
/dev/block/mmcblk0p3 /preinstall rfs rw,nosuid,nodev,relatime,vfat,llw,check=no,gid/uid/rwx,iocharset=utf8 0 0
/dev/block/vold/179:9 /mnt/sdcard vfat rw,dirsync,nosuid,nodev,noexec,noatime,nodiratime,uid=1000,gid=1015,fmask=0002,dmask=0002,allow_utime=0020,codepage=cp437,iocharset=iso8859-1,shortname=mixed,utf8,errors=remount-ro 0 0
/dev/block/vold/179:9 /mnt/secure/asec vfat rw,dirsync,nosuid,nodev,noexec,noatime,nodiratime,uid=1000,gid=1015,fmask=0002,dmask=0002,allow_utime=0020,codepage=cp437,iocharset=iso8859-1,shortname=mixed,utf8,errors=remount-ro 0 0
tmpfs /mnt/sdcard/.android_secure tmpfs ro,relatime,size=0k,mode=000 0 0
nFiniti said:
Thanks. Stupid Verizon claiming 2gb internal storage but there isn't any real internal storage. You must have a SD Card to do anything on the phone.
Click to expand...
Click to collapse
If there wasn't any internal storage, where would everything be stored? Can't store apps on the SD card on 2.1...

[Q] What determines which partitions get mounted in windows?

I've been looking off and on and having little luck finding the answer. My ultimate goal is to not have the EMMC partitions mounted at all when booting from my CM7 SD card as I have a 32GB card and have plenty of space on it so do not need the 5GB or so that's mounted as /media. I know I can go into the fstab.vold file and change the mounts there that CM7 uses, but what controls which partitions are mounted when connecting it to windows? I either want to alter the EMMC /media partition that's mounted to something else on the SD card (boot maybe? dunno if this is a good idea or not) or remove it from the USB mounting altogether.
- Aerlock
You can remove emmc from vold.fstab and create your own startup script in /data/local/userinit.sh.
Something like: mount /dev/block/mmcblk... /mnt/emmc -t ... -o .........
Note: I am using CM7 and it executes /data/local/userinit.sh at boot. (Look at /etc/init.d/20userinit)
bigsheep123 said:
You can remove emmc from vold.fstab and create your own startup script in /data/local/userinit.sh.
Something like: mount /dev/block/mmcblk... /mnt/emmc -t ... -o .........
Note: I am using CM7 and it executes /data/local/userinit.sh at boot. (Look at /etc/init.d/20userinit)
Click to expand...
Click to collapse
Thanks, I already had that in mind for changing the actual partitions mounted in Android, but what I would like to figure out (and am having absolutely zero luck with) is how to change what shows in Windows/OSX/Linux when I plug it into a USB port. Currently when I connect my Nook I have the sdcard partition show up and the internal media partition show up in windows. I want to change those so that I can get a different partition to who instead of the emmc partition.
- Aerlock
Aerlock said:
Thanks, I already had that in mind for changing the actual partitions mounted in Android, but what I would like to figure out (and am having absolutely zero luck with) is how to change what shows in Windows/OSX/Linux when I plug it into a USB port. Currently when I connect my Nook I have the sdcard partition show up and the internal media partition show up in windows. I want to change those so that I can get a different partition to who instead of the emmc partition.
- Aerlock
Click to expand...
Click to collapse
You can use the samuelhalff Nook Color UMS app to select mapping of partitions to USB
http://forum.xda-developers.com/showthread.php?t=952456
Windows is normally only going to show results for partitions which are formatted as FAT(32) and won't show the ext3/4 partitions used for system and data.
bobtidey said:
You can use the samuelhalff Nook Color UMS app to select mapping of partitions to USB
http://forum.xda-developers.com/showthread.php?t=952456
Windows is normally only going to show results for partitions which are formatted as FAT(32) and won't show the ext3/4 partitions used for system and data.
Click to expand...
Click to collapse
Hrmmm...this works temporarily. I can use this app to change whats mounted but I need to re-run and remount at every disconnect and reconnect. What I really would like to find is the files/config that determines which partitions to mount at the time the Nook is connected to the computer. If I could find that info I'd be a happy Nooker.
- Aerlock
Anybody got an idea where I can look this info up? Or what files I should start poking around in to make these changes? I tried PMing samuelhalff last week and haven't gotten a reply yet.
- Aerlock
Aerlock said:
Anybody got an idea where I can look this info up? Or what files I should start poking around in to make these changes? I tried PMing samuelhalff last week and haven't gotten a reply yet.
- Aerlock
Click to expand...
Click to collapse
I can tell you what you need to change. The partition to mount is stored in /sys/devices/platform/usb_mass_storage/lun0/file. The 'file' is a text file with the partition number in it. For instance, if you wanted to mount the boot partition in emmc you would add "/dev/block/mmcblk0p1" (without the quotes) to the file. Then you could do the same with lun1 to mount something else. After you put the value in the file and save it, just plug in the cable. It will show up as a drive letter. (Do not select the 'turn on USB storage' button that pops up in android, that changes the files to point to /media (emmc) and /sdcard, and when you exit the mode, it clears them to null.)
I leave it to you to figure which partitions to mount and how to change the file when you need it. Remember, Windows can only read fat partitions, which on emmc is /rom (2?), /boot (1) and media (8). /system (5), /data (6), and /cache (7) are all ext and Windows cannot read ext without third party software help.
Not sure why you want to do this. If you are wanting to mount the SD boot partition on an SD installed system, it is ...mmcblk1p1.
leapinlar said:
I can tell you what you need to change. The partition to mount is stored in /sys/devices/platform/usb_mass_storage/lun0/file. The 'file' is a text file with the partition number in it. For instance, if you wanted to mount the boot partition in emmc you would add "/dev/block/mmcblk0p1" (without the quotes) to the file. Then you could do the same with lun1 to mount something else. After you put the value in the file and save it, just plug in the cable. It will show up as a drive letter. (Do not select the 'turn on USB storage' button that pops up in android, that changes the files to point to /media (emmc) and /sdcard, and when you exit the mode, it clears them to null.)
Click to expand...
Click to collapse
Thank you! Thank you! Thank you! I've been trying to find this info off and on for a few months now. I wasn't able to get it to go away with fiddling with the vold.fstab so I knew it was somewhere else but I didn't know where exactly.
So if I were to leave that file blank would it have nothing show up when I connect the NC to windows? Or do I need to do something else to disable the second lun?
leapinlar said:
I leave it to you to figure which partitions to mount and how to change the file when you need it. Remember, Windows can only read fat partitions, which on emmc is /rom (2?), /boot (1) and media (8). /system (5), /data (6), and /cache (7) are all ext and Windows cannot read ext without third party software help.
Click to expand...
Click to collapse
Thanks again, I'd found this out on my own while playing with mounting the various partitions in the vold.fstab but it's helpful to get someone else to confirm my findings.
leapinlar said:
Not sure why you want to do this. If you are wanting to mount the SD boot partition on an SD installed system, it is ...mmcblk1p1.
Click to expand...
Click to collapse
My ultimate goal is to disable the second partition mount in Windows. I only want to have the SD card data partition show up, I want to completely separate the emmc boot from the SD boot. I may also want to add the boot partition from the SD card at a later time so I can do upgrades when I have a computer but no SD card adapter/reader.
Also (just theoretically, for my understanding) would it be possible to add more luns by creating the dirs and files in the /sys/devices/platform/usb_mass_storage/ directory?
- Aerlock
Aerlock said:
So if I were to leave that file blank would it have nothing show up when I connect the NC to windows? Or do I need to do something else to disable the second lun?
Also (just theoretically, for my understanding) would it be possible to add more luns by creating the dirs and files in the /sys/devices/platform/usb_mass_storage/ directory?
Click to expand...
Click to collapse
There are always going to be two drives show up when you plug it in (lun0 and lun1). They are non functional until you press the button to turn on (because the two files are empty). When you press the button the software populates the files with the emmc and sdcard partition locations and the drives become functional.
I'm not sure how to prevent emmc from showing if you want just sdcard. Maybe you can set permissions on one to be all boxes unchecked. But two drives will always show, just one may be non functional. Another option would be to set the two luns to be what you want and set permissions to be read only. Then maybe pushing the button will have no effect.
But two drive letters will always show.
No, there can only be two lun files. It is built into the operating system.
Edit: I am going to experiment and get back to you.
Edit 2: I've got it all fixed for you. I attached a rar file to the board. Just unrar and you will find two files
The first, 55mountsingleSD, will cause just the SD card to mount. The second drive letter should disappear.
The second, 56mount2customdrives, will mount the boot partition of emmc and the SD card. You can edit the file to change which two partitions you want Windows to see.
Place one (only one) of these files in the /system/etc/init.d folder and change its permissions to match the other files in that folder.
When you reboot with one of these files in that folder, the drive(s) are ready for mounting in Windows. All you have to do is plug in your USB cable. The drive(s) should show in Windows automatically. Do NOT select the "Turn on USB storage" button (just hit the back button). If you do, it will unmount emmc and the SD card in CM7 and you will have to go to settings to re-mount them. Also, be sure to "eject" the drives in Windows before disconnecting the cable.
NookColorUMS will not work anymore because I accomplished this by locking the lun files. If you want to use it, just remove the file from init.d or rename it with .bak and reboot and everything will return to normal.
Enjoy
Have you tried this? I'm looking for feedback. BTW, for others interested, this will not work on CM9 since it does not currently support UMS mounting.
leapinlar said:
Have you tried this? I'm looking for feedback. BTW, for others interested, this will not work on CM9 since it does not currently support UMS mounting.
Click to expand...
Click to collapse
Sadly I haven't had a chance to try it. I've got a 2 year old and a sick wife at home so my time has been limited. Good news is the wife is almost back to normal now and I should be able to play with these tomorrow or this weekend.
- Aerlock
P.S. Thanks for the scripts. They'll save me lots of trial and error making my own.
leapinlar said:
Have you tried this? I'm looking for feedback. BTW, for others interested, this will not work on CM9 since it does not currently support UMS mounting.
Click to expand...
Click to collapse
Finally got a chance to try these out between projects at work today.
Here's what I get when I run the 55mountsingleSD script in gscript:
Code:
stderr:
stderr:
stderr:
stderr:
stderr: cannot create /sys/devices/platform/usb_mass_storage/lun0/file: permission denied
stderr:
stderr:
stderr:
stderr:
stderr:
stderr:
The first time I ran it I got all 'stderr:' lines. I do have a Boot partition mounted in windows after running this script. I haven't checked to determine if its the SD card or the emmc but it appears to be the SD card at first glance.
Here's what I get when I run the 56mount2customdrives script in gscript:
Code:
stderr:
stderr:
stderr:
stderr:
stderr: cannot create /sys/devices/platform/usb_mass_storage/lun0/file: permission denied
stderr:
stderr: cannot create /sys/devices/platform/usb_mass_storage/lun1/file: permission denied
stderr:
stderr:
stderr:
stderr:
stderr:
stderr:
Again the first time I ran it I got all 'stderr:' lines. This time I have 2 boot partitions mounted in windows, 1 appears to be the emmc and the other the SDcard.
I also took a look at the /sys/devices/platform/usb_mass_storage/lun(x)/file files and heres what I found in them when I had the USB storage turned on:
Code:
lun0 - /dev/block/vold/179:20
lun1 - /dev/block/vold/179:8
Since you've been so helpful with these scripts I've got some more questions for you.
Where are the settings for the USB storage stored? For example what do I change if I want the 'Turn on USB storage' button to mount the sdcard and boot partitions of my SD card instead of the sdcard and emmc media partitions?
Or how do I disable the USB storage screen from popping up when I connect the USB cable so I can just use the script.
Also how do I unmount the partitions when I'm done in windows? Just delete the contents of those two files?
- Aerlock
Aerlock said:
Finally got a chance to try these out between projects at work today.
Here's what I get when I run the 55mountsingleSD script in gscript:
Code:
stderr:
stderr:
stderr:
stderr:
stderr: cannot create /sys/devices/platform/usb_mass_storage/lun0/file: permission denied
stderr:
stderr:
stderr:
stderr:
stderr:
stderr:
The first time I ran it I got all 'stderr:' lines. I do have a Boot partition mounted in windows after running this script. I haven't checked to determine if its the SD card or the emmc but it appears to be the SD card at first glance.
Here's what I get when I run the 56mount2customdrives script in gscript:
Code:
stderr:
stderr:
stderr:
stderr:
stderr: cannot create /sys/devices/platform/usb_mass_storage/lun0/file: permission denied
stderr:
stderr: cannot create /sys/devices/platform/usb_mass_storage/lun1/file: permission denied
stderr:
stderr:
stderr:
stderr:
stderr:
stderr:
Again the first time I ran it I got all 'stderr:' lines. This time I have 2 boot partitions mounted in windows, 1 appears to be the emmc and the other the SDcard.
I also took a look at the /sys/devices/platform/usb_mass_storage/lun(x)/file files and heres what I found in them when I had the USB storage turned on:
Code:
lun0 - /dev/block/vold/179:20
lun1 - /dev/block/vold/179:8
Since you've been so helpful with these scripts I've got some more questions for you.
Where are the settings for the USB storage stored? For example what do I change if I want the 'Turn on USB storage' button to mount the sdcard and boot partitions of my SD card instead of the sdcard and emmc media partitions?
Or how do I disable the USB storage screen from popping up when I connect the USB cable so I can just use the script.
Also how do I unmount the partitions when I'm done in windows? Just delete the contents of those two files?
- Aerlock
Click to expand...
Click to collapse
Did you read my post? Those scripts were not meant to run in gscript. Thats why you are getting those error messages. They were meant to put in /etc/init.d. They have to be run at boot time to have the right permissions to do things.
The settings for 'turn on' are stored in the operating system program code. You will not be able to change that.
Again, the scripts are not to be run after booting. They run at boot time and are there waiting for you to plug in the cable. When the cable is plugged in, they automatically show up in windows (depending on which script you put in init.d). Just hit the back button when the pop-up comes up to get rid of it. To disconnect the drives in Windows, use the eject command by right clicking on the drive in Windows Explorer. Then unplug the cable and it is ready for next time you plug in. Don't do anything with the files. Just never press the 'Turn on' button, ever. Just hit back to get rid of it.
If you want different partitions to show, edit the script file before you re-boot.
leapinlar said:
Did you read my post? Those scripts were not meant to run in gscript. Thats why you are getting those error messages. They were meant to put in /etc/init.d. They have to be run at boot time to have the right permissions to do things.
The settings for 'turn on' are stored in the operating system program code. You will not be able to change that.
Again, the scripts are not to be run after booting. They run at boot time and are there waiting for you to plug in the cable. When the cable is plugged in, they automatically show up in windows (depending on which script you put in init.d). Just hit the back button when the pop-up comes up to get rid of it. To disconnect the drives in Windows, use the eject command by right clicking on the drive in Windows Explorer. Then unplug the cable and it is ready for next time you plug in. Don't do anything with the files. Just never press the 'Turn on' button, ever. Just hit back to get rid of it.
If you want different partitions to show, edit the script file before you re-boot.
Click to expand...
Click to collapse
I feel stupid now. I did read that the first time. When I went back and got the files to test I just skimmed your post and thought I knew what I was doing. Let me try these again and I'll post the results.
- Aerlock
where are these files in cm 10.1
Hi there,
I'm running CM 10.1 aka 4.2 on a Samsung I9000..I'm wondering if you can point me in the wright direction where these files are stored....
And what to change...
As said in the private message i would like to make my second SDCARD or a folder from it visible on the first sdcard even when I connect to Windows.
Vold.fstap doesn't help me in this case..
Already a big thank you for pointing in the right direction
Is there a posibility to repost the scripts I understand they'll have to be in init.d...
Kind Regards
Guy Forssman
How on Samsung I9000 CM 10.1
With putty as the tool and SSHDroid running as app
I do a "ls /dev/block/vold"
results in 179.0 179.1 179.2 179.8 179.9
"ls /dev/block/platform" results in s3c-sdchi.0 s3c-sdchi.2 s5pc110-onenand
"mount" learns me
rootfs on / type rootfs (ro,relatime)
tmpfs on /dev type tmpfs (rw,nosuid,relatime,mode=755)
devpts on /dev/pts type devpts (rw,relatime,mode=600)
none on /dev/cpuctl type cgroup (rw,relatime,cpu)
proc on /proc type proc (rw,relatime)
sysfs on /sys type sysfs (rw,relatime)
/sys/kernel/debug on /sys/kernel/debug type debugfs (rw,relatime)
none on /acct type cgroup (rw,relatime,cpuacct)
tmpfs on /mnt/secure type tmpfs (rw,relatime,mode=700)
tmpfs on /mnt/asec type tmpfs (rw,relatime,mode=755,gid=1000)
tmpfs on /mnt/obb type tmpfs (rw,relatime,mode=755,gid=1000)
/dev/block/mtdblock3 on /cache type yaffs2 (rw,nosuid,nodev,relatime)
/dev/block/mtdblock5 on /radio type yaffs2 (rw,relatime)
/dev/block/mtdblock2 on /datadata type yaffs2 (rw,relatime)
/dev/lvpool/system on /system type ext4 (ro,relatime,barrier=1,data=ordered)
/dev/lvpool/userdata on /data type ext4 (rw,nosuid,nodev,noatime,errors=panic,barrier=1,nomblk_io_submit,data=ordered)
/dev/block/mtdblock4 on /efs type yaffs2 (rw,relatime)
]/dev/block/vold/179:9 on /storage/sdcard1 type vfat (rw,dirsync,nosuid,nodev,noexec,relatime,uid=1000,gid=1015,fmask=0702,dmask=0702,allow_utime=0020,codepage=cp437,iocharset=iso8859-1,shortname=mixed,utf8,errors=remount-ro)
/dev/block/vold/179:1 on /storage/sdcard0 type vfat (rw,dirsync,nosuid,nodev,noexec,relatime,uid=1000,gid=1015,fmask=0702,dmask=0702,allow_utime=0020,codepage=cp437,iocharset=iso8859-1,shortname=mixed,utf8,errors=remount-ro)
tmpfs on /storage/sdcard0/.android_secure type tmpfs (ro,relatime,size=0k,mode=000)
/dev/block/dm-2 on /mnt/asec/me.shkschneider.dropbearserver-1 type ext4 (ro,dirsync,nosuid,nodev,noatime,barrier=1)
and indeed windows 7 shows me a walkman icon with 2 entrys
SD card
USB storage
The content of the external micro sd card is on the SD card which Windows8 shows
The content of the internal memory is shown on windows8 in the USB storage
The phone itself doesn't shown the usb mount icon
It seems that even after a reboot the settings stay
I did a "setprop persist.sys.usb.config mtp,adb"
"echo /dev/block/vold/179:1 > /sys/devices/platform/s3c-usbgadget/gadget/lun0/file"
"echo /dev/block/vold/179:9 > /sys/devices/platform/s3c-usbgadget/gadget/lun1/file"
Forssound said:
With putty as the tool and SSHDroid running as app
I do a "ls /dev/block/vold"
results in 179.0 179.1 179.2 179.8 179.9
"ls /dev/block/platform" results in s3c-sdchi.0 s3c-sdchi.2 s5pc110-onenand
"mount" learns me
rootfs on / type rootfs (ro,relatime)
tmpfs on /dev type tmpfs (rw,nosuid,relatime,mode=755)
devpts on /dev/pts type devpts (rw,relatime,mode=600)
none on /dev/cpuctl type cgroup (rw,relatime,cpu)
proc on /proc type proc (rw,relatime)
sysfs on /sys type sysfs (rw,relatime)
/sys/kernel/debug on /sys/kernel/debug type debugfs (rw,relatime)
none on /acct type cgroup (rw,relatime,cpuacct)
tmpfs on /mnt/secure type tmpfs (rw,relatime,mode=700)
tmpfs on /mnt/asec type tmpfs (rw,relatime,mode=755,gid=1000)
tmpfs on /mnt/obb type tmpfs (rw,relatime,mode=755,gid=1000)
/dev/block/mtdblock3 on /cache type yaffs2 (rw,nosuid,nodev,relatime)
/dev/block/mtdblock5 on /radio type yaffs2 (rw,relatime)
/dev/block/mtdblock2 on /datadata type yaffs2 (rw,relatime)
/dev/lvpool/system on /system type ext4 (ro,relatime,barrier=1,data=ordered)
/dev/lvpool/userdata on /data type ext4 (rw,nosuid,nodev,noatime,errors=panic,barrier=1,nomblk_io_submit,data=ordered)
/dev/block/mtdblock4 on /efs type yaffs2 (rw,relatime)
]/dev/block/vold/179:9 on /storage/sdcard1 type vfat (rw,dirsync,nosuid,nodev,noexec,relatime,uid=1000,gid=1015,fmask=0702,dmask=0702,allow_utime=0020,codepage=cp437,iocharset=iso8859-1,shortname=mixed,utf8,errors=remount-ro)
/dev/block/vold/179:1 on /storage/sdcard0 type vfat (rw,dirsync,nosuid,nodev,noexec,relatime,uid=1000,gid=1015,fmask=0702,dmask=0702,allow_utime=0020,codepage=cp437,iocharset=iso8859-1,shortname=mixed,utf8,errors=remount-ro)
tmpfs on /storage/sdcard0/.android_secure type tmpfs (ro,relatime,size=0k,mode=000)
/dev/block/dm-2 on /mnt/asec/me.shkschneider.dropbearserver-1 type ext4 (ro,dirsync,nosuid,nodev,noatime,barrier=1)
and indeed windows 7 shows me a walkman icon with 2 entrys
SD card
USB storage
The content of the external micro sd card is on the SD card which Windows8 shows
The content of the internal memory is shown on windows8 in the USB storage
The phone itself doesn't shown the usb mount icon
It seems that even after a reboot the settings stay
I did a "setprop persist.sys.usb.config mtp,adb"
"echo /dev/block/vold/179:1 > /sys/devices/platform/s3c-usbgadget/gadget/lun0/file"
"echo /dev/block/vold/179:9 > /sys/devices/platform/s3c-usbgadget/gadget/lun1/file"
Click to expand...
Click to collapse
If you want those luns to be different, you echo a different /dev/block... to the file instead of the vold locations. Looks like it uses /dev/block/mtdblock with a partition number after it for the interior partitions. Look in /dev/block/platform and those sc3-h... folders and see if it lists partition numbers either for interior or sdcards.
Sent from my HD+ running CM10 on SD with XDA Premium
rest the question
how do i make these commands flash proof?
Already the commands I did made the car find my phone and played the music..
It also played system sounds, my movies etc etc
I just did a
/dev/block/platform # ls
s3c-sdhci.0 s3c-sdhci.2 s5pc110-onenand
/dev/block/platform # cd s5pc110-onenand
/dev/block/platform/s5pc110-onenand # ls
mtdblock0 mtdblock1 mtdblock2 mtdblock3 mtdblock4 mtdblock5 mtdblock6
"cd /dev/block/platform/s3c-sdhc1.0"
"ls"
result by-num mmcblk0 mmcblk0p1 mmcblk0p2
cd /dev/block/platform/s3c-sdhci.2
/dev/block/platform/s3c-sdhci.2 # ls
by-num mmcblk1 mmcblk1p1
So if I only would mount the music folder from my external folder onto a folder on the internal folder?
Or is it easyer to just mount the whole extenal sd card ?
Forssound said:
how do i make these commands flash proof?
Click to expand...
Click to collapse
I'm not sure what you mean flash proof. Do you mean so they stick after flashing a new rom? To do that you need to put the commands in /data. And for that to work, your rom has to support userinit.d or bootcompletehook.sh in /data. Each device is different. Look in your init.d folder and see if it has a script that calls userinit.d. You said you had CM10.1 and usually CM supports userinit.d. Create a folder in /data/local named userinit.d and put your scripts there. They get run right after init.d scripts are run. Be sure to set the script file permissions to execute.
Sent from my HD+ running CM10 on SD with XDA Premium
leapinlar said:
I'm not sure what you mean flash proof. Do you mean so they stick after flashing a new rom? To do that you need to put the commands in /data. And for that to work, your rom has to support userinit.d or bootcompletehook.sh in /data. Each device is different. Look in your init.d folder and see if it has a script that calls userinit.d. You said you had CM10.1 and usually CM supports userinit.d. Create a folder in /data/local named userinit.d and put your scripts there. They get run right after init.d scripts are run. Be sure to set the script file permissions to execute.
Sent from my HD+ running CM10 on SD with XDA Premium
Click to expand...
Click to collapse
I found a init.rc on /data/local/tmp
it's huge
in /system/etc/init.d I found 2 files 00banner and 90userinit
vi 90userinit is this
#!/system/bin/sh
# call userinit.sh and/or userinit.d/* scripts if present in /data/local
if [ -e /data/local/userinit.sh ];
then
log -p i -t userinit "Executing /data/local/userinit.sh";
logwrapper /system/bin/sh /data/local/userinit.sh;
setprop cm.userinit.active 1;
fi;
if [ -d /data/local/userinit.d ];
then
logwrapper busybox run-parts /data/local/userinit.d;
setprop cm.userinit.active 1;
fi;
so it seems that I can make a
/data/local/userinit.d
this file should be executable and what do you advise I put in it?
---------- Post added at 11:01 PM ---------- Previous post was at 10:51 PM ----------
Is it better to use
setprop persist.sys.usb.config mass_storage,adb
or
setprop persist.sys.usb.config mtp,adb
further you talk about the /dev/block/platform and those sc3-h... folders
I found the following
echo /dev/block/vold/179:9 > /sys/devices/platform/s3c-usbgadget/gadget/lun1/file"
Is there a reason to choose to use one above the other?

[How-To] [Link2SD] Solve "mount: No such file or directory" error on stock ROM

[How-To] [Link2SD] Solve "mount: No such file or directory" error on stock ROM
I rooted my Galaxy S3 Mini (GT-i8190) (following seedrom193's tutorial), but I'm still on the stock Android ROM.
I was trying to use Link2SD with a correctly partitioned SD card (10GB primary FAT32 + 4GB primary ext2), but got the following error, which showed every time I tried to recreate mount scripts:
"Mount script cannot be created. mount: No such file or directory"
Also, on every reboot, I would get a "Mount warning" from Link2SD, requiring me to "quick reboot" my phone. After that (second) reboot, Link2SD would work correctly, but shortcuts on my home screen to linked apps were missing.
After much googling I figured that maybe the problem was caused by my (stock) ROM not having init.d support. So I used this method to add init.d:
http://forum.xda-developers.com/showthread.php?t=1933849
Init.d worked properly, but I still got the same error in Link2SD. Then, I used Root Explorer to look at my file system (any other root browser would work too I guess) and found the cause. Here's the contents of /data/data/com.buak.Link2SD/files/init-link2sd.sh, which I *guess* is a copy of the script Link2SD is trying to get to run at boot:
Code:
set +e
echo "$(date) mounting..." > $LOG
sleep 4
mount -t ext2 -o rw [COLOR="Red"][B]/dev/block/vold/179:98[/B][/COLOR] /data/sdext2 1>>$LOG 2>>$LOG
mount -t ext2 -o rw /dev/block/mmcblk1p2 /data/sdext2 1>>$LOG 2>>$LOG
mount >> $LOG
echo "$(date) mount finished" >> $LOG
Apparently, the device node /dev/block/vold/179:98 does not exist, because Android's vold mounting system doesn't automatically mount the second partition of the SD card. This causes the "mount: No such file or directory" error on the first mount command. However, the second mount command (from /dev/block/mmcblk1p2) should work. For some reason, this error seems to keep Link2SD from installing the boot script.
So, I decided to create an init.d script of my own. Using Root Explorer, I created and edited a file named "11link2sd" in /system/etc/init.d/ and inserted the following text:
Code:
#!/system/bin/sh
sleep 4
mount -t ext2 -o rw /dev/block/mmcblk1p2 /data/sdext2
This solved the problem for me, and I can now use Link2SD without needing the extra quick reboot. I figured I'd share my solution in case anybody else had the same problem. I do suggest that anybody who tries to do the same thing first check the init-link2sd.sh file for that /dev/block/mmcblk1p2 bit, to make sure it''s the same.
Link2SD 2nd Partition getting full
Hi,
I saw that you are using Link2SD and seems to have a good understanding of the subject. I am new to using Android!
Maybe you could help. I think I properly installed Link2SD and that it is working correctly (I don't know of any way to check that).
When I go into the menu and ask for storage, I get the following: it is in french, but "libres" means "free".
Interne (85% Libres)
/data
Total: 4,37 Go Utilisés: 658 Mo Libres: 3,73 Go
Carte SD (85% Libres)
/storage/emulated/legacy
Total: 4,37 Go Utilisés: 658 Mo Libres: 3,73 Go
Externe SD (98% Libres)
/storage/external_SD
Total: 27,42 Go Utilisés: 516 Mo Libres: 26,92 Go
Carte SD 2nde Partition (9% Libres)
/data/sdext2
Total: 2,34 Go Utilisés: 2,12 Go Libres: 230 Mo
Système (23% Libres)
/system
Total: 1,67 Go Utilisés: 1,28 Go Libres: 407 Mo
Cache (98% Libres)
/cache
Total: 787 Mo Utilisés: 12,58 Mo Libres: 774 Mo
As you can see the 2nd partition is almost full.
Is it possible to remove the SD card, resize the 2nd partition and put it back in the phone without loosing everything?
I am not sure if that can be done with link2sd installed.
Thanks for your help.
Jacques
Hello Jacques,
Your Link2SD seems to be working just fine. Here's how I can tell:
jacques_xda said:
Carte SD (85% Libres)
/storage/emulated/legacy
Total: 4,37 Go Utilisés: 658 Mo Libres: 3,73 Go
Click to expand...
Click to collapse
This is your internal memory, and plenty of it is now empty, probably thanks to Link2SD.
jacques_xda said:
Carte SD 2nde Partition (9% Libres)
/data/sdext2
Total: 2,34 Go Utilisés: 2,12 Go Libres: 230 Mo
Click to expand...
Click to collapse
This is the second partition which you created and which is indeed almost full. Unless you intentionally put other files there (which I assume you didn't, or you'd have known about it ), this partition was filled by Link2SD, with over 2 Gb of data. So Link2SD is working as it should, freeing your internal memory by moving stuff to that second partition.
Now, as for your second question:
jacques_xda said:
Is it possible to remove the SD card, resize the 2nd partition and put it back in the phone without loosing everything?
I am not sure if that can be done with link2sd installed.
Click to expand...
Click to collapse
Yes, but I recommend taking a backup of your SD card first, just to be safe. If your power fails or your card reader is disconnected during re-partitioning, you might lose data.
Assuming you're using Windows, you will need to make sure that MiniTool Partition Wizard is installed first (link can be found here). Also, you will need to have a way to back up the second SD card partition (which I assume contains an ext file system) over to Windows. You can copy over the files using Ext2Fsd, DiskInternals Linux Reader or Ext2explore, or find some program for creating an image of an ext partition in windows.
Then, take these steps:
1. Turn off your phone (and do not turn it on again!)
2. Take your SD card out of your phone and connect it to your computer using a card reader
3. To make a backup, copy everything on both partitions of your SD card to your computer
4. Use Partition Wizard to shrink the first partition on your SD card, and use the resulting unallocated space to expand the second partition (don't forget to press the "Apply" button!)
5. Safe-remove your SD card and put it back in your phone
6. Turn your phone on again
This should enlarge your extra partition without causing any problems with Link2SD. If you really want to be safe, you could use Link2SD to unlink all of your apps before step 1, and re-link them after step 6. Based on the information you provided, you should have just enough internal memory to do so.
Bonne chance!
link2SD resize ext partition
Warre101 said:
Hello Jacques,
Your Link2SD seems to be working just fine. Here's how I can tell:
This is your internal memory, and plenty of it is now empty, probably thanks to Link2SD.
This is the second partition which you created and which is indeed almost full. Unless you intentionally put other files there (which I assume you didn't, or you'd have known about it ), this partition was filled by Link2SD, with over 2 Gb of data. So Link2SD is working as it should, freeing your internal memory by moving stuff to that second partition.
Now, as for your second question:
Yes, but I recommend taking a backup of your SD card first, just to be safe. If your power fails or your card reader is disconnected during re-partitioning, you might lose data.
Assuming you're using Windows, you will need to make sure that MiniTool Partition Wizard is installed first (link can be found here). Also, you will need to have a way to back up the second SD card partition (which I assume contains an ext file system) over to Windows. You can copy over the files using Ext2Fsd, DiskInternals Linux Reader or Ext2explore, or find some program for creating an image of an ext partition in windows.
Then, take these steps:
1. Turn off your phone (and do not turn it on again!)
2. Take your SD card out of your phone and connect it to your computer using a card reader
3. To make a backup, copy everything on both partitions of your SD card to your computer
4. Use Partition Wizard to shrink the first partition on your SD card, and use the resulting unallocated space to expand the second partition (don't forget to press the "Apply" button!)
5. Safe-remove your SD card and put it back in your phone
6. Turn your phone on again
This should enlarge your extra partition without causing any problems with Link2SD. If you really want to be safe, you could use Link2SD to unlink all of your apps before step 1, and re-link them after step 6. Based on the information you provided, you should have just enough internal memory to do so.
Bonne chance!
Click to expand...
Click to collapse
Hi,
Thanks for your response. I have a question: do I need to unmount the SD card before closing the phone and pulling it out?
If the answer is yes, when I put it back and open the phone, will it mount automatically?
Jacques
Hello Jacques,
I think it will re-mount automatically, but don't have any similar experience with my own phone. With my own device, the micro-SD expansion slot is underneath the battery, so I have no choice but to turn off the phone before removing the SD. By consequence, the OS offers no option to unmount the SD card (that I know of at least).
However, once you turn your phone on again, your SD card should be mounted automatically. Have you rebooted (or turned your phone off and then on again) since using Link2SD? If yes, then it's probably fine. I would recommend that you don't unmount your SD card while the phone is running and apps are still linked; your linked apps would probably stop working.
Warre101 said:
Hello Jacques,
I think it will re-mount automatically, but don't have any similar experience with my own phone. With my own device, the micro-SD expansion slot is underneath the battery, so I have no choice but to turn off the phone before removing the SD. By consequence, the OS offers no option to unmount the SD card (that I know of at least).
However, once you turn your phone on again, your SD card should be mounted automatically. Have you rebooted (or turned your phone off and then on again) since using Link2SD? If yes, then it's probably fine. I would recommend that you don't unmount your SD card while the phone is running and apps are still linked; your linked apps would probably stop working.
Click to expand...
Click to collapse
Hi,
I closed the phone and took off the SD card without any problem.
I made an image of the content with ext2explore.
I then use MiniTool Partiton to try to extend the ext4 partition. The problem is there: MiniTool Partition cannot handle the job!
On the SD card, I have one FAT32 Partition and one ext4 linux patition. MiniTool can resize the FAT32 partition, leaving an unallocated space between the FAT32 and the ext4 partition, but it cannot resize the ext4 partition to take advantage of the unallocated space! I can move the ext4 partition closer to the FAT32, leaving the unallocated space at the end; that is all I can do with MiniTool.
Of course I could delete the ext4 partition and create a new one, using all the unallocated space. But then , will I be able to load the ext4 image I created before in that new partition, since it is not the same size? When ext2explore create an image, does it make a clone of the partition (content, size, etc...) there is no explanation or help on that product!
I will try with Gparted to see what it does and try to simply copy the content of the ext4 partition instead of creating an image.
Thank again for helping.
Jacques
Hello Jacques,
That's odd. I did almost exactly the same thing you described here (except for using ext2 rather than ext4) and was able to resize my ext2 partition using Partition Wizard. I first shrunk the FAT32 partition, then moved and resized the ext2 to use all the unallocated space. Have you tried first pressing apply after you shrink the fat32 and move the ext4? In any case, GParted should also work.
I can't help you with ext2explore as I have no direct experience with that program. You might be able to get some help in other parts of this forum.
If you want to try deleting that ext4 partition and creating a new one, you may be able to do this by first unlinking your apps back to your internal memory in Link2SD (as I suggested in an earlier post), re-partitioning and then re-linking with Link2SD.
Warre101 said:
Hello Jacques,
That's odd. I did almost exactly the same thing you described here (except for using ext2 rather than ext4) and was able to resize my ext2 partition using Partition Wizard. I first shrunk the FAT32 partition, then moved and resized the ext2 to use all the unallocated space. Have you tried first pressing apply after you shrink the fat32 and move the ext4? In any case, GParted should also work.
I can't help you with ext2explore as I have no direct experience with that program. You might be able to get some help in other parts of this forum.
If you want to try deleting that ext4 partition and creating a new one, you may be able to do this by first unlinking your apps back to your internal memory in Link2SD (as I suggested in an earlier post), re-partitioning and then re-linking with Link2SD.
Click to expand...
Click to collapse
Hi,
It is realy odd! I created that ext partition with the same tool! Now I can move it, but not resize it....I will try with Gparted with my old computer running Linux (Ubuntu)...later on, expecting it will work fine.
Thanks again,
Jacques
I rooted my moto e 2nd gen 4g phone and made partition on my 16gb sd card using ext4 FAT32. After partioning sd card then i inserted it in my phone to use link2sd but when i try to recreate mount script an error pop up every time showing " mount script cannot be created. No such file or directory" please help me. If any solution you know.
ankit gaur said:
I rooted my moto e 2nd gen 4g phone and made partition on my 16gb sd card using ext4 FAT32. After partioning sd card then i inserted it in my phone to use link2sd but when i try to recreate mount script an error pop up every time showing " mount script cannot be created. No such file or directory" please help me. If any solution you know.
Click to expand...
Click to collapse
Hi,
Try to mount with ext2 instead of ext4. I had the same problem trying to mount with ext2; I then try with ext4 and it worked|
Regards,
Jacques
ankit gaur said:
I rooted my moto e 2nd gen 4g phone and made partition on my 16gb sd card using ext4 FAT32. After partioning sd card then i inserted it in my phone to use link2sd but when i try to recreate mount script an error pop up every time showing " mount script cannot be created. No such file or directory" please help me. If any solution you know.
Click to expand...
Click to collapse
jacques_xda said:
Hi,
Try to mount with ext2 instead of ext4. I had the same problem trying to mount with ext2; I then try with ext4 and it worked|
Regards,
Jacques
Click to expand...
Click to collapse
That looks exactly like the problem I had. I suggest you first try Jacques' idea (changing ext2 into ext4 or vice versa) and if that doesn't work, use the method I put in the very first post. Let us know if you have any problems with that...
Been trying to get link2sd to work for awhile now
My init-link2sd.sh file looks a bit different though. For me, it looks like:
set +e
echo "$(date) mounting..." >$LOG
sleep4
mount-t vfat-o
rw,uid=1000,gid=1000,unmask=133,dmask=0002 /
dev/block/vold/179:34/data/sdext2 1>>$LOG 2>>
$LOG
mount -t vfat-o
rw,uid=1000,gid=1000,unmask=133,dmask=0002 /
dev/block/mmcblk1p2 /data/ sdext2 1>>$LOG 2>>
$LOG
Mount >> $LOG
echo "$(date) mount finished" >> $LOG
chmod 773 /data/dalvik-cache
Whenever I try to use Link2SD, it gies me the "mount: No such file or directory error," would you be able to help me?
A couple of things stand out to me; I'll go through the script you posted step by step:
FinalFreeze said:
set +e
echo "$(date) mounting..." >$LOG
sleep4
Click to expand...
Click to collapse
A space is missing between "sleep" and "4". Was it lost in copy-pasting?
FinalFreeze said:
mount-t vfat-o
rw,uid=1000,gid=1000,unmask=133,dmask=0002 /
dev/block/vold/179:34/data/sdext2 1>>$LOG 2>>
$LOG
Click to expand...
Click to collapse
I expected this to be on a single line like this:
Code:
mount-t [B]vfat[/B]-o rw,uid=1000,gid=1000,unmask=133,dmask=0002 /dev/block/vold/179:34/data/sdext2 1>>$LOG 2>>$LOG
Is it like that in your file?
Anyway, I notice the second argument in the mount command is "vfat". If you use the "recreate mount scripts" in Link2SD, which option do you use for the file system? Does it correspond to the way your SD card is partitioned? I used EXT2.
FinalFreeze said:
mount -t vfat-o
rw,uid=1000,gid=1000,unmask=133,dmask=0002 /
dev/block/mmcblk1p2 /data/ sdext2 1>>$LOG 2>>
$LOG
Click to expand...
Click to collapse
This is the information you would need to follow the tutorial that I posted. You could try putting the following in an init.d script:
Code:
#!/system/bin/sh
sleep 4
mount -t [B]ext2[/B] -o rw,uid=1000,gid=1000,unmask=133,dmask=0002 /dev/block/mmcblk1p2 /data/sdext2
Note that I'm assuming here that your SD card uses an EXT2 partition, as shown in bold.
FinalFreeze said:
Mount >> $LOG
echo "$(date) mount finished" >> $LOG
chmod 773 /data/dalvik-cache
Click to expand...
Click to collapse
The last line (starting with chmod) is something I haven't seen before. If you create your own init.d script, you may need to add the same line.
Warre101 said:
I rooted my Galaxy S3 Mini (GT-i8190) (following seedrom193's tutorial), but I'm still on the stock Android ROM.
I was trying to use Link2SD with a correctly partitioned SD card (10GB primary FAT32 + 4GB primary ext2), but got the following error, which showed every time I tried to recreate mount scripts:
"Mount script cannot be created. mount: No such file or directory"
Also, on every reboot, I would get a "Mount warning" from Link2SD, requiring me to "quick reboot" my phone. After that (second) reboot, Link2SD would work correctly, but shortcuts on my home screen to linked apps were missing.
After much googling I figured that maybe the problem was caused by my (stock) ROM not having init.d support. So I used this method to add init.d:
http://forum.xda-developers.com/showthread.php?t=1933849
Init.d worked properly, but I still got the same error in Link2SD. Then, I used Root Explorer to look at my file system (any other root browser would work too I guess) and found the cause. Here's the contents of /data/data/com.buak.Link2SD/files/init-link2sd.sh, which I *guess* is a copy of the script Link2SD is trying to get to run at boot:
Code:
set +e
echo "$(date) mounting..." > $LOG
sleep 4
mount -t ext2 -o rw [COLOR="Red"][B]/dev/block/vold/179:98[/B][/COLOR] /data/sdext2 1>>$LOG 2>>$LOG
mount -t ext2 -o rw /dev/block/mmcblk1p2 /data/sdext2 1>>$LOG 2>>$LOG
mount >> $LOG
echo "$(date) mount finished" >> $LOG
Apparently, the device node /dev/block/vold/179:98 does not exist, because Android's vold mounting system doesn't automatically mount the second partition of the SD card. This causes the "mount: No such file or directory" error on the first mount command. However, the second mount command (from /dev/block/mmcblk1p2) should work. For some reason, this error seems to keep Link2SD from installing the boot script.
So, I decided to create an init.d script of my own. Using Root Explorer, I created and edited a file named "11link2sd" in /system/etc/init.d/ and inserted the following text:
Code:
#!/system/bin/sh
sleep 4
mount -t ext2 -o rw /dev/block/mmcblk1p2 /data/sdext2
This solved the problem for me, and I can now use Link2SD without needing the extra quick reboot. I figured I'd share my solution in case anybody else had the same problem. I do suggest that anybody who tries to do the same thing first check the init-link2sd.sh file for that /dev/block/mmcblk1p2 bit, to make sure it''s the same.
Click to expand...
Click to collapse
Mount script error
Mount Script cannot be created
Moun Invalid arguement
I've been at this every day for a week i inserted the txt file with ur script rebooted and nothing same old bs script error. PLEASE tell me som1 knows A REAL WORKING FIX.
I've tried fat32/ext2 fat32/ext4 fat32/fat32 The mount DOES NOT EXIST. i have int.d support How do I create the mount? Not just a file directory?
Hi, I have tried the script, but at restart seems not to run because no mount is done, so no partition.
I use CM13. Any ideas? Thank you.
mikeroku said:
Hi, I have tried the script, but at restart seems not to run because no mount is done, so no partition.
I use CM13. Any ideas? Thank you.
Click to expand...
Click to collapse
That's difficult to tell based on the information you provided. Can you look for this file:
Code:
/data/data/com.buak.Link2SD/files/init-link2sd.sh
and post the contents please?
Hey...my problem is mounting the second partition...I've been literally trying since yesterday....no luck using the mini tool to format any of the ext's and lost a lot of time trying different fixes....typing in "cannot mount 2nd partition" on google leaves me with so many results that don't have actual fixes...any help?
Stabbey said:
Mount script error
Mount Script cannot be created
Moun Invalid arguement
Click to expand...
Click to collapse
psantos1091 said:
Hey...my problem is mounting the second partition...I've been literally trying since yesterday....no luck using the mini tool to format any of the ext's and lost a lot of time trying different fixes....typing in "cannot mount 2nd partition" on google leaves me with so many results that don't have actual fixes...any help?
Click to expand...
Click to collapse
Hey guys,
Some time ago my phone started having the exact same problem that Stabbey describes: mounting the second partition no longer works, manually mounting the second partition results in the "Invalid argument" error when running this command in a terminal emulator:
Code:
mount -t ext2 -o rw /dev/block/mmcblk1p2 /data/sdext2
This started happening after I installed an update for busybox and some other apps and then rebooted. Something might have changed in the mount applet of busybox with that update, and that might have broken the mount command. Right now I don't know for sure if this is the case; I haven't figured out how to roll back the busybox update yet. In any case, if I can't manually mount, it certainly won't work on startup with init.d, so I'm stuck for now.
I'm sorry I can't give any of you a solution right now. If anyone else wants to take a crack at it, my problems started after installing busybox 1.25.1, so a version *before* that might work.
大神你好:
这是个非常厉害的好办法!您帮我解决了这个疑难杂症!让我手机重新获得新生,而且问题分析得非常准确。
致敬!
机油
Hi Warre101
thank you so much for your solution!
However, I still have a small issue:
When I created a file in the init.d folder, I ended with a .txt file while the others in that folder have no extension. I wrote the code you mentioned. Then with Universal init.d app, I executed the file, and it worked -> the partition get mounted. But, when I reboot my phone, it is not done automatically: I have the error message on Link2sd, then I have to come back to Universal init.d, execute the script, and come back to Link2sd to see it is mounted. Do you have an idea to have it done automatically?
the init-link2sd.sh file is like this (when the partition in mounted) :
Code:
set +e
echo "$(date)mounting..." > $LOG
sleep 2
mount -t ext4 -o rw /dev/block/vold/public:179_130 /data/sdext2 1>>$LOG 2>>$LOG
mount -t ext4 -o rw /dev/block/mmcblk1p2 /data/sdext2 1>>$LOG 2>>$LOG
mount >> $LOG
echo "$(date) mount finished" >> $LOG
chmod 773 /data/dalvik-cache
The partition I created using minitool is in ext4
The 11link2sd.txt file is:
Code:
#!/system/bin/sh
sleep 2
mount -t ext4 -o rw /dev/block/mmcblk1p2 /data/sdext2
Then in /data I got a new file link2sd-boot-receiver-mount.log:
Code:
Tue Oct 24 09:47:50 CEST 2017 mounting...
mount: No such file or directory
rootfs / rootfs ro,seclabel 0 0
tmpfs /dev tmpfs rw,seclabel,nosuid,relatime,mode=755 0 0
devpts /dev/pts devpts rw,seclabel,relatime,mode=600 0 0
proc /proc proc rw,relatime 0 0
sysfs /sys sysfs rw,seclabel,relatime 0 0
selinuxfs /sys/fs/selinux selinuxfs rw,relatime 0 0
debugfs /sys/kernel/debug debugfs rw,seclabel,relatime 0 0
none /acct cgroup rw,relatime,cpuacct 0 0
none /sys/fs/cgroup tmpfs rw,seclabel,relatime,mode=750,gid=1000 0 0
tmpfs /mnt tmpfs rw,seclabel,relatime,mode=755,gid=1000 0 0
none /dev/cpuctl cgroup rw,relatime,cpu 0 0
pstore /sys/fs/pstore pstore rw,seclabel,relatime 0 0
/dev/block/platform/mtk-msdc.0/11120000.msdc0/by-name/system /system ext4 ro,seclabel,relatime,data=ordered 0 0
/dev/block/platform/mtk-msdc.0/11120000.msdc0/by-name/userdata /data ext4 rw,seclabel,nosuid,nodev,noatime,discard,noauto_da_alloc,resuid=10010,data=ordered 0 0
/dev/block/platform/mtk-msdc.0/11120000.msdc0/by-name/cache /cache ext4 rw,seclabel,nosuid,nodev,noatime,discard,noauto_da_alloc,data=ordered 0 0
/dev/block/platform/mtk-msdc.0/11120000.msdc0/by-name/protect1 /protect_f ext4 rw,seclabel,nosuid,nodev,noatime,nodelalloc,noauto_da_alloc,commit=1,data=ordered 0 0
/dev/block/platform/mtk-msdc.0/11120000.msdc0/by-name/protect2 /protect_s ext4 rw,seclabel,nosuid,nodev,noatime,nodelalloc,noauto_da_alloc,commit=1,data=ordered 0 0
/dev/block/platform/mtk-msdc.0/11120000.msdc0/by-name/nvdata /nvdata ext4 rw,seclabel,nosuid,nodev,noatime,discard,noauto_da_alloc,data=ordered 0 0
adb /dev/usb-ffs/adb functionfs rw,relatime 0 0
tmpfs /storage tmpfs rw,seclabel,relatime,mode=755,gid=1000 0 0
/dev/block/loop1 /su ext4 rw,seclabel,noatime,data=ordered 0 0
/dev/fuse /mnt/runtime/default/emulated fuse rw,nosuid,nodev,noexec,noatime,user_id=1023,group_id=1023,default_permissions,allow_other 0 0
/dev/fuse /storage/emulated fuse rw,nosuid,nodev,noexec,noatime,user_id=1023,group_id=1023,default_permissions,allow_other 0 0
/dev/fuse /mnt/runtime/read/emulated fuse rw,nosuid,nodev,noexec,noatime,user_id=1023,group_id=1023,default_permissions,allow_other 0 0
/dev/fuse /mnt/runtime/write/emulated fuse rw,nosuid,nodev,noexec,noatime,user_id=1023,group_id=1023,default_permissions,allow_other 0 0
/dev/block/vold/public:179,129 /mnt/media_rw/319C-76D0 vfat rw,dirsync,nosuid,nodev,noexec,relatime,uid=1023,gid=1023,fmask=0007,dmask=0007,allow_utime=0020,codepage=437,iocharset=iso8859-1,shortname=mixed,utf8,errors=remount-ro 0 0
/dev/fuse /mnt/runtime/default/319C-76D0 fuse rw,nosuid,nodev,noexec,noatime,user_id=1023,group_id=1023,default_permissions,allow_other 0 0
/dev/fuse /storage/319C-76D0 fuse rw,nosuid,nodev,noexec,noatime,user_id=1023,group_id=1023,default_permissions,allow_other 0 0
/dev/fuse /mnt/runtime/read/319C-76D0 fuse rw,nosuid,nodev,noexec,noatime,user_id=1023,group_id=1023,default_permissions,allow_other 0 0
/dev/fuse /mnt/runtime/write/319C-76D0 fuse rw,nosuid,nodev,noexec,noatime,user_id=1023,group_id=1023,default_permissions,allow_other 0 0
/dev/block/mmcblk1p2 /data/sdext2 ext4 rw,seclabel,relatime,data=ordered 0 0
Tue Oct 24 09:47:50 CEST 2017 mount finished
I used MiXplorer that I found on thi forum as a file explorer and to create the script file.
I am on Android 6.0, stock ROM but not original (eg when I bought the phone the stock ROM was on Android 5, then I discovered they changed to Android 6 so I downloaded the new stock ROM from the official website and flashed it).
Thank you for your help !

Categories

Resources