Modify

Opened 6 years ago

Last modified 4 years ago

#11128 reopened defect

Can't pipe programs output to file until program is done executing

Reported by: sebkinne Owned by: developers
Priority: normal Milestone: Barrier Breaker 14.07
Component: base system Version: Trunk
Keywords: Cc:

Description

When trying to pipe the output of a running program (such as hostapd) to a file, or even piping to another program such as grep, the output is somehow held in buffer and is only written out when the running program is killed.

Example:
#:hostapd -dd /path/to/config > /tmp/hostapd.log
#:cat /tmp/hostapd.log
#Empty file
#:killall hostapd
#:cat /tmp/hostapd.log
#file now has content and the output seems to be relatively complete.

There was no issue doing this with rev29839.

Attachments (0)

Change History (4)

comment:1 Changed 6 years ago by jow

  • Resolution set to wontfix
  • Status changed from new to closed

What you experience here is commonly called output buffering or buffered io, there is nothing we can do about it.

comment:2 Changed 6 years ago by sebkinne

  • Resolution wontfix deleted
  • Status changed from closed to reopened

Sorry for re-opening this, but how come this worked without an issue in rev29839? When I compiled it with the latest trunk it doesn't.

Is there really nothing I can do?

Could I make any kernel modifications (pipe buffer size etc)?

comment:3 Changed 5 years ago by anonymous

the program called "unbuffer" maybe can resolve your problem. I would like to know how to adjust buffer size too.

comment:4 Changed 4 years ago by jow

  • Milestone changed from Attitude Adjustment 12.09 to Barrier Breaker 14.07

Milestone Attitude Adjustment 12.09 deleted

Add Comment

Modify Ticket

Action
as reopened .
Author


E-mail address and user name can be saved in the Preferences.

 
Note: See TracTickets for help on using tickets.