Streaming Webcam with RTSP - stream

I'm trying a live streaming of video using a web cam attached to my laptop. I am working in Linux Ubuntu.
Here are the Gstreamer pipeline for server side and client side:
Streaming server: I'm trying to use gst-rtsp-server to serve the video from a v4l2 device.
./test-launch --gst-debug=0 "( v4l2src
!
video/x-raw-yuv,width=352,height=288,framerate=15/1
! x264enc ! rtph264pay name=pay0 pt=96
)"
Receiver:
gst-launch -v rtspsrc
location=rtsp://192.168.XX.XX:8554/test
! decodebin ! autovideosink
I have this message error:
Setting pipeline to PAUSED …
ERROR: Pipeline doesn’t want to pause.
ERROR: from element /GstPipeline:pipeline0/GstRTSPSrc:rtspsrc0: Could
not read from resource. Additional debug info: gstrtspsrc.c(4573):
gst_rtspsrc_send (): /GstPipeline:pipeline0/GstRTSPSrc:rtspsrc0: Got
error response: 503 (Service Unavailable).
Setting pipeline to NULL …
Freeing pipeline …
Who know this problem and/or can try to help me?

You will get lot of examples here for receiver(client) and sender(server) application : http://cgit.freedesktop.org/gstreamer/gst-plugins-good/tree/tests/examples/rtp

There might be several reasons for a stream not to be available, and that HTTP 503 is not that clear (that error message about PAUSED state either, since a stream has to switch to every state from NULL to PLAYING, and it is necessarily already playing while switching to PAUSED).
You better add GST_DEBUG={1,9} before your command as in,
GST_DEBUG=3 ./test-launch --gst-debug=0 ...
In my case it was,
ERROR GST_PIPELINE grammar.y:691:priv_gst_parse_yyparse: no element "x264enc"
ERROR GST_PIPELINE grammar.y:776:priv_gst_parse_yyparse: link has no sink [source=#0x7f62b800a0d0]
ERROR GST_PIPELINE grammar.y:776:priv_gst_parse_yyparse: link has no source [sink=#0x7f62b801a1b0]
And I solved it by installing the package gstreamer-plugins-ugly-orig-addon on an openSUSE system. Hope this helps somebody to tear less hair off.

Related

The neo4j cypher shell and the browser connections are working but the golang client connection is not working

I have disabled the authentication on my neo4j server, so I can connect using the cypher shell using no credentials as it follows and is working.
$ ./bin/cypher-shell -a 192.168.0.89
This is how I'm declaring my driver and the session, I also tried using neo4j://* instead of bolt://*:
driver, err := neo4j.NewDriver("bolt://192.168.0.89:7687", neo4j.NoAuth())
if err != nil {
return "", err
}
defer driver.Close()
session, _ := driver.NewSession(neo4j.SessionConfig{AccessMode: neo4j.AccessModeWrite})
defer session.Close()
But that doesn't work either. I'm getting this error when running the hello world from the neo4j olang driver page https://neo4j.com/developer/go/
TLS error: Remote end closed the connection, check that TLS is enabled on the server
There are the logs of the server when it starts:
2021-03-07 23:17:23.227+0000 INFO ======== Neo4j 4.2.3 ========
2021-03-07 23:17:24.119+0000 INFO Performing postInitialization step for component 'security-users' with version 2 and status CURRENT
2021-03-07 23:17:24.119+0000 INFO Updating the initial password in component 'security-users'
2021-03-07 23:17:24.243+0000 INFO Bolt enabled on 192.168.0.89:7687.
2021-03-07 23:17:25.139+0000 INFO Remote interface available at http://192.168.0.89:7474/
2021-03-07 23:17:25.140+0000 INFO Started.
These are all my config settings:
dbms.connector.bolt.advertised_address=192.168.0.89:7687
dbms.connector.bolt.enabled=true
dbms.connector.bolt.listen_address=192.168.0.89:7687
dbms.connector.bolt.tls_level=DISABLED
dbms.connector.http.advertised_address=192.168.0.89:7474
dbms.connector.http.enabled=true
dbms.connector.http.listen_address=192.168.0.89:7474
dbms.connector.https.enabled=false
dbms.default_advertised_address=192.168.0.89
dbms.default_database=neo4j
dbms.default_listen_address=192.168.0.89
dbms.directories.import=/home/eduardo/NEO4J/import
dbms.directories.neo4j_home=/home/eduardo/NEO4J
dbms.jvm.additional=-Dlog4j2.disable.jmx=true
dbms.security.auth_enabled=false
dbms.tx_log.rotation.retention_policy=1 days
dbms.tx_state.memory_allocation=ON_HEAP
dbms.windows_service_name=neo4j
Again, I can connect to the same host and the browser is also working fine:
Thanks in advance for any help :)
Adding to your answer: it is likely you're using the v1.x of the Go driver. If you switch to using the v4.x driver instead, you will not have to specify this config value.
You can upgrade by simply adding v4 in your import statement like so:
import github.com/neo4j/neo4j-go-driver/v4/neo4j
More info: https://github.com/neo4j/neo4j-go-driver/blob/4.2/MIGRATIONGUIDE.md
For anyone looking for the answer, the bolt driver will try to use TLS by default and since in my case is not configured, the encryption needs to be disabled in the driver constructor call.
driver, err := neo4j.NewDriver("bolt://192.168.0.89:7687", neo4j.NoAuth(), func(c *neo4j.Config) { c.Encrypted = false })
Hope this helps other people experiencing the same issue :)

