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

win_domain / win_domain_controller - log path missing #59348

Closed
AirCombat opened this issue Jul 21, 2019 · 8 comments · Fixed by #67448
Closed

win_domain / win_domain_controller - log path missing #59348

AirCombat opened this issue Jul 21, 2019 · 8 comments · Fixed by #67448
Labels
affects_2.8 This issue/PR affects Ansible v2.8 feature This issue/PR relates to a feature request. has_pr This issue has an associated PR. module This issue/PR relates to a module. support:core This issue/PR relates to code supported by the Ansible Engineering Team. windows Windows community

Comments

@AirCombat
Copy link
Contributor

AirCombat commented Jul 21, 2019

SUMMARY

The equivelent powershell command to win_domain includes the option to specify log path:

Install-ADDSForest `
-DatabasePath "D:\Windows\NTDS" `
-SysvolPath "D:\Windows\SYSVOL" `
-LogPath "E:\Windows\NTDS"

This has been missed in the win_domain module but SYSVOL and Database path are included, this is not consistent.
In addition to this, the win_domain_controller does not include it as a parameter in docs but it is in the examples! but also has no effect.

Should be an easy fix to make, otherwise please fix the example in docs. Would be greatly appreciated. The only way to change this is by rebooting into restore mode while AD if offline.

ISSUE TYPE
  • Feature Idea
COMPONENT NAME

win_domain
win_domain_controller

ANSIBLE VERSION
ansible 2.8.2
  config file = /Users/redacted/projects/project/ansible/ansible.cfg
  configured module search path = ['/Users/redacted/.ansible/plugins/modules', '/usr/share/ansible/plugins/modules']
  ansible python module location = /usr/local/Cellar/ansible/2.8.2/libexec/lib/python3.7/site-packages/ansible
  executable location = /usr/local/bin/ansible
  python version = 3.7.4 (default, Jul  9 2019, 18:13:23) [Clang 10.0.1 (clang-1001.0.46.4)]
CONFIGURATION

For example, the config below is ignored and the logs are in the C:\ drive

    win_domain:
      create_dns_delegation: no
      dns_domain_name: '{{ prod_domain_name }}'
      domain_netbios_name: '{{ prod_netbios }}'
      domain_mode: WinThreshold
      forest_mode: WinThreshold
      safe_mode_password: '{{ prod_dsrm_pass }}'
      database_path: D:\Windows\NTDS
      sysvol_path: D:\Windows\SYSVOL
      log_path: E:\Windows\NTDS
OS / ENVIRONMENT

Non OS Specific, Tested on Server 2019 and 2016

STEPS TO REPRODUCE

n/a

EXPECTED RESULTS

Logs go to E:\Windows\NTDS\ etc...

ACTUAL RESULTS

Logs go to %systemroot%\NTDS\

@AirCombat AirCombat changed the title win_domain log path missing win_domain / win_domain_controller - log path missing Jul 21, 2019
@ansibot
Copy link
Contributor

ansibot commented Jul 21, 2019

Files identified in the description:

If these files are inaccurate, please update the component name section of the description or use the !component bot command.

click here for bot help

@ansibot
Copy link
Contributor

ansibot commented Jul 21, 2019

@ansibot ansibot added affects_2.8 This issue/PR affects Ansible v2.8 bug This issue/PR relates to a bug. module This issue/PR relates to a module. needs_triage Needs a first human triage before being processed. python3 support:core This issue/PR relates to code supported by the Ansible Engineering Team. windows Windows community labels Jul 21, 2019
@ShachafGoldstein
Copy link
Contributor

ShachafGoldstein commented Jul 21, 2019

I don't see a log related parameter for win_domain.
The log for win_domain_controller is a debug log of the module if that is what you require, and it should be in the proper location

@ansibot ansibot removed the needs_triage Needs a first human triage before being processed. label Jul 21, 2019
@AirCombat
Copy link
Contributor Author

Thats the issue, there is no method to set the active directory log directory. This is a parameter for Install-ADDSForest and all other common parameters are included in the module. Why allow the module to specify sysvol and the database but not the db log path. :)

@jborean93 jborean93 added feature This issue/PR relates to a feature request. and removed bug This issue/PR relates to a bug. python3 labels Jul 21, 2019
@jborean93
Copy link
Contributor

Issue is a feature request not a bug, edited post to reflect this.

@jborean93
Copy link
Contributor

log_path for win_domain has been implemented with #66956. The win_domain_controller module is a lot more difficult because log_path is already used for another purpose and we can't just change it to be the LogPath parameter.

@jborean93
Copy link
Contributor

I've opened #67108 which deprecates the existing (previously undocumented) log_path option so in the future we can utilise that as the option for this functionality.

@jborean93
Copy link
Contributor

This has been implemented in win_domain_controller under the domain_log_path option due to the name collision with an existing variable. In the future we can also use log_path once that original deprecated option has been removed but that can't happen right now.

#67448

@ansible ansible locked and limited conversation to collaborators Mar 17, 2020
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
affects_2.8 This issue/PR affects Ansible v2.8 feature This issue/PR relates to a feature request. has_pr This issue has an associated PR. module This issue/PR relates to a module. support:core This issue/PR relates to code supported by the Ansible Engineering Team. windows Windows community
Projects
None yet
4 participants