사용하지 않을 때 SQL Azure DB 중지
계정에 요금이 부과되지 않도록 SQL Azure DB를 중지하는 방법이 있습니까? 웹 사이트, 클라우드 서비스 및 VM에서 할 수있는 것처럼 "중지"로 설정 한 것보다 테스트 중이고 사용되지 않는 동안 삭제하고 싶지 않습니다.
감사
2019 년 10 월 5 일 (금) 현재 답변은 아니오입니다.
그들은 그것을 허용하지 않을 것입니다. 따라서 Azure 데이터베이스를 만드는 날부터 청구가 계속됩니다. Azure SQL Database에 대한 청구를 일시 중지 / 중지 할 수있는 방법은 없습니다.
출처 : 청구를 일시 중지하기 위해 SQL Azure 서버를 일시적으로 끄거나 켜는 기능을 추가하십시오 .
Microsoft의 공식 답변은 "예, 데이터베이스를 내보낼 수 있습니다. Azure SQL 데이터베이스를 삭제하면 청구가 일시 중지됩니다. 그런 다음 필요할 때 새 데이터베이스를 만들고 이전에 탐색 한 DB를 가져올 수 있습니다."라고 답했습니다.
"결제 비용을 절약하기 위해 SQL Server를 일시적으로 끌 수 있음"에 대한 대답으로 이것이 허용되지 않는다고 생각합니다.
이것은 현재 옵션이 아닙니다. 유일한 선택은 Azure SQL Database의 크기를 줄이는 것입니다. 그러면 다음 서비스 시간에 따른 비용이 절감됩니다. DB 비용을 지불하고 싶지 않다면 DB를 Blob Storage에 백업하고 데이터베이스를 삭제 한 다음 필요할 때 복원 할 수 있습니다. PowerShell 등을 사용하여이를 조정할 수 있습니다.
2019 년 5 월 업데이트 : 사용하지 않을 때 청구하지 않음으로써 비용 절감과 관련된 일부 요구 사항을 충족 할 수있는 새로운 Azure SQL 데이터베이스 "서버리스"계층이 제공됩니다. 공식 문서는 읽을 수 있습니다 .
데이터베이스는 삭제 직전에 자동으로 백업됩니다. 따라서 필요하지 않을 때 드롭하고 필요할 때 복원 할 수 있습니다. 복원은 데이터베이스 크기와 생성 한 로그 양에 따라 다소 시간이 걸리므로 큰 데이터베이스의 경우 빠르지 않습니다.
또한 백업 보관 기간 (서비스 계층에 따라 다름)에 대한 만료 정책이 있으므로주의하십시오.
https://msdn.microsoft.com/en-us/library/azure/jj650016.aspx
The Azure SQL Database team is happy to announce that there is now an option that may address your request. We just announced a "serverless" option for Azure SQL DB that will pause your database when it is not in use. You can read more about the feature here: SQL Database Serverless
As is it is not supported however there are a few work arounds. It really depends upon how long you want to stop it and how immediately you want it and the size of the database. If it is for a couple hours then it may not worth it because the billing is hourly and you may have round off issues. If days then you can drop it and restore when needed. If weeks then exporting the database and importing when needed is another option. Also you may want to check backup strategy for the edition you choose before preferring export / restore. The other thing to note is the immediate need vs planned. If immediate, and the db is big then make sure the SLAs in place works for you
You could export the database to Azure storage and Import it when you want to re-enable it, as suggested here:
Whereas, at this low scale (scale down requirement (pause) rather than scale up), SQL running within a VM might be a better answer for you...
Agree with @Shiva answer. But if you are simply trying out SQL Server on an Azure VM, you would not want to incur charges by accidentally leaving it running over the weekend or weeks. One solution is to use Automatic Shutdown Feature.
You cannot get the charge all the way down to zero, but almost...
If you try this SQL Command:
alter DATABASE myDB modify (EDITION = 'Basic')
or
alter DATABASE myDB modify (EDITION = 'Standard', SERVICE_OBJECTIVE = 'S0', MAXSIZE = 10 gb)
then your cost can go down to something like 5 USD per month (depending on your database size).
When you come back to work on your database, you just need to run
alter DATABASE myDB modify (EDITION = 'Standard', SERVICE_OBJECTIVE = 'S2', MAXSIZE = 10 gb)
and everything will be back to normal, after a few minutes.
This is now possible and the preview feature is public. Azure SQL Database serverless
https://docs.microsoft.com/en-us/azure/sql-database/sql-database-serverless
Here's what I did with my Azure database (4/20/19)
I scaled the database DTUs as low as possible while still reserving up to 250GB, which turns out to be 10 DTUs with an estimated cost of 1.50 per DTU (estimated at $15 per month). To me, that's almost as good as turning it off and on. I can scale it up to 100 DTUs when I want to get more processing and scale it down when I don't. Even at 100 DTUs for a whole month, the cost was only $75.93 last month on my test database.
NOTE: I am NOT using a VM to run a database, just the standard SQL server you get when you create a database in Azure.
참고URL : https://stackoverflow.com/questions/26986213/stopping-sql-azure-db-when-not-in-use
'Development Tip' 카테고리의 다른 글
sock send () 명령에서 "일시적으로 리소스를 사용할 수 없음"이 발생하는 원인 (0) | 2020.10.29 |
---|---|
JSLint / JSHint에게 이미 정의 된 전역 변수를 알리는 방법 (0) | 2020.10.29 |
angular2를 사용하여 서비스에서 구성 요소의 변수 변경 사항 업데이트 (0) | 2020.10.29 |
이 지연 루프가 수면없이 여러 번 반복 한 후 더 빨리 실행되기 시작하는 이유는 무엇입니까? (0) | 2020.10.29 |
JavaScript에서 잠금을 구현하는 방법 (0) | 2020.10.29 |