[CentOS] Replacing custom kernel with another - with same identifier

2008-07-17 Thread Antti J. Huhtala
Hi list,

I just finished building a custom kernel from 2.6.18-53.1.21 source rpm
- this time with ISA bus and ISAPNP support which I accidentally left
out of my previous attempt. 
Unfortunately, this time I forgot to change my identifier in
kernel-2.6.spec file. Thus I now have one *installed* kernel version
*without* ISA support, and another one *with* ISA support but as rpm,
not yet installed. Both kernels now have identical identifiers.

What is the safe way to remove the previous installed kernel version
without taking out the uninstalled new version? Is the latter safe in
~/rpmbuild/RPMS if I use 'rpm -e' to remove the former version?

TIA

Antti


___
CentOS mailing list
CentOS@centos.org
http://lists.centos.org/mailman/listinfo/centos


Re: [CentOS] Replacing custom kernel with another - with same identifier

2008-07-17 Thread Antti J. Huhtala
to, 2008-07-17 kello 09:16 +0100, ne.. kirjoitti:
 On Thu, Jul 17, 2008 at 08:05, Antti J. Huhtala [EMAIL PROTECTED] wrote:
  Hi list,
 
  I just finished building a custom kernel from 2.6.18-53.1.21 source rpm
  - this time with ISA bus and ISAPNP support which I accidentally left
  out of my previous attempt.
  Unfortunately, this time I forgot to change my identifier in
  kernel-2.6.spec file. Thus I now have one *installed* kernel version
  *without* ISA support, and another one *with* ISA support but as rpm,
  not yet installed. Both kernels now have identical identifiers.
 
  What is the safe way to remove the previous installed kernel version
  without taking out the uninstalled new version? Is the latter safe in
  ~/rpmbuild/RPMS if I use 'rpm -e' to remove the former version?
 There is no need to remove the old kernel. Use the --replacefiles option to
 rpm when installing the new kernel. Then verify that your grub.conf/lilo.conf
 has the correct entry.
 
Ah, indeed. I've never used --replacefiles in installing kernels but
guess it works with them just as with any other files. Thanks!

Antti


___
CentOS mailing list
CentOS@centos.org
http://lists.centos.org/mailman/listinfo/centos


Re: [CentOS] Replacing custom kernel with another - with same identifier

2008-07-17 Thread Antti J. Huhtala
to, 2008-07-17 kello 09:16 +0100, ne.. kirjoitti:
 On Thu, Jul 17, 2008 at 08:05, Antti J. Huhtala [EMAIL PROTECTED] wrote:
 
  What is the safe way to remove the previous installed kernel version
  without taking out the uninstalled new version? Is the latter safe in
  ~/rpmbuild/RPMS if I use 'rpm -e' to remove the former version?
 There is no need to remove the old kernel. Use the --replacefiles option to
 rpm when installing the new kernel. Then verify that your grub.conf/lilo.conf
 has the correct entry.
 
Well, it wasn't as simple as that. rpm says:kernel ... is already
installed and will not go on. The identifiers (file names) are
identical, remember?

Any other ideas?

Antti


___
CentOS mailing list
CentOS@centos.org
http://lists.centos.org/mailman/listinfo/centos


Re: [CentOS] Replacing custom kernel with another - with same identifier

2008-07-17 Thread Antti J. Huhtala
to, 2008-07-17 kello 05:26 -0500, Johnny Hughes kirjoitti:
 Antti J. Huhtala wrote:
  to, 2008-07-17 kello 09:16 +0100, ne.. kirjoitti:
  On Thu, Jul 17, 2008 at 08:05, Antti J. Huhtala [EMAIL PROTECTED] wrote:
  What is the safe way to remove the previous installed kernel version
  without taking out the uninstalled new version? Is the latter safe in
  ~/rpmbuild/RPMS if I use 'rpm -e' to remove the former version?
  There is no need to remove the old kernel. Use the --replacefiles option to
  rpm when installing the new kernel. Then verify that your 
  grub.conf/lilo.conf
  has the correct entry.
 
  Well, it wasn't as simple as that. rpm says:kernel ... is already
  installed and will not go on. The identifiers (file names) are
  identical, remember?
  
  Any other ideas?
  
  Antti
 
 rpm -ivh --force rpm_name
 
