Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Don't require gstd-check-user-xenv.sh for systemd service #251

Open
wants to merge 1 commit into
base: develop
Choose a base branch
from

Conversation

jameshilliard
Copy link
Contributor

The gstd-check-user-xenv.sh script does not appear to be required for running the gstd service so we shouldn't require it for the service to start.

Note that the non-systemd init script already does not require this.

@jameshilliard
Copy link
Contributor Author

rebased

@michaelgruner
Copy link
Contributor

@jcaballeros do you mind taking a look at this? I recall there was a reasoning behind this.

@jameshilliard jameshilliard force-pushed the optional-gstd-check-user-xenv branch 2 times, most recently from 6befcbf to 8584efb Compare June 15, 2022 23:50
@michaelgruner
Copy link
Contributor

@jcaballeros may I have your input on this one?

The gstd-check-user-xenv.sh script does not appear to be required
for running the gstd service so we shouldn't require it for the
service to start.

Note that the non-systemd init script already does not require this.

Signed-off-by: James Hilliard <james.hilliard1@gmail.com>
@jcaballeros
Copy link
Contributor

That script requirement was added because when the service is enabled to autostart, gstd starts before the x environment variables are defined and can't display things, though the pipelines run. I tried adding the dependency to the UI target (After in the unit file) instead, but it didn't work appropriately for Jetson at the time, so I enforced it with this script.

@jameshilliard
Copy link
Contributor Author

That script requirement was added because when the service is enabled to autostart, gstd starts before the x environment variables are defined and can't display things, though the pipelines run.

So making it optional like I did should be ok though right? For example if one isn't using x11 and is instead using wayland or a headless system this will cause the gstd service startup to fail entirely.

I tried adding the dependency to the UI target (After in the unit file) instead, but it didn't work appropriately for Jetson at the time, so I enforced it with this script.

Hmm, looks like it's expected that x11 should execute this script to set things up. Maybe jetson's systemd doesn't include that script or there's some dependency issue there? I don't use x11 myself so I'm not very familiar with it in general(I use wayland with the weston compositor).

@jcaballeros jcaballeros self-assigned this Jul 13, 2022
@michaelgruner
Copy link
Contributor

@jcaballeros can we have a follow up here?

@jcaballeros
Copy link
Contributor

Making the xenv script optional will cause issues in PC/Jetson cases where GstD is used to display. This script does not define the x environment variables, instead, it prevents GstD to start successfully until these variables are defined, so making it optional would cause its failure to be ignored and GstD would start successfully but unable to display video. I agree that we need to remove the dependency on headless systems, maybe we can check if the UI target works well on the latest Jetpack versions and avoid the use of the script.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants