커널 컴파일 시 생성되는 파일의 종류의 의미와 역할이 궁금합니다.

namminkk의 이미지

안녕하세요,

리눅스로 이것 저것 해보는 중에 질문이 생겨 여쭈어봅니다.

최신 커널을 올려보고 싶어서 한 블로그를 따라하던 도중 궁금한 것이 생겼습니다.

바로 커널을 이제 make rpm-pkg 형태로 make를 이용하여 rpm패키지를 만들면
kernel, kernel-devel, kernel-header 이 세개가 나오는데요,

이전까지 얄팍한 지식으로 알고 있던 것은 저 위 3개중 kernel만 설치하면 저는 새로운 커널을 사용하는 걸로
알고 있었습니다.

근데 devel과 header의 존재를 알게되니 뭔가 찜찜한?

그래서 저 두가지를 좀 찾아보니, devel은 라이브러리, header은 라이브러리에 필요한 헤더파일?
두개가 비슷한 느낌의 정보 인것 같아서요, 정확한 정의가 궁금하고
커널 버전을 올렸다. 라는 표현은 저 3가지를 모두 설치했다는 의미일까요?

그리고 커널 헤더파일을 바꾸면 부팅 시 이전 커널을 선택했을 떄 충돌같은게 발생해야 하는 것 아닌가요?

centos 7 4.15 커널에서
5.6 커널 헤더 설치 시 conflict에러가 발생하여
기존 헤더를 지우고 새 헤더를 설치했습니다.

그래서 제가 드리는 질문은
1. 저 3가지의 의미
2. 헤더 파일 바꿀 시 기존 커널 부팅 시 충돌여부

정도입니다.

https://kldp.org/node/47051
이 글과 비슷한 질문입니다.

단서가 될 만한 커널 관련이야기도 감사하게 듣겠습니다.
찾아보겠습니다~!

감사합니다.

서지훈의 이미지

패키지들 통상... kernel은 사용 가능한 kernel 그자체이고요.
devel, header는 기타 프로그램에서, kernel 관련 자원을 사용하기 위해 build 할 때 kernel library나 header 파일을 사용하기 위한 목적의 패키지입니다.
compile 할 일이 없으면 kernel 하나만 설치 하시면 별문제 없이 사용 가능하실테고요.
간혹 사용하는 프로그램중에 충돌이 난다면 해당 커널과 맞는 버젼을 찾아서 설치하시거나, 소스를 가져다가 빌드를 새로 하셔야 합니다.

1. 저 3가지의 의미 => 위에 설명
2. 헤더 파일 바꿀 시 기존 커널 부팅 시 충돌여부 => 커널 부팅은 문제 없으나 다른 프로그램이 문제 될 수 있으니 재설치 및 소스 빌드 필요.

#include <com.h> <C2H5OH.h> <woman.h>
do { if (com) hacking(); if (money) drinking(); if (women) loving(); } while (1);

namminkk의 이미지

2년이 지난 지금 감사인사를 드리네요, 감사합니다.

bushi의 이미지

kernel 패키지들은 일반 패키지들과 좀 다른 구성입니다.

kernel-core.rpm : 부팅에 필요한 파일들이 있습니다.
kernel-devel.rpm : 커널용 external 모듈을 개발하기 위해 필요한 파일들이 있습니다.
kernel-headers.rpm : 어플에서 사용할 수 있는 헤더파일들이고, linux 전용 api 에 대한 것들이 담겨있습니다.

$ rpm -q --qf="%{DESCRIPTION}" kernel-core
The kernel package contains the Linux kernel (vmlinuz), the core of any
Linux operating system.  The kernel handles the basic functions
of the operating system: memory allocation, process allocation, device
input and output, etc.
 
$ rpm -q --qf="%{DESCRIPTION}" kernel-devel
This package provides kernel headers and makefiles sufficient to build modules
against the kernel package.
 
$ rpm -q --qf="%{DESCRIPTION}" kernel-headers
Kernel-headers includes the C header files that specify the interface
between the Linux kernel and userspace libraries and programs.  The
header files define structures and constants that are needed for
building most standard programs and are also needed for rebuilding the
glibc package.
namminkk의 이미지

2년만에 확인했네요ㅜ 감사합니다.

댓글 달기

