SlideShare a Scribd company logo
1 of 51
Download to read offline
Automating the deployment of FreeBSD & PC-BSD® systemsAutomating the deployment of FreeBSD & PC-BSD® systems
Texas Linux Fest 2013Texas Linux Fest 2013
Kris MooreKris Moore
PC-BSD / iXsystemsPC-BSD / iXsystems
kris@pcbsd.orgkris@pcbsd.org
The problem:The problem:
You want to (quickly) deploy multipleYou want to (quickly) deploy multiple
FreeBSD or PC-BSD systems.FreeBSD or PC-BSD systems.
You like what you hear about this wholeYou like what you hear about this whole
“ZFS” thing“ZFS” thing
There are currently two ways to accomplishThere are currently two ways to accomplish
this:this:
Solution #1Solution #1
●
Write your own installation scriptsWrite your own installation scripts
●
Configure network booting by handConfigure network booting by hand
●
Maintain as necessaryMaintain as necessary
When to consider Solution #1:When to consider Solution #1:
●
You have a very unique installationYou have a very unique installation
●
You are a FreeBSD God – Congrats!You are a FreeBSD God – Congrats!
When to not consider Solution #1:When to not consider Solution #1:
●
Manual disk partitioning isn't your thingManual disk partitioning isn't your thing
●
You work for a livingYou work for a living
Solution #2Solution #2
●
Use theUse the pc-thinclientpc-thinclient utility included withutility included with
PC-BSD & TrueOSPC-BSD & TrueOS
When to consider Solution #2:When to consider Solution #2:
●
You don't enjoy disk partitioningYou don't enjoy disk partitioning
●
You want to have a weekendYou want to have a weekend
What you will need:What you will need:
●
A system with a network interface (2)?A system with a network interface (2)?
●
Running PC-BSD 9.1 / TrueOS 9.1Running PC-BSD 9.1 / TrueOS 9.1
●
A few GB of disk spaceA few GB of disk space
Getting StartedGetting Started
●
First, checkout a FreeBSD ports treeFirst, checkout a FreeBSD ports tree
On TrueOSOn TrueOS
# portsnap fetch extract update# portsnap fetch extract update
On PC-BSDOn PC-BSD
Control panel → System Manager → TasksControl panel → System Manager → Tasks
→ Fetch Ports→ Fetch Ports
Getting StartedGetting Started
Getting StartedGetting Started
Getting StartedGetting Started
●
Install serverInstall server
●
Or desktop “Thin-Client” serverOr desktop “Thin-Client” server
Short DetourShort Detour
What is Remote Desktop?What is Remote Desktop?
●
The thin-client utility can operate bothThe thin-client utility can operate both
install server or desktop serverinstall server or desktop server
●
Allows diskless clients to boot via PXEAllows diskless clients to boot via PXE
●
Brings up GDM login on clientBrings up GDM login on client
Why would you run Remote Desktop?Why would you run Remote Desktop?
●
You have a bunch of low-end clientsYou have a bunch of low-end clients
●
You want to simplify backup, security andYou want to simplify backup, security and
managementmanagement
Why should you not run Remote Desktop?Why should you not run Remote Desktop?
●
You don't have a server with horsepowerYou don't have a server with horsepower
●
You need sound support on the clientsYou need sound support on the clients
Back to your previously scheduledBack to your previously scheduled
presentationpresentation
Getting StartedGetting Started
●
Will run DHCPDWill run DHCPD
●
Be careful which cable is usedBe careful which cable is used
Getting StartedGetting Started
Getting startedGetting started
●
You may now connect a client systemYou may now connect a client system
●
To PXE boot, you may need to checkTo PXE boot, you may need to check
BIOS on client firstBIOS on client first
Its Demo time!Its Demo time!
Customizing the installCustomizing the install
●
Of course you will want your ownOf course you will want your own
installation options / archives, etcinstallation options / archives, etc
●
It is possible to adjust entirely on serverIt is possible to adjust entirely on server
sideside
The two key directories:The two key directories:
●
/home/thinclient/installscripts/home/thinclient/installscripts
●
/home/thinclient/installarchive/home/thinclient/installarchive
Client mounted as:Client mounted as:
●
/installscripts/installscripts
●
/installarchive/installarchive
●
pc-sysinstall.example can be used as apc-sysinstall.example can be used as a
template for other installationstemplate for other installations
Example #1Example #1
Changing to ZFSChanging to ZFS
Example disk layout:Example disk layout:
disk0-part=UFS+SUJ 1000 /disk0-part=UFS+SUJ 1000 /
disk0-part=SWAP 2000 nonedisk0-part=SWAP 2000 none
disk0-part=UFS+SUJ 0 /usrdisk0-part=UFS+SUJ 0 /usr
commitDiskLabelcommitDiskLabel
Converted to ZFS becomes:Converted to ZFS becomes:
disk0-part=ZFS 0 /,/root,/tmp,/usr,/vardisk0-part=ZFS 0 /,/root,/tmp,/usr,/var
commitDiskLabelcommitDiskLabel
Example #2Example #2
Changing installation archiveChanging installation archive
Example install archive:Example install archive:
installMedium=localinstallMedium=local
localPath=/installarchivelocalPath=/installarchive
packageType=tarpackageType=tar
installFile=fbsd-release.txzinstallFile=fbsd-release.txz
Changed to custom archive:Changed to custom archive:
installMedium=localinstallMedium=local
localPath=/installarchivelocalPath=/installarchive
packageType=tarpackageType=tar
installFile=fbsd-8.4-amd64.txzinstallFile=fbsd-8.4-amd64.txz
Example #3Example #3
User ManagementUser Management
# Root Password# Root Password
rootPass=rootrootPass=root
# User Setup# User Setup
userName=krisuserName=kris
userComment=Kris MooreuserComment=Kris Moore
userPass=krisuserPass=kris
userShell=/bin/cshuserShell=/bin/csh
userHome=/home/krisuserHome=/home/kris
userGroups=wheel,operatoruserGroups=wheel,operator
commitUsercommitUser
Example #4Example #4
Advanced CommandsAdvanced Commands
# Run command inside installed system# Run command inside installed system
runCommand=sh /root/initme.shrunCommand=sh /root/initme.sh
# Run command outside installed system# Run command outside installed system
runExtCommand=mount -t devfs devfs ${FSMNT}/devrunExtCommand=mount -t devfs devfs ${FSMNT}/dev
Example #5Example #5
Packages, oh my!Packages, oh my!
installPackages=apache22 mysql55-serverinstallPackages=apache22 mysql55-server
Can use short package names, or fullCan use short package names, or full
versions.versions.
PKGNG supportPKGNG support
●
Checks package format before installChecks package format before install
●
Will “boot-strap” PKGNG if necessaryWill “boot-strap” PKGNG if necessary
Example #6Example #6
FreeBSD dist filesFreeBSD dist files
# Install from vanilla FreeBSD dist files# Install from vanilla FreeBSD dist files
installMedium=localinstallMedium=local
localPath=/distfiles/9.1-Release/amd64/distlocalPath=/distfiles/9.1-Release/amd64/dist
packageType=distpackageType=dist
distFiles=base doc games kernel lib32distFiles=base doc games kernel lib32
Putting the Automated in “Fully Automated”Putting the Automated in “Fully Automated”
File: /home/thinclient/installscripts/unattended.cfgFile: /home/thinclient/installscripts/unattended.cfg
●
If config exists, the client will boot andIf config exists, the client will boot and
begin installation after 30 seconds.begin installation after 30 seconds.
●
System will shutdown when finishedSystem will shutdown when finished
●
USE WITH CAUTION!!USE WITH CAUTION!!
ScalabilityScalability
●
All CPU instructions are run on the clientAll CPU instructions are run on the client
●
Server is in essence a large “File Server”Server is in essence a large “File Server”
●
Will be mostly disk IO / network speedWill be mostly disk IO / network speed
dependentdependent
ScalabilityScalability
●
Default DHCP server is configured for 99Default DHCP server is configured for 99
clientsclients
●
To adjust edit the file:To adjust edit the file:
●
/usr/local/etc/dhcpd.conf/usr/local/etc/dhcpd.conf
●
range 192.168.2.100 192.168.2.199;range 192.168.2.100 192.168.2.199;
Tips and TricksTips and Tricks
●
To greatly speed up installations, use ZFSTo greatly speed up installations, use ZFS
mirrored drives, SSD, or even TMPFSmirrored drives, SSD, or even TMPFS
Tips and TricksTips and Tricks
●
The PC-BSD GUI installer is your friendThe PC-BSD GUI installer is your friend
●
Every install is a scripted installEvery install is a scripted install
●
After installation a copy of the pc-After installation a copy of the pc-
sysinstall.cfg file is saved to:sysinstall.cfg file is saved to:
●
/root/pc-sysinstallcfg/root/pc-sysinstallcfg
Generating Config filesGenerating Config files
What's next?What's next?
●
Improvements to pc-sysinstallImprovements to pc-sysinstall
●
Faster setup of initial thin-clientFaster setup of initial thin-client
environmentenvironment
Questions? Comments?Questions? Comments?
wiki.pcbsd.orgwiki.pcbsd.org
lists.pcbsd.orglists.pcbsd.org
forums.pcbsd.orgforums.pcbsd.org
Thank you!Thank you!
www.slideshare.net/krispcbsd/texas2013www.slideshare.net/krispcbsd/texas2013

