SlideShare a Scribd company logo
Copyright © 2019,eProseed and/or its affiliates. All rights reserved. | Confidential
SHELL SCRIPT FOR DBA
Rodrigo Mufalani
Principal DB Architect
Oracle Certified Master (OCM)
Oracle ACE Member
eProssed - Luxembourg
Mobile Process /
Integration
Analytics /
Big Data
Database /
Data
Management
Identity &
Access
Management
Oracle Cloud
eProseed Confidential2
Copyright © 2019,eProseed and/or its affiliates. All rights reserved. | Confidential
BOUT ME
Principal DB Architect at eProseed Lux
Oracle Certified Master (OCM)
Oracle ACE Member
Chairman of LuxOUG
Board Member at GUOB
Contacts
mufalani@gmail.com
Twitter.com/mufalani
https://www.linkedin.com/in/mufalani/
Copyright © 2019,eProseed and/or its affiliates. All rights reserved. | Confidential
bit.ly/OracleACEProgram
500+ Technical Experts
Helping Peers Globally
Nominate yourself or someone you know: acenomination.oracle.com
Copyright © 2019,eProseed and/or its affiliates. All rights reserved. | Confidential
Copyright © 2019,eProseed and/or its affiliates. All rights reserved. | Confidential
AGENDA
History
Basics
Loop structures
Conditional structures
Functions
Demos
7
Copyright © 2019,eProseed and/or its affiliates. All rights reserved. | Confidential
DISCLAIMER
“The postings on this document are my own and don’t necessarily represent my
actual employer positions, strategies or opinions. The information here was edited to
be useful for general purpose, specific data and identifications were removed to
allow reach the generic audience and to be useful for the community.”
9
HISTORY
Copyright © 2019,eProseed and/or its affiliates. All rights reserved. | Confidential10
HISTORY
Bourne Shell - (sh) - /bin/sh
First appeared 7th Ed. of Bell Labs Research version of Unix
Copyright © 2019,eProseed and/or its affiliates. All rights reserved. | Confidential11
HISTORY
C Shell - (csh) - /bin/csh
Delivered on BSD systems first available on 4.4 BSD
Used by C programmers (Similar sintax)
Copyright © 2019,eProseed and/or its affiliates. All rights reserved. | Confidential12
HISTORY
Kourn Shell - (ksh)
Shipped with comercial Unixes (AIX, HP-UX and Solaris)
It was not free (later became open-source)
http://www.kornshell.com/
Copyright © 2019,eProseed and/or its affiliates. All rights reserved. | Confidential13
HISTORY
Bourne Again Shell - (bash) - /bin/bash
Linux systems
chsh –s <shell> <username>
https://www.gnu.org/software/bash/
14
BASICS
Copyright © 2019,eProseed and/or its affiliates. All rights reserved. | Confidential15
BASICS
Copyright © 2019,eProseed and/or its affiliates. All rights reserved. | Confidential16
BASICS
Copyright © 2019,eProseed and/or its affiliates. All rights reserved. | Confidential17
BASICS
Copyright © 2019,eProseed and/or its affiliates. All rights reserved. | Confidential18
BASICS
Copyright © 2019,eProseed and/or its affiliates. All rights reserved. | Confidential19
BASICS
Copyright © 2019,eProseed and/or its affiliates. All rights reserved. | Confidential20
BASICS
Copyright © 2019,eProseed and/or its affiliates. All rights reserved. | Confidential21
BASICS
Copyright © 2019,eProseed and/or its affiliates. All rights reserved. | Confidential22
BASICS
Copyright © 2019,eProseed and/or its affiliates. All rights reserved. | Confidential23
24
LOOP STRUCTURES
Copyright © 2019,eProseed and/or its affiliates. All rights reserved. | Confidential25
LOOP STRUCTURES
Copyright © 2019,eProseed and/or its affiliates. All rights reserved. | Confidential26
LOOP STRUCTURES
Copyright © 2019,eProseed and/or its affiliates. All rights reserved. | Confidential27
LOOP STRUCTURES
Copyright © 2019,eProseed and/or its affiliates. All rights reserved. | Confidential28
LOOP STRUCTURES
Copyright © 2019,eProseed and/or its affiliates. All rights reserved. | Confidential29
LOOP STRUCTURES
Copyright © 2019,eProseed and/or its affiliates. All rights reserved. | Confidential30
LOOP STRUCTURES
Copyright © 2019,eProseed and/or its affiliates. All rights reserved. | Confidential31
32
CONDITIONAL STRUCTURES
Copyright © 2019,eProseed and/or its affiliates. All rights reserved. | Confidential33
CONDITIONAL STRUCTURES
Copyright © 2019,eProseed and/or its affiliates. All rights reserved. | Confidential34
CONDITIONAL STRUCTURES
https://ryanstutorials.net/bash-scripting-tutorial/bash-if-statements.php
Copyright © 2019,eProseed and/or its affiliates. All rights reserved. | Confidential35
CONDITIONAL STRUCTURES
36
FUNCTIONS
Copyright © 2019,eProseed and/or its affiliates. All rights reserved. | Confidential37
FUNCTIONS
Copyright © 2019,eProseed and/or its affiliates. All rights reserved. | Confidential38
FUNCTIONS
https://www.shellscript.sh/functions.html
Copyright © 2019,eProseed and/or its affiliates. All rights reserved. | Confidential39
Copyright © 2019,eProseed and/or its affiliates. All rights reserved. | Confidential
Copyright © 2019,eProseed and/or its affiliates. All rights reserved. | Confidential

