SlideShare a Scribd company logo
1 of 19
Distribuisci ed amministra le tue istanze
SQL Server con PowerShell
Marco Obinu
marco.obinu@omegamadlab.com
Sponsors
Speaker bio
Advisory Engineer @ Softjam S.p.A.
Geek to the bone 
Marco Obinu
marco.obinu@omegamadlab.com
@OmegaMadLab
www.omegamadlab.com
https://github.com/OmegaMadLab
Agenda
• Infrastructure as Code
• SQL Server Setup
• SQL Server Management
• Demo, demo, demo 
https://github.com/OmegaMadLab/DeployAndManageSqlInstancesWithPowerShell
Creare ed amministrare le proprie
istanze con PowerShell
Breve introduzione ad Infrastructure as Code
Infrastructure as Code
• Modello dichiarativo
• Automazione
• Evita derive di configurazione
• Ambienti riproducibili
• Version Control
• CI/CD
• Traccia le dipendenze delle risorse
Setup di SQL Server
PowerShell Desired State Configuration
Approccio tradizionale
PowerShell Desired State Configuration
• Sistema di configuration management basato su PowerShell
• Funziona sia su Windows che su OSS
• Elementi chiave:
• Configurazioni  componente dichiarativa
• Risorse  componente imperativa
• Tre funzioni: Test, Get, Set
• Reperibili da PSGallery  Find-DscResource
• Local Configuration Manager
• ApplyOnly
• ApplyAndMonitor
• ApplyAndAutocorrect
• Min. PoSH 4.0, consigliato 5.1 – necessita di WinRM
PowerShell Desired State Configuration
• PUSH e PULL
• CmdLet da ricordare
• Find-Module
• Install-Module
• Update-Module
• Get-Command -noun DSC*
It’s demo time!
PowerShell DSC
https://github.com/OmegaMadLab/DeployAndManageSqlInstancesWithPowerShell
Gestione di SQL Server
PowerShell
It’s demo time!
Central Management Server
SQL Server e PowerShell
Microsoft
• SQL Management Objects (SMO)
• SqlPs  SqlServer
Terze parti
• DbaTools
• SQL2000+
• Windows 7 with PowerShell 3 lato client; non necessario sui server
• DbaChecks
• Etc, etc, etc… 
It’s demo time!
Gestione SQL Server con PowerShell
https://github.com/OmegaMadLab/DeployAndManageSqlInstancesWithPowerShell
Compiti a casa 
Risorse utili per cominiciare
• Demo di questa sessione
• https://github.com/OmegaMadLab/StartingWithArmTemplates
• Risorsa DSC SqlServerDSC
• https://github.com/PowerShell/SqlServerDsc
• Esempi PowerShell DSC:
• https://github.com/OmegaMadLab/DSCDemo
• PowerShell DSC su Microsoft Virtual Academy
• Base: https://mva.microsoft.com/en-us/training-courses/getting-started-with-powershell-
desired-state-configuration-dsc--8672
• Advanced: https://mva.microsoft.com/en-US/training-courses/advanced-powershell-desired-
state-configuration-dsc-and-custom-resources-8702?l=3DnsS2H1_1504984382
• Modulo SqlServer
• https://docs.microsoft.com/en-us/powershell/module/sqlserver/?view=sqlserver-ps
• Modulo DBATools
• https://dbatools.io
SQL Start! 2019 - Ancona - Distribuisci ed amministra le tue istanze SQL Server con PowerShell
SQL Start! 2019 - Ancona - Distribuisci ed amministra le tue istanze SQL Server con PowerShell

More Related Content

What's hot

A Simple 8-Step Guide to Setting Up a Dev Shop
A Simple 8-Step Guide to Setting Up a Dev ShopA Simple 8-Step Guide to Setting Up a Dev Shop
A Simple 8-Step Guide to Setting Up a Dev Shop
Scott Porad
 

What's hot (20)

Intro to openfaas
Intro to openfaasIntro to openfaas
Intro to openfaas
 
Chat automation in a modern it environment
Chat automation in a modern it environmentChat automation in a modern it environment
Chat automation in a modern it environment
 
Chat automation in a Modern IT environment
Chat automation in a Modern IT environmentChat automation in a Modern IT environment
Chat automation in a Modern IT environment
 
How to Hack (And Secure) Serverless Apps on Azure
How to Hack (And Secure) Serverless Apps on AzureHow to Hack (And Secure) Serverless Apps on Azure
How to Hack (And Secure) Serverless Apps on Azure
 