More Related Content

What's hot

NFD9 - Matt Peterson, Data Center Operations
NFD9 - Matt Peterson, Data Center OperationsNFD9 - Matt Peterson, Data Center Operations
NFD9 - Matt Peterson, Data Center OperationsCumulus Networks
 
S4 xen hypervisor_20080622
S4 xen hypervisor_20080622S4 xen hypervisor_20080622
S4 xen hypervisor_20080622Todd Deshane
 
LOAD BALANCING OF APPLICATIONS USING XEN HYPERVISOR
LOAD BALANCING OF APPLICATIONS  USING XEN HYPERVISORLOAD BALANCING OF APPLICATIONS  USING XEN HYPERVISOR
LOAD BALANCING OF APPLICATIONS USING XEN HYPERVISORVanika Kapoor
 
Linux fundamental - Chap 12 Hardware Management
Linux fundamental - Chap 12 Hardware ManagementLinux fundamental - Chap 12 Hardware Management
Linux fundamental - Chap 12 Hardware ManagementKenny (netman)
 
What every data programmer needs to know about disks
What every data programmer needs to know about disksWhat every data programmer needs to know about disks
What every data programmer needs to know about disksiammutex
 
Comparison of-foss-distributed-storage
Comparison of-foss-distributed-storageComparison of-foss-distributed-storage
Comparison of-foss-distributed-storageMarian Marinov
 
