Службе SSAS не удается обработать куб без конкретного сообщения об ошибке

У меня есть куб SSAS, который я развертываю автоматически с помощью Octopus Deploy + некоторые сценарии PS.

Сценарий, развертывающий куб SSAS, приведен ниже:

function Deploy-Cube($databasePath)
{
    $executable = "C:\Program Files (x86)\Microsoft SQL Server\110\Tools\Binn\ManagementStudio\Microsoft.AnalysisServices.Deployment.exe"
    Write-Output "Deploying Cube"
    & $executable $databasePath "/s:Deploy.log"

    $process = Get-Process "Microsoft.AnalysisServices.Deployment"
    $process.WaitForExit()

    $log = Resolve-Path ".\Deploy.log"
    $output = [System.IO.File]::ReadAllText($log)

    if ($output.Contains("Error"))
    {
        Throw $output
    }
    else
    {
        $output | Write-Output
    }
}


$databasePath = $(Resolve-Path -Path ".\Cube.asdatabase").Path

Copy-Item ".\Cube.no-process.deploymentoptions" "Cube.deploymentoptions" -Force
Deploy-Cube -DatabasePath $databasePath

Copy-Item ".\Cube.full.deploymentoptions" "KK.Corporate.DataWarehouse.Cube.deploymentoptions" -Force
Deploy-Cube -DatabasePath $databasePath

Вывод из Deploy.log:

Connecting to the localhost server
Database, Cube, found on server, localhost. Applying configuration settings and options...
    Analyzing configuration settings...
    Done
    Analyzing optimization settings...
    Done
    Analyzing storage information...
    Done
    Analyzing security information...
    Done
Generating processing sequence...
Deploying the 'Cube' database to 'localhost'.
Internal error: The operation terminated unsuccessfully.
Server: The current operation was cancelled because another operation in the transaction failed.
Errors in the OLAP storage engine: An error occurred while the 'Dimension Item Id' attribute of the 'Sales' dimension from the 'Cube' database was being processed.
Errors in the OLAP storage engine: An error occurred while the 'Item Description' attribute of the 'Items' dimension from the 'Cube' database was being processed.
OLE DB error: OLE DB or ODBC error: Operation canceled; HY008.
Errors in the OLAP storage engine: An error occurred while the dimension, with the ID of 'Dimension Dates', Name of 'Dates' was being processed.
Errors in the OLAP storage engine: An error occurred while the 'Week' attribute of the 'Dates' dimension from the 'Cube' database was being processed.
OLE DB error: OLE DB or ODBC error: Operation canceled; HY008.
Errors in the OLAP storage engine: An error occurred while the dimension, with the ID of 'Dimension Items', Name of 'Items' was being processed.
Errors in the OLAP storage engine: An error occurred while the 'Category' attribute of the 'Items' dimension from the 'Cube' database was being processed.
OLE DB error: OLE DB or ODBC error: Operation canceled; HY008.
Errors in the OLAP storage engine: An error occurred while the dimension, with the ID of 'SalesTransactions', Name of 'SalesTransactions' was being processed.
Errors in the OLAP storage engine: An error occurred while the 'Transaction Key' attribute of the 'SalesTransactions' dimension from the 'Cube' database was being processed.
Errors in the OLAP storage engine: An error occurred while the 'Dimension Time Id' attribute of the 'Sales' dimension from the 'Cube' database was being processed.
Errors in the OLAP storage engine: An error occurred while the 'Dimension Time Id' attribute of the 'Times' dimension from the 'Cube' database was being processed.

Вывод из журнала SSAS:

(12/8/2014 12:24:42 PM) Message: OLE DB error: OLE DB or ODBC error: Operation canceled; HY008. (Source: \\?\C:\Program Files\Microsoft SQL Server\MSAS11.MSSQLSERVER\OLAP\Log\msmdsrv.log, Type: 3, Category: 289, Event ID: 0xC1210003)
(12/8/2014 12:24:42 PM) Message: OLE DB error: OLE DB or ODBC error: Operation canceled; HY008. (Source: \\?\C:\Program Files\Microsoft SQL Server\MSAS11.MSSQLSERVER\OLAP\Log\msmdsrv.log, Type: 3, Category: 289, Event ID: 0xC1210003)
(12/8/2014 12:24:42 PM) Message: OLE DB error: OLE DB or ODBC error: Operation canceled; HY008. (Source: \\?\C:\Program Files\Microsoft SQL Server\MSAS11.MSSQLSERVER\OLAP\Log\msmdsrv.log, Type: 3, Category: 289, Event ID: 0xC1210003)

Если я попытаюсь вручную запустить полный процесс в SSAS, я получу такое же загадочное сообщение об ошибке, как и файл Deploy.log.

У меня точно такой же процесс развертывания работает локально и на сервере CI. Разрешения идентичны в трех средах и работают в 2 из 3.

Что вызывает это? Могу ли я что-нибудь сделать, чтобы это исправить?


person Mike Bailey    schedule 08.12.2014    source источник
comment
После запуска ручного процесса откройте каждое отдельное сообщение об ошибке и посмотрите, сможете ли вы найти сообщение, которое не является операцией отмененной. Это будет настоящей ошибкой.   -  person Tab Alleman    schedule 08.12.2014
comment
Это это? blogs.msdn.com/b/jason_howell/archive/2012/06/11/   -  person billinkc    schedule 08.12.2014
comment
@TabAlleman: только что перезапустил SSAS и попытался выполнить полный процесс вручную. На этот раз он выдал мне несколько другой результат (последние несколько раз продолжал выдавать предупреждение о типе внутренней ошибки), не совсем понимаю, почему. Это указало мне на провал, хотя, спасибо!   -  person Mike Bailey    schedule 08.12.2014


Ответы (1)


Как предложил Таб Аллеман, я попытался вручную выполнить полный процесс куба. К сожалению, у меня нет под рукой сообщения об ошибке, но в нем говорилось что-то вроде «Произошла внутренняя ошибка».

По наитию я перезапустил экземпляр SSAS и повторил весь процесс во второй раз. Во второй раз SSAS правильно сообщил, какая ошибка привела к сбою.

Вкратце: если вы не получаете от SSAS никаких полезных ошибок или расплывчатых сообщений об ошибках, попробуйте перезапустить экземпляр и обработать его вручную.

person Mike Bailey    schedule 08.12.2014
comment
Обработка вручную дала мне более подробное сообщение об ошибке. Спасибо - person Goldfish; 23.05.2018
comment
Можете ли вы объяснить больше об этом? Спасибо - person yuliansen; 17.07.2020