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

Failed SMA install, rollback does not uninstall SQL database #32

Open
rchristman89 opened this issue Sep 4, 2019 · 2 comments
Open
Labels
enhancement The issue is an enhancement request. help wanted The issue is up for grabs for anyone in the community.

Comments

@rchristman89
Copy link

ISSUE TITLE: MSFT_xSCSMAWebServiceServerSetup SMA install fails, every other time resource fails because of existing database

ISSUE DESCRIPTION:
SMA install fails for various reasons and is the FirstWebServiceServer. The next time DSC runs it will fail because the database is already created. The rollback of the install does not seem to remove the database. 

Details of the scenario you tried and the problem that is occurring

SMA install was failing. Fixed the website folder issue and ran DSC again.
Once it ran again the resource would fail with a generic error, "Set-TargetResource failed". Looking in the logs it was failing because the database was already created.

Deleted the database, ran DSC again and SMA installed.

Verbose logs showing the problem

Suggested solution to the issue

It may be possible to delete the database on a fail install so that the database is no longer there on sequential runs.

The DSC configuration that is used to reproduce the issue (as detailed as possible)

N/A but FirstWebServiceServer is set to True

The operating system the target node is running

OsName : Microsoft Windows Server 2012 R2 Standard
OsOperatingSystemSKU : StandardServerEdition
OsArchitecture : 64-bit
WindowsBuildLabEx : 9600.19358.amd64fre.winblue_ltsb_escrow.190505-1600
OsLanguage : en-US
OsMuiLanguages : {en-US}

Version and build of PowerShell the target node is running

Name Value
PSVersion 5.1.14409.1018
PSEdition Desktop
PSCompatibleVersions {1.0, 2.0, 3.0, 4.0...}
BuildVersion 10.0.14409.1018
CLRVersion 4.0.30319.42000
WSManStackVersion 3.0
PSRemotingProtocolVersion 2.3
SerializationVersion 1.1.0.1

Version of the DSC module that was used ('dev' if using current dev branch)

dev

@devopsjesus
Copy link
Contributor

devopsjesus commented Sep 4, 2019

I'd be hesitant to remove a database that already exists without a property to confirm removal. If the database exists already, why is the create database property set to true? Sounds like a misconfiguration or infrastructure error.

@rchristman89
Copy link
Author

I'd be hesitant to remove a database that already exists without a property to confirm removal. If the database exists already, why is the create database property set to true? Sounds like a misconfiguration or infrastructure error.

I agree. The other option is before it sets CreateDatabase=Yes, check and see if there is an installed database already and not set it to Yes.

@johlju johlju added enhancement The issue is an enhancement request. help wanted The issue is up for grabs for anyone in the community. labels Jan 30, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement The issue is an enhancement request. help wanted The issue is up for grabs for anyone in the community.
Projects
None yet
Development

No branches or pull requests

3 participants