PDA

View Full Version : How to format 2gig rs-mmc?


seandarcy
10-29-2006, 01:57 PM
It appears that ext2 is the format of choice, but

a. Is there a need for a vfat partition? If so, how much 32, 64 meg?

b. Some put on a linux swap partition. Why? Does the 770 just "find" it? How does this integrate with the virtual memory app in control panel? Is this limited to 64 mb, like the virtual memory app?

Then I assume the rest would be ext2.

sean

BanditRider
10-31-2006, 06:41 AM
Here's what I did with my 2GB card.
The first partition is 256MB FAT32. I store my e-books and such here. This partition gets unmounted from the 770 and mounted on your PC when you connect with the USB cable.
The second partition is 1.6GB ext2. Here is where my maemo-mapper maps are stored along with a few videos and such.
The remaining 128MB or so is formated as linux swap.

Now, in order to use this setup, you need to edit a few files as root so make sure you can become root and get a # prompt. Also you'll need an editor that you know how to use. I like the built-in vi editor or the vim application but I've been using vi for 20 years. It's not the easiest editor to learn. Midnight Commander (mc) is a cool console file manager that has an editor and I think there's a leafpad for OS2006.

The first thing we'll do is tell the 770 how to mount the partitions by adding a few lines to /etc/fstab. Open xterm (or ssh in from your PC) and "switch user" (su) to root by typing
sudo su -
note the space and dash after su.
Your prompt should end in ~# If not, you're not root. fix this before continuing.

Open /etc/fstab in your editor of choice and add the folowing 2 lines:
/dev/mmcblk0p2 /media/mmc2 ext2 rw,noauto 0 0
/dev/mmcblk0p3 swap swap defaults 0 0

Next we want to load the ext2 kernel module and mount the ext2 partition and activate the swap partition. Open /etc/init.d/minircS in your editor. near the top, right after the PATH= line add this line:
insmod /mnt/initfs/lib/modules/2.6.16-omap1/ext2.ko
Then at the end of the file, just before the exit 0 line, add:
swapon -a
mount /media/mmc2

Now to be nice, we want to unmount mmc2 and de-activate the swap when re-booting or shutting down so edit both /etc/init.d/minireboot and /etc/init.d/minishutdown. Find the line that starts: umount -r and add /media/mmc2 to that line and add swapoff -a so it looks like this:
echo "Unmounting filesystems... "
umount -r /media/mmc1 /media/mmc2 /mnt/initfs /
swapoff -a
echo "done."

reboot and that's it. You now have a 128MB swap, a big FAT32 partition at /media/mmc1 and a nice big ext2 partition at /media/mmc2.

seandarcy
11-03-2006, 06:43 PM
Tremendous!

I really appreciate the detailed instructions.

seandarcy
11-04-2006, 01:14 PM
Just finished this, after installing the new ( Nov 2 ) kernel.

One change:

insmod /mnt/initfs/lib/modules/2.6.16-omap1/ext2.ko

becomes:

insmod /mnt/initfs/lib/modules/2.6.16.27-omap1/ext2.ko

It also took two reboots.

But it all works for me now.

BTW, your new swap partition will not show up in the Control Panel->Memory applet. To check it cat/proc/swaps.

aflegg
11-05-2006, 06:32 AM
Using /mnt/initfs/lib/modules/current/ext2.ko should insulate you from kernel version changes.

This is what I'm doing in my init script which overlays a MMC-directory over /home/user so I don't need to backup/reflash.

Unfortunately it's more of an "override" than a "union", so it's not really suitable for much else other than /home/user.

thaibill
03-05-2007, 12:09 AM
Here's what I did with my 2GB card.
The first partition is 256MB FAT32. I store my e-books and such here. This partition gets unmounted from the 770 and mounted on your PC when you connect with the USB cable.
The second partition is 1.6GB ext2. Here is where my maemo-mapper maps are stored along with a few videos and such.
The remaining 128MB or so is formated as linux swap.

