Keith Packard: Back to HP
Re-joining HP
Thursday was my first day back with HP. I've joined Steve Geary's group to
work on Linux support for the machine
I had a great time at Intel and wish my old team all the best.
Re-joining HP
Thursday was my first day back with HP. I've joined Steve Geary's group to
work on Linux support for the machine
I had a great time at Intel and wish my old team all the best.
First sequel to my Link Pack series (I ll remove the quotes when it s LP#05): Link Pack #01.
This time I m going for fewer articles, to try to keep things less overwhelming. There s no special theme, and I m actually leaving out some nice things I read recently. On the plus side, that means I have good material for a Link Pack #03.
Also, I m gonna stick with Link Pack as a name, because it s good enough :-).
Bottom Line: The low-fat, high-carb diet recommended by the mainstream nutrition organizations is a miserable failure and has been repeatedly proven to be ineffective. ( ) Bottom Line: Low-carb diets are the easiest, healthiest and most effective way to lose weight and reverse metabolic disease. It is pretty much a scientific fact at this point.GM s hit and run: How a lawyer, mechanic, and engineer blew open the worst auto scandal in history
Countless articles have been written about General Motors and its massive recalls earlier this year. What hasn t been fully told is how GM might have gotten away with multiple counts of consumercide were it not for the efforts of three men: a Georgia lawyer, a Mississippi mechanic, and a Florida engineer. ( ) Brooke Melton needn t have died that night. She was killed by a corporation s callous disregard for the safety of its customers, made worse by a regulatory agency reluctant to regulate.The Long Game: Part 1 and The Long Game: Part 2
I recently had to upload a large number (~1 million) of files to Amazon S3.
My first attempts revolved around s3cmd (and subsequently s4cmd) but both projects seem to based around analysing all the files first rather than blindly uploading them. This not only requires a large amount of memory, non-trivial experimentation, fiddling and patching is also needed to avoid unnecessary stat(2) calls. I even tried a simple find xargs -P 5 s3cmd put [..] but I just didn't trust the error handling correctly.
I finally alighted on s3-parallel-put, which worked out well. Here's a brief rundown on how to use it:
$ export AWS_ACCESS_KEY_ID=FIXME $ export AWS_SECRET_ACCESS_KEY=FIXME $ /path/to/bin/s3-parallel-put \ --bucket=my-bucket \ --host=s3.amazonaws.com \ --put=stupid \ --insecure \ --dry-run --limit=1 \ .
[..] INFO:s3-parallel-put[putter-21714]:./yadt/profile.Profile/image/circle/807.jpeg -> yadt/profile.Profile/image/circle/807.jpeg [..]
A new release of my random package for truly (hardware-based) random numbers as provided by random.org is now on CRAN.
The main change is a switch to the curl() function from the eponymous package by Jeroen Ooms. This was caused by random.org now using https instead of http, annd the fact that te url() function from R does not cope well with the redirect. Besides this (enforced) change, everything else remains the same.
Courtesy of CRANberries comes a diffstat report for this release. Current and previous releases are available here as well as on CRAN.
This post by Dirk Eddelbuettel originated on his Thinking inside the box blog. Please report excessive re-aggregation in third-party for-profit settings.
Normally, this doesn t work as one might naively expect:
program > firstfile > secondfile
The second redirection will override the first one. You d have to use
an external tool to make this work, maybe something like:
program tee firstfile secondfile
But with zsh, this type of thing actually works. It will duplicate
the output and write it to multiple files.
This feature also works with a combination of redirections and
pipes. For example
ls > foo grep bar
will write the complete directory listing into file foo and print
out files matching bar to the terminal.
That s great, but this feature pops up in unexpected places.
I have a shell function that checks whether a given command produces
any output on stderr:
! myprog "$arg" 2>&1 >/dev/null grep .
The effect of this is:
2>&1 >/dev/null to redirect stderr to stdout
and silence the original stdout, as opposed to the more common
incantation of >/dev/null 2>&1, which silences both stderr and
stdout.)
The reason for this is that myprog has a bug that causes it to print
errors but not produce a proper exit status in some cases.
Now how will my little shell function snippet behave under zsh? Well,
it s quite confusing at first, but the following happens. If there is
stderr output, then only stderr is printed. If there is no stderr
output, then stdout is passed through instead. But that s not what I
wanted.
This can be reproduced simply:
ls --bogus 2>&1 >/dev/null grep .
prints an error message, as expected, but
ls 2>&1 >/dev/null grep .
prints a directory listing. That s because zsh redirects stdout to
both /dev/null and the pipe, which makes the redirection to
/dev/null pointless.
Note that in bash, the second command prints nothing.
This behavior can be changed by turning off the MULTIOS option (see
zshmisc man page), and my first instinct was to do that, but options
are not lexically scoped (I think), so this would break again if the
option was somehow changed somewhere else. Also, I think I kind of
like that option for interactive use.
My workaround is to use a subshell:
! ( myprog "$arg" 2>&1 >/dev/null ) grep .
The long-term fix will probably be to write an external shell script
in bash or plain POSIX shell.
I got a belated Christmas present today. Thanks Jo + Simon!
About a month ago, I
blogged
about extremon. As a reminder, ExtreMon is a
monitoring tool that allows you to view things as they are happening,
rather than with the ~5 minute delay that munin gives you, and also
avoiding the quad-state limitation of Nagios' "good", "bad", "ugly",
and "unknown" states. No, they're not really called that. Yes, I know
you knew that.
Anyway. In my blog post, I explained how you can set up ExtreMon, and I
also set up a fairly limited demo version on my own server. But I have
since realized that while it is functional, it doesn't actually show
why ExtreMon is so great. In an effort to remedy that, I present you an
example of what ExtreMon can do.
Let's start with a screenshot of the ExtreMon console at the customer
for which I spent time trying to figure out how to get it up and
running:
Click for full sized version. You'll note that even in that full-sized
version, many things are unreadable. This is because the ExtreMon
console allows one to move around (right mouse button drag for zoom;
left mouse button drag for moving around; control+RMB for rotate; center
mouse button to reset to default); so what matters is that everything
fits on the screen, not whether it is all readable (if you need to read,
you zoom).
The image shows 18 rectangles. Each rectangle represents a single
machine in this particular customer's HPC cluster. The top three
rectangles are the cluster's file servers; the rest are its high
performance nodes.
You'll note that the left fileserver has 8 processor cores (top row), 8
network cards (bottom row, left part), and it also shows information on
its memory usage (bottom row, small rectangle in the middle) as well as
its NFS client and server procedure calls (bottom row, slightly larger
rectangles to the right). This file server is the one on which I
installed ZFS a while
back; hence the
large amount of disks visible in the middle row. The leftmost disk is
the root filesystem (which is an ext4 off a hardware RAID1); the two
rightmost "disks" are the PCIe-attached SSDs which are used for the ZFS
L2ARC and write log. The other disks in this file server nicely show how
ZFS does write load balancing over all its disks.
The second file server has a hardware RAID1 on which it stores all its
data; as such, there is only one disk graph there. It is also somewhat
more limited in network, as it has only two NICs. It does, however, also
have 8 cores.
The last file server has no more than four processor cores; in addition,
it also does not have a hardware RAID controller, so it must use
software RAID over its four hard disks. This server is used for archival
purposes, mostly, since it is insufficient for most anything else.
As said, the other nodes are the "compute nodes", where the hard work is
done. Most of these compute nodes have 16 cores each; two have 12
instead. When this particular screenshot was taken, four of the nodes
(the ones showing red in their processor graphs) were hard at work; the
others seem to have been mostly idling. In addition to the familiar
memory, NFS (client only), network, and processor graphs, these nodes
also show a "swap space" graph (just below the memory one), which seems
fine for most nodes, except for the bottom left one (which shows a few
bars that are coloured yellow rather than green).
The green/yellow/red stuff is supposed to represent the "ok", "warning",
"bad" states that would be familiar from Nagios. In this particular
case, however, where "processor is busy all the time" is actually a
wanted state, a low amount of idleness on the part of the processor
isn't actually a problem, on the contrary. I did consider, therefore, to
modify the ExtreMon configuration so that the processor graphs would
not show red when the system was under high load; however, I found
that differences in colour like this actually makes it more easy to see,
at a glance, which machines are busy -- and that's one of the main
reasons why we wanted to set this up.
If you look carefully, you can find a particular processor core in the
graph which shows 100% usage for "idle", "system", and "softirq", at
the same time. Obviously that can't be the case, so there's a bug
somewhere. Frank seems to believe it is a bug in CollectD; I haven't
verified that. At any rate, though, this isn't usually a problem, due to
the high update frequency of ExtreMon.
The amount of data that's flowing through ExtreMon is amazing:
As I have just moved to a new home, I had to declare my new address
to all my providers, including banks and administrations which require
a proof of address, which can be a phone, DSL or electricity bill.
Well, this is just stupid, as, by definition, one will only have a
bill after at least a month. Until then, that means the bank will keep a
false address, and that the mail they send may not be delivered to the
customer.Now, bankers and employees of similar administrations, if you could
use some common sense, I have some information for you: when someone
moves to a new home, unless he is hosted by someone else, he is either
renter or owner. Well, you should now that a renter has one contract
that proves it, which is called a lease. And an owner has one paper that
proves it, which is called a title, or, before it has been issued by
administration, a certificate of sale. Now if you do not accept that as
a proof of address, you just suck.
Besides, such a zeal to check one's address is just pointless, as it
is just to get a proof of address without waiting for a phone, DSL or
electricity bill (or to prove a false address, actually ) by just faking
one. And as a reminder, at least in France, forgery is punishable by law
but defined as an alteration of truth which can cause a
prejudice, which means modifying a previous electricity bill to
prove your actual address is not considered as a forgery (but
using the same mean to prove a false address is, of course!).
All I want for 2015 is a Free/Open Source Software social network which is:
Every few days, someone publishes a new guide, tutorial, library or framework about web scraping, the practice of extracting information from websites where an API is either not provided or is otherwise incomplete.
However, I find these resources fundamentally deceptive the arduous parts of "real world" scraping simply aren't in the parsing and extraction of data from the target page, the typical focus of these articles.
The difficulties are invariably in "post-processing"; working around incomplete data on the page, handling errors gracefully and retrying in some (but not all) situations, keeping on top of layout/URL/data changes to the target site, not hitting your target site too often, logging into the target site if necessary and rotating credentials and IP addresses, respecting robots.txt, target site being utterly braindead, keeping users meaningfully informed of scraping progress if they are waiting of it, target site adding and removing data resulting in a null-leaning database schema, sane parallelisation in the presence of prioritisation of important requests, difficulties in monitoring a scraping system due to its implicitly non-deterministic nature, and general problems associated with long-running background processes in web stacks.
Et cetera.
In other words, extracting the right text on the page is the easiest and trivial part by far, with little practical difference between an admittedly cute jQuery-esque parsing library or even just using a blunt regular expression.
It would be quixotic to simply retort that sites should provide "proper" APIs but I would love to see more attempts at solutions that go beyond the superficial.
A new release of the RcppCNPy package is now on CRAN.
This release mostly solidifies and fixes things. Support for saving integer objects, which was expanded in release 0.2.3, was not entirely correct. Operations on big-endian systems were not up to snuff either.
Wush Wu helped in getting this right with very diligent testing and patching particularly on big-endian hardware. We also got a pull request from Romain to reflect better const correctness at the Rcpp side of things. Last but not least we obliged by the CRAN Maintainers to not assume one could call gzip from system() call because, well, you guessed it.
Changes in version 0.2.4 (2015-01-05)CRANberries also provides a diffstat report for the latest release. As always, feedback is welcome and the rcpp-devel mailing list off the R-Forge page for Rcpp is may be the best place to start a discussion. GitHub issue tickets are also welcome.
- Support for saving integer objects was not correct and has been fixed.
- Support for loading and saving on 'big endian' systems was incomplete, has been greatly expanded and corrected, thanks in large part to very diligent testing as well as patching by Wush Wu.
- The implementation now uses const iterators, thanks to a pull request by Romain Francois.
- The vignette no longer assumes that one can call
gzipviasystemas the world's leading consumer OS may disagree.
This post by Dirk Eddelbuettel originated on his Thinking inside the box blog. Please report excessive re-aggregation in third-party for-profit settings.
I promised to write about this a long time, ooops... :-)
Another ARM port in Debian - yay!
arm64 is officially a release architecture for Jessie, aka Debian
version 8. That's taken a lot of manual porting and development effort
over the last couple of years, and it's also taken a lot of CPU time -
there are ~21,000 source packages in Debian Jessie! As is often the
case for a brand new architecture like arm64 (or AArch64, to use ARM's
own terminology), hardware can be really difficult to get hold of. In
time this will cease to be an issue as hardware becomes more
commoditised, but in Debian we really struggled to get hold of
equipment for a very long time during the early part of the port.
First bring-up in Debian Ports
To start with, we could use ARM's own AArch64 software models to
build the first few packages. This worked, but only very slowly. Then
Chen Baozi and the folks running
the Tianhe-2
supercomputer project in Guangzhou, China contacted us to offer access
to some arm64 hardware, and this is what Wookey used for bootstrapping
the new port in the
unofficial Debian Ports
archive. This has now become the normal way for new architectures to
get into Debian. We got most of the archive built in debian-ports this
way, and we could then use those results to seed the initial core set
of packages in the main Debian archive.
Second bring-up - moving into the main Debian archive
By the time that first Debian bring-up was
done, ARM was starting to produce its
own "Juno" development boards, and with the help of my boss^4 James
McNiven we managed to acquire a couple of those machines for use as
official Debian build machines. The existing machines in China were
faster, but for various reasons quite difficult to maintain as
official Debian machines. So I set up the Junos as buildds just before
going to DebConf in August 2014. They ran very well, and (for dev
boards!) were very fast and stable. They built a large chunk of the
Debian archive, but as the release freeze for Jessie grew close we
weren't quite there. There was a small but persistent backlog of
un-built packages that were causing us issues, plus the Juno machines
are/were not quite suitable as porter boxes for Debian developers all
over the world to use for debugging their packages on the new
architecture.
More horsepower - Linaro machines
This is where Linaro came to
our aid. Linaro's goal is to help improve Free and Open Source
Software on ARM, and one of the more recent projects in Linaro is a
cluster of
servers that are made available for software developers to use to
get early access to ARMv8 (arm64) hardware. It's a great way for
people who are interested in this new architecture to try things out,
port their software or indeed just help with the general porting
effort.
As Debian is seen as such an important part of the FLOSS ecosystem,
we managed to negotiate dedicated access to three of the machines in
that cluster for Debian's use and we set those up in October, shortly
before the freeze for Jessie. Andy Doan spent a lot of his time
getting these machines going for us, and then I set up two of them as
build machines and one as the porter box we were still needing.
With these extra machines available, we quickly caught up with the
ever-busy "Needs-Build" queue and we've got sufficient build power now
to keep things going for the Jessie release. We were officially added
to the list of release architectures at the Cambridge mini-Debconf in
November, and all is looking good now!
And in the future?
I've organised the loan of another arm64 machine from AMD for
Debian to use for further porting and/or building. We're also
expecting that more and more machines will be coming out soon as
vendors move on from prototyping to producing real customer
equipment. Once that's happened, more kit will be available and
everybody will be able to have arm64-powered computers in the server
room, on their desk and even inside their laptop! Mine will be running
Debian Jessie... :-)
Thanks!
There's been a lot of people involved in the Debian arm64
bootstrapping at various stages, so many that I couldn't possibly
credit them all! I'll highlight some, though. :-)
First of all, Wookey's life has revolved around this port for the
last few years, tirelessly porting, fixing and hacking out package
builds to get us going. We've had loads of help from other teams in
Debian, particularly the massive patience of the DSA folks with
getting early machines up and running and the prodding of the
ftpmaster, buildd and release teams when we've been grinding our way
through ever more package builds and dependency loops. We've also had
really good support from toolchain folks in Debian and ARM, fixing
bugs as we've found them by stressing new code and new machines. We've
had a number of other people helping by filing bugs and posting
patches to help us get things built and working. And (last but not
least!) thanks to all the folks who've helped us beg and borrow the
hardware to make the Debian arm64 port a reality.
Rumours of even more ARM ports coming soon are entirely
scurrilous... *grin*
My LTS December
In December 2014 I spent 11h on Debian LTS work and managed to get six DLAs released and another one almost done... I did:

