You are not logged in.
i think the lilo update on kernel update should be done automatically, and grub users could safely ignore the status message. something like that should be used if possible (taken from debian script by Guy Maor <maor@debian.org>) :
# check whether LILO is installed
lilocheck () {
echo -en "nChecking for LILO..."
if [ $(whoami) != root ] ; then
echo "Only root can check for LILO"
return 1;
fi
if [ ! -f /etc/lilo.conf -o ! -x /sbin/lilo ] ; then
echo "No"
return 1;
fi
bootpart=$(perl -ne 'print $1 if /^s*boots*=s*(S*)/' /etc/lilo.conf)
if [ -z "$bootpart" ] ; then
# lilo defaults to current root when 'boot=' is not present
bootpart=$rootpart
fi
if ! dd if=$bootpart ibs=16 count=1 2>&- | grep -q LILO ; then
echo -e "nYes, but I couldn't find a LILO signature on $bootpart"
echo "Check your /etc/lilo.conf, or run /sbin/lilo by hand."
return 1;
fi
echo "Updating lilo on $bootpart"
lilo
return 0;
}
Offline
although i use grub nowadays, i'd definately vote for this! good call...
Offline
im a grub user myself im just annoyed by this info message, but as a former lilo user and a n00b, i know this is priceless for beginners
Offline
it's one of those little things that i am surprised does not happen already - iin some ways i can see how it is against the arch ethos of not doing things for you - yet that's what all the blah.install scripts are for - seems reasonable to me!
just lilo won't cut it tho - what if you have changed your lilo config but not rerun lilo and seen that it has borked (pre installation of kernel?) - the users needs to be able to see the lilo output to confirm lilo has recreated the boot map correctly
Offline
thats not a problem. just change the script to suit those needs, and 'let my ppl go...'
Offline
Personally, I wouldn't want lilo to be run automatically, but I'm a bit of a control freak... in fact, I like to have control over what's in my kernel so I compile it myself... meaning it wouldn't affect me at all if this was included in kernel. However, it seems like it *could* cause problems, besides the ones phrakture mentioned... I just can't think of any, so maybe I'm paranoid.
Dusty
Offline
cause problems? how come? we are talking running lilo here... just to update the lilo.conf, which ANY lilo user MUST do after the kernel update. i honestly think this should be a trival thing, and highly doubt any problem can arrise from such a minor issue (ie, executing lilo... unless lilo is some fricking monster i dont know about... )
Offline
One obvious problem, that your script seems to address is if the user has switched to grub and lilo is still installed. I'd want to make sure that the script would work flawlessly here. Another is if the config file has changed since the last lilo update, it might run flawlessly and overwrite your mbr with a new lilo that won't boot your kernel for some reasons...
This could happed, for example, if pacman automatically included a new lilo.conf in an update.... but again, pacman is smart about updating config files, so I doubt it would cause a problem...
I honestly can't come up with any more serious problem, but if the lilo call doesn't work for some reason, your computer is unbootable, and that's serious... of course, if you don't call lilo after the kernel update, your computer is still unbootable. I guess in the long run, its more likely to be bootable if lilo is called, eh?
Dusty
Offline
if i understand your last sentence correctly - u do agree lilo should be updated then? and about making sure if lilo is installed - as u can see from the script, it also checks using 'dd' for lilo signature :
if ! dd if=$bootpart ibs=16 count=1 2>&- | grep -q LILO ; then
echo -e "nYes, but I couldn't find a LILO signature on $bootpart"
echo "Check your /etc/lilo.conf, or run /sbin/lilo by hand."
return 1;
fi
so i assume you wont get more accurate than this... in anyway, even if u disagree about executing lilo update automatically after kernel update, at least consider displaying the message only for lilo users?...
and btw, i honestly didnt think about it - but u r 100% right that lilo MUST be executed after the kernel update, otherwise system wont be bootable... it would be nice if we were actually lilo users so we could justify this discussion but i think most ppl here (like myself) are grub junkies...
Offline
Not me, I hate grub. Hate it. I like LiLo...
However, I don't use the stock kernel, so it won't affect me. I"m beginning to think that having it automatically run lilo would be a good idea though. I think that its come up before and been refused, however.
Dusty
Offline
When you install arch the first time, you have both lilo and grub packages installed. if you're using grub, but still have the lilo package, then installing a kernel will overwrite your grub. that's bad. especially if you never configured lilo.
Offline
:shock: hate grub? how come? i think grub is a superior bootmanager, specially with its dynamic startup menu. i think lilo is old-fashioned bootmanager, something like i had written once - not highly sophisticated, just load-n-run... grub saves us from updating the bootmanager config - as a smart bootmanager should...
ps.
i always considered lilo to be a bootsector virus hehe... it acts just the same
Offline
When you install arch the first time, you have both lilo and grub packages installed. if you're using grub, but still have the lilo package, then installing a kernel will overwrite your grub. that's bad. especially if you never configured lilo.
not at all. again, i should direct u to the previous answer - using 'dd' ensures existence of lilo in the bootsector, thus lilo will be executed ONLY if it is already installed.
Offline
:shock: hate grub? how come? i think grub is a superior bootmanager
That's great for you, grub must work for you.
I've installed about a dozen different linux distros at one time or another, and the only one that ever set up grub in a way that actually worked for me was mandrake. I don't know why, but I cannot get the grub configuration files to work properly. The really arse of it is that its *always* a different problem.
When installing a new distro (which will never happen again, now that I'm using Arch....), I choose grub first because its supposed to be better, then it breaks the bootloader, so I reinstall and choose lilo. Happens every time.
I think grub is probably a good bootloader or else nobody would use it.... the thing is, grub HATES me. (programs have a tendency of doing that)
Dusty
Offline
rotfl... this piece and the previous one (official phrakture-bashing thread) just knocked me down man... u on a roll!
about hating us - i share that hatred :twisted:
and regarding grub, could be your hardware is too much for grub to handle (though it handles just fine my 8 SATA partitons...), a problematic partition table or crazy existing MBR, or could be simply as you described it - pure hatred... but that doesnt suprise u, does it?...
i actually thought of making a patch to grub - password capabilities, and encrypt the partition table so the hd wont be accessed locally by usual means without permission. but now when u telling me YOU dont use it, i dont see what's the point well, actually lack of time, thats the real reason... but i think that would be my 1st linux project (after i finish my gui_pacman project, my live-cd, and the amd64 toolchain...)
Offline
don't use lilo. don't mind it though. i am opposed to automagical running of lilo. BUT, if it was an optional feature it would be ok. that way control freaks can turn it off and people who have never learned to run lilo after kernel changes it would be good.
AKA uknowme
I am not your friend
Offline
Good idea:
something like a "KernelUpdateProg=lilo" to run when the kernel is updated (this could be useful with other programs too.. "KernelUpdateProg=aplay tada.wav")
Offline
It would work and solve all the problems save one:
It adds another config option to pacman.conf, in direct conflict with the KISS principle, and its an option that has a very very small application area...
Dusty
Offline
yeah well the kiss principle would eliminate auto run scripts too. that ain't simple imo. it is yet another extra process added onto the kernel install.
if one does a base instal without deselecting lilo from their option lilo would be run and you could run into problems (or not). so adding this script means adding the feature to the install to deselect one bootloader if the other is chosen. and so on and so forth.
it is better to leave it as a manually run process. it could be a process that many would not like to run so why force them to swallow it? if you cannot select not to run this script then it should not be included.
AKA uknowme
I am not your friend
Offline
perhaps there could be yet another pacman wrapper that calls pacman each time it is run and checks to see if the kernel package was installed. That would be entirely optional and could be done in a few lines of bash.
I know somebody was thinking of making a generic pacman wrapper module so people could write their own wrapper scripts, but I don't think it got past the "this is an idea I had" stage.
Dusty
Offline
all i actually wanted was to avoid that lilo message...
Offline
lilo is evil! :evil:
it killed my grub onetime and I didn't even know I got it installed,
I've never got grub to work as I wanted after that and ended up reinstall my arch system...
arch + gentoo + initng + python = enlisy
Offline
actually, lilo is responsible for my biggest nightmare in the linux world -
it was about 5 years ago while i was living in Amsterdam, working for the ABN-AMRO, and i got from a colleague of mine a RedHat CD which i hurried to install on my laptop. it then installed the lilo bootmanager which for some reason didnt like my partition table and that was the last time i saw that table... it was a sad farewell... many tears where dropped i should say :cry:
i didnt touch any unix/linux for 4 years since then. the bad experience left me with bad taste in my mouth - years of work went down the drain in a flash... but here i am, better and stronger than ever an no way im gonna let lilo get back in (actually i did, for some reason 1st Arch install never let me use grub... but now i'm over it )
Offline
if you are using grub, don't forget to run "pacman -R lilo" just to make sure that nothing unexpected is going to happen
arch + gentoo + initng + python = enlisy
Offline
i didnt stop with "pacman -R lilo" but continued and deleted /etc/lilo.conf.pacsave... dont want any traces for this curse on my system... :twisted:
Offline