rtmpdump check status by command line - linux

I tried doing rtmpdump -r "rtmp-raw=rtmpe://watch.playfooty.tv/live playpath=nba1569 swfUrl=http://www.playfooty.tv/play/player/player.swf live=1 pageUrl=http://www.playfooty.tv/"
But the output it´s like offline always
RTMPDump v2.2e
(c) 2010 Andrej Stepanchuk, Howard Chu, The Flvstreamer Team; license: GPL
DEBUG: Parsing...
WARNING: Unknown protocol!
DEBUG: Parsed host : watch.playfooty.tv
DEBUG: Parsed app : live playpath=nba1569 swfUrl=http:/
DEBUG: Protocol : RTMP
DEBUG: Hostname : watch.playfooty.tv
DEBUG: Port : 1935
DEBUG: Playpath : www.playfooty.tv/play/player/player.swf live=1 pageUrl=http://www.playfooty.tv/
DEBUG: tcUrl : rtmp://watch.playfooty.tv:1935/live playpath=nba1569 swfUrl=http:/
DEBUG: app : live playpath=nba1569 swfUrl=http:/
DEBUG: live : no
DEBUG: timeout : 30 sec
I tried a lot of links of a list and seems offline with this command, but When I play it in a software it worked.
Does anyone have an idea how to test if this kind of links are alive or die?
Thanks!