Writing your First Ansible Playbook
Writing your First Ansible PlaybookWriting your First Ansible Playbook
Writing your First Ansible Playbook
 
Navigate around the edge with PowerShell
Navigate around the edge with PowerShellNavigate around the edge with PowerShell
Navigate around the edge with PowerShell
 
Armada - the way to ship microservices
Armada - the way to ship microservicesArmada - the way to ship microservices
Armada - the way to ship microservices
 
Building your own JEA Configuration
Building your own JEA ConfigurationBuilding your own JEA Configuration
Building your own JEA Configuration
 
Mean machine
Mean machineMean machine
Mean machine
 
Ansible Introduction
Ansible IntroductionAnsible Introduction
Ansible Introduction
 
Spring.new hope.1.3
Spring.new hope.1.3Spring.new hope.1.3
Spring.new hope.1.3
 
Performance Tuning Azure SQL Database
Performance Tuning Azure SQL DatabasePerformance Tuning Azure SQL Database
Performance Tuning Azure SQL Database
 
10 Tips to Pump Up Your Atlassian Performance
10 Tips to Pump Up Your Atlassian Performance10 Tips to Pump Up Your Atlassian Performance
10 Tips to Pump Up Your Atlassian Performance
 
Icinga Camp Amsterdam - Icinga Director
Icinga Camp Amsterdam - Icinga DirectorIcinga Camp Amsterdam - Icinga Director
Icinga Camp Amsterdam - Icinga Director
 
Icinga Camp Amsterdam - Icinga2 and Ansible
Icinga Camp Amsterdam - Icinga2 and AnsibleIcinga Camp Amsterdam - Icinga2 and Ansible
Icinga Camp Amsterdam - Icinga2 and Ansible
 
Overview of chef ( Infrastructure as a Code )
Overview of chef ( Infrastructure as a Code )Overview of chef ( Infrastructure as a Code )
Overview of chef ( Infrastructure as a Code )
 
A Simple 8-Step Guide to Setting Up a Dev Shop
A Simple 8-Step Guide to Setting Up a Dev ShopA Simple 8-Step Guide to Setting Up a Dev Shop
A Simple 8-Step Guide to Setting Up a Dev Shop
 
Enterprise day 2015 - Continuous delivery at Klarna (Klarna)
Enterprise day 2015 - Continuous delivery at Klarna (Klarna)Enterprise day 2015 - Continuous delivery at Klarna (Klarna)
Enterprise day 2015 - Continuous delivery at Klarna (Klarna)
 
Apply chat automation today - work smarter tomorrow
Apply chat automation today - work smarter tomorrowApply chat automation today - work smarter tomorrow
Apply chat automation today - work smarter tomorrow
 
ECS19 - Laura Kokkarinen - Introduction to Microsoft Graph
ECS19 - Laura Kokkarinen - Introduction to Microsoft GraphECS19 - Laura Kokkarinen - Introduction to Microsoft Graph
ECS19 - Laura Kokkarinen - Introduction to Microsoft Graph
 

Similar to SQL Start! 2019 - Ancona - Distribuisci ed amministra le tue istanze SQL Server con PowerShell

ZZ BC#7 asp.net mvc practice and guideline by NineMvp
ZZ BC#7 asp.net mvc practice and guideline by NineMvpZZ BC#7 asp.net mvc practice and guideline by NineMvp
ZZ BC#7 asp.net mvc practice and guideline by NineMvp
Chalermpon Areepong
 
PowerShellForDBDevelopers
PowerShellForDBDevelopersPowerShellForDBDevelopers
PowerShellForDBDevelopers
Bryan Cafferky
 

Similar to SQL Start! 2019 - Ancona - Distribuisci ed amministra le tue istanze SQL Server con PowerShell (20)

Nadzor sql a
Nadzor sql aNadzor sql a
Nadzor sql a
 
Configuration Management in the Cloud - AWS Online Tech Talks
Configuration Management in the Cloud - AWS Online Tech TalksConfiguration Management in the Cloud - AWS Online Tech Talks
Configuration Management in the Cloud - AWS Online Tech Talks
 
Continuous Delivery and Infrastructure as Code
Continuous Delivery and Infrastructure as CodeContinuous Delivery and Infrastructure as Code
Continuous Delivery and Infrastructure as Code
 
Become an Automation Ninja in 60 Minutes
Become an Automation Ninja in 60 MinutesBecome an Automation Ninja in 60 Minutes
Become an Automation Ninja in 60 Minutes
 