Linux fundamental - Chap 08 proc
Linux fundamental - Chap 08 procLinux fundamental - Chap 08 proc
Linux fundamental - Chap 08 procKenny (netman)
 
Recipe of a linux Live CD (archived)
Recipe of a linux Live CD (archived)Recipe of a linux Live CD (archived)
Recipe of a linux Live CD (archived)Bud Siddhisena
 
Upgrade ux-fosdem-2015-gdhaese
Upgrade ux-fosdem-2015-gdhaeseUpgrade ux-fosdem-2015-gdhaese
Upgrade ux-fosdem-2015-gdhaeseGratien D'haese
 
Using cobbler in a not so small environment 1.77
Using cobbler in a not so small environment 1.77Using cobbler in a not so small environment 1.77
Using cobbler in a not so small environment 1.77chhorn
 
Jagan Teki - U-boot from scratch
Jagan Teki - U-boot from scratchJagan Teki - U-boot from scratch
Jagan Teki - U-boot from scratchlinuxlab_conf
 
OSDC 2016 - Interesting things you can do with ZFS by Allan Jude&Benedict Reu...
OSDC 2016 - Interesting things you can do with ZFS by Allan Jude&Benedict Reu...OSDC 2016 - Interesting things you can do with ZFS by Allan Jude&Benedict Reu...
OSDC 2016 - Interesting things you can do with ZFS by Allan Jude&Benedict Reu...NETWAYS
 
LSA2 - 01 Virtualization with KVM
LSA2 - 01 Virtualization with KVMLSA2 - 01 Virtualization with KVM
LSA2 - 01 Virtualization with KVMMarian Marinov
 
OpenWRT guide and memo
OpenWRT guide and memoOpenWRT guide and memo
OpenWRT guide and memo家榮 吳
 

What's hot (19)

NFD9 - Matt Peterson, Data Center Operations
NFD9 - Matt Peterson, Data Center OperationsNFD9 - Matt Peterson, Data Center Operations
NFD9 - Matt Peterson, Data Center Operations
 
S4 xen hypervisor_20080622
S4 xen hypervisor_20080622S4 xen hypervisor_20080622
S4 xen hypervisor_20080622
 
LOAD BALANCING OF APPLICATIONS USING XEN HYPERVISOR
LOAD BALANCING OF APPLICATIONS  USING XEN HYPERVISORLOAD BALANCING OF APPLICATIONS  USING XEN HYPERVISOR
LOAD BALANCING OF APPLICATIONS USING XEN HYPERVISOR
 
Linux fundamental - Chap 12 Hardware Management
Linux fundamental - Chap 12 Hardware ManagementLinux fundamental - Chap 12 Hardware Management
Linux fundamental - Chap 12 Hardware Management
 
What every data programmer needs to know about disks
What every data programmer needs to know about disksWhat every data programmer needs to know about disks
What every data programmer needs to know about disks
 
Comparison of-foss-distributed-storage
Comparison of-foss-distributed-storageComparison of-foss-distributed-storage
Comparison of-foss-distributed-storage
 
Linux fundamental - Chap 08 proc
Linux fundamental - Chap 08 procLinux fundamental - Chap 08 proc
Linux fundamental - Chap 08 proc
 
Recipe of a linux Live CD (archived)
Recipe of a linux Live CD (archived)Recipe of a linux Live CD (archived)
Recipe of a linux Live CD (archived)
 
Ha opensuse
Ha opensuseHa opensuse
Ha opensuse
 
Upgrade ux-fosdem-2015-gdhaese
Upgrade ux-fosdem-2015-gdhaeseUpgrade ux-fosdem-2015-gdhaese
Upgrade ux-fosdem-2015-gdhaese
 
Os Bernier
Os BernierOs Bernier
Os Bernier
 
Adhocr T-dose 2012
Adhocr T-dose 2012Adhocr T-dose 2012
Adhocr T-dose 2012
 
Using cobbler in a not so small environment 1.77
Using cobbler in a not so small environment 1.77Using cobbler in a not so small environment 1.77
Using cobbler in a not so small environment 1.77
 
Jagan Teki - U-boot from scratch
Jagan Teki - U-boot from scratchJagan Teki - U-boot from scratch
Jagan Teki - U-boot from scratch
 
OSDC 2016 - Interesting things you can do with ZFS by Allan Jude&Benedict Reu...
OSDC 2016 - Interesting things you can do with ZFS by Allan Jude&Benedict Reu...OSDC 2016 - Interesting things you can do with ZFS by Allan Jude&Benedict Reu...
OSDC 2016 - Interesting things you can do with ZFS by Allan Jude&Benedict Reu...
 
LinuxTag2012 Rear
LinuxTag2012 RearLinuxTag2012 Rear
LinuxTag2012 Rear
 