OK, thanks. I decided to try 'rpm -e kernelversion', 'rpm -e
kernel-develversion, and then went to ~/rpmbuild/RPMS/i686 and ran
'rpm -ivh kernelversion.rpm. All went well.

Antti


___
CentOS mailing list
CentOS@centos.org
http://lists.centos.org/mailman/listinfo/centos


Re: [CentOS] Replacing custom kernel with another - with same identifier

2008-07-17 Thread Antti J. Huhtala
to, 2008-07-17 kello 17:58 +0100, ne.. kirjoitti:
 On Thu, Jul 17, 2008 at 10:19, Antti J. Huhtala [EMAIL PROTECTED] wrote:
  to, 2008-07-17 kello 09:16 +0100, ne.. kirjoitti:
  On Thu, Jul 17, 2008 at 08:05, Antti J. Huhtala [EMAIL PROTECTED] wrote:
  
   What is the safe way to remove the previous installed kernel version
   without taking out the uninstalled new version? Is the latter safe in
   ~/rpmbuild/RPMS if I use 'rpm -e' to remove the former version?
  There is no need to remove the old kernel. Use the --replacefiles option to
  rpm when installing the new kernel. Then verify that your 
  grub.conf/lilo.conf
  has the correct entry.
 
  Well, it wasn't as simple as that. rpm says:kernel ... is already
  installed and will not go on. The identifiers (file names) are
  identical, remember?
 Bummer, wrong option. From rpm --help
   --replacepkgsreinstall if the package is already present
 
 And what Mr Hughes wrote will also work.
 
I'm sure you are both right. However, I took the long path and first
removed kernel and kernel-devel, then installed with 'rpm -ivh'. All
went OK. Thanks anyway.

Antti


___
CentOS mailing list
CentOS@centos.org
http://lists.centos.org/mailman/listinfo/centos


Re: [CentOS-docs] Suggestions on I Need the Kernel Source Wiki pages

