selinux is causing “nexus.service: Failed at step EXEC spawning /opt/nexus/bin/nexus: Permission denied”...
After installing the latest version of nexus, currently 3.6.0, I'm able to start it by using the manual command
/opt/nexus/bin/nexus start
but when trying to start as a service (per directions https://help.sonatype.com/display/NXRM3/Installation#Installation-RunningtheService), I get the following:
Oct 04 13:47:53 localhost.localdomain sudo[2546]: root : TTY=pts/0 ; PWD=/root ; USER=root ; COMMAND=/bin/systemctl start nexus.service
Oct 04 13:47:53 localhost.localdomain audit[2546]: USER_CMD pid=2546 uid=0 auid=0 ses=1 subj=unconfined_u:unconfined_r:unconfined_t:s0-s0:c0.c1023 msg='cwd="/root" cmd=73797374656D63746C207374617274206E657875732E7365
Oct 04 13:47:53 localhost.localdomain audit[2546]: CRED_REFR pid=2546 uid=0 auid=0 ses=1 subj=unconfined_u:unconfined_r:unconfined_t:s0-s0:c0.c1023 msg='op=PAM:setcred grantors=pam_env,pam_unix acct="root" exe="/usr/
Oct 04 13:47:53 localhost.localdomain sudo[2546]: pam_systemd(sudo:session): Cannot create session: Already running in a session
Oct 04 13:47:53 localhost.localdomain audit[2546]: USER_START pid=2546 uid=0 auid=0 ses=1 subj=unconfined_u:unconfined_r:unconfined_t:s0-s0:c0.c1023 msg='op=PAM:session_open grantors=pam_keyinit,pam_limits,pam_keyini
Oct 04 13:47:53 localhost.localdomain sudo[2546]: pam_unix(sudo:session): session opened for user root by root(uid=0)
Oct 04 13:47:53 localhost.localdomain systemd[1]: Starting nexus service...
-- Subject: Unit nexus.service has begun start-up
-- Defined-By: systemd
-- Support: https://lists.freedesktop.org/mailman/listinfo/systemd-devel
--
-- Unit nexus.service has begun starting up.
Oct 04 13:47:53 localhost.localdomain systemd[2549]: nexus.service: Failed at step EXEC spawning /opt/nexus/bin/nexus: Permission denied
-- Subject: Process /opt/nexus/bin/nexus could not be executed
-- Defined-By: systemd
-- Support: https://lists.freedesktop.org/mailman/listinfo/systemd-devel
--
-- The process /opt/nexus/bin/nexus could not be executed and failed.
--
-- The error number returned by this process is 13.
Oct 04 13:47:53 localhost.localdomain audit[2549]: AVC avc: denied { execute } for pid=2549 comm="(nexus)" name="nexus" dev="dm-0" ino=398592 scontext=system_u:system_r:init_t:s0 tcontext=unconfined_u:object_r:adm
Oct 04 13:47:53 localhost.localdomain audit[1]: SERVICE_START pid=1 uid=0 auid=4294967295 ses=4294967295 subj=system_u:system_r:init_t:s0 msg='unit=nexus comm="systemd" exe="/usr/lib/systemd/systemd" hostname=? addr=
Oct 04 13:47:53 localhost.localdomain systemd[1]: nexus.service: Control process exited, code=exited status=203
Oct 04 13:47:53 localhost.localdomain systemd[1]: Failed to start nexus service.
-- Subject: Unit nexus.service has failed
-- Defined-By: systemd
-- Support: https://lists.freedesktop.org/mailman/listinfo/systemd-devel
--
-- Unit nexus.service has failed.
--
-- The result is failed.
Oct 04 13:47:53 localhost.localdomain systemd[1]: nexus.service: Unit entered failed state.
Oct 04 13:47:53 localhost.localdomain systemd[1]: nexus.service: Failed with result 'exit-code'.
Oct 04 13:47:53 localhost.localdomain sudo[2546]: pam_unix(sudo:session): session closed for user root
Oct 04 13:47:53 localhost.localdomain audit[2546]: USER_END pid=2546 uid=0 auid=0 ses=1 subj=unconfined_u:unconfined_r:unconfined_t:s0-s0:c0.c1023 msg='op=PAM:session_close grantors=pam_keyinit,pam_limits,pam_keyinit
Oct 04 13:47:53 localhost.localdomain audit[2546]: CRED_DISP pid=2546 uid=0 auid=0 ses=1 subj=unconfined_u:unconfined_r:unconfined_t:s0-s0:c0.c1023 msg='op=PAM:setcred grantors=pam_env,pam_unix acct="root" exe="/usr/
l
UPDATE: I discovered that disabling selinx, i.e. setenforce 0
allows for managing the service, but I don't want to do this as a long term solution.
here are a few lines from /var/log/audit/audit.log
type=AVC msg=audit(1507473817.658:193): avc: denied { execute } for pid=975 comm="(nexus)" name="nexus" dev="dm-0" ino=398592 scontext=system_u:system_r:init_t:s0 tcontext=unconfined_u:object_r:admin_home_t:s0 tclass=file permissive=0
type=SERVICE_START msg=audit(1507473817.660:194): pid=1 uid=0 auid=4294967295 ses=4294967295 subj=system_u:system_r:init_t:s0 msg='unit=nexus comm="systemd" exe="/usr/lib/systemd/systemd" hostname=? addr=? terminal=? res=failed'
type=AVC msg=audit(1507474250.245:195): avc: denied { execute } for pid=1052 comm="(nexus)" name="nexus" dev="dm-0" ino=398592 scontext=system_u:system_r:init_t:s0 tcontext=unconfined_u:object_r:unconfined_exec_t:s0 tclass=file permissive=0
type=SERVICE_START msg=audit(1507474250.246:196): pid=1 uid=0 auid=4294967295 ses=4294967295 subj=system_u:system_r:init_t:s0 msg='unit=nexus comm="systemd" exe="/usr/lib/systemd/systemd" hostname=? addr=? terminal=? res=failed'
Any chance someone can help from here?
selinux
bumped to the homepage by Community♦ 4 mins ago
This question has answers that may be good or bad; the system has marked it active so that they can be reviewed.
add a comment |
After installing the latest version of nexus, currently 3.6.0, I'm able to start it by using the manual command
/opt/nexus/bin/nexus start
but when trying to start as a service (per directions https://help.sonatype.com/display/NXRM3/Installation#Installation-RunningtheService), I get the following:
Oct 04 13:47:53 localhost.localdomain sudo[2546]: root : TTY=pts/0 ; PWD=/root ; USER=root ; COMMAND=/bin/systemctl start nexus.service
Oct 04 13:47:53 localhost.localdomain audit[2546]: USER_CMD pid=2546 uid=0 auid=0 ses=1 subj=unconfined_u:unconfined_r:unconfined_t:s0-s0:c0.c1023 msg='cwd="/root" cmd=73797374656D63746C207374617274206E657875732E7365
Oct 04 13:47:53 localhost.localdomain audit[2546]: CRED_REFR pid=2546 uid=0 auid=0 ses=1 subj=unconfined_u:unconfined_r:unconfined_t:s0-s0:c0.c1023 msg='op=PAM:setcred grantors=pam_env,pam_unix acct="root" exe="/usr/
Oct 04 13:47:53 localhost.localdomain sudo[2546]: pam_systemd(sudo:session): Cannot create session: Already running in a session
Oct 04 13:47:53 localhost.localdomain audit[2546]: USER_START pid=2546 uid=0 auid=0 ses=1 subj=unconfined_u:unconfined_r:unconfined_t:s0-s0:c0.c1023 msg='op=PAM:session_open grantors=pam_keyinit,pam_limits,pam_keyini
Oct 04 13:47:53 localhost.localdomain sudo[2546]: pam_unix(sudo:session): session opened for user root by root(uid=0)
Oct 04 13:47:53 localhost.localdomain systemd[1]: Starting nexus service...
-- Subject: Unit nexus.service has begun start-up
-- Defined-By: systemd
-- Support: https://lists.freedesktop.org/mailman/listinfo/systemd-devel
--
-- Unit nexus.service has begun starting up.
Oct 04 13:47:53 localhost.localdomain systemd[2549]: nexus.service: Failed at step EXEC spawning /opt/nexus/bin/nexus: Permission denied
-- Subject: Process /opt/nexus/bin/nexus could not be executed
-- Defined-By: systemd
-- Support: https://lists.freedesktop.org/mailman/listinfo/systemd-devel
--
-- The process /opt/nexus/bin/nexus could not be executed and failed.
--
-- The error number returned by this process is 13.
Oct 04 13:47:53 localhost.localdomain audit[2549]: AVC avc: denied { execute } for pid=2549 comm="(nexus)" name="nexus" dev="dm-0" ino=398592 scontext=system_u:system_r:init_t:s0 tcontext=unconfined_u:object_r:adm
Oct 04 13:47:53 localhost.localdomain audit[1]: SERVICE_START pid=1 uid=0 auid=4294967295 ses=4294967295 subj=system_u:system_r:init_t:s0 msg='unit=nexus comm="systemd" exe="/usr/lib/systemd/systemd" hostname=? addr=
Oct 04 13:47:53 localhost.localdomain systemd[1]: nexus.service: Control process exited, code=exited status=203
Oct 04 13:47:53 localhost.localdomain systemd[1]: Failed to start nexus service.
-- Subject: Unit nexus.service has failed
-- Defined-By: systemd
-- Support: https://lists.freedesktop.org/mailman/listinfo/systemd-devel
--
-- Unit nexus.service has failed.
--
-- The result is failed.
Oct 04 13:47:53 localhost.localdomain systemd[1]: nexus.service: Unit entered failed state.
Oct 04 13:47:53 localhost.localdomain systemd[1]: nexus.service: Failed with result 'exit-code'.
Oct 04 13:47:53 localhost.localdomain sudo[2546]: pam_unix(sudo:session): session closed for user root
Oct 04 13:47:53 localhost.localdomain audit[2546]: USER_END pid=2546 uid=0 auid=0 ses=1 subj=unconfined_u:unconfined_r:unconfined_t:s0-s0:c0.c1023 msg='op=PAM:session_close grantors=pam_keyinit,pam_limits,pam_keyinit
Oct 04 13:47:53 localhost.localdomain audit[2546]: CRED_DISP pid=2546 uid=0 auid=0 ses=1 subj=unconfined_u:unconfined_r:unconfined_t:s0-s0:c0.c1023 msg='op=PAM:setcred grantors=pam_env,pam_unix acct="root" exe="/usr/
l
UPDATE: I discovered that disabling selinx, i.e. setenforce 0
allows for managing the service, but I don't want to do this as a long term solution.
here are a few lines from /var/log/audit/audit.log
type=AVC msg=audit(1507473817.658:193): avc: denied { execute } for pid=975 comm="(nexus)" name="nexus" dev="dm-0" ino=398592 scontext=system_u:system_r:init_t:s0 tcontext=unconfined_u:object_r:admin_home_t:s0 tclass=file permissive=0
type=SERVICE_START msg=audit(1507473817.660:194): pid=1 uid=0 auid=4294967295 ses=4294967295 subj=system_u:system_r:init_t:s0 msg='unit=nexus comm="systemd" exe="/usr/lib/systemd/systemd" hostname=? addr=? terminal=? res=failed'
type=AVC msg=audit(1507474250.245:195): avc: denied { execute } for pid=1052 comm="(nexus)" name="nexus" dev="dm-0" ino=398592 scontext=system_u:system_r:init_t:s0 tcontext=unconfined_u:object_r:unconfined_exec_t:s0 tclass=file permissive=0
type=SERVICE_START msg=audit(1507474250.246:196): pid=1 uid=0 auid=4294967295 ses=4294967295 subj=system_u:system_r:init_t:s0 msg='unit=nexus comm="systemd" exe="/usr/lib/systemd/systemd" hostname=? addr=? terminal=? res=failed'
Any chance someone can help from here?
selinux
bumped to the homepage by Community♦ 4 mins ago
This question has answers that may be good or bad; the system has marked it active so that they can be reviewed.
1
You might have wrong file contexts for the files in/opt/nexus
, could try relabeling those files withrestorecon
. For more detailed explanation, see the answer for How to configure SELinux to allow daemons to use files in non-default locations
– sebasth
Oct 8 '17 at 20:20
Please delete your duplicate question on Stack Overflow.
– Rob
Oct 9 '17 at 1:05
add a comment |
After installing the latest version of nexus, currently 3.6.0, I'm able to start it by using the manual command
/opt/nexus/bin/nexus start
but when trying to start as a service (per directions https://help.sonatype.com/display/NXRM3/Installation#Installation-RunningtheService), I get the following:
Oct 04 13:47:53 localhost.localdomain sudo[2546]: root : TTY=pts/0 ; PWD=/root ; USER=root ; COMMAND=/bin/systemctl start nexus.service
Oct 04 13:47:53 localhost.localdomain audit[2546]: USER_CMD pid=2546 uid=0 auid=0 ses=1 subj=unconfined_u:unconfined_r:unconfined_t:s0-s0:c0.c1023 msg='cwd="/root" cmd=73797374656D63746C207374617274206E657875732E7365
Oct 04 13:47:53 localhost.localdomain audit[2546]: CRED_REFR pid=2546 uid=0 auid=0 ses=1 subj=unconfined_u:unconfined_r:unconfined_t:s0-s0:c0.c1023 msg='op=PAM:setcred grantors=pam_env,pam_unix acct="root" exe="/usr/
Oct 04 13:47:53 localhost.localdomain sudo[2546]: pam_systemd(sudo:session): Cannot create session: Already running in a session
Oct 04 13:47:53 localhost.localdomain audit[2546]: USER_START pid=2546 uid=0 auid=0 ses=1 subj=unconfined_u:unconfined_r:unconfined_t:s0-s0:c0.c1023 msg='op=PAM:session_open grantors=pam_keyinit,pam_limits,pam_keyini
Oct 04 13:47:53 localhost.localdomain sudo[2546]: pam_unix(sudo:session): session opened for user root by root(uid=0)
Oct 04 13:47:53 localhost.localdomain systemd[1]: Starting nexus service...
-- Subject: Unit nexus.service has begun start-up
-- Defined-By: systemd
-- Support: https://lists.freedesktop.org/mailman/listinfo/systemd-devel
--
-- Unit nexus.service has begun starting up.
Oct 04 13:47:53 localhost.localdomain systemd[2549]: nexus.service: Failed at step EXEC spawning /opt/nexus/bin/nexus: Permission denied
-- Subject: Process /opt/nexus/bin/nexus could not be executed
-- Defined-By: systemd
-- Support: https://lists.freedesktop.org/mailman/listinfo/systemd-devel
--
-- The process /opt/nexus/bin/nexus could not be executed and failed.
--
-- The error number returned by this process is 13.
Oct 04 13:47:53 localhost.localdomain audit[2549]: AVC avc: denied { execute } for pid=2549 comm="(nexus)" name="nexus" dev="dm-0" ino=398592 scontext=system_u:system_r:init_t:s0 tcontext=unconfined_u:object_r:adm
Oct 04 13:47:53 localhost.localdomain audit[1]: SERVICE_START pid=1 uid=0 auid=4294967295 ses=4294967295 subj=system_u:system_r:init_t:s0 msg='unit=nexus comm="systemd" exe="/usr/lib/systemd/systemd" hostname=? addr=
Oct 04 13:47:53 localhost.localdomain systemd[1]: nexus.service: Control process exited, code=exited status=203
Oct 04 13:47:53 localhost.localdomain systemd[1]: Failed to start nexus service.
-- Subject: Unit nexus.service has failed
-- Defined-By: systemd
-- Support: https://lists.freedesktop.org/mailman/listinfo/systemd-devel
--
-- Unit nexus.service has failed.
--
-- The result is failed.
Oct 04 13:47:53 localhost.localdomain systemd[1]: nexus.service: Unit entered failed state.
Oct 04 13:47:53 localhost.localdomain systemd[1]: nexus.service: Failed with result 'exit-code'.
Oct 04 13:47:53 localhost.localdomain sudo[2546]: pam_unix(sudo:session): session closed for user root
Oct 04 13:47:53 localhost.localdomain audit[2546]: USER_END pid=2546 uid=0 auid=0 ses=1 subj=unconfined_u:unconfined_r:unconfined_t:s0-s0:c0.c1023 msg='op=PAM:session_close grantors=pam_keyinit,pam_limits,pam_keyinit
Oct 04 13:47:53 localhost.localdomain audit[2546]: CRED_DISP pid=2546 uid=0 auid=0 ses=1 subj=unconfined_u:unconfined_r:unconfined_t:s0-s0:c0.c1023 msg='op=PAM:setcred grantors=pam_env,pam_unix acct="root" exe="/usr/
l
UPDATE: I discovered that disabling selinx, i.e. setenforce 0
allows for managing the service, but I don't want to do this as a long term solution.
here are a few lines from /var/log/audit/audit.log
type=AVC msg=audit(1507473817.658:193): avc: denied { execute } for pid=975 comm="(nexus)" name="nexus" dev="dm-0" ino=398592 scontext=system_u:system_r:init_t:s0 tcontext=unconfined_u:object_r:admin_home_t:s0 tclass=file permissive=0
type=SERVICE_START msg=audit(1507473817.660:194): pid=1 uid=0 auid=4294967295 ses=4294967295 subj=system_u:system_r:init_t:s0 msg='unit=nexus comm="systemd" exe="/usr/lib/systemd/systemd" hostname=? addr=? terminal=? res=failed'
type=AVC msg=audit(1507474250.245:195): avc: denied { execute } for pid=1052 comm="(nexus)" name="nexus" dev="dm-0" ino=398592 scontext=system_u:system_r:init_t:s0 tcontext=unconfined_u:object_r:unconfined_exec_t:s0 tclass=file permissive=0
type=SERVICE_START msg=audit(1507474250.246:196): pid=1 uid=0 auid=4294967295 ses=4294967295 subj=system_u:system_r:init_t:s0 msg='unit=nexus comm="systemd" exe="/usr/lib/systemd/systemd" hostname=? addr=? terminal=? res=failed'
Any chance someone can help from here?
selinux
After installing the latest version of nexus, currently 3.6.0, I'm able to start it by using the manual command
/opt/nexus/bin/nexus start
but when trying to start as a service (per directions https://help.sonatype.com/display/NXRM3/Installation#Installation-RunningtheService), I get the following:
Oct 04 13:47:53 localhost.localdomain sudo[2546]: root : TTY=pts/0 ; PWD=/root ; USER=root ; COMMAND=/bin/systemctl start nexus.service
Oct 04 13:47:53 localhost.localdomain audit[2546]: USER_CMD pid=2546 uid=0 auid=0 ses=1 subj=unconfined_u:unconfined_r:unconfined_t:s0-s0:c0.c1023 msg='cwd="/root" cmd=73797374656D63746C207374617274206E657875732E7365
Oct 04 13:47:53 localhost.localdomain audit[2546]: CRED_REFR pid=2546 uid=0 auid=0 ses=1 subj=unconfined_u:unconfined_r:unconfined_t:s0-s0:c0.c1023 msg='op=PAM:setcred grantors=pam_env,pam_unix acct="root" exe="/usr/
Oct 04 13:47:53 localhost.localdomain sudo[2546]: pam_systemd(sudo:session): Cannot create session: Already running in a session
Oct 04 13:47:53 localhost.localdomain audit[2546]: USER_START pid=2546 uid=0 auid=0 ses=1 subj=unconfined_u:unconfined_r:unconfined_t:s0-s0:c0.c1023 msg='op=PAM:session_open grantors=pam_keyinit,pam_limits,pam_keyini
Oct 04 13:47:53 localhost.localdomain sudo[2546]: pam_unix(sudo:session): session opened for user root by root(uid=0)
Oct 04 13:47:53 localhost.localdomain systemd[1]: Starting nexus service...
-- Subject: Unit nexus.service has begun start-up
-- Defined-By: systemd
-- Support: https://lists.freedesktop.org/mailman/listinfo/systemd-devel
--
-- Unit nexus.service has begun starting up.
Oct 04 13:47:53 localhost.localdomain systemd[2549]: nexus.service: Failed at step EXEC spawning /opt/nexus/bin/nexus: Permission denied
-- Subject: Process /opt/nexus/bin/nexus could not be executed
-- Defined-By: systemd
-- Support: https://lists.freedesktop.org/mailman/listinfo/systemd-devel
--
-- The process /opt/nexus/bin/nexus could not be executed and failed.
--
-- The error number returned by this process is 13.
Oct 04 13:47:53 localhost.localdomain audit[2549]: AVC avc: denied { execute } for pid=2549 comm="(nexus)" name="nexus" dev="dm-0" ino=398592 scontext=system_u:system_r:init_t:s0 tcontext=unconfined_u:object_r:adm
Oct 04 13:47:53 localhost.localdomain audit[1]: SERVICE_START pid=1 uid=0 auid=4294967295 ses=4294967295 subj=system_u:system_r:init_t:s0 msg='unit=nexus comm="systemd" exe="/usr/lib/systemd/systemd" hostname=? addr=
Oct 04 13:47:53 localhost.localdomain systemd[1]: nexus.service: Control process exited, code=exited status=203
Oct 04 13:47:53 localhost.localdomain systemd[1]: Failed to start nexus service.
-- Subject: Unit nexus.service has failed
-- Defined-By: systemd
-- Support: https://lists.freedesktop.org/mailman/listinfo/systemd-devel
--
-- Unit nexus.service has failed.
--
-- The result is failed.
Oct 04 13:47:53 localhost.localdomain systemd[1]: nexus.service: Unit entered failed state.
Oct 04 13:47:53 localhost.localdomain systemd[1]: nexus.service: Failed with result 'exit-code'.
Oct 04 13:47:53 localhost.localdomain sudo[2546]: pam_unix(sudo:session): session closed for user root
Oct 04 13:47:53 localhost.localdomain audit[2546]: USER_END pid=2546 uid=0 auid=0 ses=1 subj=unconfined_u:unconfined_r:unconfined_t:s0-s0:c0.c1023 msg='op=PAM:session_close grantors=pam_keyinit,pam_limits,pam_keyinit
Oct 04 13:47:53 localhost.localdomain audit[2546]: CRED_DISP pid=2546 uid=0 auid=0 ses=1 subj=unconfined_u:unconfined_r:unconfined_t:s0-s0:c0.c1023 msg='op=PAM:setcred grantors=pam_env,pam_unix acct="root" exe="/usr/
l
UPDATE: I discovered that disabling selinx, i.e. setenforce 0
allows for managing the service, but I don't want to do this as a long term solution.
here are a few lines from /var/log/audit/audit.log
type=AVC msg=audit(1507473817.658:193): avc: denied { execute } for pid=975 comm="(nexus)" name="nexus" dev="dm-0" ino=398592 scontext=system_u:system_r:init_t:s0 tcontext=unconfined_u:object_r:admin_home_t:s0 tclass=file permissive=0
type=SERVICE_START msg=audit(1507473817.660:194): pid=1 uid=0 auid=4294967295 ses=4294967295 subj=system_u:system_r:init_t:s0 msg='unit=nexus comm="systemd" exe="/usr/lib/systemd/systemd" hostname=? addr=? terminal=? res=failed'
type=AVC msg=audit(1507474250.245:195): avc: denied { execute } for pid=1052 comm="(nexus)" name="nexus" dev="dm-0" ino=398592 scontext=system_u:system_r:init_t:s0 tcontext=unconfined_u:object_r:unconfined_exec_t:s0 tclass=file permissive=0
type=SERVICE_START msg=audit(1507474250.246:196): pid=1 uid=0 auid=4294967295 ses=4294967295 subj=system_u:system_r:init_t:s0 msg='unit=nexus comm="systemd" exe="/usr/lib/systemd/systemd" hostname=? addr=? terminal=? res=failed'
Any chance someone can help from here?
selinux
selinux
asked Oct 8 '17 at 19:53
swvswv
204129
204129
bumped to the homepage by Community♦ 4 mins ago
This question has answers that may be good or bad; the system has marked it active so that they can be reviewed.
bumped to the homepage by Community♦ 4 mins ago
This question has answers that may be good or bad; the system has marked it active so that they can be reviewed.
1
You might have wrong file contexts for the files in/opt/nexus
, could try relabeling those files withrestorecon
. For more detailed explanation, see the answer for How to configure SELinux to allow daemons to use files in non-default locations
– sebasth
Oct 8 '17 at 20:20
Please delete your duplicate question on Stack Overflow.
– Rob
Oct 9 '17 at 1:05
add a comment |
1
You might have wrong file contexts for the files in/opt/nexus
, could try relabeling those files withrestorecon
. For more detailed explanation, see the answer for How to configure SELinux to allow daemons to use files in non-default locations
– sebasth
Oct 8 '17 at 20:20
Please delete your duplicate question on Stack Overflow.
– Rob
Oct 9 '17 at 1:05
1
1
You might have wrong file contexts for the files in
/opt/nexus
, could try relabeling those files with restorecon
. For more detailed explanation, see the answer for How to configure SELinux to allow daemons to use files in non-default locations– sebasth
Oct 8 '17 at 20:20
You might have wrong file contexts for the files in
/opt/nexus
, could try relabeling those files with restorecon
. For more detailed explanation, see the answer for How to configure SELinux to allow daemons to use files in non-default locations– sebasth
Oct 8 '17 at 20:20
Please delete your duplicate question on Stack Overflow.
– Rob
Oct 9 '17 at 1:05
Please delete your duplicate question on Stack Overflow.
– Rob
Oct 9 '17 at 1:05
add a comment |
1 Answer
1
active
oldest
votes
I have to suggest an answer after burning some time on this issue. I had the same issue as cited above. My OS is RHEL 7.5 with SELinux set to enforcing. Nexus version is 3.13.0-01.
The nexus service with systemd was defined as identified by
Sonatype. See Sonatype instructions for running a systemd service here: https://help.sonatype.com/repomanager3/installation/run-as-a-service
The service using nexus.service definition from that page starts up but the eventually reaches a timeout and is shutdown. The service type of forking Forking type waits some time for the parent process to exit but it this event apparently does not happen. I didn't contact Sonatype but since this question was not addressed, I am adding a solution that worked.
To resolve the issue I changed the type from forking to simple in the nexus.service file.
add a comment |
Your Answer
StackExchange.ready(function() {
var channelOptions = {
tags: "".split(" "),
id: "106"
};
initTagRenderer("".split(" "), "".split(" "), channelOptions);
StackExchange.using("externalEditor", function() {
// Have to fire editor after snippets, if snippets enabled
if (StackExchange.settings.snippets.snippetsEnabled) {
StackExchange.using("snippets", function() {
createEditor();
});
}
else {
createEditor();
}
});
function createEditor() {
StackExchange.prepareEditor({
heartbeatType: 'answer',
autoActivateHeartbeat: false,
convertImagesToLinks: false,
noModals: true,
showLowRepImageUploadWarning: true,
reputationToPostImages: null,
bindNavPrevention: true,
postfix: "",
imageUploader: {
brandingHtml: "Powered by u003ca class="icon-imgur-white" href="https://imgur.com/"u003eu003c/au003e",
contentPolicyHtml: "User contributions licensed under u003ca href="https://creativecommons.org/licenses/by-sa/3.0/"u003ecc by-sa 3.0 with attribution requiredu003c/au003e u003ca href="https://stackoverflow.com/legal/content-policy"u003e(content policy)u003c/au003e",
allowUrls: true
},
onDemand: true,
discardSelector: ".discard-answer"
,immediatelyShowMarkdownHelp:true
});
}
});
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
StackExchange.ready(
function () {
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2funix.stackexchange.com%2fquestions%2f396894%2fselinux-is-causing-nexus-service-failed-at-step-exec-spawning-opt-nexus-bin-n%23new-answer', 'question_page');
}
);
Post as a guest
Required, but never shown
1 Answer
1
active
oldest
votes
1 Answer
1
active
oldest
votes
active
oldest
votes
active
oldest
votes
I have to suggest an answer after burning some time on this issue. I had the same issue as cited above. My OS is RHEL 7.5 with SELinux set to enforcing. Nexus version is 3.13.0-01.
The nexus service with systemd was defined as identified by
Sonatype. See Sonatype instructions for running a systemd service here: https://help.sonatype.com/repomanager3/installation/run-as-a-service
The service using nexus.service definition from that page starts up but the eventually reaches a timeout and is shutdown. The service type of forking Forking type waits some time for the parent process to exit but it this event apparently does not happen. I didn't contact Sonatype but since this question was not addressed, I am adding a solution that worked.
To resolve the issue I changed the type from forking to simple in the nexus.service file.
add a comment |
I have to suggest an answer after burning some time on this issue. I had the same issue as cited above. My OS is RHEL 7.5 with SELinux set to enforcing. Nexus version is 3.13.0-01.
The nexus service with systemd was defined as identified by
Sonatype. See Sonatype instructions for running a systemd service here: https://help.sonatype.com/repomanager3/installation/run-as-a-service
The service using nexus.service definition from that page starts up but the eventually reaches a timeout and is shutdown. The service type of forking Forking type waits some time for the parent process to exit but it this event apparently does not happen. I didn't contact Sonatype but since this question was not addressed, I am adding a solution that worked.
To resolve the issue I changed the type from forking to simple in the nexus.service file.
add a comment |
I have to suggest an answer after burning some time on this issue. I had the same issue as cited above. My OS is RHEL 7.5 with SELinux set to enforcing. Nexus version is 3.13.0-01.
The nexus service with systemd was defined as identified by
Sonatype. See Sonatype instructions for running a systemd service here: https://help.sonatype.com/repomanager3/installation/run-as-a-service
The service using nexus.service definition from that page starts up but the eventually reaches a timeout and is shutdown. The service type of forking Forking type waits some time for the parent process to exit but it this event apparently does not happen. I didn't contact Sonatype but since this question was not addressed, I am adding a solution that worked.
To resolve the issue I changed the type from forking to simple in the nexus.service file.
I have to suggest an answer after burning some time on this issue. I had the same issue as cited above. My OS is RHEL 7.5 with SELinux set to enforcing. Nexus version is 3.13.0-01.
The nexus service with systemd was defined as identified by
Sonatype. See Sonatype instructions for running a systemd service here: https://help.sonatype.com/repomanager3/installation/run-as-a-service
The service using nexus.service definition from that page starts up but the eventually reaches a timeout and is shutdown. The service type of forking Forking type waits some time for the parent process to exit but it this event apparently does not happen. I didn't contact Sonatype but since this question was not addressed, I am adding a solution that worked.
To resolve the issue I changed the type from forking to simple in the nexus.service file.
edited Oct 2 '18 at 17:36
user88036
answered Oct 2 '18 at 17:13
Ben PazBen Paz
1
1
add a comment |
add a comment |
Thanks for contributing an answer to Unix & Linux Stack Exchange!
- Please be sure to answer the question. Provide details and share your research!
But avoid …
- Asking for help, clarification, or responding to other answers.
- Making statements based on opinion; back them up with references or personal experience.
To learn more, see our tips on writing great answers.
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
StackExchange.ready(
function () {
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2funix.stackexchange.com%2fquestions%2f396894%2fselinux-is-causing-nexus-service-failed-at-step-exec-spawning-opt-nexus-bin-n%23new-answer', 'question_page');
}
);
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
1
You might have wrong file contexts for the files in
/opt/nexus
, could try relabeling those files withrestorecon
. For more detailed explanation, see the answer for How to configure SELinux to allow daemons to use files in non-default locations– sebasth
Oct 8 '17 at 20:20
Please delete your duplicate question on Stack Overflow.
– Rob
Oct 9 '17 at 1:05