LSA2 - 01 Virtualization with KVM
LSA2 - 01 Virtualization with KVMLSA2 - 01 Virtualization with KVM
LSA2 - 01 Virtualization with KVM
 
OpenWRT guide and memo
OpenWRT guide and memoOpenWRT guide and memo
OpenWRT guide and memo
 
Cobbler, Func and Puppet: Tools for Large Scale Environments
Cobbler, Func and Puppet: Tools for Large Scale EnvironmentsCobbler, Func and Puppet: Tools for Large Scale Environments
Cobbler, Func and Puppet: Tools for Large Scale Environments
 

Similar to Texas 2013

Asiabsdcon2013
Asiabsdcon2013Asiabsdcon2013
Asiabsdcon2013krispcbsd
 
The Deck by Phil Polstra GrrCON2012
The Deck by Phil Polstra GrrCON2012The Deck by Phil Polstra GrrCON2012
The Deck by Phil Polstra GrrCON2012Philip Polstra
 
Hacking and Forensics on the Go - 44CON 2012
Hacking and Forensics on the Go - 44CON 2012Hacking and Forensics on the Go - 44CON 2012
Hacking and Forensics on the Go - 44CON 201244CON
 
Linux conf-admin
Linux conf-adminLinux conf-admin
Linux conf-adminbadamisri
 
Linux conf-admin
Linux conf-adminLinux conf-admin
Linux conf-adminbadamisri
 
Dru lavigne servers-tutorial
Dru lavigne servers-tutorialDru lavigne servers-tutorial
Dru lavigne servers-tutorialDru Lavigne
 
A3Sec Advanced Deployment System
A3Sec Advanced Deployment SystemA3Sec Advanced Deployment System
A3Sec Advanced Deployment Systema3sec
 
Distributed Compiler Icecc
Distributed Compiler IceccDistributed Compiler Icecc
Distributed Compiler IceccSZ Lin
 
Perfect Linux Desktop - OpenSuSE 12.2
Perfect Linux Desktop - OpenSuSE 12.2Perfect Linux Desktop - OpenSuSE 12.2
Perfect Linux Desktop - OpenSuSE 12.2Davor Guttierrez
 
linux minimal os tutorial - by shatrix
linux minimal os tutorial - by shatrixlinux minimal os tutorial - by shatrix
linux minimal os tutorial - by shatrixSherif Mousa
 
Linux Installation
Linux InstallationLinux Installation
Linux InstallationBIT DURG
 
Oracle11g On Fedora14
Oracle11g On Fedora14Oracle11g On Fedora14
Oracle11g On Fedora14kmsa
 

Similar to Texas 2013 (20)

Asiabsdcon2013
Asiabsdcon2013Asiabsdcon2013
Asiabsdcon2013
 
Scale2013
Scale2013Scale2013
Scale2013
 
The Deck by Phil Polstra GrrCON2012
The Deck by Phil Polstra GrrCON2012The Deck by Phil Polstra GrrCON2012
The Deck by Phil Polstra GrrCON2012
 
Polstra 44con2012
Polstra 44con2012Polstra 44con2012
Polstra 44con2012
 
Hacking and Forensics on the Go - 44CON 2012
Hacking and Forensics on the Go - 44CON 2012Hacking and Forensics on the Go - 44CON 2012
Hacking and Forensics on the Go - 44CON 2012
 
Linux conf-admin
Linux conf-adminLinux conf-admin
Linux conf-admin
 
Linux conf-admin
Linux conf-adminLinux conf-admin
Linux conf-admin
 
Linux Conf Admin
Linux Conf AdminLinux Conf Admin
Linux Conf Admin
 
Dru lavigne servers-tutorial
Dru lavigne servers-tutorialDru lavigne servers-tutorial
Dru lavigne servers-tutorial
 
A3Sec Advanced Deployment System
A3Sec Advanced Deployment SystemA3Sec Advanced Deployment System
A3Sec Advanced Deployment System
 
Distributed Compiler Icecc
Distributed Compiler IceccDistributed Compiler Icecc
Distributed Compiler Icecc
 
Perfect Linux Desktop - OpenSuSE 12.2
Perfect Linux Desktop - OpenSuSE 12.2Perfect Linux Desktop - OpenSuSE 12.2
Perfect Linux Desktop - OpenSuSE 12.2
 
linux minimal os tutorial - by shatrix
linux minimal os tutorial - by shatrixlinux minimal os tutorial - by shatrix
linux minimal os tutorial - by shatrix
 
FreeBSD Portscamp, Kuala Lumpur 2016
FreeBSD Portscamp, Kuala Lumpur 2016FreeBSD Portscamp, Kuala Lumpur 2016
FreeBSD Portscamp, Kuala Lumpur 2016
 
Linux Installation
Linux InstallationLinux Installation
Linux Installation
 
Kickstart server
Kickstart serverKickstart server
Kickstart server
 
Oracle11g On Fedora14
Oracle11g On Fedora14Oracle11g On Fedora14
Oracle11g On Fedora14
 
Oracle11g on fedora14
Oracle11g on fedora14Oracle11g on fedora14
Oracle11g on fedora14
 
Xen time machine
Xen time machineXen time machine
Xen time machine
 
olf10
olf10olf10
olf10
 

Recently uploaded

