It is currently 25 Jun 2017, 01:20



Server gets spammed by console with carriage returns

Help to specific problems with your setup, or discussing CasparCG bugs

Moderators: Macey, Jonas Hummelstrand, didikunz

Server gets spammed by console with carriage returns

Postby String_Theorist » 15 Mar 2017, 20:31

Hi all,

I'm using the beta release for Linux. Running on Ubuntu Studio 16.04.

To start the server i simply launch the ./run.sh script and pipe the output to a log file.

For some unknown reason, under different/inconsistent circumstances, the log file just spits out thousands of lines of the same INFO message. The log files grow in GB's in seconds. The INFO line says that the server receives "/r/n" from the console, and the server returns error 400.

We've sniffed the socket for TCP traffic and found that the messages are not coming from the client, and they're not coming through TC either. It's coming from the console, as if someone jammed the "Enter" button in the terminal window. But this happens even when the script is run in the background as a startup item.

The script we're running resides in usr/bin. All the script does is "cd" to the location of the "run.sh" script and executes it, outputting the console output to a log file.
String_Theorist
 
Posts: 8
Joined: 09 Mar 2017, 22:45

Re: Server gets spammed by console with carriage returns

Postby String_Theorist » 18 Mar 2017, 01:19

Hi everyone,

Ok so I've come to realize that the only way I can get this to work properly is by running it as a system daemon.

I'm just having some trouble getting my systemd service setup correctly. Does anyone have any suggestions? . . So I've got my bash script saved in the /usr/sbin folder and I've setup the .service file as follows:

Code: Select all
[Unit]
Description=Starts CasparCG Server

[Service]
ExecStart=/usr/sbin/start_caspar.sh
StandardOutput=null
Restart=on-failure

[Install]
WantedBy=multi-user.target
WantedBy=graphical.target


Running the service definitely launches the script, according to the log file:

Code: Select all
[2017-03-18 02:04:11.407] [3336] [info]    Starting CasparCG Video and Graphics Playout Server 2.1.0.430 1c872ac Beta 1
[2017-03-18 02:04:11.407] [3336] [info]    on Ubuntu 16.04.2 LTS
[2017-03-18 02:04:11.408] [3336] [info]    Intel(R) Core(TM) i7-6800K CPU @ 3.40GHz Physical threads: 16
[2017-03-18 02:04:11.408] [3336] [info]    Default string
[2017-03-18 02:04:11.408] [3336] [info]    Initialized reroute module.
[2017-03-18 02:04:11.409] [3336] [info]    Initialized ffmpeg module.
[2017-03-18 02:04:11.409] [3336] [info]    Initialized oal module.
[2017-03-18 02:04:11.409] [3336] [info]    Initialized decklink module.
[2017-03-18 02:04:11.409] [3336] [info]    Initialized screen module.


Strangely though, I'm not able to communicate with it via the client. Also, it does not seem to be listening on port 5250, according to lsof.

Your help is appreciated.
String_Theorist
 
Posts: 8
Joined: 09 Mar 2017, 22:45

Re: Server gets spammed by console with carriage returns

Postby String_Theorist » 18 Mar 2017, 13:55

UPDATE:

The systemctl status log shows a warning that the Caspar log does not:

Code: Select all
● start-caspar.service - Starts Caspar CG
   Loaded: loaded (/etc/systemd/system/start-caspar.service; enabled; vendor preset: enabled)
   Active: inactive (dead) since Sat 2017-03-18 14:22:49 SAST; 24min ago
  Process: 2993 ExecStart=/bin/sh /usr/sbin/start_caspar.sh (code=exited, status=0/SUCCESS)

Mar 18 14:22:48 ZAPS001 sh[2993]: [2017-03-18 14:22:48.960] [2996] [info]    on Ubuntu 16.04.2 LTS
Mar 18 14:22:48 ZAPS001 sh[2993]: [2017-03-18 14:22:48.962] [2996] [info]    Intel(R) Core(TM) i7-6800K CPU @ 3.40GHz Physical threads: 16
Mar 18 14:22:48 ZAPS001 sh[2993]: [2017-03-18 14:22:48.962] [2996] [info]    Default string
Mar 18 14:22:48 ZAPS001 sh[2993]: [2017-03-18 14:22:48.962] [2996] [info]    Initialized reroute module.
Mar 18 14:22:48 ZAPS001 sh[2993]: [2017-03-18 14:22:48.963] [2996] [info]    Initialized ffmpeg module.
Mar 18 14:22:48 ZAPS001 sh[2993]: [2017-03-18 14:22:48.963] [2996] [info]    Initialized oal module.
Mar 18 14:22:48 ZAPS001 sh[2993]: [2017-03-18 14:22:48.963] [2996] [info]    Initialized decklink module.
Mar 18 14:22:48 ZAPS001 sh[2993]: [2017-03-18 14:22:48.963] [2996] [info]    Initialized screen module.
Mar 18 14:22:48 ZAPS001 sh[2993]: (.:2996): Gtk-WARNING **: cannot open display:
Mar 18 14:22:49 ZAPS001 systemd[1]: Started Starts Caspar CG.


So the extra information here is this line:

Code: Select all
Mar 18 14:22:48 ZAPS001 sh[2993]: (.:2996): Gtk-WARNING **: cannot open display:
String_Theorist
 
Posts: 8
Joined: 09 Mar 2017, 22:45


Return to Help & Support

Who is online

Users browsing this forum: No registered users and 3 guests