2008-07-14 Thread Antti J. Huhtala
ma, 2008-07-14 kello 06:07 -0700, Akemi Yagi kirjoitti:

 This is most likely because you missed the step of adding the # i386
 (or #x86_64) line.  Could you check this out?
 
 Akemi

That was it, indeed. Looks like Custom Kernel HowTo survived the
idiot test by me. One question though: when installing the rpms as the
last step (rpm -ivh kernel-*.rpm), I get error: can't create
transaction lock on /var/lib/rpm/_db.000. That means I should do it as
root, doesn't it? Perhaps the HowTo could mention this even if it might
be reasonably obvious that only root can install kernels...

Antti


___
CentOS-docs mailing list
CentOS-docs@centos.org
http://lists.centos.org/mailman/listinfo/centos-docs


Re: [CentOS-docs] Suggestions on I Need the Kernel Source Wiki pages

2008-07-13 Thread Antti J. Huhtala
su, 2008-07-13 kello 08:32 -0700, Akemi Yagi kirjoitti:
 On Sat, Jul 12, 2008 at 11:24 PM, Antti J. Huhtala [EMAIL PROTECTED] wrote:
  la, 2008-07-12 kello 22:02 -0700, Akemi Yagi kirjoitti:
  On Sat, Jul 12, 2008 at 9:31 PM, Scott Robbins [EMAIL PROTECTED] wrote:
 
  If there is a certain level of knowledge one must have before such
  attempts, why give *any* advice in the form of HowTos? People really in
  the know do not need it anyway.
 
 This raises an interesting point by itself.  The role of CentOS Wiki
 is primarily to provide CentOS-related information or help.  In the
 case of the kernel articles, they explain how to handle the kernel
 CentOS way, and many lines in there are specific for CentOS (like URLs
 for kernel rpms).  Therefore, even Linux experts would benefit from
 them unless they are already familiar with CentOS, or more generally,
 with package-based managed systems (they tend to prefer make; make
 rpm, for example).
 
Perhaps I was a bit playing the role of devil's advocate in raising the
question. Of course, I'm all for HowTos in general and understand that
there are OS-specific issues needing explanation no matter what level
expertise one might have.
 On the other hand, CentOS Wiki can include more general, non-CentOS
 specific help as well.   So, the question is what is the guidance here
 for writing CentOS Wiki articles with respect to CentOS relatedness.
I for one don't mind at all if CentOS Wiki articles contain some general
*nix advice. Most of us learn by picking up things here and there, not
necessarily as a result of systematic training confined to a certain
subject. The problem is finding proper balance between CentOS-related
material and general *nix advice. Here newbies such as myself perhaps
may contribute their little bit...
I might add that I have both written and translated manuals of various
electronic devices during my working career. That may explain why I am
particularly interested in manuals and HowTos.
 
 Akemi

Antti


___
CentOS-docs mailing list
CentOS-docs@centos.org
http://lists.centos.org/mailman/listinfo/centos-docs


Re: [CentOS-docs] Suggestions on I Need the Kernel Source Wiki pages

2008-07-13 Thread Antti J. Huhtala
su, 2008-07-13 kello 08:14 -0700, Akemi Yagi kirjoitti:

 But before my posting, I had already added a back ticks note in
 parenthesis on that wiki page.  Then Alan woke up (for people who
 don't know he is in the UK) and made it much nicer.
 
 Akemi

I just looked at the updated I Need the Kernel Source HowTo and in my
eyes it is now perfect. No doubt a careful person could now succeed in
building the kernel tree in one go.

Thank you, Akemi and Alan!

Antti


___
CentOS-docs mailing list
CentOS-docs@centos.org
http://lists.centos.org/mailman/listinfo/centos-docs


[CentOS-docs] Suggestions on I Need the Kernel Source Wiki pages

2008-07-12 Thread Antti J. Huhtala
Hi all,

I am a newcomer to CentOS but slightly less so to Linux in general
(FC4-F9). In short, I am trying to make an old SB Vibra 16C (ISA) sound
card work in Centos 5. To achieve this, support for ISA bus and ISA PnP
is apparently needed in kernel. Therefore, a custom kernel needs to be
built. -- Yes, I have read all the warnings of lack of support, etc.

As a first step, I had to build the complete kernel tree according to I
Need the Kernel Source CentOS Wiki. I tried to meticulously follow the
directions given there but it took five or six attempts before I had a
complete tree in ~/rpmbuild/BUILD/. Would you please consider the
following questions in order to decide if any changes/additions are
necessary in the article:

a) In section 2.1 it is said: [EMAIL PROTECTED] yum install rpm-build. To
'yum install' something you need to be superuser (as confirmed by '#'
prompt before the command). Shouldn't the example read: 
[EMAIL PROTECTED] yum install rpm-build?

b) The next command on the page is rpm -i http://mirror.centos.org...;.
Two of my futile attempts to install the ...src.rpm were due to the fact
that 1) I did not understand and then 2) forgot to exit from root before
trying to install the source rpm. Shouldn't there be at least a $
prompt (and perhaps the directory, too) before the 'rpm -i' command?

c) One attempt of 'rpmbuild' failed because redhat-rpm-config is needed
by kernel-2.6.18-92.1.6.el5.i686. This may not apply to everyone but it
certainly applied to me who had only installed 5.1 in March and updated
it to 5.2 in July by just updating when told to do so. Perhaps it would
be advisable to add # yum install redhat-rpm-config to the article?

d) Two attempts of 'rpmbuild' perhaps failed because I inadvertently
used single quotes or apostrophes around 'uname -m' instead of `s
(accent grave?). The result in prep-err.log, however, was: Building
target platforms: uname -m and Building for target uname -m. 
I had to explicitly insert i686 in the 'rpmbuild' command like this:
[EMAIL PROTECTED] SPECS]$ rpmbuild -bp --target=i686 kernel-2.6.spec 2 
If this is what the user is supposed to do anyway, perhaps it could be
worded a little differently to make it perfectly clear? On the other
hand, if 'accent grave' characters around 'uname -m' really work in
replacing the proper architecture in the command, perhaps the text
should emphasize the fact? I foolishly did not cut-and-paste the
'rpmbuild' command but wrote it myself.

I realize there is another thread about these Wiki pages currently being
discussed on centos-docs list but I thought it better to start a new
thread.

TIA, Antti



___
CentOS-docs mailing list
CentOS-docs@centos.org
http://lists.centos.org/mailman/listinfo/centos-docs