WelcomeWelcome | FAQFAQ | DownloadsDownloads | WikiWiki

Author Topic: initrd  (Read 2908 times)

Offline icbrainy

  • Newbie
  • *
  • Posts: 3
initrd
« on: April 12, 2015, 11:28:36 AM »
howdy guys,

I have been trying for a while to make a custom ramdisk image for vmlinuz to load. So far I can get the kernel to detect GZIP presence but I cannot get any further due to this:

RAMDISK: zgip image found at block 0
List of all partitions:
0b00  1048575 sr0 driver: sr
No filesystem could mount root, tried: ext3 ext2 ext4 cramfs vfat iso9660 fuseblk
Kernel panic - not syncing: VFS: Unable to mount root fs on unknown-block(2,0)
Kernel Offser: 0x0 from 0xc0100000 (relocation range: 0xc0000000-0xe07fffff)

My image is a CPIO inside a GZIP and was built with the Windows version of gnuwin32 CPIO utility (http://gnuwin32.sourceforge.net/packages/cpio.htm). It has caught my eye that my CPIO archive's "Host OS" trait, according to 7-zip when viewing, says "FAT" instead of Unix in the official gz file featured in the official downloads on the TCL front page.

Does anybody know what I might be doing wrong?

If anyone needs it for diagnostics, my isolinux.cfg is:

PROMPT 0
NOESCAPE 1
DEFAULT n
LABEL n
KERNEL kernel
APPEND initrd=image

(I am a beginner at this so I apologise for my naivity. Also I don't have any Linux machines of my own so any linux-exclusive things are not possible on my end.)

Offline gerald_clark

  • TinyCore Moderator
  • Hero Member
  • *****
  • Posts: 4254
Re: initrd
« Reply #1 on: April 12, 2015, 03:14:31 PM »
Follow the instructions in the wiki.

Offline curaga

  • Administrator
  • Hero Member
  • *****
  • Posts: 11044
Re: initrd
« Reply #2 on: April 13, 2015, 03:25:51 AM »
You really shouldn't use Windows for such things. You'll break permissions, line endings...

If you can't use TC live (cd or usb), use a virtual machine.
The only barriers that can stop you are the ones you create yourself.

Offline icbrainy

  • Newbie
  • *
  • Posts: 3
Re: initrd
« Reply #3 on: April 13, 2015, 04:16:35 AM »
You really shouldn't use Windows for such things. You'll break permissions, line endings...

If you can't use TC live (cd or usb), use a virtual machine.
So...What I need to do is replicate the file system within a live Linux OS environment with a single folder acting as the filesystem root, applying the relevant permissions, then run it though "makecpio" or something to make the final file?

Offline curaga

  • Administrator
  • Hero Member
  • *****
  • Posts: 11044
Re: initrd
« Reply #4 on: April 13, 2015, 04:57:15 AM »
Better to create it in Linux in the first place, trying to patch up permissions is bound to miss some.
The only barriers that can stop you are the ones you create yourself.

Offline Rich

  • Administrator
  • Hero Member
  • *****
  • Posts: 11590
Re: initrd
« Reply #5 on: April 13, 2015, 11:13:57 AM »
Hi icbrainy
Go to:
http://tinycorelinux.net/faq.html#pendrives
There is link for core2usb. This will allow you to create a bootable Linux environment on a thumb drive so you can use the proper tools.

Offline icbrainy

  • Newbie
  • *
  • Posts: 3
Re: initrd
« Reply #6 on: April 14, 2015, 09:33:35 AM »
Right, I downloaded Zorin OS 9 since it looks somewhat familiar to Windows and did the exact same procedures that I did before being pointed out that doing this on Windows wasn't wise of me.

Thanks and much appreciation for the pointers, the kernel is no longer complaining and now mounts perfectly and without error. I have patched together a straightforward image that launches bash immediately. The image size when gzipped is only 1.22MB and my CD image size is only 4.52MB when coupled up with the kernel, isolinux.cfg, and boot sector. Again, many thanks.