Stack Exchange Network

Stack Exchange network consists of 175 Q&A communities including Stack Overflow, the largest, most trusted online community for developers to learn, share their knowledge, and build their careers.

Visit Stack Exchange

Questions tagged [streams]

In computer networking, STREAMS is the native framework in Unix System V for implementing character devices.

1
vote
2answers
107 views

What are two caveats of line buffering in Unix?

A paragraph from APUE Chapter 5.4 about line buffer: Line buffered. In this case, the standard I/O library performs I/O when a newline character is encountered on input or output. This allows us ...
2
votes
1answer
563 views

Reading partially downloaded gzip with an offset

Let's say that there is one huge db.sql.gz of size 100GB available https://example.com/db/backups/db.sql.gz and the server supports range requests. So instead of downloading the entire file, I ...
1
vote
1answer
840 views

Ffmpeg - youtube-dl

I have try to use ffmpeg to download youtube media in mp3. ffmpeg -i <url> -f mp3 output.mp3 It's working with other urls, but not with youtube-dl retrived youtube video urls. Ffmpeg returns ...
3
votes
2answers
132 views

How to pass multiple files in one stream to process them pipe-like (without saving) on the receiving side?

I need to determine the filetype on an indeterminate number of base64-encoded filestreams coming from stdin (image files base64-encoded and cat'ed). A single file would simply be ... | base64 -d | ...
1
vote
1answer
25 views

Stream raminication with continuation if one branch breaks

Say I ramify a video stream to 2 ffplay processes cat video.mp4 | tee >(ffplay -i -) >(ffplay -i -) > /dev/null Now, if I kill one of the ffplay process, the stream is stopped which is not ...
-1
votes
3answers
228 views

Redirect nohup-heredoc stdout to stdin, to execute directly?

I aim to paste this heredoc script and execute so to install and timeout-uninstall PHPmyadmin after 2 hours, from security reasons. nohup bash -s -- $$ <<'EOF0' & #!/bin/bash -x apt-get ...
3
votes
2answers
259 views

Why were STREAMS marked obsolescent in POSIX.1-2008? [closed]

The POSIX.1-2008 XRAT rationale states that X/Open STREAMS may be removed from future versions of the standard, and that strictly conforming applications shouldn't use them, but it doesn't explain why....
1
vote
1answer
720 views

piping text file to telnet over ssh

I would like to pipe a text file with commands to a telnet session I have open on a ssh client, Is this possible? an example: I have a text file cmds that contains commands like FirstFunction(A,B,C,...
2
votes
1answer
105 views

How to store endless stream to file?

Let's have any stream of binary data (like /dev/random, /dev/zero, etc.). Let's have a file which size can be N at maximum. Let's the N is in order of gigabytes. Is there any elegant method/...
4
votes
3answers
1k views

How do pipes and infinite streams work?

I usually use command1 | command2 | command3 a lot in Linux but most of them are dealing with definite content. When I tried this with an infinite stream cat | sed '' | sed '' which hopefully ...
3
votes
1answer
526 views

Watch not showing subshell output

Why does the following not output "hello" line? watch bash -c 'echo hello' As this one? watch 'echo hello' I expected to have echo write to bash output directly and this to be read by watch and ...
10
votes
3answers
9k views

How can I set up a “USB proxy” for /dev/ttyUSB0 over the network?

I have a device under test (DUT) and I measure its power usage the using a Power Analyzer Datalogger using the data from /dev/ttyUSB0. The problem is that the DUT is now remotely from the workstation ...
12
votes
4answers
6k views

How to use sed to manipulate continuously streaming output?

I am putting together a presentation for a non-technical audience. I have a program running in bash that outputs a continuous stream of values, a few of which are important. I would like to highlight ...
3
votes
2answers
837 views

Remove data from the STDIN stream buffer of another TTY session

I encountered a problem the other day while running multiple tty sessions in separate terminal windows. I was running a expensive disk access command and was waiting for it to return. Meanwhile I was ...
8
votes
2answers
5k views

How I/O channels are implemented in Linux kernel?

stdin, stdout, stderr are some integers that index into a data structure which 'knows' which I/O channels are to be used for the process. I understand this data structure is unique to every process. ...
0
votes
1answer
2k views

How can I install STREAMS in Linux?

I searched on Google, but found nothing useful. I use SUSE now, how can I install LiS on my computer? I'm hoping for a download link.