Now, in order to use this setup, you need to edit a few files as root so make sure you can become root and get a # prompt. Also you'll need an editor that you know how to use. I like the built-in vi editor or the vim application but I've been using vi for 20 years. It's not the easiest editor to learn. Midnight Commander (mc) is a cool console file manager that has an editor and I think there's a leafpad for OS2006.

The first thing we'll do is tell the 770 how to mount the partitions by adding a few lines to /etc/fstab. Open xterm (or ssh in from your PC) and "switch user" (su) to root by typing
sudo su -
note the space and dash after su.
Your prompt should end in ~# If not, you're not root. fix this before continuing.

Open /etc/fstab in your editor of choice and add the folowing 2 lines:
/dev/mmcblk0p2 /media/mmc2 ext2 rw,noauto 0 0
/dev/mmcblk0p3 swap swap defaults 0 0

Next we want to load the ext2 kernel module and mount the ext2 partition and activate the swap partition. Open /etc/init.d/minircS in your editor. near the top, right after the PATH= line add this line:
insmod /mnt/initfs/lib/modules/2.6.16-omap1/ext2.ko
Then at the end of the file, just before the exit 0 line, add:
swapon -a
mount /media/mmc2

Now to be nice, we want to unmount mmc2 and de-activate the swap when re-booting or shutting down so edit both /etc/init.d/minireboot and /etc/init.d/minishutdown. Find the line that starts: umount -r and add /media/mmc2 to that line and add swapoff -a so it looks like this:
echo "Unmounting filesystems... "
umount -r /media/mmc1 /media/mmc2 /mnt/initfs /
swapoff -a
echo "done."

reboot and that's it. You now have a 128MB swap, a big FAT32 partition at /media/mmc1 and a nice big ext2 partition at /media/mmc2.

I did the things above with the -14 and had no problems. But since upgrading to the -49 firmware, Audioplayer, VideoPlayer. File Manager, etc, cannot see the mmc2 partition. df sees the partition and I can cp to it via xterm. I've flashed to the -49 firmware, three times and checked for editor errors in the files above.

Any suggestions for correcting this problem.

thaibill

BanditRider
03-08-2007, 05:46 AM
What I do is put a symbolic link to the directory in ~/MyDocs
One for root so I can browse the whole filesystem and one for mmc2 to save me a few clicks when looking there.

ln -s / ~/MyDocs/root
ln -s /media/mmc2 ~/MyDocs/mmc2

thaibill
03-08-2007, 08:24 PM
What I do is put a symbolic link to the directory in ~/MyDocs
One for root so I can browse the whole filesystem and one for mmc2 to save me a few clicks when looking there.

ln -s / ~/MyDocs/root
ln -s /media/mmc2 ~/MyDocs/mmc2

Mucho thanks. I vaguely remember the second link but can't find it in my notes. The first link definitely is useful.

thaibill

revwillie
03-14-2007, 08:26 PM
I had a 1GB MMC card working fine. I thought that since I had the gregale firmware installed, a 2GB card would work automatically. But something is not right with my 770 since I started using the 2GB card. When I check the space left on the card from within the 770, it says the card is nearly full at only ~990MB. The 770 also seems to slow down and/or lock up often now. I made a point of formatting the card in the 770 to it's full capacity before writing to it.

What did I miss?

Karel Jansens
03-15-2007, 07:23 AM
I had a 1GB MMC card working fine. I thought that since I had the gregale firmware installed, a 2GB card would work automatically. But something is not right with my 770 since I started using the 2GB card. When I check the space left on the card from within the 770, it says the card is nearly full at only ~990MB. The 770 also seems to slow down and/or lock up often now. I made a point of formatting the card in the 770 to it's full capacity before writing to it.

What did I miss?

I'd suggest formatting it on a pc (cardreader or 770 connected through USB). The Internet Tablet's file manager is notoriously stupid.

revwillie
03-15-2007, 09:15 PM
I'd suggest formatting it on a pc (cardreader or 770 connected through USB). The Internet Tablet's file manager is notoriously stupid.

OK, here's the weird part. Every device and card reader I've tried will only format the card as 1GB. I have a brand new laptop with a built in card reader running vista and it also will only let me format as 1GB.

