Basic Brilliant Scripting for Beginners. Bryce Carlson
|
|
- Adelia Pierce
- 5 years ago
- Views:
Transcription
1 Basic Brilliant Scripting for Beginners Bryce Carlson
2 Basic Bash for Beginners Basic Brilliant Scripting for Beginners Bryce Carlson
3 bash script for macos
4 Bryce Carlson Senior Support Engineer at Jamf Previously at (pre 1/2016): UW - Green Bay Appleton Area School District
5
6 Agenda Why use a script? Basic anatomy of a script Logic Results (for Inventory) End User interaction in scripts Good commands to have Questions
7
8 Why use a script?
9 Command - Set Time Zone sudo systemsetup -settimezone America/Chicago
10 Command - Set Time Zone and sudo systemsetup -settimezone America/Chicago sudo systemsetup -setnetworktimeserver time.apple.com sudo ntpdate -u time.apple.com
11 Command - Set Time Zone and Last login: Mon Jun 18 15:27:23 on ttys000 carlson-jamf-mbp:~ bryce$ sudo systemsetup -settimezone America/ Chicago Set TimeZone: America/Chicago carlson-jamf-mbp:~ bryce$ sudo systemsetup -setnetworktimeserver time.apple.com setnetworktimeserver: time.apple.com carlson-jamf-mbp:~ bryce$ sudo ntpdate -u time.apple.com 19 Jun 15:28:36 ntpdate[6607]: adjust time server offset sec carlson-jamf-mbp:~ bryce$
12 !? ~/Desktop/some-script.txt
13 Text/Script Editors sudo nano
14 Text/Script Editors
15 !/bin/sh This script will set system timezone, NTP Server, and sync the clock, and remove skew set to US Central Time systemsetup -settimezone America/Chicago set ntp server to time.apple.com systemsetup -setnetworktimeserver time.apple.com runs an ntp update ntpdate -u time.apple.com
16 Basic anatomy of a script
17 The Script!/bin/sh This script will set system timezone, NTP Server, and sync the clock, and remove skew set to US Central Time systemsetup -settimezone America/Chicago set ntp server to time.apple.com systemsetup -setnetworktimeserver time.apple.com runs an ntp update ntpdate -u time.apple.com
18 !/bin/sh Interpreter line The Script = Comment This script will set system timezone, NTP Server, and sync the clock, and remove skew set to US Central Time systemsetup -settimezone America/Chicago set ntp server to time.apple.com systemsetup -setnetworktimeserver time.apple.com runs an ntp update ntpdate -u time.apple.com Command to run
19 The Script ~/Desktop/scripts/set-ntp.sh sudo sh ~/Desktop/scripts/set-ntp.sh!/bin/sh This script will set system timezone, NTP Server, and sync the clock, and remove skew set to US Central Time systemsetup -settimezone America/Chicago set ntp server to time.apple.com systemsetup -setnetworktimeserver time.apple.com runs an ntp update ntpdate -u time.apple.com
20 Logic
21 Logic IF, THEN, DO, ELSE, DO, FI WHILE, DO, DONE
22 Logic IF, THEN, DO, ELSE, DO, FI If we have this file, then do this command. If not move on. WHILE, DO, DONE While this file is here do this. When it is gone, or if it was never there move on.
23 IF THEN Example THEN DO IF FI.app ELSE DO
24 !/bin/sh if [ -f "/Applications/Minecraft.app" ]; then rm /Applications/Minecraft.app else say Thanks for not playing games fi
25 !/bin/sh if [ -f "/Applications/Minecraft.app" ]; then rm /Applications/Minecraft.app else say Thanks for not playing games fi Operator
26 !/bin/sh if [ -f "/Applications/Minecraft.app" ]; then rm /Applications/Minecraft.app else osascript -e 'display notification "Thanks for not playing games." with title Thanks!"' fi
27 Logic - Operators Operator What it does -f Looks for file -d Looks for folder File X -nt File Y If file X is newer than file Y (according to modification date) File X -ot File Y If file X is older than file Y x = y Value equals value x!= y Value does not equal value x -gt y X is greater than Y x -lt y X is less than Y
28 Logic - Operators carlson-jamf-mbp:~ bryce$ help test
29 WHILE DO Example WHILE DO DONE.app
30 !/bin/sh while [ -f /Applications/Minecraft.app ]; do echo The game is here; removing rm /Applications/Minecraft.app done echo All good here we will move on now"
31 WHILE DO Example DO WHILE sleep 60 DONE.appdownload
32 !/bin/sh while [ -f /Applications/*.appdownload ]; do echo "Apps Installing" sleep 60 done echo "Apps Done Installing"
33 Results (for Inventory)
34 Scenarios You want to know the date and time of the last password change for your technician account on client Macs. Security auditing needs to know if the Security Update is installed on client Macs.
35 User s last password change dscl. read /Users/ladmin grep --context=3 passwordlastsettime carlson-jamf-mbp:~ bryce$ dscl. read /Users/ladmin grep --context=3 passwordlastsettime <integer>0</integer> <key>failedlogintimestamp</key> <integer>0</integer> <key>passwordlastsettime</key> <real> </real> </dict> </plist>
36 User s last password change!/bin/sh grabs and stores user PW info and strips EPOCH to one number etime=`dscl. read /Users/ladmin grep --context=3 passwordlastsettime` etime2=`echo $etime sed -n 's:.*<real>\(.*\)</real>.*:\1:p'` etime3=`echo ${etime2%.*}` real time rtime=`date -r $etime3 '+%m/%d/%y:%h:%m:%s'` echo "<result>$rtime</result>" exit 0
37 User s last password change!/bin/sh grabs and stores user PW info and strips EPOCH to one number etime=`dscl. read /Users/ladmin grep --context=3 passwordlastsettime` etime2=`echo $etime sed -n 's:.*<real>\(.*\)</real>.*:\1:p'` List users etime3=`echo ${etime2%.*}` cuts tags Variable = real time grave accent rtime=`date -r $etime3 '+%m/%d/%y:%h:%m:%s'` echo "<result>$rtime</result>" $var date exit 0 $var
38 User s last password change
39 User s last password change
40 User s last password change!/bin/sh grabs and stores user PW info and strips EPOCH to one number etime=`dscl. read /Users/ladmin grep --context=3 passwordlastsettime` etime2=`echo $etime sed -n 's:.*<real>\(.*\)</real>.*:\1:p'` etime3=`echo ${etime2%.*}` real time rtime=`date -r $etime3 '+%m/%d/%y:%h:%m:%s'` echo $rtime >> /Library/Globodyne/tech-admin-date-of-lastchange.txt Output
41 Security Update ? /usr/sbin/system_profiler SPInstallHistoryDataType carlson-jamf-mbp:~ bryce$ /usr/sbin/system_profiler SPInstallHistoryDataType Installations: SU_TITLE: Version: Source: Apple Install Date: 4/1/18, 4:40 PM QuickAdd: Version: Source: 3rd Party Install Date: 4/1/18, 5:07 PM
42 Security Update ?!/bin/sh grabs and stores user SU info if Security Update is there swupdatelist=`/usr/sbin/system_profiler SPInstallHistoryDataType grep "Security Update " awk '{ print $3 }'` swq=${swupdatelist%?}; swa=" " if [[ "$swq" == "$swa" ]]; then echo "<result>yes; Security Update is installed.</ result>" else echo "<result>no; Security Update is not installed.</ result>" fi
43 Security Update ?!/bin/sh grabs and stores user SU info if Security Update is there swupdatelist=`/usr/sbin/system_profiler SPInstallHistoryDataType grep "Security Update " awk '{ print $3 }'` swq=${swupdatelist%?}; swa=" " if [[ "$swq" == "$swa" ]]; then echo "<result>yes; Security Update is installed.</ result>" else echo "<result>no; Security Update is not installed.</ result>" fi One var is like the other
44 Security Update ?
45 Security Update ?
46 Security Update ?!/bin/sh grabs and stores user SU info if Security Update is there swupdatelist=`/usr/sbin/system_profiler SPInstallHistoryDataType grep "Security Update " awk '{ print $3 }'` swq=${swupdatelist%?}; swa=" " if [[ "$swq" == "$swa" ]]; then echo Yes SU > /Library/Globodyne/swu stat.txt else echo No SU > /Library/Globodyne/swu stat.txt fi exit 0
47 Security Update ?!/bin/sh grabs and stores user SU info if Security Update is there swupdatelist=`/usr/sbin/system_profiler SPInstallHistoryDataType grep "Security Update " awk '{ print $3 }'` swq=${swupdatelist%?}; swa=" " if [[ "$swq" == "$swa" ]]; then echo Yes SU > /Library/Globodyne/swu stat.txt else echo No SU > /Library/Globodyne/swu stat.txt fi exit 0 Output
48 End User interaction in scripts
49 !/bin/sh userprompt= $(osascript -e 'display dialog Is this a question for the user? buttons {"Yes", "No"} default button "No"')" if [ "$userprompt" = "button returned:yes" ]; then echo They said yes else echo They said no fi
50 !/bin/sh userprompt= $(osascript -e 'display dialog Is this a question for the user? buttons {"Yes", "No"} default button "No"')" if [ "$userprompt" = "button returned:yes" ]; then else fi Command in var echo They said yes echo They said no If $var = then
51 Scenario Mac users in the graphics area of the organization are talking about running low on disk free space. How can we help them clean up?
52 Disk free df / carlson-jamf-mbp:~ bryce$ df / awk '/dev\/disk/ {print substr($5,1,length($5) - 1)}' 59 carlson-jamf-mbp:~ bryce$ df / awk '/dev\/disk/ {print $5}' 59% carlson-jamf-mbp:~ bryce$ df / Filesystem 512-blocks Used Available Capacity iused ifree %iused Mounted on /dev/disk1s % % /
53 !/bin/sh diskusednumonly=`df / awk '/dev\/disk/ {print substr($5,1,length($5) - 1)}'` currentuser=`ls -l /dev/console awk '/ / { print $3 }'` diskusageallowed="90" if [ "$diskusednumonly" -gt "$diskusageallowed" ]; then echo "The drive is more that 90 percent full. Will ask user for clean up." if [ "$(osascript -e 'display dialog "Looks like your boot drive is getting full. Can we clean Caches?" buttons {"Yes", "No"} default button "No"')" = "button returned:yes" ]; then echo "Cleaning end user home folder" rm -rf /Users/$currentuser/Library/Caches/* else echo "No need to clean; user says they will" fi else echo "No need to clean. Drive is free." fi
54 !/bin/sh diskusednumonly=`df / awk '/dev\/disk/ {print substr($5,1,length($5) - 1)}'` currentuser=`ls -l /dev/console awk '/ / { print $3 }'` diskusageallowed="90" Disk free if [ "$diskusednumonly" -gt "$diskusageallowed" ]; then echo "The drive is more that 90 percent full. Will ask user for clean up." if [ "$(osascript -e 'display dialog "Looks like your boot drive is getting full. Can we clean Caches?" buttons {"Yes", "No"} default button "No"')" = "button returned:yes" ]; then echo "Cleaning end user home folder" rm -rf /Users/$currentuser/Library/Caches/* else Nested if Greater than Current user print echo "No need to clean; user says they will" fi else echo "No need to clean. Drive is free." fi
55 Recap Why use a script? Basic anatomy of a script Logic IF, THEN, DO, ELSE, DO, FI WHILE, DO, DONE Operators Results (for Inventory) Extension Attribute To a file End User interaction in scripts osascript - Open Scripting Architecture
56 Good commands to have man ANY COMMAND HERE mdfind "kmditemappstorecategorytype == '*game*'" carlson-jamf-mbp:~ bryce$ mdfind "kmditemappstorecategorytype == '*game*'" /Applications/Chess.app installer -pkg /path/to/some.pkg -target / sudo chmod +x /path/to/some/script.sh
57 Questions?
58 Thank Feedback:
59 Topics that came up after session Apple s Shell Scripting Primer OpenSource/Conceptual/ShellScripting/shell_scripts/shell_scripts.html How do I launch a script as a user at their log in, or not have it auto launch Launch agent More info here: bash Cookbook by O'Reilly Media
60 Topics that came up after session Manuals - Bash Reference Manual BASH Reference - SS64 Bash Index A-Z - The Linux Documentation Project: Guides - Bash cheat sheet PDF, from Learn Code the Hard Way - ShellCheck shell script analysis tool - explainshell.com - bash keyboard shortcuts Bash SS64.com - MAN PAGES - HOW TO READ MAN PAGES - SS64 Bash Index A-Z Thanks to Joseph K. for these!
61 Topics that came up after session Thanks to Joseph K. for these! - Bash Guide for Beginners - BASH Programming - Introduction HOW-TO - The Bash Academy - Advanced Bash-Scripting Guide - Linux Tutorial Introduction Linux Survival - Bash Scripting Tutorial - Ryans Tutorials - Learn Bash Scripts - Tutorial - YouTube - Learn X in Y Minutes: Scenic Programming Language Tours - The Beginner s Guide to Shell Scripting: The Basics - UNIX / Linux Tutorial for Beginners - Getting to Know the Command Line David Baumgold - The Linux Basics Course - YouTube - Unix for Mac OS X Users Introduction.html - developer.apple.com - Shell Scripting Primer
62 Topics that came up after session Thanks to Joseph K. for these! - Terminus srchtrk=index%3a0%0alinktypeid%3a2%0aq%3abash%0apage%3a1%0as%3arelevance%0asa%3atrue%0aproducttypeid%3a2 - Up and Running with Bash Scripting - LinuxCommand.org: Learn the Linux command line. Write shell scripts. - Learn the Linux Command Line: The Basics - Udacity - Linux Command Line Basics - Learn Python The Hard Way - Command Line Crash Course - Learn the Command Line Codecademy - Master Command Line Interface Basics JAMF Software
Bash, In A NutShell RUSTY MYERS - SYSTEMS ADMINISTRATOR, PENN STATE CHRIS LAWSON - IT CONSULTANT/SUPPORT SPECIALIST, PENN STATE ALTOONA
Bash, In A NutShell RUSTY MYERS - SYSTEMS ADMINISTRATOR, PENN STATE CHRIS LAWSON - IT CONSULTANT/SUPPORT SPECIALIST, PENN STATE ALTOONA BASH, IN A NUTSHELL What is bash? Brian Fox 1989 Bourne Again Shell
More informationScripting OS X. Armin Briegel. Mac Admin, Consultant and Author
Scripting OS X Armin Briegel Mac Admin, Consultant and Author Scripting OS X Armin Briegel Mac Admin, Consultant and Author Scripting Bash Armin Briegel Mac Admin, Consultant and Author Scripting Bash
More informationIntroduction to the shell Part II
Introduction to the shell Part II Graham Markall http://www.doc.ic.ac.uk/~grm08 grm08@doc.ic.ac.uk Civil Engineering Tech Talks 16 th November, 1pm Last week Covered applications and Windows compatibility
More informationVi & Shell Scripting
Vi & Shell Scripting Comp-206 : Introduction to Week 3 Joseph Vybihal Computer Science McGill University Announcements Sina Meraji's office hours Trottier 3rd floor open area Tuesday 1:30 2:30 PM Thursday
More informationThis tutorial will guide you how to setup and run your own minecraft server on a Linux CentOS 6 in no time.
This tutorial will guide you how to setup and run your own minecraft server on a Linux CentOS 6 in no time. Running your own server lets you play together with your friends and family with your own set
More informationScripting. Randy Saeks Network Administrator Northbrook / Glenview School District 30
Scripting Randy Saeks Network Administrator Northbrook / Glenview School District 30 rsaeks@district30.k12.il.us 1 Scripting What is it? Why do it? Flavors 2 3 AppleScript Automator Shell Ability to record
More informationMore Raspian. An editor Configuration files Shell scripts Shell variables System admin
More Raspian An editor Configuration files Shell scripts Shell variables System admin Nano, a simple editor Nano does not require the mouse. You must use your keyboard to move around the file and make
More informationLINUX FUNDAMENTALS. Supported Distributions: Red Hat Enterprise Linux 6 SUSE Linux Enterprise 11 Ubuntu LTS. Recommended Class Length: 5 days
LINUX FUNDAMENTALS The course is a challenging course that focuses on the fundamental tools and concepts of Linux and Unix. Students gain proficiency using the command line. Beginners develop a solid foundation
More informationBourne Shell Reference
> Linux Reviews > Beginners: Learn Linux > Bourne Shell Reference Bourne Shell Reference found at Br. David Carlson, O.S.B. pages, cis.stvincent.edu/carlsond/cs330/unix/bshellref - Converted to txt2tags
More informationThe Unix Shell & Shell Scripts
The Unix Shell & Shell Scripts You should do steps 1 to 7 before going to the lab. Use the Linux system you installed in the previous lab. In the lab do step 8, the TA may give you additional exercises
More information9.2 Linux Essentials Exam Objectives
9.2 Linux Essentials Exam Objectives This chapter will cover the topics for the following Linux Essentials exam objectives: Topic 3: The Power of the Command Line (weight: 10) 3.3: Turning Commands into
More informationUseful Unix Commands Cheat Sheet
Useful Unix Commands Cheat Sheet The Chinese University of Hong Kong SIGSC Training (Fall 2016) FILE AND DIRECTORY pwd Return path to current directory. ls List directories and files here. ls dir List
More informationCS Unix Tools & Scripting
Cornell University, Spring 2014 1 February 24, 2014 1 Slides evolved from previous versions by Hussam Abu-Libdeh and David Slater A note on awk for (item in array) The order in which items are returned
More informationPerl and R Scripting for Biologists
Perl and R Scripting for Biologists Lukas Mueller PLBR 4092 Course overview Linux basics (today) Linux advanced (Aure, next week) Why Linux? Free open source operating system based on UNIX specifications
More informationShell. SSE2034: System Software Experiment 3, Fall 2018, Jinkyu Jeong
Shell Prof. Jinkyu Jeong (Jinkyu@skku.edu) TA -- Minwoo Ahn (minwoo.ahn@csl.skku.edu) TA -- Donghyun Kim (donghyun.kim@csl.skku.edu) Computer Systems Laboratory Sungkyunkwan University http://csl.skku.edu
More informationNew to Mac. Viewing Options in Finder:
New to Mac Finder Preferences Finder helps you find and organize your files. To set Finder preferences, click on your desktop > Click Finder on the top left menu > Preferences. General Check External Hard
More informationHow To Use The UNIX-LINUX Vi Text Editor: Tips, Tricks, And Techniques (And Tutorials Too!) By Larry L. Smith READ ONLINE
How To Use The UNIX-LINUX Vi Text Editor: Tips, Tricks, And Techniques (And Tutorials Too!) By Larry L. Smith READ ONLINE How To Use the UNIX-LINUX vi Text Editor: Tips, Tricks, and - This book, which
More informationLinux Fundamentals (L-120)
Linux Fundamentals (L-120) Modality: Virtual Classroom Duration: 5 Days SUBSCRIPTION: Master, Master Plus About this course: This is a challenging course that focuses on the fundamental tools and concepts
More informationPrerequisites: Students should be comfortable with computers. No familiarity with Linux or other Unix operating systems is required.
GL-120: Linux Fundamentals Course Length: 4 days Course Description: The GL120 is a challenging course that focuses on the fundamental tools and concepts of Linux and Unix. Students gain proficiency using
More informationShells & Shell Programming (Part B)
Shells & Shell Programming (Part B) Software Tools EECS2031 Winter 2018 Manos Papagelis Thanks to Karen Reid and Alan J Rosenthal for material in these slides CONTROL STATEMENTS 2 Control Statements Conditional
More informationLINUX FUNDAMENTALS (5 Day)
www.peaklearningllc.com LINUX FUNDAMENTALS (5 Day) Designed to provide the essential skills needed to be proficient at the Unix or Linux command line. This challenging course focuses on the fundamental
More informationDOWNLOAD OR READ : UNIX FOR MAC OS X 10 4 TIGER VISUAL QUICKPRO GUIDE PDF EBOOK EPUB MOBI
DOWNLOAD OR READ : UNIX FOR MAC OS X 10 4 TIGER VISUAL QUICKPRO GUIDE PDF EBOOK EPUB MOBI Page 1 Page 2 unix for mac os x 10 4 tiger visual quickpro guide unix for mac os pdf unix for mac os x 10 4 tiger
More information15-Minute Linux DFIR Triage. Dr. Phil Polstra Bloomsburg University of Pennsylvania
15-Minute Linux DFIR Triage Dr. Phil Polstra Bloomsburg University of Pennsylvania What is this talk about? Determining with some certainty if you have been hacked In a matter of minutes With minimal disturbance
More informationThe student will have the essential skills needed to be proficient at the Unix or Linux command line.
Table of Contents Introduction Audience At Course Completion Prerequisites Certified Professional Exams Student Materials Course Outline Introduction This challenging course focuses on the fundamental
More informationExercise sheet 1 To be corrected in tutorials in the week from 23/10/2017 to 27/10/2017
Einführung in die Programmierung für Physiker WS 207/208 Marc Wagner Francesca Cuteri: cuteri@th.physik.uni-frankfurt.de Alessandro Sciarra: sciarra@th.physik.uni-frankfurt.de Exercise sheet To be corrected
More informationDeploying Code42 CrashPlan with Jamf Pro. Technical Paper Jamf Pro 9.0 or Later 21 January 2019
Deploying Code42 CrashPlan with Jamf Pro Technical Paper Jamf Pro 9.0 or Later 21 January 2019 copyright 2002-2019 Jamf. All rights reserved. Jamf has made all efforts to ensure that this guide is accurate.
More informationIntroduction to the Linux Command Line January Presentation Topics
1/22/13 Introduction to the Linux Command Line January 2013 Presented by Oralee Nudson ARSC User Consultant & Student Supervisor onudson@alaska.edu Presentation Topics Information Assurance and Security
More informationMac Os X Terminal User Guide
Mac Os X Terminal User Guide 10.7.4 First Mac OS X is Unix based so any book on the bash shell will be helpful. There are some differences between the Mac and older Unix systems. One I know is the default
More informationPart I. UNIX Workshop Series: Quick-Start
Part I UNIX Workshop Series: Quick-Start Objectives Overview Connecting with ssh Command Window Anatomy Command Structure Command Examples Getting Help Files and Directories Wildcards, Redirection and
More informationBasic Linux Commands Manual Pdf Examples And Syntax
Basic Linux Commands Manual Pdf Examples And Syntax each command. More information and free.pdf available at linux-training.be. GNU Free Documentation License, Version 1.3 or any later version. This is
More informationShells and Shell Programming
Shells and Shell Programming 1 Shells A shell is a command line interpreter that is the interface between the user and the OS. The shell: analyzes each command determines what actions are to be performed
More informationLinux Essentials. Smith, Roderick W. Table of Contents ISBN-13: Introduction xvii. Chapter 1 Selecting an Operating System 1
Linux Essentials Smith, Roderick W. ISBN-13: 9781118106792 Table of Contents Introduction xvii Chapter 1 Selecting an Operating System 1 What Is an OS? 1 What Is a Kernel? 1 What Else Identifies an OS?
More informationПрограмиранев UNIX среда
Програмиранев UNIX среда Използванена команден шел и създаванена скриптове: tcsh, bash, awk, python Shell programming As well as using the shell to run commands you can use its built-in programming language
More informationShell Programming Systems Skills in C and Unix
Shell Programming 15-123 Systems Skills in C and Unix The Shell A command line interpreter that provides the interface to Unix OS. What Shell are we on? echo $SHELL Most unix systems have Bourne shell
More informationNetwork softwarization Lab session 2: OS Virtualization Networking
Network softwarization Lab session 2: OS Virtualization Networking Nicolas Herbaut David Bourasseau Daniel Negru December 16, 2015 1 Introduction 1.1 Discovering docker 1.1.1 Installation Please launch
More informationDOC SHELL LINUX TUTORIAL ARCHIVE
11 January, 2018 DOC SHELL LINUX TUTORIAL ARCHIVE Document Filetype: PDF 453.65 KB 0 DOC SHELL LINUX TUTORIAL ARCHIVE Learn Linux / Unix shell scripting by example along with the theory. This tutorial
More informationLPI102 EXAM PREPARATION LPIC-1 (LINUX PROFESSIONAL INSTITUTE)
LPI102 EXAM PREPARATION LPIC-1 (LINUX PROFESSIONAL INSTITUTE) COURSE DESCRIPTION: This course prepares students to take the LPI 102 exam of the LPI level 1 certification. The LPI objectives covered are
More informationLinux for Beginners. Windows users should download putty or bitvise:
Linux for Beginners Windows users should download putty or bitvise: https://putty.org/ Brief History UNIX (1969) written in PDP-7 assembly, not portable, and designed for programmers as a reaction by Bell
More informationShells and Shell Programming
Shells and Shell Programming Shells A shell is a command line interpreter that is the interface between the user and the OS. The shell: analyzes each command determines what actions are to be performed
More informationLinux Systems Administration Getting Started with Linux
Linux Systems Administration Getting Started with Linux Network Startup Resource Center www.nsrc.org These materials are licensed under the Creative Commons Attribution-NonCommercial 4.0 International
More informationLab 5a Shell Script Lab 4 Using Arithmetic Operators in shell script
Lab 5a Shell Script Lab 4 Using Arithmetic Operators in shell script Objective Upon completion of this lab, the student will be able to use arithmetic operators in Linux shell script. Scenario The student
More informationCONFIGURING BASIC MACOS MANAGEMENT: VMWARE WORKSPACE ONE OPERATIONAL TUTORIAL VMware Workspace ONE
GUIDE FEBRUARY 2019 PRINTED 26 FEBRUARY 2019 CONFIGURING BASIC MACOS MANAGEMENT: VMWARE WORKSPACE ONE OPERATIONAL TUTORIAL VMware Workspace ONE Table of Contents Overview Introduction Purpose Audience
More informationManual Shell Scripting Linux Examples Pdf Tutorial
Manual Shell Scripting Linux Examples Pdf Tutorial Click Here to buy the full 86-page PDF for only 4.99, $9.99 or 6.99, or the Kindle ebook Learn Linux / Unix shell scripting by example along with the
More informationPrerequisites: Students must be proficient in general computing skills but not necessarily experienced with Linux or Unix. Supported Distributions:
This GL124 course is designed to follow an identical set of topics as the Red Hat RH124 course with the added benefit of very comprehensive lab exercises and detailed lecture material. The Red Hat Enterprise
More informationManually Kill Process Mac Os X Terminal Running
Manually Kill Process Mac Os X Terminal Running If you've ever been using your Mac and had an application hang (Spinning Normally, most applications run fairly well on OS X and the spinning You can open
More informationGetting Started with Python
Getting Started with Python Python is a general purpose, high level programming language that is used in a variety of application domains. The Python language has a very clear and expressive syntax as
More informationIntroduction: What is Unix?
Introduction Introduction: What is Unix? An operating system Developed at AT&T Bell Labs in the 1960 s Command Line Interpreter GUIs (Window systems) are now available Introduction: Unix vs. Linux Unix
More informationmacos Security Checklist:
WHITE PAPER macos Security Checklist: implementing the Center for Internet Security Benchmark for macos Recommendations for securing macos The Center for Internet Security (CIS) benchmark for macos is
More informationContents. Note: pay attention to where you are. Note: Plaintext version. Note: pay attention to where you are... 1 Note: Plaintext version...
Contents Note: pay attention to where you are........................................... 1 Note: Plaintext version................................................... 1 Hello World of the Bash shell 2 Accessing
More informationUse Jamf Self Service to upgrade to macos Mojave
Use Jamf Self Service to upgrade to macos Mojave REV20180601 Project Technology & Best Practice Recommendations Overview The purpose of this document is to supply guidance and best practice solutions to
More informationAssignment clarifications
Assignment clarifications How many errors to print? at most 1 per token. Interpretation of white space in { } treat as a valid extension, involving white space characters. Assignment FAQs have been updated.
More informationPhp Scripts If Then Else Linux Bash Shell
Php Scripts If Then Else Linux Bash Shell I am using awk as part of and if then else statement. KSH, CSH, SH, BASH, PERL, PHP, SED, AWK and shell scripts and shell scripting languages here. I just wrote
More informationMacSysAdmin 2016 Which Version is This?
MacSysAdmin 2016 Which Version is This? Duncan McCracken Mondada Pty Ltd Remember When The Game Has Changed Frequency of Updates BYOD Environments Developers are Anarchists What Happens If... An App is
More informationUpgrade Tool Guide. July
Upgrade Tool Guide July 2015 http://www.liveaction.com 4.X to 5.0 The Upgrade Guide from 4.X to 5.0 consists of three parts: Upgrading the LiveAction Server Upgrading the LiveAction Node Upgrading the
More informationOctagon Plugin Environment. using a virtual machine
Octagon Plugin Development Environment using a virtual machine done by maxodil www.octagon-forum.com V.1.0 Introduction: The goal of this project is setting up a plugin development environment for Octagon
More informationUsing Doxygen to Create Xcode Documentation Sets
Using Doxygen to Create Xcode Documentation Sets Documentation sets (doc sets) provide a convenient way for an Xcode developer to search API and conceptual documentation (including guides, tutorials, TechNotes,
More informationUoW HPC Quick Start. Information Technology Services University of Wollongong. ( Last updated on October 10, 2011)
UoW HPC Quick Start Information Technology Services University of Wollongong ( Last updated on October 10, 2011) 1 Contents 1 Logging into the HPC Cluster 3 1.1 From within the UoW campus.......................
More informationCISC 220 fall 2011, set 1: Linux basics
CISC 220: System-Level Programming instructor: Margaret Lamb e-mail: malamb@cs.queensu.ca office: Goodwin 554 office phone: 533-6059 (internal extension 36059) office hours: Tues/Wed/Thurs 2-3 (this week
More informationAX88179/AX88178A Mac OS X Driver Installation Guide
AX88179/AX88178A Mac OS X Driver Installation Guide Revision 1.00 Sep. 10 th, 2012 1 Revision Date Description 1.00 2012/09/10 Initial release. AX88179/AX88178A Revision History 2 Contents 1. Introduction...
More informationGrep and Shell Programming
Grep and Shell Programming Comp-206 : Introduction to Software Systems Lecture 7 Alexandre Denault Computer Science McGill University Fall 2006 Teacher's Assistants Michael Hawker Monday, 14h30 to 16h30
More informationCasper Suite Release Notes. Version 8.5
Casper Suite Release Notes Version 8.5 JAMF Software, LLC 2012 JAMF Software, LLC. All rights reserved. JAMF Software has made all efforts to ensure that this guide is accurate. JAMF Software 301 4th Ave
More informationCS197U: A Hands on Introduction to Unix
CS197U: A Hands on Introduction to Unix Lecture 11: WWW and Wrap up Tian Guo University of Massachusetts Amherst CICS 1 Reminders Assignment 4 was graded and scores on Moodle Assignment 5 was due and you
More informationUNIX System Programming Lecture 3: BASH Programming
UNIX System Programming Outline Filesystems Redirection Shell Programming Reference BLP: Chapter 2 BFAQ: Bash FAQ BMAN: Bash man page BPRI: Bash Programming Introduction BABS: Advanced Bash Scripting Guide
More informationAdvanced Unix Programming Module 03 Raju Alluri spurthi.com
Advanced Unix Programming Module 03 Raju Alluri askraju @ spurthi.com Advanced Unix Programming: Module 3 Shells & Shell Programming Environment Variables Writing Simple Shell Programs (shell scripts)
More informationGNU/Linux 101. Casey McLaughlin. Research Computing Center Spring Workshop Series 2018
GNU/Linux 101 Casey McLaughlin Research Computing Center Spring Workshop Series 2018 rccworkshop IC;3df4mu bash-2.1~# man workshop Linux101 RCC Workshop L101 OBJECTIVES - Operating system concepts - Linux
More informationShell Programming (bash)
Shell Programming Shell Programming (bash) Commands run from a file in a subshell A great way to automate a repeated sequence of commands. File starts with #!/bin/bash absolute path to the shell program
More informationIntroduction to UNIX I: Command Line 1 / 21
Introduction to UNIX I: Command Line 1 / 21 UNIX Command line The UNIX Shell: command line interface Navigating Directories and Files Running applications Reminder about helpful tutorial: http://korflab.ucdavis.edu/unix_and_perl/current.html
More informationUnix Guide. Meher Krishna Patel. Created on : Octorber, 2017 Last updated : December, More documents are freely available at PythonDSP
Unix Guide Meher Krishna Patel Created on : Octorber, 2017 Last updated : December, 2017 More documents are freely available at PythonDSP Table of contents Table of contents i 1 Unix commands 1 1.1 Unix
More informationA Brief Introduction to the Linux Shell for Data Science
A Brief Introduction to the Linux Shell for Data Science Aris Anagnostopoulos 1 Introduction Here we will see a brief introduction of the Linux command line or shell as it is called. Linux is a Unix-like
More informationGetting Started with Linux Development
Getting Started with Linux Development VB-Linux on your Laptop First, on your Windows or Mac OS-X laptop, install Oracle Virtual-Box as follows: First, download Ubuntu Linux distribution 12.04.1, or newer
More informationmacos Security Checklist:
WHITE PAPER macos Security Checklist: implementing the Center for Internet Security Benchmark for macos Recommendations for securing macos The Center for Internet Security (CIS) benchmark for macos is
More informationD, E I, J, K. Generalized Regular Expression Parser (GREP), 110 Generic 105 key (Intl) PC, 29 git command, 242
Index A Advanced Linux Sound Architecture (ALSA) device, 214 Airplay amixer command, 252 boot, 255 build script, 254 Build.PL script, 254 central controlling system, 251 lsmod command, 252 make command,
More informationIntroduction p. 1 Who Should Read This Book? p. 1 What You Need to Know Before Reading This Book p. 2 How This Book Is Organized p.
Introduction p. 1 Who Should Read This Book? p. 1 What You Need to Know Before Reading This Book p. 2 How This Book Is Organized p. 2 Conventions Used in This Book p. 2 Introduction to UNIX p. 5 An Overview
More informationCS CS Tutorial 2 2 Winter 2018
CS CS 230 - Tutorial 2 2 Winter 2018 Sections 1. Unix Basics and connecting to CS environment 2. MIPS Introduction & CS230 Interface 3. Connecting Remotely If you haven t set up a CS environment password,
More informationIntroduction to UNIX. Logging in. Basic System Architecture 10/7/10. most systems have graphical login on Linux machines
Introduction to UNIX Logging in Basic system architecture Getting help Intro to shell (tcsh) Basic UNIX File Maintenance Intro to emacs I/O Redirection Shell scripts Logging in most systems have graphical
More informationArkansas High Performance Computing Center at the University of Arkansas
Arkansas High Performance Computing Center at the University of Arkansas AHPCC Workshop Series Introduction to Linux for HPC Why Linux? Compatible with many architectures OS of choice for large scale computing
More informationSchool District of Milton of Milton
School District of Milton of Milton Utilizing JAMF s Casper Suite - A comprehensive look at 1:1 Utilizing JAMF s Casper Suite - A Comprehensive Look at 1:1 Karl Senger sengerk@milton.k12.wi.us Matthew
More informationQuickStart Guide for Managing Computers. Version
QuickStart Guide for Managing Computers Version 10.2.0 copyright 2002-2018 Jamf. All rights reserved. Jamf has made all efforts to ensure that this guide is accurate. Jamf 100 Washington Ave S Suite 1100
More informationUNIX Concepts COMPSCI 386
UNIX Concepts COMPSCI 386 Topics History of C and UNIX The GNU Project Linux Command-Line Basics UNIX-Style File System Multics Multiplexed Information and Computing Service Time-sharing system for mainframes
More informationContainers. Pablo F. Ordóñez. October 18, 2018
Containers Pablo F. Ordóñez October 18, 2018 1 Welcome Song: Sola vaya Interpreter: La Sonora Ponceña 2 Goals Containers!= ( Moby-Dick ) Containers are part of the Linux Kernel Make your own container
More informationParallels Remote Application Server
Parallels Remote Application Server Parallels Client for Mac User's Guide v16 Parallels International GmbH Vordergasse 59 8200 Schaffhausen Switzerland Tel: + 41 52 672 20 30 www.parallels.com Copyright
More informationToday. Review. Unix as an OS case study Intro to Shell Scripting. What is an Operating System? What are its goals? How do we evaluate it?
Today Unix as an OS case study Intro to Shell Scripting Make sure the computer is in Linux If not, restart, holding down ALT key Login! Posted slides contain material not explicitly covered in class 1
More informationWhat's New with MunkiReport. John Eberle
What's New with MunkiReport John Eberle (@tuxudo) John: Desktop Engineer and Mac Admin @tuxudo @tuxudo github.com/tuxudo Table of Bananas Review of MunkiReport What's new with MunkiReport Upgrade from
More informationManual Shell Script Linux If Not Exist Directory Does
Manual Shell Script Linux If Not Exist Directory Does Bash can be configured to be POSIX-confor mant by default. and then a much longer manual available using info (usually they refer to the info page
More informationDAVE LIDDAMENT INTRODUCTION TO BASH
DAVE LIDDAMENT INTRODUCTION TO BASH @daveliddament FORMAT Short lectures Practical exercises (help each other) Write scripts LEARNING OBJECTIVES What is Bash When should you use Bash Basic concepts of
More informationIntroduction to Unix and Linux. Workshop 1: Directories and Files
Introduction to Unix and Linux Workshop 1: Directories and Files Genomics Core Lab TEXAS A&M UNIVERSITY CORPUS CHRISTI Anvesh Paidipala, Evan Krell, Kelly Pennoyer, Chris Bird Genomics Core Lab Informatics
More informationPuppet 101 Basic installation for master and agent machines on Ubuntu with VMware Workstation
Puppet 101 Basic installation for master and agent machines on Ubuntu 12.04 with VMware Workstation You don t have to go far to hear the word Puppet these days. Configuration management isn t just a new
More informationHitchhiker s Guide to VLSI Design with Cadence & Synopsys
Hitchhiker s Guide to VLSI Design with Cadence & Synopsys David Money Harris 17 January 2009 The VLSI design tools at Harvey Mudd College are hosted on a Linux server named chips. This document introduces
More informationIntroduction. Let s start with the first set of slides
Tux Wars Class - 1 Table of Contents 1) Introduction to Linux and its history 2) Booting process of a linux system 3) Linux Kernel 4) What is a shell 5) Bash Shell 6) Anatomy of command 7) Let s make our
More informationQuick Audience Survey. New to imaging on Macs? Have Mac OS X Server(s)? Basic Scripting Skills? Have Windows (SMB) Servers?
PSUMAC202: Imaging Remember us? Justin Elliott, Penn State University IT Manager, Classroom and Lab Computing Rusty Myers, Penn State University IT Support Specialist, College of Education Quick Audience
More informationSeaSonde on macos Sierra
SeaSonde on macos 10.12 Sierra 139.01.IG Aug 8, 2017 Installation Guide for SeaSonde on macos 10.12 (Sierra) This document outlines the proper method for configuring a Macintosh computer with macos version
More informationAdafruit's Raspberry Pi Lesson 1. Preparing an SD Card for your Raspberry Pi
Adafruit's Raspberry Pi Lesson 1. Preparing an SD Card for your Raspberry Pi Created by Simon Monk Last updated on 2013-07-08 12:15:38 PM EDT Guide Contents Guide Contents Overview You Will Need Downloading
More informationIntroduction to Supercomputing
Introduction to Supercomputing TMA4280 Introduction to UNIX environment and tools 0.1 Getting started with the environment and the bash shell interpreter Desktop computers are usually operated from a graphical
More informationDCLI User's Guide. Modified on 20 SEP 2018 Data Center Command-Line Interface
Modified on 20 SEP 2018 Data Center Command-Line Interface 2.10.0 You can find the most up-to-date technical documentation on the VMware website at: https://docs.vmware.com/ If you have comments about
More informationCSCI 211 UNIX Lab. Shell Programming. Dr. Jiang Li. Jiang Li, Ph.D. Department of Computer Science
CSCI 211 UNIX Lab Shell Programming Dr. Jiang Li Why Shell Scripting Saves a lot of typing A shell script can run many commands at once A shell script can repeatedly run commands Help avoid mistakes Once
More informationLecture # 2 Introduction to UNIX (Part 2)
CS390 UNIX Programming Spring 2009 Page 1 Lecture # 2 Introduction to UNIX (Part 2) UNIX is case sensitive (lowercase, lowercase, lowercase) Logging in (Terminal Method) Two basic techniques: 1. Network
More informationStartup, Login, Logout scripts. By James Reynolds
Startup, Login, Logout scripts By James Reynolds Startup, Login, Logout scripts Startup script? Runs at startup time Login script? Runs right after user authenticates Runs before Finder loads Logout script?
More informationEssentials for Scientific Computing: Bash Shell Scripting Day 3
Essentials for Scientific Computing: Bash Shell Scripting Day 3 Ershaad Ahamed TUE-CMS, JNCASR May 2012 1 Introduction In the previous sessions, you have been using basic commands in the shell. The bash
More informationOn successful completion of the course, the students will be able to attain CO: Experiment linked. 2 to 4. 5 to 8. 9 to 12.
CIE- 25 Marks Government of Karnataka Department of Technical Education Bengaluru Course Title: Linux Lab Scheme (L:T:P) : 0:2:4 Total Contact Hours: 78 Type of Course: Tutorial, Practical s & Student
More informationLiveNX Upgrade Guide from v5.2.0 to v5.2.1
LIVEACTION, INC. LiveNX Upgrade Guide from v5.2.0 to v5.2.1 UPGRADE LiveAction, Inc. 3500 Copyright WEST BAYSHORE 2016 LiveAction, ROAD Inc. All rights reserved. LiveAction, LiveNX, LiveUX, the LiveAction
More information