Announcing AWS CodeBuild - January 2017 Online Teck Talks
Announcing AWS CodeBuild - January 2017 Online Teck TalksAnnouncing AWS CodeBuild - January 2017 Online Teck Talks
Announcing AWS CodeBuild - January 2017 Online Teck Talks
 
ECS19 - Nik Charlebois - Automate the Deployment & Monitoring of SharePoint w...
ECS19 - Nik Charlebois - Automate the Deployment & Monitoring of SharePoint w...ECS19 - Nik Charlebois - Automate the Deployment & Monitoring of SharePoint w...
ECS19 - Nik Charlebois - Automate the Deployment & Monitoring of SharePoint w...
 
2019 Blackhat Booth Presentation - PowerUpSQL
2019 Blackhat Booth Presentation - PowerUpSQL2019 Blackhat Booth Presentation - PowerUpSQL
2019 Blackhat Booth Presentation - PowerUpSQL
 
AWS Webcast - Build Agile Applications in AWS Cloud for Government
AWS Webcast - Build Agile Applications in AWS Cloud for GovernmentAWS Webcast - Build Agile Applications in AWS Cloud for Government
AWS Webcast - Build Agile Applications in AWS Cloud for Government
 
DevOps, Continuous Integration and Deployment on AWS: Putting Money Back into...
DevOps, Continuous Integration and Deployment on AWS: Putting Money Back into...DevOps, Continuous Integration and Deployment on AWS: Putting Money Back into...
DevOps, Continuous Integration and Deployment on AWS: Putting Money Back into...
 
Devops continuousintegration and deployment onaws puttingmoneybackintoyourmis...
Devops continuousintegration and deployment onaws puttingmoneybackintoyourmis...Devops continuousintegration and deployment onaws puttingmoneybackintoyourmis...
Devops continuousintegration and deployment onaws puttingmoneybackintoyourmis...
 
Tokyo Azure Meetup #7 - Introduction to Serverless Architectures with Azure F...
Tokyo Azure Meetup #7 - Introduction to Serverless Architectures with Azure F...Tokyo Azure Meetup #7 - Introduction to Serverless Architectures with Azure F...
Tokyo Azure Meetup #7 - Introduction to Serverless Architectures with Azure F...
 
ENT201 A Tale of Two Pizzas: Accelerating Software Delivery with AWS Develope...
ENT201 A Tale of Two Pizzas: Accelerating Software Delivery with AWS Develope...ENT201 A Tale of Two Pizzas: Accelerating Software Delivery with AWS Develope...
ENT201 A Tale of Two Pizzas: Accelerating Software Delivery with AWS Develope...
 
Plantilla oracle
Plantilla oraclePlantilla oracle
Plantilla oracle
 
AWS re:Invent 2016: Configuration Management in the Cloud (DEV305)
AWS re:Invent 2016: Configuration Management in the Cloud (DEV305)AWS re:Invent 2016: Configuration Management in the Cloud (DEV305)
AWS re:Invent 2016: Configuration Management in the Cloud (DEV305)
 
ZZ BC#7 asp.net mvc practice and guideline by NineMvp
ZZ BC#7 asp.net mvc practice and guideline by NineMvpZZ BC#7 asp.net mvc practice and guideline by NineMvp
ZZ BC#7 asp.net mvc practice and guideline by NineMvp
 
IBM InterConnect 2015 - IIB in the Cloud
IBM InterConnect 2015 - IIB in the CloudIBM InterConnect 2015 - IIB in the Cloud
IBM InterConnect 2015 - IIB in the Cloud
 
Azure Integration DTAP Series, How to go from Development to Production – Par...
Azure Integration DTAP Series, How to go from Development to Production – Par...Azure Integration DTAP Series, How to go from Development to Production – Par...
Azure Integration DTAP Series, How to go from Development to Production – Par...
 
Operations Validation for Infrastructure As Code - PSConfEU 2016
Operations Validation for Infrastructure As Code - PSConfEU 2016Operations Validation for Infrastructure As Code - PSConfEU 2016
Operations Validation for Infrastructure As Code - PSConfEU 2016
 
Standardizing and Managing Your Infrastructure - MOSC 2011
Standardizing and Managing Your Infrastructure - MOSC 2011Standardizing and Managing Your Infrastructure - MOSC 2011
Standardizing and Managing Your Infrastructure - MOSC 2011
 
