WelcomeWelcome | FAQFAQ | DownloadsDownloads | WikiWiki

Author Topic: Single FAT32 Partition  (Read 2617 times)

Offline pulse

  • Newbie
  • *
  • Posts: 3
Single FAT32 Partition
« on: February 13, 2021, 04:10:45 PM »
Hello,

would it be possible to run piCore from a single FAT32 partition which would contain all RPI firmware files, Linux kernel and also all piCore files? If yes: What would be needed to make this work?

Background: since all files are loaded into RAM at boot time and since SD card is not used afterwards, it would be simpler to have only one partition which is easily accessible from Windows when preparing the SD card for installation...

Regards,
MK

Offline Paul_123

  • Administrator
  • Hero Member
  • *****
  • Posts: 1243
Re: Single FAT32 Partition
« Reply #1 on: February 14, 2021, 08:11:39 AM »
It cannot be done with standard images.  You would have to remaster the image.   Build everything you need into the initrd.

Offline curaga

  • Administrator
  • Hero Member
  • *****
  • Posts: 11044
Re: Single FAT32 Partition
« Reply #2 on: February 14, 2021, 12:47:23 PM »
The tce dir can be stored on fat32, just persistent home/opt require a linux fs.
The only barriers that can stop you are the ones you create yourself.

Offline wysiwyg

  • Sr. Member
  • ****
  • Posts: 266
Re: Single FAT32 Partition
« Reply #3 on: February 16, 2021, 09:39:24 AM »
Wouldn't that pretty much be resolved by using the "filetool.sh -b" command curaga?  That just creates a tarball that could easily be stored on a FAT32 partition, yet restore all the files contained in the linux fs being used in RAM for TC.

The only thing that I would imagine would be necessary would be to mount the FAT32 partition to the /opt directory so the tarball would be stored permanently.

Dave

Offline curaga

  • Administrator
  • Hero Member
  • *****
  • Posts: 11044
Re: Single FAT32 Partition
« Reply #4 on: February 16, 2021, 12:27:42 PM »
Yes, the backup is stored under the tce dir by default. Its downside comes in slow boot and shutdown when you have lots of files in your home dir.
The only barriers that can stop you are the ones you create yourself.

Offline pulse

  • Newbie
  • *
  • Posts: 3
Re: Single FAT32 Partition
« Reply #5 on: February 20, 2021, 01:21:51 PM »
Thank you for all your answers! I had to read them many times, because I am new to building my own customized Linux... :-)

I did this:
1) I unpacked both partitions in piCore-12.0.zip on my working PC.
2) Then I gzipped the "tce" directory from the second partition into "extra.gz".
3) I copied "extra.gz" file into the directory for the first, FAT partition.
4) Then I edited config.txt from the first partition and added extra.gz after other GZ files in "initramfs".
5) I formatted my MicroSD card with FAT32 and copied the directory for the first partition (including extra.gz and changes in config.txt) onto the MicroSD.

Then I inserted MicroSD card into Raspberry PI and powered it on...

I came to the point:
--[ end Kernel panic - not syncing: VFS: Unable to mount root fs on unknown-block(1,0) ]--

So I guess I need to disable mounting the second partition somehow...

Do you know maybe where this could be done?

Is it somewhere in rootfs-piCore-12.0.gz? Or is this some parameter in cmdline.txt?

Thank you for your help!

Offline pulse

  • Newbie
  • *
  • Posts: 3
Re: Single FAT32 Partition
« Reply #6 on: February 20, 2021, 02:26:36 PM »
UPDATE: It seems to be something wrong with my change of initramfs in config.txt.

This time I did this:
1) I unpacked both partitions in piCore-12.0.zip on my working PC.
2) I formatted my MicroSD card with FAT32 and copied the directory of first partition onto the MicroSD (I didn't copy anything from the second partition).

I inserted MicroSD card into Raspberry PI and powered it on... and... it works!!! :-)

So it works almost out-of-the-box!

I guess there are some missing files which are present on the EXT partition, but it works anyway...

Offline CNK

  • Wiki Author
  • Sr. Member
  • *****
  • Posts: 278
Re: Single FAT32 Partition
« Reply #7 on: February 25, 2021, 10:13:48 PM »
Worked here too!

I copied the contents of both first and second partitions in the distribution image over to my single FAT32 parition on my SD card and added "tce=mmcblk0p1" to cmdline.txt. So loading extensions works too.

tce-ab shows a HTTP 404 error when I try to search for a package using that though, so I've had to download everything manually. I'm not sure if that problem is related to the single-partition installation( probably not?).