New browser not working in Robot Framework on server with Docker

I cannot open the browser when using the browser library in the robot framework on the server. But it is working on local with same docker.
NOT : I use browser library, I don't use selenium.
Thank you in advance for your help
Error log
{"level":30,"time":"2021-01-12T08:43:15.541Z","pid":1042,"hostname":"9e6377fbd66f","msg":"Changed active context"}
{"level":30,"time":"2021-01-12T08:43:15.684Z","pid":1042,"hostname":"9e6377fbd66f","msg":"Video path: undefined"}
{"level":30,"time":"2021-01-12T08:43:15.684Z","pid":1042,"hostname":"9e6377fbd66f","msg":"Changed active page"}
================= Original suppressed error =================
page.goto: Timeout 10000ms exceeded.
=========================== logs ===========================
navigating to "https://google.com.tr", waiting until "load"
============================================================
Note: use DEBUG=pw:api environment variable and rerun to capture Playwright logs.
at Connection.sendMessageToServer (/usr/local/lib/python3.9/site-packages/Browser/wrapper/node_modules/playwright/lib/client/connection.js:69:15)
at Proxy.<anonymous> (/usr/local/lib/python3.9/site-packages/Browser/wrapper/node_modules/playwright/lib/client/channelOwner.js:44:61)
at /usr/local/lib/python3.9/site-packages/Browser/wrapper/node_modules/playwright/lib/client/frame.js:80:71
at Frame._wrapApiCall (/usr/local/lib/python3.9/site-packages/Browser/wrapper/node_modules/playwright/lib/client/channelOwner.js:72:34)
at Frame.goto (/usr/local/lib/python3.9/site-packages/Browser/wrapper/node_modules/playwright/lib/client/frame.js:78:21)
at /usr/local/lib/python3.9/site-packages/Browser/wrapper/node_modules/playwright/lib/client/page.js:267:60
at Page._attributeToPage (/usr/local/lib/python3.9/site-packages/Browser/wrapper/node_modules/playwright/lib/client/page.js:202:20)
at Page.goto (/usr/local/lib/python3.9/site-packages/Browser/wrapper/node_modules/playwright/lib/client/page.js:267:21)
at Object.<anonymous> (/usr/local/lib/python3.9/site-packages/Browser/wrapper/index.js:70868:49)
at step (/usr/local/lib/python3.9/site-packages/Browser/wrapper/index.js:70323:23) {
name: 'TimeoutError'
}
=============================================================
================= Original suppressed error =================
Error: Tried to take screenshot, but no page was open.
at Object.exists (/usr/local/lib/python3.9/site-packages/Browser/wrapper/index.js:70233:15)
at Object.<anonymous> (/usr/local/lib/python3.9/site-packages/Browser/wrapper/index.js:66456:41)
at step (/usr/local/lib/python3.9/site-packages/Browser/wrapper/index.js:66384:23)
at Object.next (/usr/local/lib/python3.9/site-packages/Browser/wrapper/index.js:66365:53)
at /usr/local/lib/python3.9/site-packages/Browser/wrapper/index.js:66359:71
at new Promise (<anonymous>)
at __webpack_modules__../node/playwright-wrapper/browser-control.ts.__awaiter (/usr/local/lib/python3.9/site-packages/Browser/wrapper/index.js:66355:12)
at Object.takeScreenshot (/usr/local/lib/python3.9/site-packages/Browser/wrapper/index.js:66437:12)
at PlaywrightServer.<anonymous> (/usr/local/lib/python3.9/site-packages/Browser/wrapper/index.js:67972:61)
at step (/usr/local/lib/python3.9/site-packages/Browser/wrapper/index.js:67457:23)
=============================================================
{"level":30,"time":"2021-01-12T08:43:25.750Z","pid":1042,"hostname":"9e6377fbd66f","msg":"Changed active context"}
{"level":30,"time":"2021-01-12T08:43:25.777Z","pid":1042,"hostname":"9e6377fbd66f","msg":"Changed active context"}
Problem solved. Because it is a foreign server, the url has been closed for security purposes. I solved the problem by applying a proxy.
Thanks to everyone who helped