PowerShellForDBDevelopers
PowerShellForDBDevelopersPowerShellForDBDevelopers
PowerShellForDBDevelopers
 

More from Marco Obinu

More from Marco Obinu (17)

Securing an Azure full-PaaS architecture - Data saturday #0001 Pordenone
Securing an Azure full-PaaS architecture - Data saturday #0001 PordenoneSecuring an Azure full-PaaS architecture - Data saturday #0001 Pordenone
Securing an Azure full-PaaS architecture - Data saturday #0001 Pordenone
 
Implement a disaster recovery solution for your on-prem SQL with Azure? Easy!
Implement a disaster recovery solution for your on-prem SQL with Azure? Easy!Implement a disaster recovery solution for your on-prem SQL with Azure? Easy!
Implement a disaster recovery solution for your on-prem SQL with Azure? Easy!
 
Infrastructure as Code on Azure - Show your Bicep! v0.2 - .NetConf 2020 by Do...
Infrastructure as Code on Azure - Show your Bicep! v0.2 - .NetConf 2020 by Do...Infrastructure as Code on Azure - Show your Bicep! v0.2 - .NetConf 2020 by Do...
Infrastructure as Code on Azure - Show your Bicep! v0.2 - .NetConf 2020 by Do...
 
Infrastructure as Code on Azure: Show your Bicep!
Infrastructure as Code on Azure: Show your Bicep!Infrastructure as Code on Azure: Show your Bicep!
Infrastructure as Code on Azure: Show your Bicep!
 
Sql Start! 2020 - SQL Server Lift & Shift su Azure
Sql Start! 2020 - SQL Server Lift & Shift su AzureSql Start! 2020 - SQL Server Lift & Shift su Azure
Sql Start! 2020 - SQL Server Lift & Shift su Azure
 
SQL Server Lift & Shift on Azure - SQL Saturday 921
SQL Server Lift & Shift on Azure - SQL Saturday 921SQL Server Lift & Shift on Azure - SQL Saturday 921
SQL Server Lift & Shift on Azure - SQL Saturday 921
 
SQL Server Disaster Recovery on Azure - SQL Saturday 921
SQL Server Disaster Recovery on Azure - SQL Saturday 921SQL Server Disaster Recovery on Azure - SQL Saturday 921
SQL Server Disaster Recovery on Azure - SQL Saturday 921
 
Azure VM 101 - HomeGen by CloudGen Verona - Marco Obinu
Azure VM 101 - HomeGen by CloudGen Verona - Marco ObinuAzure VM 101 - HomeGen by CloudGen Verona - Marco Obinu
Azure VM 101 - HomeGen by CloudGen Verona - Marco Obinu
 
Global Azure Virtual 2020 What's new on Azure IaaS for SQL VMs
Global Azure Virtual 2020 What's new on Azure IaaS for SQL VMsGlobal Azure Virtual 2020 What's new on Azure IaaS for SQL VMs
Global Azure Virtual 2020 What's new on Azure IaaS for SQL VMs
 
Azure Day Reloaded 2019 - React to infrastructure events with Azure Monitor
Azure Day Reloaded 2019 - React to infrastructure events with Azure MonitorAzure Day Reloaded 2019 - React to infrastructure events with Azure Monitor
Azure Day Reloaded 2019 - React to infrastructure events with Azure Monitor
 
Azure Day Reloaded 2019 - ARM Template workshop
Azure Day Reloaded 2019 - ARM Template workshopAzure Day Reloaded 2019 - ARM Template workshop
Azure Day Reloaded 2019 - ARM Template workshop
 
Sql Saturday 895 - SQL Server e PowerShell: from Zero to Hero
Sql Saturday 895 - SQL Server e PowerShell: from Zero to HeroSql Saturday 895 - SQL Server e PowerShell: from Zero to Hero
Sql Saturday 895 - SQL Server e PowerShell: from Zero to Hero
 
Automazione serverless con Azure Functions e PowerShell - Marco Obinu - DevOp...
Automazione serverless con Azure Functions e PowerShell - Marco Obinu - DevOp...Automazione serverless con Azure Functions e PowerShell - Marco Obinu - DevOp...
Automazione serverless con Azure Functions e PowerShell - Marco Obinu - DevOp...
 
Azure Saturday Pordenone 2019 - Reagire agli eventi di infrastruttura con Azu...
Azure Saturday Pordenone 2019 - Reagire agli eventi di infrastruttura con Azu...Azure Saturday Pordenone 2019 - Reagire agli eventi di infrastruttura con Azu...
Azure Saturday Pordenone 2019 - Reagire agli eventi di infrastruttura con Azu...
 