More Related Content

Similar to Shell Script 4 DBAs

2019-11-09 DevOpsNG - What I've learned from DevOps
2019-11-09 DevOpsNG - What I've learned from DevOps2019-11-09 DevOpsNG - What I've learned from DevOps
2019-11-09 DevOpsNG - What I've learned from DevOpsCobus Bernard
 
10thMeetup-20190420-REST API Design Principles 되새기기
10thMeetup-20190420-REST API Design Principles 되새기기10thMeetup-20190420-REST API Design Principles 되새기기
10thMeetup-20190420-REST API Design Principles 되새기기DongHee Lee
 
Kyma: Extending Business systems with Kubernetes, Istio and <fill the blank>.
Kyma: Extending Business systems with Kubernetes, Istio and <fill the blank>.Kyma: Extending Business systems with Kubernetes, Istio and <fill the blank>.
Kyma: Extending Business systems with Kubernetes, Istio and <fill the blank>.SAP HANA Cloud Platform
 
RPA Automation Tutorial | RPA Training | RPA Tutorial For Beginners | Edureka
RPA Automation Tutorial | RPA Training | RPA Tutorial For Beginners | EdurekaRPA Automation Tutorial | RPA Training | RPA Tutorial For Beginners | Edureka
RPA Automation Tutorial | RPA Training | RPA Tutorial For Beginners | EdurekaEdureka!
 
API Design Principles Essential 
API Design Principles Essential API Design Principles Essential 
API Design Principles Essential Oracle Korea
 
顧客要望と情熱のあいだ - B2B SaaS のプロダクトマネジメント -
顧客要望と情熱のあいだ - B2B SaaS のプロダクトマネジメント -顧客要望と情熱のあいだ - B2B SaaS のプロダクトマネジメント -
顧客要望と情熱のあいだ - B2B SaaS のプロダクトマネジメント -Takuma Haraguchi
 
CSPA Keynote: BLOCKCHAIN for Enterprise
CSPA Keynote: BLOCKCHAIN for EnterpriseCSPA Keynote: BLOCKCHAIN for Enterprise
CSPA Keynote: BLOCKCHAIN for EnterpriseDavid Haimes
 