Apidays New York 2024 - APIs in 2030: The Risk of Technological Sleepwalk by ...
Apidays New York 2024 - APIs in 2030: The Risk of Technological Sleepwalk by ...Apidays New York 2024 - APIs in 2030: The Risk of Technological Sleepwalk by ...
Apidays New York 2024 - APIs in 2030: The Risk of Technological Sleepwalk by ...apidays
 
DBX First Quarter 2024 Investor Presentation
DBX First Quarter 2024 Investor PresentationDBX First Quarter 2024 Investor Presentation
DBX First Quarter 2024 Investor PresentationDropbox
 
Platformless Horizons for Digital Adaptability
Platformless Horizons for Digital AdaptabilityPlatformless Horizons for Digital Adaptability
Platformless Horizons for Digital AdaptabilityWSO2
 
EMPOWERMENT TECHNOLOGY GRADE 11 QUARTER 2 REVIEWER
EMPOWERMENT TECHNOLOGY GRADE 11 QUARTER 2 REVIEWEREMPOWERMENT TECHNOLOGY GRADE 11 QUARTER 2 REVIEWER
EMPOWERMENT TECHNOLOGY GRADE 11 QUARTER 2 REVIEWERMadyBayot
 
AI in Action: Real World Use Cases by Anitaraj
AI in Action: Real World Use Cases by AnitarajAI in Action: Real World Use Cases by Anitaraj
AI in Action: Real World Use Cases by AnitarajAnitaRaj43
 
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 educationjfdjdjcjdnsjd
 
Architecting Cloud Native Applications
Architecting Cloud Native ApplicationsArchitecting Cloud Native Applications
Architecting Cloud Native ApplicationsWSO2
 
Repurposing LNG terminals for Hydrogen Ammonia: Feasibility and Cost Saving
Repurposing LNG terminals for Hydrogen Ammonia: Feasibility and Cost SavingRepurposing LNG terminals for Hydrogen Ammonia: Feasibility and Cost Saving
Repurposing LNG terminals for Hydrogen Ammonia: Feasibility and Cost SavingEdi Saputra
 
AI+A11Y 11MAY2024 HYDERBAD GAAD 2024 - HelloA11Y (11 May 2024)
AI+A11Y 11MAY2024 HYDERBAD GAAD 2024 - HelloA11Y (11 May 2024)AI+A11Y 11MAY2024 HYDERBAD GAAD 2024 - HelloA11Y (11 May 2024)
AI+A11Y 11MAY2024 HYDERBAD GAAD 2024 - HelloA11Y (11 May 2024)Samir Dash
 
Finding Java's Hidden Performance Traps @ DevoxxUK 2024
Finding Java's Hidden Performance Traps @ DevoxxUK 2024Finding Java's Hidden Performance Traps @ DevoxxUK 2024
Finding Java's Hidden Performance Traps @ DevoxxUK 2024Victor Rentea
 
TrustArc Webinar - Unlock the Power of AI-Driven Data Discovery
TrustArc Webinar - Unlock the Power of AI-Driven Data DiscoveryTrustArc Webinar - Unlock the Power of AI-Driven Data Discovery
TrustArc Webinar - Unlock the Power of AI-Driven Data DiscoveryTrustArc
 
Modular Monolith - a Practical Alternative to Microservices @ Devoxx UK 2024
Modular Monolith - a Practical Alternative to Microservices @ Devoxx UK 2024Modular Monolith - a Practical Alternative to Microservices @ Devoxx UK 2024
Modular Monolith - a Practical Alternative to Microservices @ Devoxx UK 2024Victor Rentea
 
Connector Corner: Accelerate revenue generation using UiPath API-centric busi...
Connector Corner: Accelerate revenue generation using UiPath API-centric busi...Connector Corner: Accelerate revenue generation using UiPath API-centric busi...
Connector Corner: Accelerate revenue generation using UiPath API-centric busi...DianaGray10
 
Corporate and higher education May webinar.pptx
Corporate and higher education May webinar.pptxCorporate and higher education May webinar.pptx
Corporate and higher education May webinar.pptxRustici Software
 
JohnPollard-hybrid-app-RailsConf2024.pptx
JohnPollard-hybrid-app-RailsConf2024.pptxJohnPollard-hybrid-app-RailsConf2024.pptx
JohnPollard-hybrid-app-RailsConf2024.pptxJohnPollard37
 
Mcleodganj Call Girls 🥰 8617370543 Service Offer VIP Hot Model
Mcleodganj Call Girls 🥰 8617370543 Service Offer VIP Hot ModelMcleodganj Call Girls 🥰 8617370543 Service Offer VIP Hot Model
Mcleodganj Call Girls 🥰 8617370543 Service Offer VIP Hot ModelDeepika Singh
 
Polkadot JAM Slides - Token2049 - By Dr. Gavin Wood
Polkadot JAM Slides - Token2049 - By Dr. Gavin WoodPolkadot JAM Slides - Token2049 - By Dr. Gavin Wood
Polkadot JAM Slides - Token2049 - By Dr. Gavin WoodJuan lago vázquez
 
Six Myths about Ontologies: The Basics of Formal Ontology
Six Myths about Ontologies: The Basics of Formal OntologySix Myths about Ontologies: The Basics of Formal Ontology
Six Myths about Ontologies: The Basics of Formal Ontologyjohnbeverley2021
 
