Slide 1

Slide 1 text

@mikedanko Rails on Solaris And Friends

Slide 2

Slide 2 text

As a Developer... • Hey bro, it’s 2013. We have Heroku. • Platform? The client can gure that out. • Everyone uses Linux. Why bother using anything else? • I got out of ops so I didn’t have to think about this!

Slide 3

Slide 3 text

You Should Care Because... • Deploying to Heroku? Great. It can’t be beat. • If you’re building a service of scale, platform is important. • You can sell your platform as a feature.

Slide 4

Slide 4 text

So Why Not Linux? • Well, why not? If it works for you, great. • There are other options with great ops and development features not available on Linux. • Licensing can work against you if applicable, such as deploying a black box product.

Slide 5

Slide 5 text

Let’s Talk Solaris • The Revolution starts with OpenSolaris. • Derivatives • SmartOS • Nexenta/NexentaStor

Slide 6

Slide 6 text

So These Features... • Semantic Commands • Zones • Storage. ZFS. • DTrace. • Network Virtualization / Crossbow • KVM/Xen • SMF • RBAC

Slide 7

Slide 7 text

Semantic Commands • Solaris: ZFS • Linux: • fdisk • mkfs • lvm • /etc/exports • SAMBA • ETC ETC

Slide 8

Slide 8 text

So DTrace? • Count system calls for any process • See time spent in nanoseconds on any process/method/module/class. • DTrace Toolkit • See Tenderlove’s Blog for More.

Slide 9

Slide 9 text

ZFS? • Snapshots Bro. • Boot into a previous environment. • Block sizes per lesystem. • Reliability - No silent data corruption • Pools! RAIDZ!

Slide 10

Slide 10 text

ZFS? (cont.) • 128 Bit - Boiling the Oceans • Deduplication and Compression. PostgreSQL’s Friend! • Hybrid Storage Pools, SSD/Spindles • Integrated Search • NAS and SAN in the same box.

Slide 11

Slide 11 text

ZFS Scenario #1 • Developer Bob is going to create a migration. • Bob snapshots his Postgres data directory. • Bob screws up. • Bob restores the snapshot.

Slide 12

Slide 12 text

ZFS Scenario #2 • Deployer Dan upgrades some packages and gems. • Explosions, reworks, blue smoke. • Reboot, pick previous environment from GRUB, problem solved.

Slide 13

Slide 13 text

ZFS Scenario #3 • NOC Admin Nate has 500,000 RRD les. • Nate encounters the Linux page/block size problem. • Nate sets the block size at 8k. • Nate cuts down IO by 75%.

Slide 14

Slide 14 text

ZFS Scenario #4 • Ops Oliver has a power issue causing silent data errors on a single disk in a RAIDZ. • ZFS recognizes this, marks the disk bad, and there’s no data loss in the pool. • OIiver ZFS sends the FS to another box, replaces the hardware and moves on with life.

Slide 15

Slide 15 text

ZFS Scenario #5 • Maltreated Mike gets little budget. • His main server is out of space, has four drives of various sizes, and one open slot. • He plugs in the disk and ZFS adds it to the main pool automatically. • ZFS automatically allocates recovery data in an intelligent way across the pool. • He can go on being oppressed in other ways.

Slide 16

Slide 16 text

Zones? • Jailesque • Large Zones, Small Zones • Native and LX Branded • Resource pools, device access

Slide 17

Slide 17 text

Zones In Action • Deploy Apache on a zone with read only access to a le system with content, limit its resources via a pool. • Create another zone with limited access via RBAC (we’ll get there) with RW to the content le system.

Slide 18

Slide 18 text

Crossbow • Fine Grained Network Virtualization • Build an entire network between zones • Dedicate TCP/IP processing to a pool • Bind interfaces arbitrarily. • Killer for things like streaming assets.

Slide 19

Slide 19 text

KVM/Xen • Virtualization • Which you get depends on platform choice • Move VM’s from machine to machine with zero downtime. • Freeze, pause, snapshot, whatever. • Bene ts of Solaris for other platforms.

Slide 20

Slide 20 text

SMF • Dependency Order • Message verbosity • Delegation to non-root users • Parallel starting of services. • Restart after failure

Slide 21

Slide 21 text

RBAC • Think SELinux, sudo • Roles allow for: • A DBA to have complete access to Postgres, nothing else. • An application to only have access to resources in its scope.

Slide 22

Slide 22 text

Final Thoughts • If you can’t Heroku... • You can run these in EC2, the advantages of ZFS are there even if you don’t use other features. • If you need to build your own mini-cloud, there are very few options that are better. • It’s the killer full-stack enterprise product platform.