SQL Saturday 871 - Sardegna 2019 - SQL Server DR on Azure
SQL Saturday 871 - Sardegna 2019 - SQL Server DR on AzureSQL Saturday 871 - Sardegna 2019 - SQL Server DR on Azure
SQL Saturday 871 - Sardegna 2019 - SQL Server DR on Azure
 
Global Azure BootCamp 2019 - Verona - Ottimizzazione delle VM SQL Server su A...
Global Azure BootCamp 2019 - Verona - Ottimizzazione delle VM SQL Server su A...Global Azure BootCamp 2019 - Verona - Ottimizzazione delle VM SQL Server su A...
Global Azure BootCamp 2019 - Verona - Ottimizzazione delle VM SQL Server su A...
 
Global Azure BootCamp 2019 - Verona - Azure Cloud Shell
Global Azure BootCamp 2019 - Verona - Azure Cloud ShellGlobal Azure BootCamp 2019 - Verona - Azure Cloud Shell
Global Azure BootCamp 2019 - Verona - Azure Cloud Shell
 

Recently uploaded

CNv6 Instructor Chapter 6 Quality of Service
CNv6 Instructor Chapter 6 Quality of ServiceCNv6 Instructor Chapter 6 Quality of Service
CNv6 Instructor Chapter 6 Quality of Service
giselly40
 

Recently uploaded (20)

From Event to Action: Accelerate Your Decision Making with Real-Time Automation
From Event to Action: Accelerate Your Decision Making with Real-Time AutomationFrom Event to Action: Accelerate Your Decision Making with Real-Time Automation
From Event to Action: Accelerate Your Decision Making with Real-Time Automation
 
A Domino Admins Adventures (Engage 2024)
A Domino Admins Adventures (Engage 2024)A Domino Admins Adventures (Engage 2024)
A Domino Admins Adventures (Engage 2024)
 
Boost PC performance: How more available memory can improve productivity
Boost PC performance: How more available memory can improve productivityBoost PC performance: How more available memory can improve productivity
Boost PC performance: How more available memory can improve productivity
 
Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...
Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...
Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...
 
2024: Domino Containers - The Next Step. News from the Domino Container commu...
2024: Domino Containers - The Next Step. News from the Domino Container commu...2024: Domino Containers - The Next Step. News from the Domino Container commu...
2024: Domino Containers - The Next Step. News from the Domino Container commu...
 
Scaling API-first – The story of a global engineering organization
Scaling API-first – The story of a global engineering organizationScaling API-first – The story of a global engineering organization
Scaling API-first – The story of a global engineering organization
 
GenAI Risks & Security Meetup 01052024.pdf
GenAI Risks & Security Meetup 01052024.pdfGenAI Risks & Security Meetup 01052024.pdf
GenAI Risks & Security Meetup 01052024.pdf
 
CNv6 Instructor Chapter 6 Quality of Service
CNv6 Instructor Chapter 6 Quality of ServiceCNv6 Instructor Chapter 6 Quality of Service
CNv6 Instructor Chapter 6 Quality of Service
 
Handwritten Text Recognition for manuscripts and early printed texts
Handwritten Text Recognition for manuscripts and early printed textsHandwritten Text Recognition for manuscripts and early printed texts
Handwritten Text Recognition for manuscripts and early printed texts
 
Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...
Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...
Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...
 
presentation ICT roal in 21st century education
presentation ICT roal in 21st century educationpresentation ICT roal in 21st century education
presentation ICT roal in 21st century education
 
Strategies for Landing an Oracle DBA Job as a Fresher
Strategies for Landing an Oracle DBA Job as a FresherStrategies for Landing an Oracle DBA Job as a Fresher
Strategies for Landing an Oracle DBA Job as a Fresher
 
TrustArc Webinar - Stay Ahead of US State Data Privacy Law Developments
TrustArc Webinar - Stay Ahead of US State Data Privacy Law DevelopmentsTrustArc Webinar - Stay Ahead of US State Data Privacy Law Developments
TrustArc Webinar - Stay Ahead of US State Data Privacy Law Developments
 
How to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected WorkerHow to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected Worker
 
[2024]Digital Global Overview Report 2024 Meltwater.pdf
[2024]Digital Global Overview Report 2024 Meltwater.pdf[2024]Digital Global Overview Report 2024 Meltwater.pdf
[2024]Digital Global Overview Report 2024 Meltwater.pdf
 
Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024
Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024
Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024
 
