[Q]page cache 삭제후, segmentation fault가 발생합니다.

chunmok의 이미지

ls를 실행한후에 페이지 캐쉬중 inactive_list에 남아있는 ls에 매핑된 페이지를 모두 해제했습니다. 그랬더니, 다음에 ls를 실행할때, segmentation fault 오류가 뜨네요.

inactive_list에서 해제된 페이지는 화일에 매핑된 페이지중 현재 사용되지 않는 것들만 골라서 해제했습니다.

페이지 해제에 다음 함수들과 관련 lock함수들을 썼는데,
lru_cache_del()
remove_inode_page()
page_cache_release()
혹시 제가 잘못한 것이 있는지...아시는 분의 조언을 부탁드립니다.

정준목.

sjpark의 이미지

segmentation fault 가 나는 이유중 하나가,
page fault handler에 있지는 않을까 합니다.

page fault handler 에서 어떤 플래그를 보고 해당 코드 페이지가 캐쉬되어있다고 보게 되어, 잘못된 페이지를 사용하게 되지는 않을까 싶어서 입니다.

어디까지나 추측입니다.

chunmok wrote:
ls를 실행한후에 페이지 캐쉬중 inactive_list에 남아있는 ls에 매핑된 페이지를 모두 해제했습니다. 그랬더니, 다음에 ls를 실행할때, segmentation fault 오류가 뜨네요.

inactive_list에서 해제된 페이지는 화일에 매핑된 페이지중 현재 사용되지 않는 것들만 골라서 해제했습니다.

페이지 해제에 다음 함수들과 관련 lock함수들을 썼는데,
lru_cache_del()
remove_inode_page()
page_cache_release()
혹시 제가 잘못한 것이 있는지...아시는 분의 조언을 부탁드립니다.

정준목.

chunmok의 이미지

Quote:
page fault handler 에서 어떤 플래그를 보고 해당 코드 페이지가 캐쉬되어있다고 보게 되어, 잘못된 페이지를 사용하게 되지는 않을까 싶어서 입니다.

어떤 플래그라는 것이 존재하나요? 저는 잘 모르겠는데.
그리고, 페이지가 캐쉬되었다는건 hash table을 검색해봐야 아는것 아닌가요? 전 hash table의 해당 entry를 삭제했는데요.(remove_inode_page함수)
어떤 근거가 있으신건지...

정준목.

댓글 달기

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
이것은 자동으로 스팸을 올리는 것을 막기 위해서 제공됩니다.