Time for another update on my work
for UEFI
improvements in Jessie!
I now have a mixed 32- and 64-bit UEFI netinst up and running right
now, which will boot and install on the Asus X205TA machine I
have. Since the last build, I've added 64-bit (amd64) support and
added CONFIG_EFI_MIXED in the kernel so that the 64-bit kernel will
also work with a 32-bit UEFI
firmware. Visit http://cdimage.debian.org/cdimage/unofficial/efi-development/jessie-upload2/
to download and test the image. There are a few other missing pieces
yet for a complete solution, but I'm getting there...!
WARNING: this CD is provided for testing
only. Use at your own risk! If you have appropriate
(U)EFI hardware, please try this image and let me know how you get on,
via the debian-cd and debian-boot mailing lists.
True story: Two days ago, as I was about to drift off to sleep at 2 am, a tiny
little bug flew into my ear. Right down to my eardrum, which it fluttered
against with its wings.
It was a tiny little moth-like bug, the kind you don't want to find in a bag of
flour, and it had been beating against my laptop screen a few minutes before.
This went on for 20 minutes, in which I failed to get it out with a cue tip and
shaking my head. It is very weird to have a bug flapping in your head.
I finally gave up and put in eardrops, and stopped the poor thing flapping. I
happen to know these little creatures mass almost nothing, and rapidly break up
into nearly powder when dead. So while I've not had any bug bits come out, I'm
going by the way my ear felt a little stopped up yesterday, and just fine
today, and guessing it'll be ok. Oh, and I've been soaking it in the tub and
putting in eardrops for good measure.
If I've seemed a little distracted lately, now you know why!
Once upon a time I worked from home for seven years, for a company called Bytemark. Then, due to a variety of reasons, I left. I struck out for adventures and pastures new, enjoyed the novelty of wearing clothes every day, and left the house a bit more often.
Things happened. A year passed.
Now I'm working for Bytemark again, although there are changes and the most obvious one is that I'm working in a shared-space/co-working setup, renting a room in a building near my house instead of being in the house.
Shame I have to get dressed, but otherwise it seems to be OK.
Right on the heels of yesterday's BH release 1.55.0-2 bringing Boost Fusion, we now have release 1.55.0-3 bringing Boost Graph. To recap, BH is our CRAN package providing (a large part of the) Boost C++ libraries as a set of template headers for use by R and of course Rcpp.
And as a small project I am working on--and which should now be so much closer to release--needed not only Boost Fusion but also Boost Graph, I had to bother the CRAN maintainers twice in two days. This new version closes issue ticket 9, and may be of interest to other packages such as the venerable RBGL formerly on CRAN and now a BioConductor package which includes its own copy of this graph library (plus depends).
A brief summary of changes from the NEWS file is below.
Changes in version 1.55.0-3 (2015-01-04)Courtesy of CRANberries, there is also a
- Added Boost Graph requested in GH ticket #9 by Dirk for RcppStreams
diffstat report for the most recent release.
Comments and suggestions are welcome via the mailing list or the issue tracker at the GitHubGitHub repo.
This post by Dirk Eddelbuettel originated on his Thinking inside the box blog. Please report excessive re-aggregation in third-party for-profit settings.
This was my first month working on Debian LTS. My first project
at Codethink was winding
down, so Freexian's
Debian LTS initiative was able to hire me via Codethink. I spent
all of the assigned 11.5 hours working on an update to the kernel
package (linux-2.6,
version 2.6.32-48squeeze9).
We had stopped following the upstream stable branch maintained by
Willy Tarreau after 2.6.32.60 (released October 2012). Since then, we
have only applied specific security fixes and other critical fixes.
Rapha l Hertzog and Holger Levsen started to rebase our package
on 2.6.32.64 (released November 2014), bringing in a few security
fixes we didn't yet have and a larger number of fixes for functional
and performance issues.
I spent most of my time reviewing the several hundred changes from the
upstream stable branch. I found a number of mistakes that would have
caused regressions. Those should all be fixed in the update to
linux-2.6, though I did not have nearly enough time for a thorough
regression test. I sent my fixes to Willy for inclusion in 2.6.32.65.
I also reviewed and applied fixes for several security flaws in the
kernel entry and exit paths. Andy Lutomirski identified and fixed
a number of problems upstream, the most serious of which was
CVE-2014-9322 (though this is not listed in the changelog because
the details weren't yet public). Willy found and backported the
upstream fixes for inclusion in 2.6.32.65. I checked that these make
sense (so far as I understand this code) and verified that Andy's test
cases now have the expected results when run on the new kernel version.
Updated: Added references to Codethink and Freexian.
Next.