You are not logged in.
Pages: 1
Hi,
so, I have been trying out archiso, and I like it for its simplicity. It certainly is nice work. I have been running into a problem though. I wanted to create a livecd with a different kernel than the mainline, the rt kernel in AUR for that matter. In order to do so, I made some minor, but necessary modifications to the scripts, basically some hacks.
In any case, I get up to the point where the archiso.img is to be created. However, mkinitcpio fails to see the archiso and boot-cd hooks, even though they certainly are present in /lib/initcpio/hooks, and get listed by the mkinitcpio -L command. Somehow, I feel I am missing something, but I am not sure what that is. Could anyone who knows more about this point me to my problem?
Cheers,
Blind
PS: I will try my best to make the scripts to accept any kernel, right now it is just a dirty hack.
Offline
My post is probably a little off but I have to post it anyway, just ignore it if you're offended in some way:
I've never used archiso but I use gradgrinds larch scripts without any problems. Are there any benefits in using archiso?
Sorry that I can't help you with your actual problem.
Dammit, haven't been here in a while. Still rocking Arch. ![]()
Offline
The implementation I was going to go for on the alternate kernel thing was to add some syntax to the mkarchiso command line to allow you to specify a non-repo package file to install on the image. This way you can make the alternate kernel and just include it like any other package on the command line. (currently we've got -P <pkgname> but that only works for packages in repos).
In the meantime, an easy way to hack around the issue is to make an in place repo somewhere with just your kernel in it, add that repo to your pacman.conf, and then explictly specify that kernel in the package list ... like "myrepo/kernel26". This is the easiest workaround that doesnt require monkeying with anything special.
The general gist of this is that the kernel should not be a special case if we can avoid it.
For the hooks thing, it's a little hard to say. If they're present they should work fine, so I'm a bit stumped like you are. did you use hte makefile ot install them or did you install them by hand?
The suggestion box only accepts patches.
Offline
Sigi: I don't know, I have never used larch...sorry
neotuli: Yeah, that is what I did, adding a repo. The problem is: for example in the rt-kernel, files are called differntly, e.g. not System.map26 but System.map26rt etc. This is not a real flaw in the scripts, but as these names are hardcoded, it poses a problem. I thought about redoing the kernel without these name-additions, well, long story, I would have had to add the gcc 4.3 patches etc. I was just too lazy, I suppose. And I thought about trying to get these additions somehow from the kernel package name...dunno if that makes sense.
As to the mkinitcpio, I installed by hand, but also checked permissions, so ... dunno.
Cheers,
Blind
Offline
Hi,
I saw the latest git change and tried it out. It does not work, because there still are hardcoded names of files in there that are invalid if a different kernel is used (e.g. also true for kernel26mm from extra):
etc/mkinitcpio.d/kernel26mm.kver
etc/mkinitcpio.d/kernel26mm.preset
etc/mkinitcpio.d/kernel26mm-fallback.conf
boot/kconfig26mm
boot/System.map26mm
boot/vmlinuz26mm
An example is line 77 in the mkarchiso script.
This has some other weird side effects. I am trying to fix this atm.
Blind
[edit]
PS: Ok, I fixed that issue and it should work now with any kernel. Let me know if you are interested in a patch.
However, here are the next problems:
1. I cannot remember that the script wanted unionfs/squashfs hooks. It does now, and I don't know where to get those from.
2. The genisoimage is missing. Where do I get that from?
[/edit]
Last edited by Blind (2008-03-30 17:17:47)
Offline
That's correct. It only removed one hardcoded reference. There is one left.
There are a few possible solutions I dicussed with dan... either we add yet another command line option and allow you to specify the kernel version (undesirable), or maybe just have _kversion() return an array of ALL_kvers, and change any code that uses it to loop on the array. I think the latter idea makes mroe sense in case someone's got multiple kernels for some reason, at least we'd hit all of them that way.
I'm always interested in patches, when in doubt, just send 'em ![]()
1. It shouldn't .... the hooks array looks like tihs doesnt it? HOOKS="base udev boot-cd archiso ide scsi sata usb fw filesystems"
2. What is genisoimage? If you meant mkisofs, you can find that in the cdrkit package.
The suggestion box only accepts patches.
Offline
Here is th hack... ![]()
Please regard it as a suggestion to tackle the problem ![]()
--- mkarchiso.orig 2008-03-30 10:48:18.000000000 -0600
+++ mkarchiso 2008-03-30 10:59:35.000000000 -0600
@@ -7,6 +7,7 @@
QUIET="y"
FORCE="n"
ADDON_DIR=""
+KERNELFLAVOR=`fgrep "kernel26" ${PKGFILE} | sed 's/kernel26//'`
command_name=""
work_dir=""
@@ -74,7 +75,7 @@
_kversion ()
{
- source ${instroot}/etc/mkinitcpio.d/kernel26.kver
+ source ${instroot}/etc/mkinitcpio.d/kernel26${KERNELFLAVOR}.kver
echo ${ALL_kver}
}I will post the errors I get by the script here soon.
[edit]
Oh, to 1:
====> Making ISO image
Generating initcpio for ISO...
:: Begin build
:: Parsing hook [base]
:: Parsing hook [udev]
:: Parsing hook [boot-cd]
ERROR: module 'unionfs' not found
ERROR: module 'squashfs' not found
:: Parsing hook [archiso]
ERROR: module 'unionfs' not found
ERROR: module 'squashfs' not found
:: Parsing hook [ide]
:: Parsing hook [scsi]
:: Parsing hook [sata]
:: Parsing hook [usb]
:: Parsing hook [fw]
:: Parsing hook [filesystems]
:: Generating module dependencies
Sorry, I confused hooks with modules.
Is this error critical? I assume this is because the patches for unionfs/squashfs are not included.
The next problem is: when I use testiso, grub looks for /boot/vmlinuz26. Of course, this file is now vmlinuz26BLAH.
I will look if I can change something there...
[/edit]
[edit2]
Ok, a progress report.
I found out that the missing modules are vital ![]()
I was able to boot the system with the grub command line, setting it to the right kernel image. Of course I got a kernel panic because the root file system was unknown.
Oh dear. On to a new rt - kernel with squashfs. Ack.
[/edit2]
[edit3]
Ok, compiling squashfs into the kernel helped. I have the feeling that in order to use a different kernel, you need to rename the files mentioned above to the 'conventional' names atm., i.e. System.map26, vmlinuz26, kernel26.preset etc. Otherwise the boot image will be out of control.
Also, when testing the image with testiso, I now get: /dev/cd not found in qemu.
What am I doing wrong now?
[/edit3]
Last edited by Blind (2008-03-31 15:14:45)
Offline
The whole point was that if you want to use a non-standard kernel, you would modify the "config overlay" for this. I am not sure if this has changed with the addition of the addon subsystem or not, but you should, in theory, only need to edit some config files to make this work.
Offline
Mmh, I was not able to understand from the README which config file is responsible for this.
From what I understood, I can install additional programs with the addon_config file, using either a squashed fs, or simply bind. It is not clear to me how I would force the boot image to use kernel26rt with this.
Right now, I am installing a base system (in packages.list), and pretty much only the kernel26 exchanged by kernel26rt from my private repo ( with squashfs/unionfs now
). I have now changed the mkarchiso script so the files just get renamed to what the script expects, and that works fine. But I think there is still something hardcoded...also when creating the boot ramdisk.
Well, dunno. Is there a documentation beyond the README?
Cheers,
Blind
Offline
Well, dunno. Is there a documentation beyond the README?
of course, there is the code itself (hurray for open source!)
pacman roulette : pacman -S $(pacman -Slq | LANG=C sort -R | head -n $((RANDOM % 10)))
Offline
Dumb question, dumb answer...
Offline
It's "hardcoded" in the default-config directory. This is the directory that has all the grub configs and all that fun stuff. Copy that directory to "my_personal_configs_for_this_thing" and use THAT instead of default-config
Offline
Hmmm it looks like there is no option to use an alternate directory for that. You should be able to just change the default-config files then.
Offline
Ah. Yeah, I see. Well, one could also just sed the menu.lst file.
Ok.
I will keep on trying here. Doesn't seem to be as easy as I hoped it would be. But already very nice for a start ![]()
I was able to boot the CD I created, but only until Arch's initscripts were started. Then it pretty much stopped.
But that might also be a kernel thing. udev takes about 33s.
Offline
Ok, so here is basically what I do:
1. rename the relevant kernel files
2. copy the etc/ directory from the default-config to the install etc/
Then everything works like a charm (except in qemu. Dunno, testing the iso doesn't work, because obviously, qemu does not create /dev/cd/*, maybe I am doing something wrong there).
Step 2. had me thrown off there for a coaster...
Blind
Offline
I've been trying to use archiso for my Arch fork, but am getting stuck at klibc's run-init. I have all of the modules needed, the right order of hook execution, and everything else *seems* to be fine.
First the base hook goes, then udev, then boot-cd, then archiso, but it stops at "/bin/run-init: opening console: No such file or directory". There are no prior errors to that.
I tried to `mknod c 5 1 /dev/console`, but the device is already existant, and I'm 99% sure its configured properly. I am using archiso from the most recent git commit.
Any ideas?
Thanks,
sega01
EDIT: The problem was from my udev package lacking the migrate-udev script.
Last edited by sega01 (2008-06-23 12:50:55)
Offline
Pages: 1