Empresas
Empleos
  • Sobre nosotros
  • Soluciones
    • Publicación de vacantes
      Publica tu vacante y recibe candidatos calificados en 48h.
    • Evaluación de candidatos
      500+ pruebas técnicas y psicológicas, más anti-fraude.
    • Headhunting
      Búsqueda ejecutiva a la medida de principio a fin.
    • Nómina + EOR
      Dispersión de nómina y EOR en más de 15 países de LATAM.
  • Precios
  • Empleos

0

404
Vistas
Service permission denied - Fedora 31

I am currently working on a website that will run .net code using this guide:

https://docs.microsoft.com/en-us/aspnet/core/host-and-deploy/linux-apache?view=aspnetcore-3.1

And this guide to install .net core SDK (I installed 2.1 and 3.1 while troubleshooting):

https://docs.microsoft.com/en-ca/dotnet/core/install/linux-package-manager-fedora31

I am trying to configure the apache proxy server to send requests to the Kestrel server but I am having issues with my service at /etc/systemd/system/kestrel-helloapp.service.

My service's code is:

[Unit]
Description=Started service

[Service]
WorkingDirectory=/var/www/html/PublishedVersion
ExecStart=/usr/share/dotnet /var/www/html/PublishedVersion/Website.dll
KillSignal=SIGINT
SyslogIdentifier=dotnet-example
User=root
Enviroment=ASPNETCORE_ENVIROMENT=Production

[Install]
WantedBy=multi-user.target

The service status is:

Mar 15 19:37:38 localhost.localdomain systemd[1]: Started service
Mar 15 19:37:38 localhost.localdomain systemd[1706]: kestrel-helloapp.service: Failed to execute command: Permission denied
Mar 15 19:37:38 localhost.localdomain systemd[1706]: kestrel-helloapp.service: Failed at step EXEC spawning /usr/share/dotnet: Permission denied
Mar 15 19:37:38 localhost.localdomain systemd[1]: kestrel-helloapp.service: Main process exited, code=exited, status=203/EXEC
Mar 15 19:37:38 localhost.localdomain systemd[1]: kestrel-helloapp.service: Failed with result 'exit-code'.

There are three main differences in my service code in comparison to the guides code:

1st: I have removed to auto restart, so it dosen't bog down my machine.

2nd: I have changed the ExecStart=/usr/local/dotnet to ExectStart=/usr/shared/dotnet, I have done this because my .net installation isn't at that location for some reason that eludes me.

3rd: I have changed the User=apache to User=root in an attempt to troubleshoot, the only user on my machine is root as this machine is just for school purposes.

I have also changed the SELinux settings on my machine to permissive and finally disabled in an attempt at troubleshooting.

I'm still new to this and none of this was seen in class, so go easy on me.

Thanks you for your time/answers.

over 4 years ago · Santiago Trujillo
1 Respuestas
Responde la pregunta

0

Systemd has restrictions on where executed files are located. I'm not an expert in this field but there is a workaround on this issue. You can edit /etc/selinux/config and change line:

SELINUX=enforcing with SELINUX=permissive,

then restart the system and the service from systemd will start.

over 4 years ago · Santiago Trujillo Denunciar
Responde la pregunta
Encuentra empleos remotos

¡Descubre la nueva forma de encontrar empleo!

Top de empleos
Top categorías de empleo
Empresas
Publicar vacante Precios Comercial
Legal
Términos y condiciones Política de privacidad
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Recomiéndame algunas ofertas
Necesito ayuda