클라우드 세상에서 CIO로 살아남기 - 이한주 대표이사, Bespin Global :: AWS Summit Seoul 2019
클라우드 세상에서 CIO로 살아남기 - 이한주 대표이사, Bespin Global :: AWS Summit Seoul 2019클라우드 세상에서 CIO로 살아남기 - 이한주 대표이사, Bespin Global :: AWS Summit Seoul 2019
클라우드 세상에서 CIO로 살아남기 - 이한주 대표이사, Bespin Global :: AWS Summit Seoul 2019Amazon Web Services Korea
 
Keynote_AWS_BecomingAHighFrequencyEnterprise
Keynote_AWS_BecomingAHighFrequencyEnterpriseKeynote_AWS_BecomingAHighFrequencyEnterprise
Keynote_AWS_BecomingAHighFrequencyEnterpriseAmazon Web Services
 
Power Up Your Productivity with ER/Studio 18.0
Power Up Your Productivity with ER/Studio 18.0Power Up Your Productivity with ER/Studio 18.0
Power Up Your Productivity with ER/Studio 18.0IDERA Software
 
Microapps: Redefining Enterprise Mobility
Microapps: Redefining Enterprise MobilityMicroapps: Redefining Enterprise Mobility
Microapps: Redefining Enterprise MobilityNischal Reddy
 
Best practices for privileged access & secrets management in the cloud - DEM0...
Best practices for privileged access & secrets management in the cloud - DEM0...Best practices for privileged access & secrets management in the cloud - DEM0...
Best practices for privileged access & secrets management in the cloud - DEM0...Amazon Web Services
 
Using GitHub and Visual Studio Code for Mainframe Development
Using GitHub and Visual Studio Code for Mainframe DevelopmentUsing GitHub and Visual Studio Code for Mainframe Development
Using GitHub and Visual Studio Code for Mainframe DevelopmentDevOps.com
 
Move your Castle to the Cloud
Move your Castle to the CloudMove your Castle to the Cloud
Move your Castle to the CloudBlaine Carter
 
How Pokémon’s SecOps team enables its business - SDD328 - AWS re:Inforce 2019
How Pokémon’s SecOps team enables its business - SDD328 - AWS re:Inforce 2019 How Pokémon’s SecOps team enables its business - SDD328 - AWS re:Inforce 2019
How Pokémon’s SecOps team enables its business - SDD328 - AWS re:Inforce 2019 Amazon Web Services
 
eProseed Oracle Open World 2016 debrief - Oracle Management Cloud
eProseed Oracle Open World 2016 debrief - Oracle Management CloudeProseed Oracle Open World 2016 debrief - Oracle Management Cloud
eProseed Oracle Open World 2016 debrief - Oracle Management CloudMarco Gralike
 
AI APIs as a Catalyst for Machine Learning Initiatives
AI APIs as a Catalyst for Machine Learning InitiativesAI APIs as a Catalyst for Machine Learning Initiatives
AI APIs as a Catalyst for Machine Learning InitiativesNicholas Walsh
 

Similar to Shell Script 4 DBAs (20)

2019-11-09 DevOpsNG - What I've learned from DevOps
2019-11-09 DevOpsNG - What I've learned from DevOps2019-11-09 DevOpsNG - What I've learned from DevOps
2019-11-09 DevOpsNG - What I've learned from DevOps
 
10thMeetup-20190420-REST API Design Principles 되새기기
10thMeetup-20190420-REST API Design Principles 되새기기10thMeetup-20190420-REST API Design Principles 되새기기
10thMeetup-20190420-REST API Design Principles 되새기기
 
Kyma: Extending Business systems with Kubernetes, Istio and <fill the blank>.
Kyma: Extending Business systems with Kubernetes, Istio and <fill the blank>.Kyma: Extending Business systems with Kubernetes, Istio and <fill the blank>.
Kyma: Extending Business systems with Kubernetes, Istio and <fill the blank>.
 
