[SERVER-33146] mongod.service does not source system-wide environment variables as stated in the documentation Created: 06/Feb/18  Updated: 29/Oct/23  Resolved: 03/May/18

Status: Closed
Project: Core Server
Component/s: Packaging
Affects Version/s: 3.2.19, 3.4.11, 3.6.2
Fix Version/s: 4.0.0-rc0

Type: Bug Priority: Major - P3
Reporter: Vick Mena (Inactive) Assignee: Mathew Robinson (Inactive)
Resolution: Fixed Votes: 0
Labels: None
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified

Backwards Compatibility: Fully Compatible
Operating System: ALL
Steps To Reproduce:
  • yum install mongodb-enterprise
  • Add kerberos options to /etc/mongod.conf
  • Create keytab
  • Create /etc/sysconfig/mongod with env vars
  • Start service (systemctl start mongod)
Sprint: Build 2018-05-07
Participants:
Case:
Story Points: 3

 Description   

Following the Kerberos tutorial I am unable to configure the keytab environment variable for the rpm installed mongod.

The service file does not source /etc/sysconfig/mongod

As a workaround I modified the service file to include

Environment="KRB5_TRACE=/path/to/krb5.log"
Environment="KRB5_KTNAME=/path/to/keytab"



 Comments   
Comment by Githook User [ 03/May/18 ]

Author:

{'email': 'chasinglogic@gmail.com', 'name': 'Mathew Robinson', 'username': 'chasinglogic'}

Message: SERVER-33146 Source /etc/sysconfig/mongod in service file
Branch: master
https://github.com/mongodb/mongo/commit/91db8033a2ddc65b682d16f46fc00cde7949e9fc

Generated at Thu Feb 08 04:32:28 UTC 2024 using Jira 9.7.1#970001-sha1:2222b88b221c4928ef0de3161136cc90c8356a66.