DEV meet-up UiPath Document Understanding May 7 2024 Amsterdam
DEV meet-up UiPath Document Understanding May 7 2024 AmsterdamDEV meet-up UiPath Document Understanding May 7 2024 Amsterdam
DEV meet-up UiPath Document Understanding May 7 2024 AmsterdamUiPathCommunity
 
Apidays New York 2024 - Passkeys: Developing APIs to enable passwordless auth...
Apidays New York 2024 - Passkeys: Developing APIs to enable passwordless auth...Apidays New York 2024 - Passkeys: Developing APIs to enable passwordless auth...
Apidays New York 2024 - Passkeys: Developing APIs to enable passwordless auth...apidays
 

Recently uploaded (20)

Apidays New York 2024 - APIs in 2030: The Risk of Technological Sleepwalk by ...
Apidays New York 2024 - APIs in 2030: The Risk of Technological Sleepwalk by ...Apidays New York 2024 - APIs in 2030: The Risk of Technological Sleepwalk by ...
Apidays New York 2024 - APIs in 2030: The Risk of Technological Sleepwalk by ...
 
DBX First Quarter 2024 Investor Presentation
DBX First Quarter 2024 Investor PresentationDBX First Quarter 2024 Investor Presentation
DBX First Quarter 2024 Investor Presentation
 
Platformless Horizons for Digital Adaptability
Platformless Horizons for Digital AdaptabilityPlatformless Horizons for Digital Adaptability
Platformless Horizons for Digital Adaptability
 
EMPOWERMENT TECHNOLOGY GRADE 11 QUARTER 2 REVIEWER
EMPOWERMENT TECHNOLOGY GRADE 11 QUARTER 2 REVIEWEREMPOWERMENT TECHNOLOGY GRADE 11 QUARTER 2 REVIEWER
EMPOWERMENT TECHNOLOGY GRADE 11 QUARTER 2 REVIEWER
 
AI in Action: Real World Use Cases by Anitaraj
AI in Action: Real World Use Cases by AnitarajAI in Action: Real World Use Cases by Anitaraj
AI in Action: Real World Use Cases by Anitaraj
 
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
 
Architecting Cloud Native Applications
Architecting Cloud Native ApplicationsArchitecting Cloud Native Applications
Architecting Cloud Native Applications
 
Repurposing LNG terminals for Hydrogen Ammonia: Feasibility and Cost Saving
Repurposing LNG terminals for Hydrogen Ammonia: Feasibility and Cost SavingRepurposing LNG terminals for Hydrogen Ammonia: Feasibility and Cost Saving
Repurposing LNG terminals for Hydrogen Ammonia: Feasibility and Cost Saving
 
AI+A11Y 11MAY2024 HYDERBAD GAAD 2024 - HelloA11Y (11 May 2024)
AI+A11Y 11MAY2024 HYDERBAD GAAD 2024 - HelloA11Y (11 May 2024)AI+A11Y 11MAY2024 HYDERBAD GAAD 2024 - HelloA11Y (11 May 2024)
AI+A11Y 11MAY2024 HYDERBAD GAAD 2024 - HelloA11Y (11 May 2024)
 
Finding Java's Hidden Performance Traps @ DevoxxUK 2024
Finding Java's Hidden Performance Traps @ DevoxxUK 2024Finding Java's Hidden Performance Traps @ DevoxxUK 2024
Finding Java's Hidden Performance Traps @ DevoxxUK 2024
 
TrustArc Webinar - Unlock the Power of AI-Driven Data Discovery
TrustArc Webinar - Unlock the Power of AI-Driven Data DiscoveryTrustArc Webinar - Unlock the Power of AI-Driven Data Discovery
TrustArc Webinar - Unlock the Power of AI-Driven Data Discovery
 
Modular Monolith - a Practical Alternative to Microservices @ Devoxx UK 2024
Modular Monolith - a Practical Alternative to Microservices @ Devoxx UK 2024Modular Monolith - a Practical Alternative to Microservices @ Devoxx UK 2024
Modular Monolith - a Practical Alternative to Microservices @ Devoxx UK 2024
 
Connector Corner: Accelerate revenue generation using UiPath API-centric busi...
Connector Corner: Accelerate revenue generation using UiPath API-centric busi...Connector Corner: Accelerate revenue generation using UiPath API-centric busi...
Connector Corner: Accelerate revenue generation using UiPath API-centric busi...
 
Corporate and higher education May webinar.pptx
Corporate and higher education May webinar.pptxCorporate and higher education May webinar.pptx
Corporate and higher education May webinar.pptx
 
JohnPollard-hybrid-app-RailsConf2024.pptx
JohnPollard-hybrid-app-RailsConf2024.pptxJohnPollard-hybrid-app-RailsConf2024.pptx
JohnPollard-hybrid-app-RailsConf2024.pptx
 
Mcleodganj Call Girls 🥰 8617370543 Service Offer VIP Hot Model
Mcleodganj Call Girls 🥰 8617370543 Service Offer VIP Hot ModelMcleodganj Call Girls 🥰 8617370543 Service Offer VIP Hot Model
Mcleodganj Call Girls 🥰 8617370543 Service Offer VIP Hot Model
 
