Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 8889959
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 14, 20262026-06-14T22:23:26+00:00 2026-06-14T22:23:26+00:00

On Linux application level all printf messages go to stdout and all err messages

  • 0

On Linux application level all printf messages go to stdout and all err messages goto stderr. Where

stderr is usually unbuffered and

stdout is line-buffered

So at kernel space when we use printk() with or without KERN_ERR and such other level specifying macro then how this messages are buffered?

Does dmesg has any separate mechanism?

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-14T22:23:27+00:00Added an answer on June 14, 2026 at 10:23 pm

    All that printk() does is to simply add few more bytes into in-memory ring-buffer (and wrap around if end of buffer reached). So, it does not make sense to say whether it is line-buffered or not – this just does not apply.

    Also, while in user space stdout, stderr make sense, this is not the case in kernel and for printk(): it does not write to stdout because there is no such thing in kernel.

    Granted, something takes care of actually delivering contents of this ring-buffer to the user – whether it is printing it on serial console or retrieving it with dmesg, and this typically looks for LF characters to separate lines.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I'm trying to make an application level firewall for Linux , but for now
I have a user-level C++ test application running on a linux mobile device. One
I'm writing an application that on some stage performs low-level disk operations in Linux
I am trying to understand my embedded Linux application's memory use. The /proc/pid/maps utility/file
I have a (C, Linux) application which handles Ctrl-C SIGINT by shutting down. I'd
I am trying to setup a development environment for Linux C++ application. Because I'm
Here's my question. Right now I have a Linux server application (written using C++
I am developing some application in Linux .This Linux is a virtual machine running
I am writing application in Linux using C, pthreads and sockets. This will be
We're distributing a commercial application for Linux and we currently make it available for

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.