rtmpdump -i "rtmpe://watch.playfooty.tv/live playpath=nba1569 swfUrl=http://www.playfooty.tv/play/player/player.swf live=1 pageUrl=http://www.playfooty.tv/"
Admittedly the online documentation on RtmpDump is pretty poor, however it is
listed in the command line help
--url|-i url URL with options included
(e.g. rtmp://host[:port]/path swfUrl=url tcUrl=url)
http://lists.mplayerhq.hu/pipermail/rtmpdump/2012-July/002016.html

Related

Cannot start J-Link GDB Server on Ubuntu

I am currently working on the ARM Cortex-M4 inside the NXP i.MX8M Mini.
I am able to compile a project for M4 on Eclipse IDE on an Ubuntu VM.
I would now like to debug on the M4 via a SEGGER Flasher ARM probe, still from Ubuntu.
My probe is well recognized by Ubuntu, and I can launch the J-Link GDB server by simply typing the command :
$ sudo ./JLinkGDBServerCLExe
However, if I type the same command without sudo, I get :
$ ./JLinkGDBServerCLExe
SEGGER J-Link GDB Server V7.58b Command Line Version
JLinkARM.dll V7.58b (DLL compiled Nov 16 2021 15:04:27)
-----GDB Server start settings-----
GDBInit file: none
GDB Server Listening port: 2331
SWO raw output listening port: 2332
Terminal I/O port: 2333
Accept remote connection: yes
Generate logfile: off
Verify download: off
Init regs on start: off
Silent mode: off
Single run mode: off
Target connection timeout: 0 ms
------J-Link related settings------
J-Link Host interface: USB
J-Link script: none
J-Link settings file: none
------Target related settings------
Target device: Unspecified
Target interface: JTAG
Target interface speed: 4000kHz
Target endian: little
Connecting to J-Link...
Connecting to J-Link failed. Connected correctly?
GDBServer will be closed...
Shutting down...
Could not connect to J-Link.
Please check power, connection and settings.
My problem is that when I start eclipse, I get the same result as starting the GDB server without sudo.
It seems that this is a rights issue, how can I solve it?
As #KamilCuk said, the problem came from the udev rules.
So you just have to copy the rules provided by Segger with J-Link Software on the system:
$ sudo cp 99-jlink.rules /etc/udev/rules.d
Then you have to reboot the system:
$ reboot

STM32CubeIDE and OpenOCD: Error: timed out while waiting for target halted

Hardware/IDE Context:
Part/board: Genuine STM32F103C8 (BluePill)
Programmer: ST-Link V2
IDE: STM32CubeIDE 1.5.1 on fully-updated Windows 10
Flashing utility/debugger: OpenOCD
In attempting to build/flash a simple PC_13 LED blinky program to my BluePill board, I experience errors from OpenOCD like so:
Open On-Chip Debugger 0.10.0+dev-01288-g7491fb4 (2020-10-27-17:36)
Licensed under GNU GPL v2
For bug reports, read
http://openocd.org/doc/doxygen/bugs.html
Info : Listening on port 6666 for tcl connections
Info : Listening on port 4444 for telnet connections
Info : STLINK V2J37S7 (API v2) VID:PID 0483:3748
Info : Target voltage: 3.256346
Info : Unable to match requested speed 8000 kHz, using 4000 kHz
Info : Unable to match requested speed 8000 kHz, using 4000 kHz
Info : clock speed 4000 kHz
Info : stlink_dap_op_connect(connect)
Info : SWD DPIDR 0x1ba01477
Info : STM32F103C8Tx.cpu: hardware has 6 breakpoints, 4 watchpoints
Info : STM32F103C8Tx.cpu: external reset detected
Info : starting gdb server for STM32F103C8Tx.cpu on 3333
Info : Listening on port 3333 for gdb connections
Info : accepting 'gdb' connection on tcp/3333
Error: timed out while waiting for target halted
Error executing event gdb-attach on target STM32F103C8Tx.cpu:
TARGET: STM32F103C8Tx.cpu - Not halted
Info : device id = 0x20036410
Info : flash size = 64kbytes
Info : accepting 'gdb' connection on tcp/3333
Error: timed out while waiting for target halted
Error executing event gdb-attach on target STM32F103C8Tx.cpu:
TARGET: STM32F103C8Tx.cpu - Not halted
Error: timed out while waiting for target halted
Error executing event gdb-flash-erase-start on target STM32F103C8Tx.cpu:
TARGET: STM32F103C8Tx.cpu - Not halted
Error: Target not halted
Error: failed erasing sectors 0 to 5
Error: flash_erase returned -304
shutdown command invoked
Info : dropped 'gdb' connection
shutdown command invoked
I'm interested in using OpenOCD-based flashing for my project to make use of some STM32F103C8 clone boards I have lying around, but the upload process works again when I switch the flashing mode/"Debug Probe" in STM32CubeIDE back to ST-Link (ST-Link GDB Server) from ST-Link (OpenOCD).
This is a peculiar error to me, especially since I specifically remember this exact configuration (STM32CubeIDE + OpenOCD + ST-Link + STM32F103C8) working a couple of months ago. Does anyone have any ideas as to what this could be caused by? I have the OpenOCD debugger to use the standard auto-generated config file.
Also please let me know if there is any more information/details you'd need to help diagnose this issue. I'd be happy to provide anything necessary.
EDIT 2/22/2021:
Here is a copy of the auto-generated (by STM32CubeIDE) OpenOCD .cfg file:
# This is an genericBoard board with a single STM32F103C8Tx chip
#
# Generated by STM32CubeIDE
# Take care that such file, as generated, may be overridden without any early notice. Please have a look to debug launch configuration setup(s)
source [find interface/stlink-dap.cfg]
set WORKAREASIZE 0x5000
transport select "dapdirect_swd"
set CHIPNAME STM32F103C8Tx
set BOARDNAME genericBoard
# Enable debug when in low power modes
set ENABLE_LOW_POWER 1
# Stop Watchdog counters when halt
set STOP_WATCHDOG 1
# STlink Debug clock frequency
set CLOCK_FREQ 8000
# Reset configuration
# use hardware reset, connect under reset
# connect_assert_srst needed if low power mode application running (WFI...)
reset_config srst_only srst_nogate connect_assert_srst
set CONNECT_UNDER_RESET 1
set CORE_RESET 0
# ACCESS PORT NUMBER
set AP_NUM 0
# GDB PORT
set GDB_PORT 3333
# BCTM CPU variables
source [find target/stm32f1x.cfg]
#SWV trace
tpiu config disable
Ultimately, after some further research and trial & error, I settled on a fix that seems to work for me. I noticed that when the error with halting the CPU came up, the correct program seemed to have been loaded and the RESET button just needed to be toggled manually. These are the OpenOCD settings I ended up settling on:
Changes from the default configuration:
SWD Frequency: 8 → 4 MHz
This is technically not required to work, but OpenOCD will automatically revert back to 4 MHz during the upload anyway
Reset Mode: Connect Under Reset → None
This works for me with the following output:
Open On-Chip Debugger 0.10.0+dev-01288-g7491fb4 (2020-10-27-17:36)
Licensed under GNU GPL v2
For bug reports, read
http://openocd.org/doc/doxygen/bugs.html
Info : Listening on port 6666 for tcl connections
Info : Listening on port 4444 for telnet connections
Info : STLINK V2J37S7 (API v2) VID:PID 0483:3748
Info : Target voltage: 3.254751
Info : clock speed 4000 kHz
Info : stlink_dap_op_connect(connect)
Info : SWD DPIDR 0x1ba01477
Info : STM32F103C8Tx.cpu: hardware has 6 breakpoints, 4 watchpoints
Info : STM32F103C8Tx.cpu: external reset detected
Info : starting gdb server for STM32F103C8Tx.cpu on 3333
Info : Listening on port 3333 for gdb connections
Info : accepting 'gdb' connection on tcp/3333
Info : device id = 0x20036410
Info : flash size = 64kbytes
undefined debug reason 8 - target needs reset
Info : accepting 'gdb' connection on tcp/3333
undefined debug reason 8 - target needs reset
target halted due to debug-request, current mode: Thread
xPSR: 0x01000000 pc: 0x08000474 msp: 0x20005000
target halted due to debug-request, current mode: Thread
xPSR: 0x01000000 pc: 0x08000474 msp: 0x20005000
shutdown command invoked
Info : dropped 'gdb' connection
shutdown command invoked

how to remove sails js default log messages

Please how to remove this default log messages that are displayed when "sails lift" that also written to my external log files :
info: Starting app...
debug: Deprecation warning: Support for `sails.config.sockets.onConnect` will be
removed in an upcoming release. See the v0.11 migration guide for more informat
ion and alternate options.
info:
info: .-..-.
info:
info: Sails <| .-..-.
info: v0.12.4 |\
info: /|.\
info: / || \
info: ,' |' \
info: .-'.-==|/_--'
info: `--'-------'
info: __---___--___---___--___---___--___
info: ____---___--___---___--___---___--___-__
info:
info: Server lifted in `E:\Orange\sailsJS_workspace\server`
info: To see your app, visit http://localhost:1337
info: To shut down Sails, press <CTRL> + C at any time.
debug: -------------------------------------------------------
debug: :: Wed Nov 02 2016 12:03:45 GMT+0200 (Egypt Standard Time)
debug: Environment : development
debug: Port : 1337
debug: -------------------------------------------------------
Just add:
noShip: true
To file: config/log.js
For other default log messages play with "level", it's documented in comments at beginning of file.
Set level: to silent in the log.js
Ex:
module.exports.log = {
custom: blahblahBlah,
inspect: false
level: 'info'
};

Wrong visualization of Sails.js project deployed on Openshift

I deployed my Sails project on Openshift.
It works but I receive errors with websockets and I don't able to load pages built on ejs.
I found these links enough explanatory about grunt/openshift, but I am not able to solve the problem.
Deploying Sails.js On Openshift
Deploy Sails.js on Openshift ... app restarting over and over
My nodejs.log is:
DEBUG: Running node-supervisor with
DEBUG: program 'app.js'
DEBUG: --watch '/var/lib/openshift/537b5ae8500446c95900057f/app-root/data/.nodewatch'
DEBUG: --ignore 'undefined'
DEBUG: --extensions 'node|js|coffee'
DEBUG: --exec 'node'
DEBUG: Starting child process with 'node app.js'
DEBUG: Watching directory '/var/lib/openshift/537b5ae8500446c95900057f/app-root/data/.nodewatch' for changes.
Warning: connection.session() MemoryStore is not
designed for a production environment, as it will leak
memory, and will not scale past a single process.
^[[32minfo^[[39m:
^[[32minfo^[[39m:
^[[32minfo^[[39m: Sails.js <|
^[[32minfo^[[39m: v0.9.16 |\
^[[32minfo^[[39m: /|.\
^[[32minfo^[[39m: / || \
^[[32minfo^[[39m: ,' |' \
^[[32minfo^[[39m: .-'.-==|/_--'
^[[32minfo^[[39m: `--'-------'
^[[32minfo^[[39m: __---___--___---___--___---___--___
^[[32minfo^[[39m: ____---___--___---___--___---___--___-__
^[[32minfo^[[39m:
^[[32minfo^[[39m: Server lifted in `/var/lib/openshift/537b5ae8500446c95900057f/app-root/runtime/repo`
^[[32minfo^[[39m: To see your app, visit http://127.2.95.129:8080
^[[32minfo^[[39m: To shut down Sails, press <CTRL> + C at any time.
^[[34mdebug^[[39m: --------------------------------------------------------
^[[34mdebug^[[39m: :: Wed May 21 2014 14:26:01 GMT-0400 (EDT)
^[[34mdebug^[[39m:
^[[34mdebug^[[39m: Environment : production
^[[34mdebug^[[39m: Host : 127.2.95.129
^[[34mdebug^[[39m: Port : 8080
^[[34mdebug^[[39m: --------------------------------------------------------
^[[31merror^[[39m: Server doesn't seem to be starting.
^[[31merror^[[39m: Perhaps something else is already running on port 8080 with hostname 127.2.95.129?
^[[32minfo^[[39m: handshake authorized qR_aOT3qx40k6X34CF-2
^[[32minfo^[[39m: handshake authorized tnAUouwi-d32h82rCF-3
^[[33mwarn^[[39m: websocket connection invalid
^[[32minfo^[[39m: transport end (undefined)
^[[31merror^[[39m: Error rendering view at :: /var/lib/openshift/537b5ae8500446c95900057f/app-root/runtime/repo/views/viewshows/index
^[[31merror^[[39m: Using layout located at :: /var/lib/openshift/537b5ae8500446c95900057f/app-root/runtime/repo/views/layout
^[[31merror^[[39m: Error: Failed to lookup view "viewshows/index"
at Function.app.render (/var/lib/openshift/537b5ae8500446c95900057f/app-root/runtime/repo/node_modules/sails/node_modules/express/lib/application.js:495:17)
at ServerResponse.res.render (/var/lib/openshift/537b5ae8500446c95900057f/app-root/runtime/repo/node_modules/sails/node_modules/express/lib/response.js:798:7)
at ServerResponse._addResViewMethod.res.view (/var/lib/openshift/537b5ae8500446c95900057f/app-root/runtime/repo/node_modules/sails/lib/hooks/views/index.js:297:15)
at module.exports.index (/var/lib/openshift/537b5ae8500446c95900057f/app-root/runtime/repo/api/controllers/ViewShowsController.js:32:13)
at _bind.enhancedFn (/var/lib/openshift/537b5ae8500446c95900057f/app-root/runtime/repo/node_modules/sails/lib/router/bind.js:375:4)
at callbacks (/var/lib/openshift/537b5ae8500446c95900057f/app-root/runtime/repo/node_modules/sails/node_modules/express/lib/router/index.js:164:37)
Here my app.js:
require('sails').lift(require('optimist').argv);
Here my local.js:
module.exports = {
host: process.env.OPENSHIFT_NODEJS_IP || "127.0.0.1",
port: process.env.OPENSHIFT_NODEJS_PORT || 8080,
environment: process.env.NODE_ENV || 'development'
}
Calling 'env | grep OPENSHIFT_NODEJS_PORT' on openshift console I receive:
OPENSHIFT_NODEJS_PORT=8080
In my opinion the problem isn't the port. The server start and answer correctly.
But when I call a page built on ejs it answer me with a piece of json...
{"view":{"name":"viewshows/index","root":"/var/lib/openshift/537b5ae8500446c95900057f/app-root/runtime/repo/views","defaultEngine":"ejs","ext":".ejs"}}
...and print the error above in the server log.
Any suggestion?
Thanks
I'm fairly certain that openshift requires your application to listen to a specific port, specified by an environmental variable, not 8080
You're going to want to change your app.js to to use the hostname and port env variables in this openshift doc

Error configuring Network Audio System [NAS] in RHEL 6 x64

I tried to setup NAS (Network Audio System ) in RHEL 6 by two methods:
First, by RPM install,
[root#localhost ~]# rpm -Uvh nas-1.9.2-1.el6.x86_64.rpm nas-libs-1.9.2-1.el6.x86_64.rpm
it gets installed, but I cannot find the service in /etc/init.d/ directory.
only /etc/nas/nasd.conf file gets created. And if I run the command
[root#localhost ~]# nasd
Network Audio System Release 1.9.2
Network Audio System Release 1.9.2
Init: Output open(/dev/dsp) failed: No such file or directory
Fatal server error:
could not create audio connection block info
Secondly, by Configuring latest tar-ball nas-1.9.3.src.tar.gz provided by NAS site.
but the problem is same.
Please help me to install this properly, as I want to get enable the audio for qt based applications, and qt uses NAS for its audio functionalities.
Tried Very much by NAS but not succeed to resolve my problem.
Then i used Phonon library to resolve sound issue !!
Thanx anyways for helping me! :)
okay. well it's been a while but...
you dont have enough perms to open the underlying socket.
me#dev $ strace -o ./nasd.txt nasd -aa -config ./nasd.conf
Network Audio System Release 1.9.3
Network Audio System Release 1.9.3
Error binding unix socket: /var/run/nasd/audio0
: Address already in use
Fatal server error:
Cannot establish unix listening socket
the appropriate bit is here from the strace
ioctl(0, SIOCGIFCONF, {96, {{"lo", {AF_INET, inet_addr("127.0.0.1")}}, {"wlan0", {AF_INET, inet_addr("192.168.1.69")}}, {"usb0", {AF_INET, inet_addr("192.168.15.100")}}}}) = 0
umask(0) = 022
mkdir("/var/run/nasd", 0777) = -1 EEXIST (File exists)
unlink("/var/run/nasd/audio0") = -1 EPERM (Operation not permitted)
socket(PF_FILE, SOCK_STREAM, 0) = 1
bind(1, {sa_family=AF_FILE, path="/var/run/nasd/audio0"}, 22) = -1 EADDRINUSE (Address already in use)
The unlink("/var/run/nasd/audio0") = -1 EPERM (Operation not permitted) is the clue.
if we copy the nasd.conf locally and tweak the debug value to 1 and run it as root
me#dev $ sudo nasd -aa -config ./nasd.conf
config: Maxfrags set to 3
config: Minfrags set to 2
config: Fragsize set to 256
config: Maxfrags set to 3
config: Minfrags set to 2
config: Fragsize set to 256
Network Audio System Release 1.9.3
Network Audio System Release 1.9.3
AuInitPhysicalDevices();
Init: will close device when finished with stream.
Init: will keep mixer device open.
Init: Leaving the mixer device options alone at startup.
Init: openDevice OUT /dev/snd/pcmC1D0p mode 1
Init: openDevice(1) IN /dev/snd/pcmC1D0c mode 0
setupSoundcard(...);
++ Setting up Output device (/dev/snd/pcmC1D0p)
+++ requesting wordsize of 16, got 8
+++ requesting 2 channel(s), got 1 channel(s)
+++ Requesting minimum sample rate of 5000, got 5000
+++ Requesting maximum sample rate of 44100, got 44100
setupSoundcard(...);
++ Setting up Input device (/dev/snd/pcmC1D0c)
+++ requesting wordsize of 8, got 8
+++ requesting 2 channel(s), got 1 channel(s)
+++ Requesting minimum sample rate of 4000, got 4000
+++ Requesting maximum sample rate of 44100, got 44100
initMixer: could not open output mixer device /dev/mixer: No such file or directory
Init: initMixer failed
createServerComponents(...);
closeDevice: out
closeDevice OUT /dev/snd/pcmC1D0p mode 1
closeDevice: in
closeDevice IN /dev/snd/pcmC1D0c mode 0
closeDevice: mixer
closeDevice: leaving mixer device(s) open
in my case looks like I need to setup the mixer section but that should nerf your error.
EDIT: initMixer: could not open output mixer device /dev/mixer: No such file or directory
This can be fixed by placing mixer ="" in the nasd.conf (even though the docs state it won't be honoured, it is)
Also: remember to set your AUDIOSERVER env variable
export AUDIOSERVER=tcp/localhost:8000
Is the default but never hurts to be certain...
Final thoughts:
by default many x server now -nolisten tcp and that could be an issue in implementation to consider.
nmap is your friend.
And, for the record, I still haven't actually got an end-to-end system working...
Hopefully some other kind soul will jump in and point out anything I have missed.
Hope it helps.
I don't have a rhel box... but it's probably the same perms issue.
The docs are "thin" at best

Resources