euchreprof
03-15-2007, 10:25 PM
Where did you buy your card memory from? An eBay Hong Kong seller?

revwillie
03-15-2007, 10:47 PM
Where did you buy your card memory from? An eBay Hong Kong seller?

Why? is this a known issue? (that's where I got it from)

Milhouse
03-15-2007, 11:42 PM
Why? is this a known issue? (that's where I got it from)

Yes, fairly (http://www.internettablettalk.com/forums/showthread.php?p=37229&highlight=ebay+fake#post37229) well known. It's possible you've bought a 1GB card remarked as 2GB.

BanditRider
03-16-2007, 06:07 AM
It may just have a 1GB partition.
Try deleting all existing partitions and creating a new one.

revwillie
03-16-2007, 01:15 PM
It may just have a 1GB partition.
Try deleting all existing partitions and creating a new one.

That's what I was hoping. I know it said it had 2GB free when I first put it in the 770. Then I formatted it in the 770 and I don't remember if I re-checked the capacity. The 770 formatter offered no choices. When I got up to about 900 megs, started noticing the system monitor plugin's mmc bar was almost full. Now, windows only recognizes 979megs available to format. The disk manager in WinXP was no help. It wouldn't let me delete the partition and it appeared to show only 1GB for total capacity.

I don't have a linux box anymore. I booted a mandriva live CD in my wife's laptop last night. It's a new Dell XPS with a built in card reader (ricoh something). I looked for a while and couldn't find a reference in dmesg or the /dev files of the card in the card slot so I don't know what /dev to mount or format. I'm not able to stay up late fiddling with linux like I used to. I gave up around midnight.

BanditRider
03-17-2007, 10:31 AM
I use gparted or qtparted to edit partitions in linux.

nspeer
03-30-2007, 07:15 PM
Where did you buy your card memory from? An eBay Hong Kong seller?


I just received my supposed 2GB card from an Ebay Hong Kong seller too. Guess what? It was marked with a little sticker that said "2GB" but my 770 only reads it as a 1GB. I had to format it in order for it not to be greyed out in the file manager.

I actually did read a few feedbacks on this Ebay seller saying he sent them a 1GB instead of a 2GB but his overall feedback rating is 98.3 with over 9000 sales. He goes by the name of "wholesaleoffer" on Ebay. I've emailed him to see what he intends to do about the bogus 2GB card, but, I'm sure I'll not get any resolution. BTW, it took a month to receive it (I live in Colorado).
Live and learn!
Neil

SeRi@lDiE
03-30-2007, 07:26 PM
I never never NEVER buy from ebay.

rr0123
03-30-2007, 07:32 PM
My limit is 99+ percent. I won't go to 98%. At 98, it seems to me they are getting at least some legitimate gripes that they did not work to resolve.

euchreprof
03-31-2007, 12:20 AM
I never never NEVER buy from ebay.


I always thought this way until 6 months ago and i bought a bunch of small stuff and then gained enough confidence to finally get my Nokia N800 from eBay (but I only bought this one because it still had the SEAL intact) and I have had 0 problems with it so far. But I heard about eBay like 10 years ago or so and I vowed to never buy 1 thing on it... in 61 experiences I had just a couple of small lies from the sellers but never got ripped off.

Milhouse
03-31-2007, 01:00 PM
I never never NEVER buy from ebay.

I wouldn't say that for all auctions on eBay, but certainly I would not buy Flash memory from eBay, there are too many re-programmed and fake memory cards on eBay to make it worth the risk. :(

I think there should be a stick on here somewhere - "Don't buy memory cards from eBay!". :)

revwillie
04-02-2007, 09:37 PM
He goes by the name of "wholesaleoffer" on Ebay. I've emailed him to see what he intends to do about the bogus 2GB card, but, I'm sure I'll not get any resolution. BTW, it took a month to receive it (I live in Colorado).
Live and learn!
Neil

yep, same seller for me. I was promised a replacement card and I've made it clear that I'm considering filing fraud charges.

one quote: "one chip may be defective in the card"
shipping takes forever. My rma return shipment to HK only took a couple of days global priority mail for five bucks and change.

nspeer
04-03-2007, 12:19 AM
yep, same seller for me. I was promised a replacement card and I've made it clear that I'm considering filing fraud charges.

one quote: "one chip may be defective in the card"
shipping takes forever. My rma return shipment to HK only took a couple of days global priority mail for five bucks and change.

Yeah, he tried to tell me that he had a problem with his supplier and would send me another 1gb card or refund me $7.50 is I just kept the 1gb card he sent me. He said if I chose a refund for the 1gb card, I had to pay return shipping and he would only refund me the card price and not his shipping cost...which was $20. I replied that if I had wanted a 1gb card, I would have bought one...and not his alleged 2gb card.

Let me know if you decide to pursue action against him...I'm in.
Neil

revwillie
04-05-2007, 12:52 AM
If you paid with paypal, register a dispute with the paypal website. You can force a refund if you follow all of their silly rules.

nspeer
04-08-2007, 10:02 PM
If you paid with paypal, register a dispute with the paypal website. You can force a refund if you follow all of their silly rules.


I did register a complaint with PayPal. I'm still waiting to hear back from them. I urge anyone else who has be hosed by these clowns to register a complaint.
Neil

revwillie
04-16-2007, 09:46 AM
Sorry to hijack the thread and all. I'm awaiting a replacement card from that ebay seller, but I bit the bullet and got one of the kingston dual voltage 2gig cards for $50 from Meritline. Thanks to the fanoush wiki and this thread, I have the card partitioned, formatted and I'm booting from the 1.6gig ext2 partition. It's a little early to say, but I may have fixed my full memory problems.

At first, the swap partition wasn't working as expected, but I was using tabs in the fstab file instead of double spaces....oops. Now, all the little bars in my system monitor plugin are down low in the green :cool:

kalex
05-23-2007, 10:45 PM
Hey everybody,

just got myself 770 and I can say so far its the best thing for reading books, manuals i could find. i have tried many things before :)

Here is what i'm trying to do:

I got a 2gb card and want to create partions on it and my next step would be to boot from it. What i'm trying to figure is will the post by BanditRider would allow me to create and format the partions?

i was reading the wiki here:
http://maemo.org/community/wiki/HowTo_EASILY_Boot_From_MMC_card

Step 2 says to partition the card and follow this link: http://maemo.org/maemowiki/HowTo_EASILY_Partition_your_MMC_card to do it. my question is I use this method quoated below to do this? or do i have to folow the wiki page to do it?





Thanks

Alex

Here's what I did with my 2GB card.
The first partition is 256MB FAT32. I store my e-books and such here. This partition gets unmounted from the 770 and mounted on your PC when you connect with the USB cable.
The second partition is 1.6GB ext2. Here is where my maemo-mapper maps are stored along with a few videos and such.
The remaining 128MB or so is formated as linux swap.

Now, in order to use this setup, you need to edit a few files as root so make sure you can become root and get a # prompt. Also you'll need an editor that you know how to use. I like the built-in vi editor or the vim application but I've been using vi for 20 years. It's not the easiest editor to learn. Midnight Commander (mc) is a cool console file manager that has an editor and I think there's a leafpad for OS2006.

The first thing we'll do is tell the 770 how to mount the partitions by adding a few lines to /etc/fstab. Open xterm (or ssh in from your PC) and "switch user" (su) to root by typing
sudo su -
note the space and dash after su.
Your prompt should end in ~# If not, you're not root. fix this before continuing.

Open /etc/fstab in your editor of choice and add the folowing 2 lines:
/dev/mmcblk0p2 /media/mmc2 ext2 rw,noauto 0 0
/dev/mmcblk0p3 swap swap defaults 0 0

Next we want to load the ext2 kernel module and mount the ext2 partition and activate the swap partition. Open /etc/init.d/minircS in your editor. near the top, right after the PATH= line add this line:
insmod /mnt/initfs/lib/modules/2.6.16-omap1/ext2.ko
Then at the end of the file, just before the exit 0 line, add:
swapon -a
mount /media/mmc2

Now to be nice, we want to unmount mmc2 and de-activate the swap when re-booting or shutting down so edit both /etc/init.d/minireboot and /etc/init.d/minishutdown. Find the line that starts: umount -r and add /media/mmc2 to that line and add swapoff -a so it looks like this:
echo "Unmounting filesystems... "
umount -r /media/mmc1 /media/mmc2 /mnt/initfs /
swapoff -a
echo "done."

reboot and that's it. You now have a 128MB swap, a big FAT32 partition at /media/mmc1 and a nice big ext2 partition at /media/mmc2.

thaibill
07-28-2007, 02:30 AM
Here's what I did with my 2GB card.
The first partition is 256MB FAT32. I store my e-books and such here. This partition gets unmounted from the 770 and mounted on your PC when you connect with the USB cable.
The second partition is 1.6GB ext2. Here is where my maemo-mapper maps are stored along with a few videos and such.
The remaining 128MB or so is formated as linux swap.

Now, in order to use this setup, you need to edit a few files as root so make sure you can become root and get a # prompt. Also you'll need an editor that you know how to use. I like the built-in vi editor or the vim application but I've been using vi for 20 years. It's not the easiest editor to learn. Midnight Commander (mc) is a cool console file manager that has an editor and I think there's a leafpad for OS2006.

The first thing we'll do is tell the 770 how to mount the partitions by adding a few lines to /etc/fstab. Open xterm (or ssh in from your PC) and "switch user" (su) to root by typing
sudo su -
note the space and dash after su.
Your prompt should end in ~# If not, you're not root. fix this before continuing.

Open /etc/fstab in your editor of choice and add the folowing 2 lines:
/dev/mmcblk0p2 /media/mmc2 ext2 rw,noauto 0 0
/dev/mmcblk0p3 swap swap defaults 0 0

Next we want to load the ext2 kernel module and mount the ext2 partition and activate the swap partition. Open /etc/init.d/minircS in your editor. near the top, right after the PATH= line add this line:
insmod /mnt/initfs/lib/modules/2.6.16-omap1/ext2.ko
Then at the end of the file, just before the exit 0 line, add:
swapon -a
mount /media/mmc2

Now to be nice, we want to unmount mmc2 and de-activate the swap when re-booting or shutting down so edit both /etc/init.d/minireboot and /etc/init.d/minishutdown. Find the line that starts: umount -r and add /media/mmc2 to that line and add swapoff -a so it looks like this:
echo "Unmounting filesystems... "
umount -r /media/mmc1 /media/mmc2 /mnt/initfs /
swapoff -a
echo "done."

reboot and that's it. You now have a 128MB swap, a big FAT32 partition at /media/mmc1 and a nice big ext2 partition at /media/mmc2.

What are the owner/permission for /media/mmc1 and /media/mmc2 when finished with the instructions above?

Bill

DJTim
07-29-2007, 03:25 PM
I just followed the instructions here:
http://maemo.org/maemowiki/HowTo_EASILY_Partition_your_MMC_card

but changed 15000 to 20000

so, my USB partition mounts as 638MB, but I cannot fathom why I would need over a gig for the OS?

I'm thinking of re-doing it.

BanditRider
08-03-2007, 06:11 AM
Bill,
Here's what I have.

Nokia770-49:~$ cd /media
Nokia770-49:/media$ ls -lA
drwxr-xr-x 6 user root 4096 Dec 31 1969 mmc1
drwxrwxrwx 4 user root 4096 May 26 19:14 mmc2
Nokia770-49:/media$ ls -lA mmc1
drwxr-xr-x 2 user root 4096 Nov 5 2006 .archive
drwxr-xr-x 2 user root 4096 Feb 25 06:29 .canola
drwxr-xr-x 2 user root 8192 Oct 12 2006 Books
drwxr-xr-x 20 user root 4096 Jan 28 2007 backup
Nokia770-49:/media$ ls -lA mmc2
drwx------ 2 root root 16384 Oct 12 2006 lost+found
drwxrwxr-x 7 user users 4096 Feb 16 07:22 maps