RPA Automation Tutorial | RPA Training | RPA Tutorial For Beginners | Edureka
RPA Automation Tutorial | RPA Training | RPA Tutorial For Beginners | EdurekaRPA Automation Tutorial | RPA Training | RPA Tutorial For Beginners | Edureka
RPA Automation Tutorial | RPA Training | RPA Tutorial For Beginners | Edureka
 
API Design Principles Essential 
API Design Principles Essential API Design Principles Essential 
API Design Principles Essential 
 
顧客要望と情熱のあいだ - B2B SaaS のプロダクトマネジメント -
顧客要望と情熱のあいだ - B2B SaaS のプロダクトマネジメント -顧客要望と情熱のあいだ - B2B SaaS のプロダクトマネジメント -
顧客要望と情熱のあいだ - B2B SaaS のプロダクトマネジメント -
 
CSPA Keynote: BLOCKCHAIN for Enterprise
CSPA Keynote: BLOCKCHAIN for EnterpriseCSPA Keynote: BLOCKCHAIN for Enterprise
CSPA Keynote: BLOCKCHAIN for Enterprise
 
클라우드 세상에서 CIO로 살아남기 - 이한주 대표이사, Bespin Global :: AWS Summit Seoul 2019
클라우드 세상에서 CIO로 살아남기 - 이한주 대표이사, Bespin Global :: AWS Summit Seoul 2019클라우드 세상에서 CIO로 살아남기 - 이한주 대표이사, Bespin Global :: AWS Summit Seoul 2019
클라우드 세상에서 CIO로 살아남기 - 이한주 대표이사, Bespin Global :: AWS Summit Seoul 2019
 
Keynote_AWS_BecomingAHighFrequencyEnterprise
Keynote_AWS_BecomingAHighFrequencyEnterpriseKeynote_AWS_BecomingAHighFrequencyEnterprise
Keynote_AWS_BecomingAHighFrequencyEnterprise
 
Power Up Your Productivity with ER/Studio 18.0
Power Up Your Productivity with ER/Studio 18.0Power Up Your Productivity with ER/Studio 18.0
Power Up Your Productivity with ER/Studio 18.0
 
Microapps: Redefining Enterprise Mobility
Microapps: Redefining Enterprise MobilityMicroapps: Redefining Enterprise Mobility
Microapps: Redefining Enterprise Mobility
 
Best practices for privileged access & secrets management in the cloud - DEM0...
Best practices for privileged access & secrets management in the cloud - DEM0...Best practices for privileged access & secrets management in the cloud - DEM0...
Best practices for privileged access & secrets management in the cloud - DEM0...
 
Using GitHub and Visual Studio Code for Mainframe Development
Using GitHub and Visual Studio Code for Mainframe DevelopmentUsing GitHub and Visual Studio Code for Mainframe Development
Using GitHub and Visual Studio Code for Mainframe Development
 
Startup Day Buenos Aires
Startup Day Buenos AiresStartup Day Buenos Aires
Startup Day Buenos Aires
 
AWS Startup Day Santiago - Pitch essentials
AWS Startup Day Santiago - Pitch essentialsAWS Startup Day Santiago - Pitch essentials
AWS Startup Day Santiago - Pitch essentials
 
Move your Castle to the Cloud
Move your Castle to the CloudMove your Castle to the Cloud
Move your Castle to the Cloud
 
AWS Initiate - DevOps do Jeito Amazon
AWS Initiate - DevOps do Jeito AmazonAWS Initiate - DevOps do Jeito Amazon
AWS Initiate - DevOps do Jeito Amazon
 
How Pokémon’s SecOps team enables its business - SDD328 - AWS re:Inforce 2019
How Pokémon’s SecOps team enables its business - SDD328 - AWS re:Inforce 2019 How Pokémon’s SecOps team enables its business - SDD328 - AWS re:Inforce 2019
How Pokémon’s SecOps team enables its business - SDD328 - AWS re:Inforce 2019
 