Filtered HTML

  • 텍스트에 BBCode 태그를 사용할 수 있습니다. URL은 자동으로 링크 됩니다.
  • 사용할 수 있는 HTML 태그: <p><div><span><br><a><em><strong><del><ins><b><i><u><s><pre><code><cite><blockquote><ul><ol><li><dl><dt><dd><table><tr><td><th><thead><tbody><h1><h2><h3><h4><h5><h6><img><embed><object><param><hr>
  • 다음 태그를 이용하여 소스 코드 구문 강조를 할 수 있습니다: <code>, <blockcode>, <apache>, <applescript>, <autoconf>, <awk>, <bash>, <c>, <cpp>, <css>, <diff>, <drupal5>, <drupal6>, <gdb>, <html>, <html5>, <java>, <javascript>, <ldif>, <lua>, <make>, <mysql>, <perl>, <perl6>, <php>, <pgsql>, <proftpd>, <python>, <reg>, <spec>, <ruby>. 지원하는 태그 형식: <foo>, [foo].
  • web 주소와/이메일 주소를 클릭할 수 있는 링크로 자동으로 바꿉니다.

BBCode

  • 텍스트에 BBCode 태그를 사용할 수 있습니다. URL은 자동으로 링크 됩니다.
  • 다음 태그를 이용하여 소스 코드 구문 강조를 할 수 있습니다: <code>, <blockcode>, <apache>, <applescript>, <autoconf>, <awk>, <bash>, <c>, <cpp>, <css>, <diff>, <drupal5>, <drupal6>, <gdb>, <html>, <html5>, <java>, <javascript>, <ldif>, <lua>, <make>, <mysql>, <perl>, <perl6>, <php>, <pgsql>, <proftpd>, <python>, <reg>, <spec>, <ruby>. 지원하는 태그 형식: <foo>, [foo].
  • 사용할 수 있는 HTML 태그: <p><div><span><br><a><em><strong><del><ins><b><i><u><s><pre><code><cite><blockquote><ul><ol><li><dl><dt><dd><table><tr><td><th><thead><tbody><h1><h2><h3><h4><h5><h6><img><embed><object><param>
  • web 주소와/이메일 주소를 클릭할 수 있는 링크로 자동으로 바꿉니다.

Textile

  • 다음 태그를 이용하여 소스 코드 구문 강조를 할 수 있습니다: <code>, <blockcode>, <apache>, <applescript>, <autoconf>, <awk>, <bash>, <c>, <cpp>, <css>, <diff>, <drupal5>, <drupal6>, <gdb>, <html>, <html5>, <java>, <javascript>, <ldif>, <lua>, <make>, <mysql>, <perl>, <perl6>, <php>, <pgsql>, <proftpd>, <python>, <reg>, <spec>, <ruby>. 지원하는 태그 형식: <foo>, [foo].
  • You can use Textile markup to format text.
  • 사용할 수 있는 HTML 태그: <p><div><span><br><a><em><strong><del><ins><b><i><u><s><pre><code><cite><blockquote><ul><ol><li><dl><dt><dd><table><tr><td><th><thead><tbody><h1><h2><h3><h4><h5><h6><img><embed><object><param><hr>

Markdown

  • 다음 태그를 이용하여 소스 코드 구문 강조를 할 수 있습니다: <code>, <blockcode>, <apache>, <applescript>, <autoconf>, <awk>, <bash>, <c>, <cpp>, <css>, <diff>, <drupal5>, <drupal6>, <gdb>, <html>, <html5>, <java>, <javascript>, <ldif>, <lua>, <make>, <mysql>, <perl>, <perl6>, <php>, <pgsql>, <proftpd>, <python>, <reg>, <spec>, <ruby>. 지원하는 태그 형식: <foo>, [foo].
  • Quick Tips:
    • Two or more spaces at a line's end = Line break
    • Double returns = Paragraph
    • *Single asterisks* or _single underscores_ = Emphasis
    • **Double** or __double__ = Strong
    • This is [a link](http://the.link.example.com "The optional title text")
    For complete details on the Markdown syntax, see the Markdown documentation and Markdown Extra documentation for tables, footnotes, and more.
  • web 주소와/이메일 주소를 클릭할 수 있는 링크로 자동으로 바꿉니다.
  • 사용할 수 있는 HTML 태그: <p><div><span><br><a><em><strong><del><ins><b><i><u><s><pre><code><cite><blockquote><ul><ol><li><dl><dt><dd><table><tr><td><th><thead><tbody><h1><h2><h3><h4><h5><h6><img><embed><object><param><hr>

Plain text

  • HTML 태그를 사용할 수 없습니다.
  • web 주소와/이메일 주소를 클릭할 수 있는 링크로 자동으로 바꿉니다.
  • 줄과 단락은 자동으로 분리됩니다.
댓글 첨부 파일
이 댓글에 이미지나 파일을 업로드 합니다.
파일 크기는 8 MB보다 작아야 합니다.
허용할 파일 형식: txt pdf doc xls gif jpg jpeg mp3 png rar zip.
CAPTCHA
이것은 자동으로 스팸을 올리는 것을 막기 위해서 제공됩니다.