Polkadot JAM Slides - Token2049 - By Dr. Gavin Wood
Polkadot JAM Slides - Token2049 - By Dr. Gavin WoodPolkadot JAM Slides - Token2049 - By Dr. Gavin Wood
Polkadot JAM Slides - Token2049 - By Dr. Gavin Wood
 
Six Myths about Ontologies: The Basics of Formal Ontology
Six Myths about Ontologies: The Basics of Formal OntologySix Myths about Ontologies: The Basics of Formal Ontology
Six Myths about Ontologies: The Basics of Formal Ontology
 
DEV meet-up UiPath Document Understanding May 7 2024 Amsterdam
DEV meet-up UiPath Document Understanding May 7 2024 AmsterdamDEV meet-up UiPath Document Understanding May 7 2024 Amsterdam
DEV meet-up UiPath Document Understanding May 7 2024 Amsterdam
 
Apidays New York 2024 - Passkeys: Developing APIs to enable passwordless auth...
Apidays New York 2024 - Passkeys: Developing APIs to enable passwordless auth...Apidays New York 2024 - Passkeys: Developing APIs to enable passwordless auth...
Apidays New York 2024 - Passkeys: Developing APIs to enable passwordless auth...
 

Texas 2013

  • 1. Automating the deployment of FreeBSD & PC-BSD® systemsAutomating the deployment of FreeBSD & PC-BSD® systems Texas Linux Fest 2013Texas Linux Fest 2013 Kris MooreKris Moore PC-BSD / iXsystemsPC-BSD / iXsystems kris@pcbsd.orgkris@pcbsd.org
  • 2. The problem:The problem: You want to (quickly) deploy multipleYou want to (quickly) deploy multiple FreeBSD or PC-BSD systems.FreeBSD or PC-BSD systems. You like what you hear about this wholeYou like what you hear about this whole “ZFS” thing“ZFS” thing
  • 3. There are currently two ways to accomplishThere are currently two ways to accomplish this:this:
  • 4. Solution #1Solution #1 ● Write your own installation scriptsWrite your own installation scripts ● Configure network booting by handConfigure network booting by hand ● Maintain as necessaryMaintain as necessary
  • 5. When to consider Solution #1:When to consider Solution #1: ● You have a very unique installationYou have a very unique installation ● You are a FreeBSD God – Congrats!You are a FreeBSD God – Congrats!
  • 6. When to not consider Solution #1:When to not consider Solution #1: ● Manual disk partitioning isn't your thingManual disk partitioning isn't your thing ● You work for a livingYou work for a living
  • 7. Solution #2Solution #2 ● Use theUse the pc-thinclientpc-thinclient utility included withutility included with PC-BSD & TrueOSPC-BSD & TrueOS
  • 8. When to consider Solution #2:When to consider Solution #2: ● You don't enjoy disk partitioningYou don't enjoy disk partitioning ● You want to have a weekendYou want to have a weekend
  • 9. What you will need:What you will need: ● A system with a network interface (2)?A system with a network interface (2)? ● Running PC-BSD 9.1 / TrueOS 9.1Running PC-BSD 9.1 / TrueOS 9.1 ● A few GB of disk spaceA few GB of disk space
  • 10. Getting StartedGetting Started ● First, checkout a FreeBSD ports treeFirst, checkout a FreeBSD ports tree On TrueOSOn TrueOS # portsnap fetch extract update# portsnap fetch extract update
  • 11. On PC-BSDOn PC-BSD Control panel → System Manager → TasksControl panel → System Manager → Tasks → Fetch Ports→ Fetch Ports
  • 14. Getting StartedGetting Started ● Install serverInstall server ● Or desktop “Thin-Client” serverOr desktop “Thin-Client” server
  • 16. What is Remote Desktop?What is Remote Desktop? ● The thin-client utility can operate bothThe thin-client utility can operate both install server or desktop serverinstall server or desktop server ● Allows diskless clients to boot via PXEAllows diskless clients to boot via PXE ● Brings up GDM login on clientBrings up GDM login on client
  • 17. Why would you run Remote Desktop?Why would you run Remote Desktop? ● You have a bunch of low-end clientsYou have a bunch of low-end clients ● You want to simplify backup, security andYou want to simplify backup, security and managementmanagement
  • 18. Why should you not run Remote Desktop?Why should you not run Remote Desktop? ● You don't have a server with horsepowerYou don't have a server with horsepower ● You need sound support on the clientsYou need sound support on the clients
  • 19. Back to your previously scheduledBack to your previously scheduled presentationpresentation
  • 20. Getting StartedGetting Started ● Will run DHCPDWill run DHCPD ● Be careful which cable is usedBe careful which cable is used
  • 22. Getting startedGetting started ● You may now connect a client systemYou may now connect a client system ● To PXE boot, you may need to checkTo PXE boot, you may need to check BIOS on client firstBIOS on client first
  • 23. Its Demo time!Its Demo time!
  • 24. Customizing the installCustomizing the install ● Of course you will want your ownOf course you will want your own installation options / archives, etcinstallation options / archives, etc ● It is possible to adjust entirely on serverIt is possible to adjust entirely on server sideside
  • 25. The two key directories:The two key directories: ● /home/thinclient/installscripts/home/thinclient/installscripts ● /home/thinclient/installarchive/home/thinclient/installarchive Client mounted as:Client mounted as: ● /installscripts/installscripts ● /installarchive/installarchive
  • 26. ● pc-sysinstall.example can be used as apc-sysinstall.example can be used as a template for other installationstemplate for other installations Example #1Example #1 Changing to ZFSChanging to ZFS
  • 27. Example disk layout:Example disk layout: disk0-part=UFS+SUJ 1000 /disk0-part=UFS+SUJ 1000 / disk0-part=SWAP 2000 nonedisk0-part=SWAP 2000 none disk0-part=UFS+SUJ 0 /usrdisk0-part=UFS+SUJ 0 /usr commitDiskLabelcommitDiskLabel Converted to ZFS becomes:Converted to ZFS becomes: disk0-part=ZFS 0 /,/root,/tmp,/usr,/vardisk0-part=ZFS 0 /,/root,/tmp,/usr,/var commitDiskLabelcommitDiskLabel
  • 28. Example #2Example #2 Changing installation archiveChanging installation archive
  • 29. Example install archive:Example install archive: installMedium=localinstallMedium=local localPath=/installarchivelocalPath=/installarchive packageType=tarpackageType=tar installFile=fbsd-release.txzinstallFile=fbsd-release.txz Changed to custom archive:Changed to custom archive: installMedium=localinstallMedium=local localPath=/installarchivelocalPath=/installarchive packageType=tarpackageType=tar installFile=fbsd-8.4-amd64.txzinstallFile=fbsd-8.4-amd64.txz
  • 30. Example #3Example #3 User ManagementUser Management
  • 31. # Root Password# Root Password rootPass=rootrootPass=root # User Setup# User Setup userName=krisuserName=kris userComment=Kris MooreuserComment=Kris Moore userPass=krisuserPass=kris userShell=/bin/cshuserShell=/bin/csh userHome=/home/krisuserHome=/home/kris userGroups=wheel,operatoruserGroups=wheel,operator commitUsercommitUser
  • 32. Example #4Example #4 Advanced CommandsAdvanced Commands
  • 33. # Run command inside installed system# Run command inside installed system runCommand=sh /root/initme.shrunCommand=sh /root/initme.sh # Run command outside installed system# Run command outside installed system runExtCommand=mount -t devfs devfs ${FSMNT}/devrunExtCommand=mount -t devfs devfs ${FSMNT}/dev
  • 34. Example #5Example #5 Packages, oh my!Packages, oh my!
  • 35. installPackages=apache22 mysql55-serverinstallPackages=apache22 mysql55-server Can use short package names, or fullCan use short package names, or full versions.versions.
  • 36. PKGNG supportPKGNG support ● Checks package format before installChecks package format before install ● Will “boot-strap” PKGNG if necessaryWill “boot-strap” PKGNG if necessary
  • 37. Example #6Example #6 FreeBSD dist filesFreeBSD dist files
  • 38. # Install from vanilla FreeBSD dist files# Install from vanilla FreeBSD dist files installMedium=localinstallMedium=local localPath=/distfiles/9.1-Release/amd64/distlocalPath=/distfiles/9.1-Release/amd64/dist packageType=distpackageType=dist distFiles=base doc games kernel lib32distFiles=base doc games kernel lib32
  • 39. Putting the Automated in “Fully Automated”Putting the Automated in “Fully Automated” File: /home/thinclient/installscripts/unattended.cfgFile: /home/thinclient/installscripts/unattended.cfg ● If config exists, the client will boot andIf config exists, the client will boot and begin installation after 30 seconds.begin installation after 30 seconds. ● System will shutdown when finishedSystem will shutdown when finished ● USE WITH CAUTION!!USE WITH CAUTION!!
  • 40. ScalabilityScalability ● All CPU instructions are run on the clientAll CPU instructions are run on the client ● Server is in essence a large “File Server”Server is in essence a large “File Server” ● Will be mostly disk IO / network speedWill be mostly disk IO / network speed dependentdependent
  • 41. ScalabilityScalability ● Default DHCP server is configured for 99Default DHCP server is configured for 99 clientsclients ● To adjust edit the file:To adjust edit the file: ● /usr/local/etc/dhcpd.conf/usr/local/etc/dhcpd.conf ● range 192.168.2.100 192.168.2.199;range 192.168.2.100 192.168.2.199;
  • 42. Tips and TricksTips and Tricks ● To greatly speed up installations, use ZFSTo greatly speed up installations, use ZFS mirrored drives, SSD, or even TMPFSmirrored drives, SSD, or even TMPFS
  • 43. Tips and TricksTips and Tricks ● The PC-BSD GUI installer is your friendThe PC-BSD GUI installer is your friend ● Every install is a scripted installEvery install is a scripted install ● After installation a copy of the pc-After installation a copy of the pc- sysinstall.cfg file is saved to:sysinstall.cfg file is saved to: ● /root/pc-sysinstallcfg/root/pc-sysinstallcfg
  • 45.
  • 46.
  • 47.
  • 48.
  • 49. What's next?What's next? ● Improvements to pc-sysinstallImprovements to pc-sysinstall ● Faster setup of initial thin-clientFaster setup of initial thin-client environmentenvironment