Author Topic: Auto-mounting multi-partitioned cards  (Read 3225 times)

zenyatta

  • Sr. Member
  • ****
  • Posts: 366
    • View Profile
    • http://
Auto-mounting multi-partitioned cards
« on: July 12, 2004, 08:25:24 am »
Hi all,

I recently split my CF card into two partitions (/dev/hda1: FAT, /dev/hda2: ext2). I use the FAT partition for flashing and I store my data & programs on the ext2 partition (it is set up as an ipkg destination).

My problem is that only /dev/hda1 gets auto-mounted. I tried various things:

1. tweaking /etc/fstab
2. installing opie-mediummount and tweaking the settings
3. adding "mount /mnt/cf2" to $HOME/.profile

The last option works in that it handles startup. It does not work when I eject and re-insert the CF card. I don't like this solution. I would like to auto-mount /dev/hda2 using the same mechanism that works for /de/hda1. Can anyone advise me how to do that?

thx in advance.

z.
« Last Edit: July 12, 2004, 08:27:21 am by zenyatta »
SL-5500, 256MB Kingston CF card, 128MB EDGE SD card, Thomson HED-155 headphones
OpenZaurus 3.5.3 / Opie (kernel 64-0)

maslovsky

  • Hero Member
  • *****
  • Posts: 1426
    • View Profile
    • http://my-zaurus.narod.ru
Auto-mounting multi-partitioned cards
« Reply #1 on: July 12, 2004, 07:56:17 pm »
Look into /etc/pcmcia/ide script

zenyatta

  • Sr. Member
  • ****
  • Posts: 366
    • View Profile
    • http://
Auto-mounting multi-partitioned cards
« Reply #2 on: July 13, 2004, 04:52:52 am »
Of course! I even remember helping someone with the same problem a while ago. Wonder how I could have forgotten about that... And next time I will also search the forums for automounting, not just auto-mounting  

Anyway, I wrote up a multi-partition Howto for future generations.

z.
« Last Edit: July 13, 2004, 04:54:01 am by zenyatta »
SL-5500, 256MB Kingston CF card, 128MB EDGE SD card, Thomson HED-155 headphones
OpenZaurus 3.5.3 / Opie (kernel 64-0)

jesizmi

  • Jr. Member
  • **
  • Posts: 66
    • View Profile
    • http://
Auto-mounting multi-partitioned cards
« Reply #3 on: July 26, 2004, 01:03:40 pm »
Hi zenyatta,
when I found this posting, I first thought, my problems where solved.
I have my SD-Card partitioned with 1. vfat and 2. ext2 but I'm not shure in which way your how-to can be adapted for SD-Cards. Can you give me some advise, where to find something similar for SD.
So far I found /etc/sdcontrol which seems to deal with mounting of SD, but beeing not exactly an expert, I'm completely at a loss to figure out, what to do.

Thx
C860 Cacko ROM 1.23 / OZ 3.5.4.1
CF: 512M extreMemory
SD: 1G noname (2 partitions automounted; vfat+ext2)
Stylus: Tungsten T

maslovsky

  • Hero Member
  • *****
  • Posts: 1426
    • View Profile
    • http://my-zaurus.narod.ru
Auto-mounting multi-partitioned cards
« Reply #4 on: July 26, 2004, 03:15:36 pm »
Quote
Hi zenyatta,
when I found this posting, I first thought, my problems where solved.
I have my SD-Card partitioned with 1. vfat and 2. ext2 but I'm not shure in which way your how-to can be adapted for SD-Cards. Can you give me some advise, where to find something similar for SD.
So far I found /etc/sdcontrol which seems to deal with mounting of SD, but beeing not exactly an expert, I'm completely at a loss to figure out, what to do.

Thx
The way /etc/sdconrtol manages SD cards should be very similar, except for partition names - /dev/mmcda1, /dev/mmcda2, etc instead of /dev/hda

zenyatta

  • Sr. Member
  • ****
  • Posts: 366
    • View Profile
    • http://
Auto-mounting multi-partitioned cards
« Reply #5 on: July 27, 2004, 04:30:05 am »
Well, I don't have an SD card so I cannot help you with any practical experience. Maslovsky is right, though. You should be able to just substitute different /dev entries and be fine. There seems to be a problem with the ZUG Wiki so I cannot review the Howto right now.

If you do succeed please amend the Howto or post here.

z.
SL-5500, 256MB Kingston CF card, 128MB EDGE SD card, Thomson HED-155 headphones
OpenZaurus 3.5.3 / Opie (kernel 64-0)

jesizmi

  • Jr. Member
  • **
  • Posts: 66
    • View Profile
    • http://
Auto-mounting multi-partitioned cards
« Reply #6 on: July 29, 2004, 09:24:59 am »
Hi all,
after some trial and error cycles, I finally got my SD-auto-mounting for 2 Partitions working. Since the sdcontrol is a little longish, I'm not quoting the code here.
What I did was to duplicate everything except for the initial comment lines and the final exit 0 statement, just altering three lines in the beginning:

Quote
ACTION=$1
DEVICE=/dev/mmcda1
MOUNT_POINT=/mnt/card
SMB_MOUNT=/home/samba/SD_Card
change to
ACTION=$1
DEVICE=/dev/mmcda2
MOUNT_POINT=/mnt/card2
SMB_MOUNT=/home/samba/SD_Card2

edititing fstab I just followed zenyatta's How-To which helped me quiet a lot.

I'm in no way certain whether what I did was all correct - though it worked for me.
If someone feels an urge to simplify the procedure, I'll be gratefull for a hint.
C860 Cacko ROM 1.23 / OZ 3.5.4.1
CF: 512M extreMemory
SD: 1G noname (2 partitions automounted; vfat+ext2)
Stylus: Tungsten T