unset error puma-rails 5 on production server

I am deploying my app using puma+nginx+capistrano on rails 5 and using this tutorial http://codepany.com/blog/rails-5-puma-capistrano-nginx-jungle-upstart/. I performed all the steps. But when I do:
start puma-manager
I get following error:
start: Rejected send message, 1 matched rules; type="method_call",
sender=":1.1" (uid=500 pid=2737 comm="start puma-manager ")
interface="com.ubuntu.Upstart0_6.Job" member="Start" error name="(unset)"
requested_reply="0" destination="com.ubuntu.Upstart" (uid=0 pid=1 comm="/sbin/init")
I am not able to start my app and what is the error here, I am not able to understand. How can I correct this?

pjsua:Err=70018 (gethostbyname() has returned error (PJ_ERESOLVE))

the pjsua project is configured in linux(centos),the follows are my codes.Please help me,I have checked more about this problem ,but nothing useful about pjsua testing in linux.
[root#hy bin]# ls pjsua-x86_64-unknown-linux-gnu PJSYSTEST.TXT
pjsystest-x86_64-unknown-linux-gnu reg.cfg samples [root#hy bin]#
./pjsua-x86_64-unknown-linux-gnu --config-file reg.cfg
after this,the error is coming:
02:43:37.421 sip_resolve.c ...Failed to resolve 'xxxxxxx(sip
address)'. Err=70018 (gethostbyname() has returned error
(PJ_ERESOLVE))
02:43:37.421 tsx0x2342998 ...Failed to send Request msg
REGISTER/cseq=9911 (tdta0x2340930)! err=70018 (gethostbyname() has
returned error (PJ_ERESOLVE))
02:43:37.421 pjsua_acc.c .....SIP registration failed, status=502
(gethostbyname() has returned error (PJ_ERESOLVE))
looking forward your help.
Obviously this is a name resolution problem. The REGISTER URI can not be resolved by your system. Make sure you are pointing to a valid, reachable DNS server or the hostname is configured in your /etc/hosts.

RStudio server ROracle throws : Error in .oci.Driver() : ROracle internal error [rociDrvInit, 1, -1]

I've setup RStudio server and pointed it to use an existing R (2.13) installation. ROracle works fine when accessed from R, but the same does not work from RStudio web-interface.
> library(ROracle)
Loading required package: DBI
> drv <- dbDriver("Oracle")
Error in .oci.Driver() : ROracle internal error [rociDrvInit, 1, -1]
I installed RStudio server with --nodeps and later pointed it to an existing installation of R
by setting the values in /etc/rstudio/rserver.conf file.
Tried getting help from RStudio support, but was pointed toward "Stack Overflow".
http://support.rstudio.org/help/discussions/problems/1879-rstudio-roracle-internal-error
Thanks in advance,
Sai.
Finally got it working with help from Denis Mukhin on the Oracle forums. In particular, ORACLE_HOME and OREACLE_SID were missing in the RStudio environment. Adding the following lines to ~/.Renviron fixed it:
ORACLE_HOME=/u01/app/oracle/product/11.1.0/db_1
ORACLE_SID=<your sid (the default is usually orcl)>
export ORACLE_HOME ORACLE_SID

Resources