Showing posts with label Linux. Show all posts
Showing posts with label Linux. Show all posts

Friday, April 17, 2015

Standard Container Manifesto

If you haven't seen it, see the  "Standard Container Manifesto" below.   It might help you understand some of the current buzz around container technology.   This one was added to the Docker README at one point but has been since removed.   There are better but longer descriptions.  

Note: to appreciate this, it helps to have been involved in the struggles of delivering enterprise IT where one of the core challenges, (if not the fundamental problem), is trying to get away from everything being somewhat different because it's all built by hand.

Oh, and if you aren't familiar with the story of the standard shipping container and its impact on global commerce, this looks like a reasonable overview: http://www.nytimes.com/2006/03/23/business/23scene.html?_r=0



1. STANDARD OPERATIONS

Just like shipping containers, Standard Containers define a set of STANDARD OPERATIONS. Shipping containers can be lifted, stacked, locked, loaded, unloaded and labelled. Similarly, standard containers can be started, stopped, copied, snapshotted, downloaded, uploaded and tagged.

2. CONTENT-AGNOSTIC

Just like shipping containers, Standard Containers are CONTENT-AGNOSTIC: all standard operations have the same effect regardless of the contents. A shipping container will be stacked in exactly the same way whether it contains Vietnamese powder coffee or spare Maserati parts. Similarly, Standard Containers are started or uploaded in the same way whether they contain a postgres database, a php application with its dependencies and application server, or Java build artifacts.

3. INFRASTRUCTURE-AGNOSTIC

Both types of containers are INFRASTRUCTURE-AGNOSTIC: they can be transported to thousands of facilities around the world, and manipulated by a wide variety of equipment. A shipping container can be packed in a factory in Ukraine, transported by truck to the nearest routing center, stacked onto a train, loaded into a German boat by an Australian-built crane, stored in a warehouse at a US facility, etc. Similarly, a standard container can be bundled on my laptop, uploaded to S3, downloaded, run and snapshotted by a build server at Equinix in Virginia, uploaded to 10 staging servers in a home-made Openstack cluster, then sent to 30 production instances across 3 EC2 regions.

4. DESIGNED FOR AUTOMATION

Because they offer the same standard operations regardless of content and infrastructure, Standard Containers, just like their physical counterpart, are extremely well-suited for automation. In fact, you could say automation is their secret weapon.
Many things that once required time-consuming and error-prone human effort can now be programmed. Before shipping containers, a bag of powder coffee was hauled, dragged, dropped, rolled and stacked by 10 different people in 10 different locations by the time it reached its destination. 1 out of 50 disappeared. 1 out of 20 was damaged. The process was slow, inefficient and cost a fortune - and was entirely different depending on the facility and the type of goods.
Similarly, before Standard Containers, by the time a software component ran in production, it had been individually built, configured, bundled, documented, patched, vendored, templated, tweaked and instrumented by 10 different people on 10 different computers. Builds failed, libraries conflicted, mirrors crashed, post-it notes were lost, logs were misplaced, cluster updates were half-broken. The process was slow, inefficient and cost a fortune - and was entirely different depending on the language and infrastructure provider.

5. INDUSTRIAL-GRADE DELIVERY

There are 17 million shipping containers in existence, packed with every physical good imaginable. Every single one of them can be loaded on the same boats, by the same cranes, in the same facilities, and sent anywhere in the World with incredible efficiency. It is embarrassing to think that a 30 ton shipment of coffee can safely travel half-way across the World in less time than it takes a software team to deliver its code from one datacenter to another sitting 10 miles away.
With Standard Containers we can put an end to that embarrassment, by making INDUSTRIAL-GRADE DELIVERY of software a reality.



Tuesday, April 29, 2014

Linux Trivia: Grub Legacy 128 byte inode dependency

Documenting something that I tripped over while trying to fix a very old Linux system. 

Grub Legacy (0.97) is dependent on 128 byte inode sizes.  Newer systems use 256 byte inodes to store extended attributes.  This confuses grub causing it not to be able to boot system as well as cause boot loader installation to fail with odd error messages like can find /boot/grub/stage1.

Fortunately googling found that Kristian Reese had documented this in his own "knowledge base", somewhat like I'm doing here in a less organized fashion.

The file /boot/grub/stage1 not read correctly kristianreese.com knowledge base
The solution is to use mke2fs ... -I 128 ...to force a 128 byte inode size when re-making the "legacy" root file system that will be booted by grub "legacy".

Use tune2fs -l /dev/foo to see the current file system parameters.  Tip: Save tune2fs dump info someplace for import (root) file systems someplace off the system.



Thursday, January 2, 2014

Trying Linux and amateur radio software without having to install it on your computer.

The topic of trying Linux without having to actually install it on your computer came up recently.   There are several "Live" distributions which can be downloaded to a bootable DVD or USB thumb drive. You can then boot your computer from the DVD or USB drive without having to touch the existing installation on your hard drive.

The simplest approach is to download the DVD .iso, burn it to a blank DVD, and then reboot your computer, telling it to boot from the DVD drive.

The USB thumb drive approach has more steps to create, but can be faster as well as allowing you to save changes between reboots.

Two ham radio oriented builds that have been mentioned:

Both are based on Ubuntu Linux and include software such as FLdigi and Chirp.

If you are interested in trying them, I think there are better tutorials available if you google "ubuntu live" than the instructions that accompany the two ham specific packages mentioned above.

Rigol DS1052E/DS1102 and Linux, Python, usbtmc

[To Be Updated]
This is one of those intersections of electronics, open source, hacking, and programming that really gets my interest.

Here are some links with information on connecting the Rigol scope to Linux, and controlling it using Python via USB.  The scope implements the USB test and measurement class, usbtmc.