본문 바로가기

DB/mssql

[mssql][웹서비스호출] 구성 요소 'Ole Automation Procedures'이(가) SQL Server 보안 구성의 일부로 해제되었으므로 이 구성 요소의 프로시저 'sys.sp_OACreate'에 대한 액세스가 차단되었습니다. 시스템 관리..



구성 요소 'Ole Automation Procedures'이(가) SQL Server 보안 구성의 일부로 해제되었으므로 이 구성 요소의 프로시저 'sys.sp_OACreate'에 대한 액세스가 차단되었습니다. 

시스템 관리자는 sp_configure를 사용하여 'Ole Automation Procedures'의 사용을 활성화할 수 있습니다. 

'Ole Automation Procedures' 활성화 방법은 SQL Server 온라인 설명서의 "노출 영역 구성"을 참조하십시오.


관련 문서 

https://docs.microsoft.com/ko-kr/sql/relational-databases/system-stored-procedures/ole-automation-stored-procedures-transact-sql

Ole Automation Procedures 대상 spsp_OACreate	
sp_OAMethod
sp_OADestroy	
sp_OASetProperty
sp_OAGetErrorInfo	
sp_OAStop
sp_OAGetProperty



1. 쿼리에서 설정/해제 방법


관련문서

https://docs.microsoft.com/ko-kr/sql/database-engine/configure-windows/ole-automation-procedures-server-configuration-option


1-1. 고급옵션 상태보기

EXEC sp_configure 'show advanced options'; 
GO



1-2. Ole Automation Procedures 상태보기

-- Show Ole Automation Procedures, 0 = disabled, 1 = enabled 
EXEC sp_configure 'Ole Automation Procedures'; 
GO

활성화 되지 않는 상태에서는 "구성 옵션 'Ole Automation Procedures'이(가) 없거나 고급 옵션입니다." 오류 발생합니다.


1-3. 고급옵션 활성화

sp_configure 'show advanced options', 1; 
GO
--> 구성 옵션 'show advanced options'이(가) 0에서 1(으)로 변경되었습니다. RECONFIGURE 문을 실행하여 설치하십시오.
RECONFIGURE; 
GO
--> 명령이 완료되었습니다.


1-4. Ole Automation Procedures 활성화

-- Enable the Ole Automation Procedures 
sp_configure 'Ole Automation Procedures', 1; 
GO 
--> 구성 옵션 'Ole Automation Procedures'이(가) 0에서 1(으)로 변경되었습니다. RECONFIGURE 문을 실행하여 설치하십시오.
RECONFIGURE; 
GO 
--> 명령이 완료되었습니다.


1-5. 고급옵션 비활성화

sp_configure 'show advanced options', 0; 
GO 
--> 구성 옵션 'show advanced options'이(가) 1에서 0(으)로 변경되었습니다. RECONFIGURE 문을 실행하여 설치하십시오.
RECONFIGURE; 
GO
--> 명령이 완료되었습니다.


1-6. Ole Automation Procedures 비활성화

-- Disable the Ole Automation Procedures 
sp_configure 'Ole Automation Procedures', 0; 
GO 
--> 구성 옵션 'Ole Automation Procedures'이(가) 1에서 0(으)로 변경되었습니다. RECONFIGURE 문을 실행하여 설치하십시오.
RECONFIGURE; 
GO
--> 명령이 완료되었습니다.



1-7. 활성화 순서


1-3 -> 1-4


Ole Automation Procedures 상태보기는 활성화 상태에서만 가능


1-8. 비활성화 순서


1-5 -> 1-6


2. Sql Server Management Studio (SSMS) 에서 설정/해제 하는 방법

관련문서

https://docs.microsoft.com/ko-kr/sql/relational-databases/security/surface-area-configuration

- 위의 쿼리에서 복잡하게 했던 작업을 SSMS 에서는 true / false 변경으로 손쉽게 합니다.

개체 탐색기 (우클릭) > 패싯


OleAutomationEnabled - True/False > 확인