The 7 Things I Know About Cyber Security After 25 Years | April 2024
The 7 Things I Know About Cyber Security After 25 Years | April 2024The 7 Things I Know About Cyber Security After 25 Years | April 2024
The 7 Things I Know About Cyber Security After 25 Years | April 2024
 
What Are The Drone Anti-jamming Systems Technology?
What Are The Drone Anti-jamming Systems Technology?What Are The Drone Anti-jamming Systems Technology?
What Are The Drone Anti-jamming Systems Technology?
 
ProductAnonymous-April2024-WinProductDiscovery-MelissaKlemke
ProductAnonymous-April2024-WinProductDiscovery-MelissaKlemkeProductAnonymous-April2024-WinProductDiscovery-MelissaKlemke
ProductAnonymous-April2024-WinProductDiscovery-MelissaKlemke
 
Tech Trends Report 2024 Future Today Institute.pdf
Tech Trends Report 2024 Future Today Institute.pdfTech Trends Report 2024 Future Today Institute.pdf
Tech Trends Report 2024 Future Today Institute.pdf
 

SQL Start! 2019 - Ancona - Distribuisci ed amministra le tue istanze SQL Server con PowerShell

  • 1. Distribuisci ed amministra le tue istanze SQL Server con PowerShell Marco Obinu marco.obinu@omegamadlab.com
  • 3. Speaker bio Advisory Engineer @ Softjam S.p.A. Geek to the bone  Marco Obinu marco.obinu@omegamadlab.com @OmegaMadLab www.omegamadlab.com https://github.com/OmegaMadLab
  • 4. Agenda • Infrastructure as Code • SQL Server Setup • SQL Server Management • Demo, demo, demo  https://github.com/OmegaMadLab/DeployAndManageSqlInstancesWithPowerShell
  • 5. Creare ed amministrare le proprie istanze con PowerShell Breve introduzione ad Infrastructure as Code
  • 6. Infrastructure as Code • Modello dichiarativo • Automazione • Evita derive di configurazione • Ambienti riproducibili • Version Control • CI/CD • Traccia le dipendenze delle risorse
  • 7. Setup di SQL Server PowerShell Desired State Configuration
  • 9. PowerShell Desired State Configuration • Sistema di configuration management basato su PowerShell • Funziona sia su Windows che su OSS • Elementi chiave: • Configurazioni  componente dichiarativa • Risorse  componente imperativa • Tre funzioni: Test, Get, Set • Reperibili da PSGallery  Find-DscResource • Local Configuration Manager • ApplyOnly • ApplyAndMonitor • ApplyAndAutocorrect • Min. PoSH 4.0, consigliato 5.1 – necessita di WinRM
  • 10. PowerShell Desired State Configuration • PUSH e PULL • CmdLet da ricordare • Find-Module • Install-Module • Update-Module • Get-Command -noun DSC*
  • 11. It’s demo time! PowerShell DSC https://github.com/OmegaMadLab/DeployAndManageSqlInstancesWithPowerShell
  • 12. Gestione di SQL Server PowerShell
  • 13. It’s demo time! Central Management Server
  • 14. SQL Server e PowerShell Microsoft • SQL Management Objects (SMO) • SqlPs  SqlServer Terze parti • DbaTools • SQL2000+ • Windows 7 with PowerShell 3 lato client; non necessario sui server • DbaChecks • Etc, etc, etc… 
  • 15. It’s demo time! Gestione SQL Server con PowerShell https://github.com/OmegaMadLab/DeployAndManageSqlInstancesWithPowerShell
  • 17. Risorse utili per cominiciare • Demo di questa sessione • https://github.com/OmegaMadLab/StartingWithArmTemplates • Risorsa DSC SqlServerDSC • https://github.com/PowerShell/SqlServerDsc • Esempi PowerShell DSC: • https://github.com/OmegaMadLab/DSCDemo • PowerShell DSC su Microsoft Virtual Academy • Base: https://mva.microsoft.com/en-us/training-courses/getting-started-with-powershell- desired-state-configuration-dsc--8672 • Advanced: https://mva.microsoft.com/en-US/training-courses/advanced-powershell-desired- state-configuration-dsc-and-custom-resources-8702?l=3DnsS2H1_1504984382 • Modulo SqlServer • https://docs.microsoft.com/en-us/powershell/module/sqlserver/?view=sqlserver-ps • Modulo DBATools • https://dbatools.io