Link to home
Start Free TrialLog in
Avatar of elthamcollege
elthamcollege

asked on

Upgrading 7.1 to 7.5 XenDesktop fails when running the database upgrade script

Hi,
 
We are upgrading our XenDesktop environment from 7.1 to 7.6. Following the recommended steps when we ran the database upgrade script after launching Studio for the first time the DB upgrade appeared to complete OK but failed at the end with the following:
Error Id: XDDS:DA11D207
 
Exception:
    Citrix.Console.Models.Exceptions.ScriptException Failed to upload database scripts
       at Citrix.Console.PowerShellSdk.UpgradeService.UpgradeTasks.DatabaseUpgradeTask.UpgradeDatabases(IList`1 scripts, IProgressReporter applyDbScriptProgress, ITaskLogger taskLogger)
       at Citrix.Console.PowerShellSdk.UpgradeService.UpgradeTasks.DatabaseUpgradeTask.DoImpersonatedWork(Action work)
       at Citrix.Console.PowerShellSdk.UpgradeService.UpgradeTasks.DatabaseUpgradeTask.RunUpgradeTask(IProgressReporter progressReporter, ITaskLogger taskLogger)
       at Citrix.Console.PowerShellSdk.UpgradeService.UpgradeTasks.UpgradeTaskBase.RunUpgrade(IProgressReporter progressReporter, ITaskLogger taskLogger)
       at Citrix.Console.PowerShellSdk.UpgradeService.UpgradeTasks.ServiceUpgradeTask.RunUpgradeTask(IProgressReporter progressReporter, ITaskLogger taskLogger)
       at Citrix.Console.PowerShellSdk.UpgradeService.UpgradeTasks.UpgradeTaskBase.RunUpgrade(IProgressReporter progressReporter, ITaskLogger taskLogger)
       at Citrix.Console.PowerShellSdk.UpgradeService.UpgradeTasks.Upgrade.RunUpgradeTask(IProgressReporter progressReporter, ITaskLogger taskLogger)
       at Citrix.Console.PowerShellSdk.UpgradeService.UpgradeTasks.UpgradeTaskBase.RunUpgrade(IProgressReporter progressReporter, ITaskLogger taskLogger)
       at Citrix.Console.DeliveryCenter.UI.Mmc.UpgradeResultPaneViewModel.UpgradeTask(IProgressReporter progressReporter, UserCredentials databaseCredentials)
       at Citrix.Console.CommonControls.ProgressDisplay.GenericProgressOperationWithFeedBack.PerformOperationInternal()
       at Citrix.Console.CommonControls.ProgressDisplay.ProgressWindowOperation.PerformOperation()
       at Citrix.Console.CommonControls.ProgressDisplay.ProgressWindowViewModel.PerformAction(Action operationComplete)
   
    DesktopStudio_ErrorId : UnknownError
    ErrorCategory : NotSpecified
   
Inner Exception:
    Microsoft.SqlServer.Management.Smo.FailedOperationException ExecuteNonQuery failed for Database 'CitrixXenDesktopDB'.
       at Microsoft.SqlServer.Management.Smo.Database.ExecuteNonQuery(StringCollection sqlCommands, ExecutionTypes executionType)
       at Citrix.Console.PowerShellSdk.UpgradeService.UpgradeTasks.DatabaseUpgradeTask.ApplySqlUpdate(String script, DataStoreModel appliesTo)
       at Citrix.Console.PowerShellSdk.UpgradeService.UpgradeTasks.DatabaseUpgradeTask.UpgradeDatabases(IList`1 scripts, IProgressReporter applyDbScriptProgress, ITaskLogger taskLogger)
   
    HelpLink.ProdName : Microsoft SQL Server
    HelpLink.BaseHelpUrl : http://go.microsoft.com/fwlink
    HelpLink.LinkId : 20476
    HelpLink.ProdVer : 11.0.3000.0 ((SQL11_PCU_Main).121019-1322 )
    HelpLink.EvtSrc : Microsoft.SqlServer.Management.Smo.ExceptionTemplates.FailedOperationExceptionText
    HelpLink.EvtData1 : ExecuteNonQuery
    HelpLink.EvtData2 : Database
   
Inner Exception:
    Microsoft.SqlServer.Management.Common.ExecutionFailureException An exception occurred while executing a Transact-SQL statement or batch.
       at Microsoft.SqlServer.Management.Common.ServerConnection.ExecuteNonQuery(String sqlCommand, ExecutionTypes executionType)
       at Microsoft.SqlServer.Management.Common.ServerConnection.ExecuteNonQuery(StringCollection sqlCommands, ExecutionTypes executionType)
       at Microsoft.SqlServer.Management.Smo.ExecutionManager.ExecuteNonQuery(StringCollection queries, ExecutionTypes executionType)
       at Microsoft.SqlServer.Management.Smo.Database.ExecuteNonQuery(StringCollection sqlCommands, ExecutionTypes executionType)
   
   
Inner Exception:
    System.Data.SqlClient.SqlException There is already an object named 'EnvTestServiceSchema' in the database.
    CREATE SCHEMA failed due to previous errors.
       at Microsoft.SqlServer.Management.Common.ConnectionManager.ExecuteTSql(ExecuteTSqlAction action, Object execObject, DataSet fillDataSet, Boolean catchException)
       at Microsoft.SqlServer.Management.Common.ServerConnection.ExecuteNonQuery(String sqlCommand, ExecutionTypes executionType)
   
    HelpLink.ProdName : Microsoft SQL Server
    HelpLink.ProdVer : 10.50.4000
    HelpLink.EvtSrc : MSSQLServer
    HelpLink.EvtID : 2714
    HelpLink.BaseHelpUrl : http://go.microsoft.com/fwlink
    HelpLink.LinkId : 20476
   
 
We've tried this thread but does not seem to work - http://discussions.citrix.com/topic/356640-site-upgrade-xendesktop-75-to-76-error-id-xddsc266bbdf/
 
I've googled for a few hours but don't seem to be getting anywhere.
 
Advice and suggestion welcomed.
 
Thanks
 
Damien
Avatar of Vitor Montalvão
Vitor Montalvão
Flag of Switzerland image

This problem is easy to solve in SQL Server (connect to the database and delete the schema 'EnvTestServiceSchema') but I don't know what is the impact in the XenDesktop.
Does your database name have any spaces?
Do you have separate databases for Site, Config Logging and Monitoring or are they still in the default config of all 3 databases combined?
Avatar of elthamcollege
elthamcollege

ASKER

Hi,

thanks for the replies.

No spaces in database and yes it is still the default config of all 3 databases combined.

Thanks

Damien
ASKER CERTIFIED SOLUTION
Avatar of Carl Webster
Carl Webster
Flag of United States of America image

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
Thanks for your input.
The only issue I have seen with upgrading a default database where all 3 DBs are still in the 1 default DB is where a space is in the DB name.  The monitoring DB will not work if it has a space in the name because the API that Director uses to read the monitoring DB crashes if there is a space in the DB name.
I have the same issue did you get a resolution on this?.