eProseed Oracle Open World 2016 debrief - Oracle Management Cloud
eProseed Oracle Open World 2016 debrief - Oracle Management CloudeProseed Oracle Open World 2016 debrief - Oracle Management Cloud
eProseed Oracle Open World 2016 debrief - Oracle Management Cloud
 
AI APIs as a Catalyst for Machine Learning Initiatives
AI APIs as a Catalyst for Machine Learning InitiativesAI APIs as a Catalyst for Machine Learning Initiatives
AI APIs as a Catalyst for Machine Learning Initiatives
 

Recently uploaded

Understanding Poverty: A Community Questionnaire
Understanding Poverty: A Community QuestionnaireUnderstanding Poverty: A Community Questionnaire
Understanding Poverty: A Community Questionnairebazilnaeem7
 
Oracle Database Administration I (1Z0-082) Exam Dumps 2024.pdf
Oracle Database Administration I (1Z0-082) Exam Dumps 2024.pdfOracle Database Administration I (1Z0-082) Exam Dumps 2024.pdf
Oracle Database Administration I (1Z0-082) Exam Dumps 2024.pdfSkillCertProExams
 
The Canoga Gardens Development Project. PDF
The Canoga Gardens Development Project. PDFThe Canoga Gardens Development Project. PDF
The Canoga Gardens Development Project. PDFRahsaan L. Browne
 
Writing Sample 2 -Bridging the Divide: Enhancing Public Engagement in Urban D...
Writing Sample 2 -Bridging the Divide: Enhancing Public Engagement in Urban D...Writing Sample 2 -Bridging the Divide: Enhancing Public Engagement in Urban D...
Writing Sample 2 -Bridging the Divide: Enhancing Public Engagement in Urban D...Rahsaan L. Browne
 
ACM CHT Best Inspection Practices Kinben Innovation MIC Slideshare.pdf
ACM CHT Best Inspection Practices Kinben Innovation MIC Slideshare.pdfACM CHT Best Inspection Practices Kinben Innovation MIC Slideshare.pdf
ACM CHT Best Inspection Practices Kinben Innovation MIC Slideshare.pdfKinben Innovation Private Limited
 
527598851-ppc-due-to-various-govt-policies.pdf
527598851-ppc-due-to-various-govt-policies.pdf527598851-ppc-due-to-various-govt-policies.pdf
527598851-ppc-due-to-various-govt-policies.pdfrajpreetkaur75080
 
OC Streetcar Final Presentation-Downtown Santa Ana
OC Streetcar Final Presentation-Downtown Santa AnaOC Streetcar Final Presentation-Downtown Santa Ana
OC Streetcar Final Presentation-Downtown Santa AnaRahsaan L. Browne
 
ServiceNow CIS-Discovery Exam Dumps 2024
ServiceNow CIS-Discovery Exam Dumps 2024ServiceNow CIS-Discovery Exam Dumps 2024
ServiceNow CIS-Discovery Exam Dumps 2024SkillCertProExams
 
Cymulate (Breach and Attack Simulation).
Cymulate (Breach and Attack Simulation).Cymulate (Breach and Attack Simulation).
Cymulate (Breach and Attack Simulation).luckyk1575
 
Breathing in New Life_ Part 3 05 22 2024.pptx
Breathing in New Life_ Part 3 05 22 2024.pptxBreathing in New Life_ Part 3 05 22 2024.pptx
Breathing in New Life_ Part 3 05 22 2024.pptxFamilyWorshipCenterD
 
art integrated project of computer applications
art integrated project of computer applicationsart integrated project of computer applications
art integrated project of computer applicationsmarvelpwian65
 
The Influence and Evolution of Mogul Press in Contemporary Public Relations.docx
The Influence and Evolution of Mogul Press in Contemporary Public Relations.docxThe Influence and Evolution of Mogul Press in Contemporary Public Relations.docx
The Influence and Evolution of Mogul Press in Contemporary Public Relations.docxMogul Press
 
