Results 1 to 8 of 8

Thread: Edit LILO?

  1. #1
    Junior Member
    Join Date
    Apr 2005
    Posts
    6

    Edit LILO?

    Hey All,

    I'm running Knoppix from the Hard Disk in Dual-boot with Windows XP. But on the lilo boot selection screen, I get four OS's.

    linux
    Linux(2.6)-1
    Windows(hda1)
    WinXP/2K(hda2)
    Windows(hda7)

    Linux and WinXP/2K(hda2) are both working as they should, I havent tried Linux(2.6)-1 and the two windows(hdaX) boots are dead ends, resulting in a blank screen (Although Windows(hda1) tries to load MS-DOS then fails).

    Is it possible to remove the 3 "obsolete" Options, as I have some "Non-Computer-Literate" people using the computer, and they get confused by many options .

    Any help appreciated.

    Thanks in advance,

    El__sid

    P.S. I am pretty new to Linux on the whole, so if you could please explain using as many lamen terms as possible, I'd be very grateful .

  2. #2
    Senior Member registered user
    Join Date
    Feb 2005
    Location
    Colorado, USA
    Posts
    205
    The quickest way to do what you're asking is to edit LILO's configuration file, /etc/lilo.conf, which you have to do as root.

    There's a sort of paragraph (the geek word is "stanza") for each system LILO thinks is bootable. Put the symbol # at the beginning of each line of those stanzas - this turns them into comments, and LILO will skip over them.

    With LILO (but not the other big multibooter, GrUB) there's one more step - still as root you type the command # lilo to get the new configuration written to the drive's Master Boot Record.

    The reason for just commenting out the three stanzas instead of completely deleting them is so you can go back when you feel like it and improve LILO's behavior. It would be nice to boot into Windows, wouldn't it? You can also make LILO and GrUB give some users some options and other users other options at boot time.

    You can read manual pages for this stuff by typing (as a regular user or as root) $ man lilo and $ man lilo.conf. The file /etc/lilo.conf also has examples written into it -- look at the bottom of the file first. Adding other distros of Linux takes a little studying and figuring out, but making LILO boot into Windows correctly should be easy.

    LILO doesn't understand Windows (or BSD types of Unix, or anything other than Linux) so there's nothing to confiugre in those stanzas of /etc/lilo.conf. Basically you tell LILO to just hand off control to whatever is in that partition without doing any checking.

    Let us know if you have more questions, okay?

    -- Ed

  3. #3
    Junior Member
    Join Date
    Apr 2005
    Posts
    6
    Hey ed, Thanks for the reply, but I'm having a root problem it seems.

    I'm entering into a terminal session:

    Code:
    knoppix@1[~]$ su root
    root@1[knoppix]# /etc/lilo.conf
    And I'm getting a permission denied message, and I've tried the "ctrl+alt+f2" console too, still to no avail.

    Any ideas?

  4. #4
    Senior Member registered user
    Join Date
    Feb 2005
    Location
    Colorado, USA
    Posts
    205
    The file /etc/lilo.conf is what you edit, then the program /sbin/lilo is what you run to put the changes into the boot record. But /sbin should be in your path (where Linux looks for programs), so you can get away with just typing # lilo when you're done editing.

    The error you're getting is due to /etc/lilo.conf not having permission set for anybody, including root, to run it as an executable even though it can be read by everyone and written to by root.

    Try $ ls -l /etc/lilo.conf and you should see something like:
    • -rw-r--r-- 1 root root 5994 Apr 18 02:55 /etc/lilo.conf
    After the first dash, the possible permissions are read write execute for file owner, rwx for the owner's group, then rwx for everybody else - but nobody has execute permission 'cause it's just a configuration file.

    -- Ed

  5. #5
    Junior Member
    Join Date
    Apr 2005
    Posts
    6
    Is it possible to edit the permissions?

    I've tried through properties, but the checkboxes are all greyed out

  6. #6
    Senior Member registered user
    Join Date
    Feb 2005
    Location
    Colorado, USA
    Posts
    205
    Sure - I'll tell you how if you'll tell me why! In fact, if you let me guess, I'll show you two ways to go about it.

    Occasionally I want to edit something owned by root, like /etc/fstab, with a GUI editor like KWrite - I install a new Linux distro and need to make a bunch of changes that are easier with a nice, fat, visual cut-and-paste operation.

    Easier, that is, when I've spent more years doing it that way than with a command-line editor. And when my poor old brain balks at learning emacs. I started playing with computers 35 years ago and don't need to prove my geekhood.

    But by default KDE-the-nanny won't let you log in as root. That can be changed, of course. But before you figure out how to do that, it's still important to know how to change ownership and permissions on files.

    For permissions, use the change-mode command. Be sure to read the manual ($ man chmod) to see why this works, but here's what you do as root: # chmod +w /etc/lilo.conf. This is a shortened version of # chmod a+w /etc/lilo.conf - that is, for all (owner, group, others) add write permission to the file.

    Another way to achieve this end is to just plain change who owns the file, with the change-owner command. Again as root you'd type # chown ed:ed /etc/lilo.conf. This changes both the user and group ownership (see $ man chown).

    After either one of these commands you'd want to check the results with $ ls -l /etc/lilo.conf. By the way, remember to run # lilo after you edit /etc/lilo.conf, and don't be surprised if LILO complains about people other than root having access to its configuration file. It's a security risk, of course, but at my house the dogs just never turn on the computer and log in.

    Here's one more command, for when you know what you want to do but you've forgotten the obscure unix command name: $ apropos permission (for example). This goes through all the man pages looking for that keyword.

    It'll say that there are actually two versions of chmod, one documented in section (1) of the man pages, and another in section (2). Almost everything you'll want to look up will be in section (1), and just typing $ man command only shows you the first one that man comes across. But if you're curious about the chmod in section (2) you can type $ man 2 chmod.

    Okay? Next question!

    -- Ed

  7. #7
    Junior Member
    Join Date
    Apr 2005
    Posts
    6
    That worked beautifully ed, thank you very much, it's very appreciated.

    I think i need to read those manuals again though

  8. #8
    Senior Member registered user
    Join Date
    Feb 2005
    Location
    Colorado, USA
    Posts
    205
    Is it not written, in the ancient texts compiled by the sages of old, "If you got it the first time, you didn't get it."

    -- Ed

