Overwriting TS Stream File with FFMPEG in Linux

I'm trying to convert rtmp streams to m3u8 stream. To reach that aim I use FFMPEG. Now, there is no problem with converting and downloading. However, it writes lots of .ts file such as channel0000.ts,channel0001.ts,channel0002.ts. Per every 10 second...
more »

2017-08-11 18:08 (1) Answers

Combine two find commands in one

I currently have the following line: find . -type f ! -name "*.xml" -delete && find . -type d -empty -delete But as they are 2 find commands, I suppose I can merge them into one. But I don't want to use -exec. I wan't to use something nat...
more »

2017-08-11 17:08 (1) Answers

linux kernel code navigation

I have a question about C code navigation. In C++ or Java it's easy to navigate throught code. For example if there are 3 subsystems (3 classes) DatebaseSubsystem, HardwareSubsystem, ServerSubsystem, and any entity in project use them, I can see all...
more »

2017-08-10 15:08 (0) Answers

Save 'tc qdisc' config on device

I have done some config like this on my linux device. tc qdisc add dev "em1.450" ingress tc qdisc add dev "em1.956" ingress However once the host restarts, the 'tc qdisc' related configs are gone. How can I make these configs persistent on the dev...
more »

2017-08-10 13:08 (0) Answers

How to avoid <defunct> processes?

I do ZFS remote replication from a master host to a slave host, where I have a Perl script that runs on the master host. For each filesystem it ssh to the remote host and start mbuffer in listening mode and then the script continues and then send th...
more »

2017-08-09 15:08 (2) Answers

Delay output till EOF rather than newline

I am writing a program that copies input to output character by character on Linux terminal. The code is as follows (from Dennis Ritchie's C book) #include <stdio.h> /* copy input to output; 2nd version*/ main() { int c; while ((c = get...
more »

2017-08-09 14:08 (4) Answers

Printing the word echo in the output of cat file

I am trying to generate a file using cat in bash where inside the bash, i already ran a script, that i saved into a variable then will be used inside the cat. To ran the script and save the output to a variable, I used the following: declare RESULT...
more »

2017-08-08 17:08 (2) Answers

fftw Cross Compile for linux angstrom ARM8

I have a processor board and cross compile with my code QTcreator. The compiler works and I got all my code on the board (C and C++). To calculate a fft I use the fftw library. On my Linux PC everything works fine. I installed it as mentioned in th...
more »

2017-08-08 15:08 (0) Answers

EOF issue in shell script

This following code segment giving error:14: syntax error: unexpected end of file #!/bin/bash func_some() { cd some_directory lftp -u user,'password' sftp://192.168.xx.xx <<EOF cd some_directory mget ADMS_report_*${2}${3}${4}*....
more »

2017-08-08 09:08 (1) Answers

Is active waiting common in linux

I am in a debate with a colleague that it is bad programming if you do active waiting in Linux. He is more experienced than I am in bash scripting and says it is common to do it. For example, we try to start a bash script after a WiFi USB is insert...
more »

2017-08-07 17:08 (2) Answers

Is it possible to downgrade glibc on OpenSUSE?

I want to run a C++ program on an older device, which only supports glibc 2.11.3. So I have to create a develloping enviroment using the same glibc version. Currently it is running version 2.25 x86_64 for openSUSE Tumbleweed. First of all, where do...
more »

2017-08-07 15:08 (2) Answers

Linux Wayland and X11

Used language I am using C++14 with cmake for my program. Problem: I would like to know how I can find out if a Linux system uses Wayland or X11 as a window system to be able to use both APIs in my source code without conflict. Thus creating a win...
more »

2017-08-06 22:08 (2) Answers