Deciding The Topic of our Magazine.pptx.
Deciding The Topic of our Magazine.pptx.Deciding The Topic of our Magazine.pptx.
Deciding The Topic of our Magazine.pptx.bazilnaeem7
 
05232024 Joint Meeting - Community Networking
05232024 Joint Meeting - Community Networking05232024 Joint Meeting - Community Networking
05232024 Joint Meeting - Community NetworkingMichael Orias
 

Recently uploaded (14)

Understanding Poverty: A Community Questionnaire
Understanding Poverty: A Community QuestionnaireUnderstanding Poverty: A Community Questionnaire
Understanding Poverty: A Community Questionnaire
 
Oracle Database Administration I (1Z0-082) Exam Dumps 2024.pdf
Oracle Database Administration I (1Z0-082) Exam Dumps 2024.pdfOracle Database Administration I (1Z0-082) Exam Dumps 2024.pdf
Oracle Database Administration I (1Z0-082) Exam Dumps 2024.pdf
 
The Canoga Gardens Development Project. PDF
The Canoga Gardens Development Project. PDFThe Canoga Gardens Development Project. PDF
The Canoga Gardens Development Project. PDF
 
Writing Sample 2 -Bridging the Divide: Enhancing Public Engagement in Urban D...
Writing Sample 2 -Bridging the Divide: Enhancing Public Engagement in Urban D...Writing Sample 2 -Bridging the Divide: Enhancing Public Engagement in Urban D...
Writing Sample 2 -Bridging the Divide: Enhancing Public Engagement in Urban D...
 
ACM CHT Best Inspection Practices Kinben Innovation MIC Slideshare.pdf
ACM CHT Best Inspection Practices Kinben Innovation MIC Slideshare.pdfACM CHT Best Inspection Practices Kinben Innovation MIC Slideshare.pdf
ACM CHT Best Inspection Practices Kinben Innovation MIC Slideshare.pdf
 
527598851-ppc-due-to-various-govt-policies.pdf
527598851-ppc-due-to-various-govt-policies.pdf527598851-ppc-due-to-various-govt-policies.pdf
527598851-ppc-due-to-various-govt-policies.pdf
 
OC Streetcar Final Presentation-Downtown Santa Ana
OC Streetcar Final Presentation-Downtown Santa AnaOC Streetcar Final Presentation-Downtown Santa Ana
OC Streetcar Final Presentation-Downtown Santa Ana
 
ServiceNow CIS-Discovery Exam Dumps 2024
ServiceNow CIS-Discovery Exam Dumps 2024ServiceNow CIS-Discovery Exam Dumps 2024
ServiceNow CIS-Discovery Exam Dumps 2024
 
Cymulate (Breach and Attack Simulation).
Cymulate (Breach and Attack Simulation).Cymulate (Breach and Attack Simulation).
Cymulate (Breach and Attack Simulation).
 
Breathing in New Life_ Part 3 05 22 2024.pptx
Breathing in New Life_ Part 3 05 22 2024.pptxBreathing in New Life_ Part 3 05 22 2024.pptx
Breathing in New Life_ Part 3 05 22 2024.pptx
 
art integrated project of computer applications
art integrated project of computer applicationsart integrated project of computer applications
art integrated project of computer applications
 
The Influence and Evolution of Mogul Press in Contemporary Public Relations.docx
The Influence and Evolution of Mogul Press in Contemporary Public Relations.docxThe Influence and Evolution of Mogul Press in Contemporary Public Relations.docx
The Influence and Evolution of Mogul Press in Contemporary Public Relations.docx
 
Deciding The Topic of our Magazine.pptx.
Deciding The Topic of our Magazine.pptx.Deciding The Topic of our Magazine.pptx.
Deciding The Topic of our Magazine.pptx.
 
05232024 Joint Meeting - Community Networking
05232024 Joint Meeting - Community Networking05232024 Joint Meeting - Community Networking
05232024 Joint Meeting - Community Networking
 

Shell Script 4 DBAs