Similar Threads

  1. Copy lilo here and how to edit
    By raparadis in forum Hardware & Booting
    Replies: 10
    Last Post: 05-21-2005, 12:33 PM
  2. how to edit LILO settings in Knoppix 3.7?
    By dedinje in forum Hardware & Booting
    Replies: 1
    Last Post: 03-01-2005, 08:00 PM
  3. How do you edit lilo?
    By rrfish72 in forum General Support
    Replies: 2
    Last Post: 07-14-2004, 04:00 PM
  4. can't edit lilo.conf
    By totenengle in forum General Support
    Replies: 2
    Last Post: 07-09-2004, 03:39 AM
  5. you will need to edit the file "/etc/lilo.conf"
    By pat reen in forum General Support
    Replies: 3
    Last Post: 07-02-2003, 02:13 AM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  


Dell Poweredge R640 Server | 2x Silver 4114 20 Cores | 96GB | 8x 1.8TB Dell SAS picture

Dell Poweredge R640 Server | 2x Silver 4114 20 Cores | 96GB | 8x 1.8TB Dell SAS

$2749.99



Dell PowerEdge R720XD Xeon E5-2680 V2 2.8GHz 20 Cores 256GB RAM 12x4TB picture

Dell PowerEdge R720XD Xeon E5-2680 V2 2.8GHz 20 Cores 256GB RAM 12x4TB

$510.00



Dell PowerEdge R620 Server 2x E5-2660 v1 2.2GHz 16 Cores 256GB RAM 1x 300GB HDD picture

Dell PowerEdge R620 Server 2x E5-2660 v1 2.2GHz 16 Cores 256GB RAM 1x 300GB HDD

$89.99



Dell PowerEdge R730XD 28 Core Server 2X Xeon E5-2680 V4 H730 128GB RAM No HDD picture

Dell PowerEdge R730XD 28 Core Server 2X Xeon E5-2680 V4 H730 128GB RAM No HDD

$389.99



Dell PowerEdge R730, 2 sinks, SystemBoard, 8 trays,H330,Idrac 8 exp, 2x750w Psu picture

Dell PowerEdge R730, 2 sinks, SystemBoard, 8 trays,H330,Idrac 8 exp, 2x750w Psu

$135.00



Dell Poweredge R730xd 2.5in 2x E5-2690 v3 2.6ghz 24-Cores  64gb  H730  2x 750w picture

Dell Poweredge R730xd 2.5in 2x E5-2690 v3 2.6ghz 24-Cores 64gb H730 2x 750w

$189.99



Dell PowerEdge R720 Server - 2x8c CPU,256Gb RAM, 128Gb SSD/3x600Gb SAS, Proxmox picture

Dell PowerEdge R720 Server - 2x8c CPU,256Gb RAM, 128Gb SSD/3x600Gb SAS, Proxmox

$360.00



DELL POWEREDGE T430 SERVER W/ DUAL XEON E5-2609 CPU & 16GB MEMORY picture

DELL POWEREDGE T430 SERVER W/ DUAL XEON E5-2609 CPU & 16GB MEMORY

$329.00



DELL PowerEdge R630 8SFF Server 2x E5-2690v3 2.6GHz =24 Cores 32GB H730 4xRJ45 picture

DELL PowerEdge R630 8SFF Server 2x E5-2690v3 2.6GHz =24 Cores 32GB H730 4xRJ45

$254.00



DELL PowerEdge R730 Server 2x E5-2690v3 2.6GHz =24 Cores 32GB H730 4xRJ45 picture

DELL PowerEdge R730 Server 2x E5-2690v3 2.6GHz =24 Cores 32GB H730 4xRJ45

$274.00