A new user group for free and open VoIP and RTC is getting together in London. The first meeting is this Tuesday, 20 May at a central London location.
Free RTC mailing list
Please feel free to join the Free RTC mailing list (kindly sponsored by FSF Europe) if you would like to find out more about the emergence of free software based RTC solutions.
I previously wrote about the case for a Basic Income in Australia [1]. Since then I read an interesting article by Rutger Bregman in the Dutch site The Correspondent discussing the benefit that such Basic Income schemes have given in various places [2], he makes a great case for giving a Basic Income to poor people. However I believe that it should be provided to everyone. I believe that government payments shouldn t be means tested because the proportion of the population who earn more than the cutoff is usually very small (IE it doesn t save much money), because the money will be recovered from wealthy people in tax, and because the bureaucracy involved in determining who is eligible involves spending tax money to pay bureaucrats and costing everyone time in dealing with the process.
The concept of an Attention Economy has been getting some interest recently. But discussions of it seem to be mostly concerned with the needs of fairly wealthy people, how to advertise to them, how to filter out unwanted ads for them, etc. But the costs in attention can be even worse for people on low incomes or social security because they have many attention costs that could be solved by money. Many common essential purchases (EG soap, basic foods, and purely functional clothes) can become difficult decisions if saving a few dollars is important. The amount of thought involved in buying such items can result in someone who s not well off having little energy to concentrate on other things. I think that to have an effective social security system we need to consider how much cognitive effort is being required of people who are receiving benefits.
Last month I wrote yet another review of mobile phone plans in Australia [3]. Every time I do this it takes a significant amount of time because the Telcos devise overly complex plans to make it difficult to compare their offerings. It seems that they aim to make their offerings somewhat competitive if you can interpret them but confusing enough to allow many (most?) of their customers to pay needlessly high bills. I could just pick a random telco and pay whatever it takes, spending an extra $10 or $20 per month isn t such a big deal for me. Even though I advise a number of my relatives on the cheapest phone plan it s probably only barely saving enough money to be worth the effort, a major motivation for me is being stubborn and not wanting telcos to rip people off.
The Importance of Mobile Phones
A mobile phone seems to be essential for most people. Mobile phones are used for making medical appointments and for applying for work, so in almost every case some of the financial assistance paid to a job seeker or person on a disability pension will go towards mobile phone costs. The aims of the social security benefits seem to clearly involve a phone service. Given that most people who receive social security payments spend some of that money on mobile phone bills the government has a direct financial interest in not having such money wasted on needlessly expensive phone plans. As we also don t want to have people on social security spending time and attention trying to find the best phone plan it makes sense to have the government help manage this process.
Good communications is regarded as essential to education and economic development. A huge amount of taxpayer money was spent on the NBN (and then wasted by Tony Abbott when he cancelled the original plans) for these benefits.
Good phone access is also an issue of personal safety. While it is possible to call emergency services from a mobile phone that doesn t have a valid SIM there are probably few people who keep a spare phone charged for that purpose. Also there are a variety of issues that can impact life or health which can best be resolved by calling friends or relatives.
Free Phones
I think that the best solution to these problems is for the government to directly pay mobile phone bills. If we are going to have a Basic Income then the government should make the base payment for mobile phone calls for every resident, if not then the government should make the base payment for everyone who receives any form of social security payment. Obviously the amount of data that could be transferred over a 3G network is greatly in excess of the amount that any plans allow and offering true unlimited calling leads to people using mobile phones as baby-monitors, so some limits are necessary. But the government could cheaply pay for a phone plan that exceeds the requirements of most people and then allow anyone who wants more data or calls to pay extra.
Which Plan?
The cheapest all-inclusive mobile phone plan in recent times was Kogan who charged $299 per annum for 6G of data per month and unlimited calls. The cheapest current offer for unlimited calls seems to be Lebara s $30 per month offer which includes 2G of data.
My observation is that people who use 3G Internet just for phone use (as opposed to tethering a laptop or providing home Internet), who use a home Wifi network for installing Android programs and don t play Ingress tend to use a lot less than 1G of data per month. I would use between 400M and 700M per month if I wasn t playing Ingress and didn t use my phone as a Wifi access point.
In terms of call volume, 600 minutes a month should be enough to cover the basic needs of most people judging by the number of plans on offer with limits smaller than that.
As a current Lebara offer is $30 per month for unlimited calls and 2G of data (and there are similar offers from other telcos), it should be possible for a telco to offer 600 minutes of calls and 1G of data for less than $15 per month. When the government is paying (no bad debts) and many of the users will use much less than the quota such a plan should be profitable at $10 per month or less.
Implementation
The way to implement this would be to start with a tender that has a hard requirement for the minimum amount of service provided. This would include the number of minutes per month for calls, the number of SMS sent, and the amount of data transfer. To avoid excessive billing (a standard telco scam) there should be a requirement that fees for extra use not exceed some small multiple of the base rate, for example if the government was paying $10 for 600 minutes of calls and 1G of data the excess usage charges could be capped at 3 cents per meg and 5 cents per minute (3* the base rate) which would be profitable for the telco but not a scam.
If the telcos act in a market driven competitive manner they will compete to provide the most attractive offerings for $10 per month.
If the build cost of the NBN had been invested at government bond rates (for any of the rates used for current bonds) then it would pay for the mobile phone bills for every resident forever, so the cost of providing phones for everyone is in the range of government telecommunications programs. If people who are working were to pay an extra $10 in tax and people who are on social security had their benefits reduced by $10 then that would be a great deal if it saved them the $20 or more that most people spend on a basic phone plan.
Government Phone Delays
A friend who s a single mother pays for an unlimited mobile phone plan because calls to the social security office are usually kept on hold for more than an hour. It s likely that she could save money over the course of a year by paying for a cheaper plan and just dealing with the occasional big bill, but she needs to budget carefully and feels that she can t take that risk. It seems stupid that government phone delays (partly caused by cutting funds for staff) cause increased expenses for people who are receiving social security payments. If the government implemented a smart queuing system that allowed them to call people back instead of making them wait on hold then it would save money overall.
So there are obviously other ways that the government can save money on phone calls and time for everyone.
I ve been searching for interesting ways to manipulate RDF graphs in Python, to create an application that would handle Linked Data Resources in an OO-way, i.e. using Python classes and not tables/sets/lists of triples. The data will be persisted in graphs in a triple store, accessed through a SPARQL enpoint.
In this post, I ll illustrate how I managed to tie RDFLib s SPARQLStore plugin and RDFAlchemy to reach a rather nice looking result.
RDFLib provides tools to manipulate graphs, but most of the examples I found didn t load Graph instances from SPARQL, and generally used SPARQLWrapper results (tables) manually. Here comes a first tool to the rescue : SPARQLStore, which allows to dynamically query a remote SPARQL endpoint when navigating an RDFLib graph. I couldn t find a lot of documentation about it, but I found some hints in slide 51 of the excellent presentation by Tatiana Al-Chueyr Linking the world with Python and Semantics.
Now, I know how I can manipulate the RDFLib Graphs queried from a remote SPARQL endpoint with the usual methods, I m still not satisfied, because I want OO stuff, not lists of (predicate, object) tuples.
Here comes the second tool, RDFAlchemy, which allows to create descriptor classes mapping RDF Resources to Python classes. Here again, there isn t much docs available, but I found the excellent tutorial by Ted Lawless Reading and writing RDF for VIVO with RDFAlchemy.
Now we can put the 2 pieces together, modulo a few precautions : the SPARQLStore plugin of RDFLib will generate SPARQL queries everytime a graph is navigated, whereas RDFAlchemy expects the graph to be in memory (at least AFAIU). So we ll have to manually pre-load the contents of the graphs that we need for all the attributes of the descriptor classes.
I ve written an example code that illustrates this by trying to query french films in Wikipedia. Here s a copy of the gist. Attention, it will query DBPedia a lot, so pay attention to the bandwidth and memory if you change parameters.
It isn t perfect, and I still need to investigate benefits and limitations of the approach. On clear limitation is the number of SPARQL queries made on the endpoint, instead of a smarter pre-loading.
Also, on a side note, during tests I could spot a few issues with SPARQLStore, which seems lagging behind probably not used by so many people. The RDFAlchemy project doesn t seem to be in great health, mostly unmaintained from what I can see (and notice that I linked to the GitHub clone/fork that seemed to be the latest maintained while the original author s seems dead), but nevertheless, the code works with a more recent RDFLib, so that s not so bad.
Stay tuned for more adventures in Linked Data land in Python.
Random thoughts of a new contributor
I've started to contribute to Mozilla - and particularly to the Firefox Desktop QA team -
at the end of March, in order to apply for the OPW
with Mozilla as Bug Wrangler.
While being already part of the Free Software world as contributor clearly helps,
it's always difficult to find your way at first in such a big project, no matter how helpful the people you're working with are.
It's about trying to understand how the project is organized and who works on what, what is expected from you
as contributor and the specific style of interaction and contribution accepted in the project.
So, here's a couple of thought about it: the necessary disclaimer is that I'm a long-time Debian contributor meaning that,
inevitably, Debian is my reference model.
Also, everything I'm writing here regards only the specific part of the project I've been working in: Desktop QA and Bugmastering.
Documentation
The first thing that I noticed is the huge amount of documentation. Everything is very well documented
and while this is definitely a plus in my book, it's sometimes difficult to keep track of all this resources.
AFAICT, there are basically three main sources of documentation:
Some of the documents on these three different places are sometimes similar, making them redundant and it's difficult
to remember where you read what. At least for me. My workaround has been to bookmark pages as a mad woman, and also to
make a list on my wikipage of the pages I found more useful.
My top five of useful pages? Here we go!
And speaking of triage, special shout-out for the most useful addon ever for Mozilla triagers/testers: Nightly Tester Tools.
Community interaction
For someone coming from Debian, where everything is done via public mailing lists and/or IRC chans, Mozilla was a bit of a cultural shock.
The mailing lists are not very much used, at least in the QA community (or I'm not subscribed to the right ones ;)).
As for IRC, while there are many channels, they are not very active: meetings and important discussions are held using a proprietary videoconference software (Vidyo), and are mostly restricted to employees (but other people can join if they have a guest URL).
On the other hand, every time I asked for help - even the most stupid question - on IRC, I got a useful reply. And thanks to the folks on #testdays and #qa (especially petruta and Aleksej) I was able to speed up the learning process and understand how things work in the project.
So, while I'd like to see more public meetings, it's also true that the community is working well on interaction among contributors.
Community outreach
This is where I think Debian could borrow a couple of ideas. Mozilla basically got me hooked
thanks to their Bugdays: every Monday and Wednesday are - respectively -
dedicated to Triage and Verification of bugs. The events are open to everyone,
the wikipages for the events provide a good tutorial explaining the workflow in detail, and if you have any doubts
there are always people willing to help you on the dedicated IRC chan.
Every bug worked on during these events is also tagged: so that later it's possible to
check how successful the day was in terms of participation.
Bugzilla and the triaging/verification workflow
About Bugzilla I can only say that I like it. I like how flexible is for search queries, I like the possibility to have custom tags
on the whiteboard (as the [bugday-xxxxxx] one) and the smart way to interact among people in the bug without making the bug go stale (ie,
mostly the needinfo feature).
But beside the software used as BTS, I must admit that I really like the workflow and the whole concept of triaging in Mozilla.
The granularity of rights (everyone, canconfirm, editbugs) and the clear procedure for a permission upgrade; the presence of a team
constantly working on cleaning the incoming bugs, regardless of the product/component, to make easier for the developers the filtering
and the resolution as well; the attention to details of the verification process: each bug marked as Resolved Fixed need
to be Verified, to be sure that it's been actually fixed... All these things are really impressive.
This, obviously, is something that can be done inside an upstream project where there are people doing paid work,
and where the products are not too many. I cannot see how this kind of QA process can be applied to bugs against an entire OS.
But there are some things we (as in Debian) could take inspiration from.
Organizing regular Bugdays, for instance.
Creating a team of triagers to help both with incoming and with very old bugs.
And this, again, is a kind of work that can be done by everyone,
not only coding contributors: meaning that an additional effect would be to increase the diversity in the contributors pool.
As a side note: I'll start my OPW internship next Monday, and will spend three months playing with bugs and learning
how to be a Bug Wrangler! \o/\o/
Recently I've been seeing lot of posts about DNSSEC on Internet and I
thought I should configure my domain to be secured by DNSSEC.
copyninja.info domain is now secured with DNSSEC you can verify
this by DNSSEC analyzer by Verisign and DNSViz online tool or by
installing DNSSEC validator addon for
your browser.
There are good amount of tutorials and guides available to enable
DNSSEC for your domain, still I want to note down steps I followed to
here for the record (of course it will be helpful for me if I forget
it ;-))
First step will be installing bind9 and dnssec-tools package, if
you use aptitude installing dnssec-tools will pull down the bind9
unless you have configured aptitude to not install the Recommends.
Next setting up the zone file for your domain, for this first make a
copy of /etc/bind/db.local as /etc/bind/db.example.com, replace
example.com with your domain name. Now you need to add your zone
records to the zone file.
Next edit the /etc/bind/named.conf.local file and add following lines
zone "example.com"
type master;
file "/etc/bind/db.copyninja.info";
allow-transfer secondary; ;
;
Here replace secondary with your secondary DNS servers, if you don't
have one you can ommit this but its always recommended to have
secondary DNS servers for a zone, in cases when primary fails. After
this we need to enable DNSSEC on bind, this is done by editing the
file /etc/bind/named.conf.options. Add following lines into
options section.
A more explanation on this can be found on Linux Journal article.
Now its time to create DNSSEC keys and sign your zone, more about
different DNSSEC keys and records can be found in the Linux Journal
Article on implementation.
I used zonesigner utility from dnssec-tools which does job of
signing and including KSK and ZSK keys into bind configuration which
otherwise should be done manually. Here is the command line I used for
generating keys, thanks to Jonas for this.
Here we store our keys into /etc/bind/keys directory, and use
RSASHA256 algorithm for key generation which is more stronger than
the default used RSASHA1 (atleast thats what Jonas told me). This will
create ZSK and KSK for the signing zone and creates a signed zone file
db.example.com.signed in same directory as original zone file. Now all
you need to do is replace the zone file from db.example.com to
db.example.com.signed in file directive with your named.conf.local
file.
Note that this keys expire after 30 days so you need to resign your
zone before 30 days. For resigning just run zonesigner from
/etc/bind/keys. You can setup cron job to do this periodically.
Our signed zone is ready but we are not done yet! For DNSSEC to work
others should trust your signed record for this you need to register
your public keys with registrar for your domain and this can be done
via your domain provider (in my case this is Gandi).
You need to check your domain name providers documentation on how to
do this. For Gandi users there is a nice documentation.
Crowdsourcing ventures with disruptive business models are a regular point of contention these days.
In London, taxi drivers are threatening to create gridlock as part of an anti-Uber protest. In Melbourne, Uber drivers have been issued with $1,700 fines for operating without a taxi license. San Francisco city officials, despite being the birthplace of many of these ventures, are debating whether AirBNB should be regulated.
An orderly society or an old-school protection racket?
Just what exactly is it that established players in these industries are trying to achieve through their protests and lobbying efforts?
In the case of apartment rentals, many people have sympathy for respecting the wishes of neighbourhoods over those of individual landlords. In the case of car pooling schemes, the arguments tend to come not from motorists at large but from those who are afraid of competition.
Without competition, could things be any worse?
Melbourne actually provides the perfect backdrop for this debate. Only a couple of years before Uber came on the scene, the government had made a detailed study into the taxi industry. One of Australia's most prominent economic experts, a former chairman of the Australian Competition and Consumer Commission spent 18 months studying the industry.
One of the highlights of the incumbent system (and the reason I suggest Melbourne is the perfect backdrop for this debate) is the way licenses are issued to taxi drivers. There are a fixed number of licenses issued by the government. The licenses are traded on the open market so prices can go up and down just like real-estate. Under the rules of Australia's pension scheme, people have even been able to use money from their pension fund to purchase a taxi license as an investment. It goes without saying that this has helped rampant speculation and the price of a license is now comparable to the price of a house.
The end result is that no real taxi driver can afford a license: most of them have to rent their license from one of the speculators who bought the license. These fixed rental fees have to be paid every month whether the driver uses their car or not. Consequently, taxi drivers have cut back on other expenses, they are often criticised for failing to keep their cars clean and the industry as a whole is criticised due to the poor quality of drivers who don't even know their way around the city. The reason, of course, is simple: by the time some newly arrived immigrant has learnt his way around Melbourne he has also figured out that the economics of driving a taxi are not in his favor. Realizing there is no way to break even, they take other jobs instead.
It was originally speculated that the government review would dramatically reduce or abolish these speculative practices but ultimately lower license charges have only been used for the issue of 60 new licenses, barely 1% of the taxi fleet in the city today. Furthermore, the new licenses were only available to existing players in the industry.
Uber to the rescue?
Uber drove into the perfect storm as they launched their service in Melbourne in 2013.
Uber drivers get a significant benefit over their competitors in traditional taxis. In particular, as they don't have the fixed monthly payment to rent a taxi license, they don't have to work every day and can even take holidays or take time to clean the cars. These things may simultaneously benefit road safety and passenger comfort.
Meanwhile, those people who speculated on the old taxi licenses have tried hunger strikes and all kinds of other desperate tactics to defer the inevitable loss of their "investment".
The reality is that crowdsourcing is here to stay. Even if Uber is stopped by bullying and intimidation, the inefficiency of Melbourne's taxi system is plain for all to see and both customers and drivers will continue looking for alternatives. Other car-pooling apps based on barter or cost sharing will continue to find ways to operate even if the Uber model is prohibited.
It is interesting to note that the last great reform of Melbourne taxis, under Premier Jeff Kennett in the 1990s, simply resulted in a change of paint with the aim of making them look like those in New York City. Disruptive services like Uber (with their numerous technology-powered innovations to save time and money) appear to be doing far more to improve the lives of passengers and drivers.
The hidden cost
That said, large scale schemes like Uber do also have a down side for customer privacy. Hailing cabs in the street leaves no records of your movements. This new model, however, is leaving a very detailed trail of breadcrumbs that can be used for both marketing purposes or extracted (lawfully or otherwise) by some third party who wishes to monitor a particular customer's past or future movements. This is the trade-off that arises when we benefit from the efficiencies of any cloud-based service.
Recently I was wearing my Free Hugs shirt to different Free Software meetings, and I came up with the idea if we are advocating the Free in Software specificly, why not come up with Free Hugging Guidelines, too. So here they are, from now on considered to be named the RFHG.
Free Redistribution
Your hugs may not restrict any party from passing on the hugs they received from you.
Source Code
The hugs must be possible to be perceived and understandable in complete. You are not allowed to use any special techniques that can not be perceived.
Derived Works
Your hugs must be allowed to be modified, and must allow the modified forms of your hugs to be distributed under the same terms as they received them.
Integrity of The Author's Source Code
While you are allowed to pass on the hugs in modified form, you are not allowed to modify the DNA of the original person you received the hugs from. Genetic modification is out of the scope of the RFHG.
No Discrimination Against Persons or Groups
While we acknowledge that you might not feel willing to hug everyone, you must apply rules that do not distinquish by rules which would violate The Universal Declaration of Human Rights. Furthermore, you have the right to not hug a person if you are not in the mood for it. Please refrain from wearing any Free Hugs markers at those times though.
No Discrimination Against Fields of Endeavor
The hugs can not be restricted to be used in a specific field of endeavor. For example, you may not restrict the hugs from being passed on only in times of sorrow.
Distribution of Hugs
The rights attached to the hugs must apply to all to whom the hugs are redistributed without the need for execution of an additional license by those parties.
Hugs Must Not Be Specific to Rhonda
The rights attached to the hugs must not depend on the hugs being related to Rhonda. If the hugs are extracted from Rhonda and used or distributed without Rhonda nearby but otherwise within the terms of the hug's permissions, all parties to whom the hugs are distributed should have the same rights as those that are granted in conjunction with Rhonda.
Hugs Must Not Contaminate Other People
If you are contagious (e.g. got the flu, or worse) you have to apply appropriate counter measures to not transfer your illness with your hugs.
One last note: If you feel like it you don't have to wait until I wear my Free Hugs shirt again. I am fine with receiving (or giving) hugs like almost always. Surprise me. I at least know then that you read the RFHG. :)
Like always, enjoy!
Near the end of my internship with Simon Peyton Jones at MSR Cambridge I tackled the problem that foldl is not a good consumer in the sense of list fusion, as the resulting code compiles quite badly. I found an analysis that would allow GHC to safely do the required transformation to fix this in the common case; I dubbed this analysis Call Arity. The code is in GHC master (but not in 7.8), and I get to present at the Trends in Functional Programming conference in Soesterburg in 2 weeks. If you are curious you can either look at the code in CallArity.hs or the submitted paper, which yet has to go through the formal post-conference peer review in order to be officially accepted.
If you are going to TFP as well and want to get your GPG key signed, just talk to me there!
As promised, today I would like to write a bit about the making of
The Hacker's Guide to Python. It has
been a very interesting experimentation, and I think it is worth sharing it
with you.
The inspiration
All started out at the beginning of August 2013. I was spending my summer,
as the rest of the year, hacking on OpenStack.
As years passed, I got more and more deeply involved in the various tools
that we either built or contributed to within the OpenStack community. And I
somehow got the feeling that my experience with Python, the way we used it
inside OpenStack and other applications during these last years was worth
sharing. Worth writing something bigger than a few blog posts.
The OpenStack project is doing code reviews, and therefore so did I for
almost two years. That inspired a lot of topics, like
the definitive guide to method decorators
that I wrote at the time I started the hacker's guide. Stumbling upon the
same mistakes or misunderstanding over and over is, somehow, inspiring.
I also stumbled upon Nathan Barry's blog and book
Authority which were very helpful to
get started and some sort of guideline.
All of that brought me enough ideas to start writing a book about Python
software development for people already familiar with the language.
The writing
The first thing I started to do is to list all the topics I wanted to write
about. The list turned out to have subjects that had no direct interest for
a practical guide. For example, on one hand, very few developers know in
details how metaclasses work, but on the other hand, I never had to write a
metaclass during these last years. That's the kind of subject I decided not
to write about, dropped all subjects that I felt were not going to help my
reader to be more productive. Even if they could be technically interesting.
Then, I gathered all problems I saw during the code reviews I did during
these last two years. Some of them I only recalled in the days following the
beginning of that project. But I kept adding them to the table of contents,
reorganizing stuff as needed.
After a couple of weeks, I had a pretty good overview of the contents that
there I will write about. All I had to do was to fill in the blank (that
sounds so simple now).
The entire writing of the took hundred hours spread from August to November,
during my spare time. I had to stop all my other side projects for that.
The interviews
While writing the book, I tried to parallelize every thing I could. That
included asking people for interviews to be included in the book. I already
had a pretty good list of the people I wanted to feature in the book, so I
took some time as soon as possible to ask them, and send them detailed
questions.
I discovered two categories of interviewees. Some of them were very fast to
answer ( 1 week), and others were much, much slower. A couple of them even
set up Git repositories to answer the questions, because that probably
looked like an entire project to them. :-) So I had to not lose sight and
kindly ask from time to time if everything was alright, and at some point
started to kindly set some deadline.
In the end, the quality of the answers was awesome, and I like to think that
was because I picked the right people!
The proof-reading
Once the book was finished, I somehow needed to have people proof-reading
it. This was probably the hardest part of this experiment. I needed two
different types of reviews: technical reviews, to check that the content was
correct and interesting, and language review. That one is even more
important since English is not my native language.
Finding technical reviewers seemed easy at first, as I had ton of contacts
that I identified as being able to review the book. I started by asking a
few people if they would be comfortable reading a simple chapter and giving
me feedbacks. I started to do that in September: having the writing and the
reviews done in parallel was important to me in order to minimize latency
and the book's release delay.
All people I contacted answered positively that they would be interested in
doing a technical review of a chapter. So I started to send chapters to
them. But in the end, only 20% replied back. And even after that, a large
portion stopped reviewing after a couple of chapters.
Don't get me wrong: you can't be mad at people not wanting to spend their
spare time in book edition like you do.
However, from the few people that gave their time to review a few chapters,
I got tremendous feedback, at all level. That's something that was very
important and that helped a lot getting confident. Writing a book alone for
months without having anyone taking a look upon your shoulder can make you
doubt that you are creating something worth it.
As far as English proof-reading, I went ahead and used
ODesk to recruit a professional proof-reader. I looked
for people with the right skills: a good English level (being a native
English speaker at least), be able to understand what the book was about,
and being able to work with correct delays. I had mixed results from the
people I hired, but I guess that's normal. The only error I made was not to
parallelize those reviews enough, so I probably lost a couple of months on
that.
The toolchain
While writing the book, I did a few breaks to build a toolchain. What I call
a toolchain is set of tools used to render the final PDF, EPUB and MOBI
files of the guide.
After some research, I decided to settle on
AsciiDoc, using the
DocBook output, which is then being transformed to
LaTeX, and then to PDF, or either to EPUB directly. I realy on
Calibre to convert the EPUB file to MOBI. It
took me a few hours to do what I wanted, using some magic LaTeX tricks to
have a proper render, but it was worth it and I'm particularly happy with
the result.
For the cover design, I asked my talented friend
Nicolas to do something for me, and he
designed the wonderful cover and its little snake!
The publishing
Publishing in an interesting topic people kept asking me about. This is what
I had to answer a few dozens of time:
"Who is your editor?"
"Me."
I never had any plan for asking an editor to publish this book. Nowadays,
asking an editor to publish a book feels to me like asking a major company
to publish a CD. It feels awkward.
However, don't get me wrong: there can be a few upsides of having an editor.
They will find reviewers and review your book for you. Having the book
review handled for you is probably a very good thing, considering how it was
hard to me to get that in place. It can be especially important for a
technical book.
Also, your book may end up in brick and mortar stores and be part of a
collection, both improving visibility. That may improve your book's selling,
though the editor and all the intermediaries are going to keep the largest
amount of the money anyway.
"Oh, you will publish it yourself, great. So you will print it and sell it
to people?"
"Not really."
I've heard good stories about people using Gumroad to
sell electronic contents, so after looking for competitors in that market, I
picked them. I also had the idea to sell the book with Bitcoins, so I
settled on Coinbase, because they have a nice API to
do that.
Setting up everything was quite straight-forward, especially with Gumroad.
It only took me a few hours to do so. Writing the Coinbase application took
a few hours too.
"Oh, you will sell it only as an ebook? That's too bad. You need a paper
version. Many people will want a paper version."
My initial plan was to only sell online an electronic version. On the other
hand, since I kept hearing that a printed version should exist, I decided to
give it a try. I chose to work with Lulu because I knew
people using it, and it was pretty simple to set up.
The launch
Once I had everything ready, I built the selling page and connected
everything between Mailchimp, Gumroad, Coinbase, Google Analytics, etc.
Writing the launch email was really exciting. I used Mailchimp feature to
send the launch mail in several batches, just to have some margin in case of
a sudden last minute problem. But everything went fine. Hurrah!
I distributed around 200 copies of the ebook in the first 48 hours, for
about $5000. That covered all the cost I had from the writing the book, and
even more, so I was already pretty happy with the launch.
Retrospective
In retrospect, something that I didn't do the best way possible is probably
to build a solid mailing list of people interested, and to build an
important anticipation and incentive to buy the book at launch date. My
mailing list counted around 1500 people subscribed because they were
interested in the launch of the book subscribed; in the end, probably only
10-15% of them bought the book during the launch, which is probably a bit
lower than what I could expect.
But more than a month later, I distributed in total almost 500 copies of the
book (including physical units) for more than $10000, so I tend to think
that this was a success. I still sell a few copies of the book each weeks,
but the number are small compared to the launch.
I sold less than 10 copies of the ebook using Bitcoins, and I admit I'm a
bit disappointed and surprised about that.
Physical copies represent 10% of the book distribution. It's probably a lot
lower than most people that pushed me to do it thought it would be. But it
is still higher of what I thought it would be. So I still would advise to
have a paperback version of your book. At least because it's nice to have it
in your library.
I only got positive feedbacks, a few typo notices, and absolutely no refund
demand, which I really find amazing.
The good news is also that I've been contacted with a couple of Korean and
Chinese editors to get the book translated and published in those countries.
If everything goes well, the book should be translated in the upcoming
months and be available on these markets in 2015!
If you didn't get a copy,
it's still time to do so!
pub 2048R/9C6C32C7 2014-02-16 Laura ARJONA REINA <larjona99@gmail.com>
Laura ARJONA REINA <larjona@fsfe.org>
Laura ARJONA REINA <laura.arjona@upm.es>
Old key 0xE20474C3 no longer valid: lost secret key. (Clave antigua 0xE20474C4 ya no es v lida: clave secreta perdida.)
Fingerprint=F29B A6D8 D1DC A30F 3E34 53DF 5CD1 FDE5 9C6C 32C7
Please act as if it does not exist. The reason is that I cannot remember the passphrase of my master GPG key. This is why I didn t signed any of the keys of people that I met in Barcelona MiniDebconf. My geek self steem is a bit undermined, but feeling sorry for myself accomplishes nothing, so I think I will not hide problems and move on.
I ll post about my new key soon.
Long version
The bad news
The bad news are many.
I generated my key in February 2014 (I generated my very first GPG Key in 2010, as an exercise, but never used it again, and in 2014 I couldn t remember the passphrase, and the paper where it was written, had got lost before). Anyway, February 2014, new GPG key. I followed the Howto in FSFE wiki in order to use my brand new FSFE SmartCard. I have to admit that I didn t understand very well how all this works, and it seems that my main mistake was to miss-understand that since I was using a smartcard, with a PIN and an Admin PIN, remembering passphrases was no longer required (only remembering the PINs). I was WRONG! PINs are for daily use with the subkeys of your card (for encryption, decryption, and signing stuff different than GPG keys), you still have the master key that is not in the card (but in a separate medium in a safe place), and for the master key we still use passphrase, and the master key is the one that allows signing keys from other people, and changing, revoking, adding subkeys, etc.
So, it seems I used a random passphrase that I didn t write down and I could not remember, due to this terrible missunderstanding.
Another bad news is that I didn t generate a revocation certificate (well in fact, I was going to generate just before signing the first key of another person, and then I realize that it was asking the passphrase, hence the problem). First I thought that it should ask the PIN and my smartcard setup was wrong or anything, but after reading and interchanging emails with other people more experienced than me, I realized that I should remember that passphrase. And I couldn t. So there are no revocation certificates :(
Another bad news is that some (awesome) people already signed my key, and it will be difficult to meet again so they sign my new key. I was thinking about applying to the Debian new member process this summer, and I have not many opportunities to meet Debian people in person, so I gathered quite a lot signs last March in MiniDebConf Barcelona. Now I m again at the starting point (well, this is perfect excuse to try to join a Debian event soon :) I don t know how I would manage to do it, but I ll try!).
The good news (Always look at the bright side of life )
The main good news is that I didn t used the GPG key for signing/encrypting important stuff: I just interchanged some encrypted mail as test with friends, and signed some mails sent to public mailing lists (for signing mails I was using the smartcard PIN so I didn t notiece the problem).
The other main good news is that my key is not compromised (well, you can never be sure, but I think so). I cannot revoke it but I m quite sure nothing important depends on that key.
Other good news is that I have read a lot about how GPG works and how the smartcard works, keys and subkeys and all this stuff, and I think now I understand everything quite better. I have learned (and also tried) tools as nasty, John The Ripper and rephrase to try to recover the passphrase. I didn t recover it, but at least I know that all those (free software) tools exist and how to use them :)
And I have learned the lesson: to be extremely careful, test that everything works (not just try one or two things, test everything) and to not leave work for later (and for example, generate the revocation certificates just right after the keys).
Next steps
I ll send a message to all the friends that signed or downloaded my old GPG key apologysing and pointing to this blog post so they learn the details about why I create a new key.
I ll take this opportunity to download and use the Tails (The Agnostic Incognito System, a Debian derivative which is a live system and is focused in protecting privacy and anonymity of the user). Tails will be my safe, network disconnected environment to generate the new keys and do the sensible tasks with them. I think this time I will create my main key 4096-bit long (since now I understand that the main key is not stored in the card) and the subkeys can be 2048-bit or 3072 to fit in the smarcard.
Well, hands on! I ll write another blog post when my new GPG keys are ready. I hope third time s the charm!
Note: Thank you to all the people that gave me advice and support (knowledge, links, moral support) about this issue. You know who you are! Filed under: My experiences and opinion, Tools Tagged: Debian, encryption, English, Free Software, gpg, libre software, Moving into free software, mswl-cases
Just saw http://sny.no/2014/04/dbts and I feel compelled to note that distributed bug trackers are not new the earliest I personally encountered was Aaron Bentley s Bugs everywhere coming up on it s 10th birthday. BE meets many of the criteria in the dbts post I read earlier today, but it hasn t taken over the world and I think this is in large part due to the propogation nature of bugs being very different to code different solutions are needed.
XXXX: With distributed code versioning we often see people going to some effort to avoid conflicts semantic conflicts are common, and representation conflicts extremely common.The idions
Take for example https://bugs.launchpad.net/ubuntu/+source/ntp/+bug/805661. Here we can look at the nature of the content:
Concurrent cannot-conflict content e.g. the discussion about the bug. In general everyone should have this in their local bug database as soon as possible, and anyone can write to it.
Observations of fact e.g. the code change that should fix the bug has landed in Ubuntu or Commit C should fix the bug .
Reports of symptoms e.g. Foo does not work for me in Ubuntu with package versions X, Y and Z .
Collaboratively edited metadata tags, title, description, and arguably even the fields like package, open/closed, importance.
Note that only one of these things the commit to fix the bug happens in the same code tree as the code; and that the commit fixing it may be delayed by many things before the fix is available to users. Also note that conceptually conflicts can happen in any of those fields except 1).
Anyhow my humble suggestion for tackling the conflicts angle is to treat all changes to a bug as events in a timeline e.g. adding a tag foo is an event to add foo , rather than an event setting the tags list to bar,foo then multiple editors adding foo do not conflict (or need special handling). Collaboratively edited fields would be likely be unsatisfying with this approach though last-writer-wins isn t a great story. OTOH the number of people that edit the collaborative fields on any given bug tend to be quite low so one could defer that to manual fixups.
Further, as a developer wanting local access to my bug database, syncing all of these things is appealing but if I m dealing with a million-bug bug database, I may actually need the ability to filter what I sync or do not sync with some care. Even if I want everything, query performance on such a database is crucial for usability (something git demonstrated convincingly in the VCS space).
Lastly, I don t think distributed bug tracking is needed it doesn t solve a deeply burning use case offline access would be a 90% solution for most people. What does need rethinking is the hugely manual process most bug systems use today. Making tools like whoopsie-daisy widely available is much more interesting (and that may require distributed underpinnings to work well and securely). Automatic collation of distinct reports and surfacing the most commonly experienced faults to developers offers a path to evidence based assessment of quality something I think we badly need.
The NVidia card being unable to drive two monitors is a little annoying, and the lack of support for skype and chrome is a bother, but I think I can build chrome There ll probably be no flash, I imagine.
It took some time, but now it s finally done: KDE has translations for AppStream upstream metadata!
AppStream is a Freedesktop project to extend metadata about the software projects which is available in distributions, especially regarding applications. Distributions compile a metadata file from data collected from packages, .desktop files and possibly other information sources, and create an AppStream XML file from it, which is then directly or via a Xapian cache read by software-center-like applications such as GNOME-Software or KDEs Apper.
Since the metadata available from current sources is not standardized and rather poor, upstream projects can ship small XML files, AppStream upstream metadata or AppData in short. These files contain additional information about a project, such as a long description and links to screenshots. They also provide hints about public interfaces a software provides, for example binaries and libraries, making it possible for distributors to give users exactly the right package name in case they are missing a software component.
So, in order to represent graphical KDE applications like they deserve it in the new software centers making use of AppStream, we need to ship AppData files, with long descriptions, screenshots and a few URLs.
But how can you create these metadata files? In case you want your graphical KDE app to ship an AppData file, there is now a help page on the Techbase Wiki which provides all information needed to get started!
For non-visual stuff or software which just wants to publish it s provided interfaces with AppStream metadata, there is a dedicated page for that as well. Shipping metadata for non-GUI apps will help programmers to satisfy depedencies in order to compile new software, enhance bash-completion for missing binaries and provides some other neat stuff (take a look at this blogpost to get a taste of it).
And if you want to read a FAQ about the metadata stuff and get the bigger picture, just go to the Techbase Wiki page about AppStream metadata as well.
The pages are not 100% final, so if you have questions, please write me a mail and I ll update the pages, or simply correct/refine it by yourself (it s a wiki afterall).
And now to the best thing: As soon as you ship an AppStream upstream metadata file (*.appdata.xml* for apps or *.metainfo.xml* for other stuff), the KDE l10n-script (Scripty!) will automatically start translating it, just like we already do with .desktop files. No further actions are necessary.
I already have a large amount of metadata files here, partially auto-generated, which show that we have about 160+ applications in KDE which could get an AppData file, not counting any frameworks or other non-GUI stuff yet. Since that is a bit much to submit via Reviewboard (which I originally planned to do), I hope I can commit the changes directly to the respective repositories, where the maintainers can take a look at it and adjust it to their liking. If that idea does not receive approval, I will just publish a set of data at some place for the KDE app maintainers to take as a reference (the auto-generated stuff needs some fixup to be commit-ready (which I d do in case I can just commit changes)). Either way, it is safe now to write and ship AppData files in KDE projects!
In order to get your stuff translated, it is necessary that you follow the AppStream 0.6 metadata specification, and not one of ther older revisions. You can easily detect 0.6 metadata by the <component> root node, instead of <application>, or by it having a metadata_license tag. We don t support the older versions simply because it s not necessary, as there were only two KDE projects shipping AppData before, which are now using 0.6 data as well. Since 0.6, the metadata XML format is guaranteed to be stable, and the only reason which could make me change it in an incompatible way is to prevent something as bad as the end of the world from happening (== won t happen ). You can find the full specification (upstream and distro data) here.
All parsers are able to handle 0.6 data now, and the existing tools are almost all migrated already (might take a few months to hit the distributions though).
So, happy metadata-writing!
Thanks to all people who helped with making this happen, and especially Burkhard L ck and Albert Astals Cid for their patch-review and help with integrating the necessary changes into the KDE l10n-script.
British taxpayers are paying for extra support for Windows XP due to a lack of planning by the UK government [1]. While the cost of this is trivial compared to other government stupidity (such as starting wars of aggression) this sort of thing should be stopped.
The best way to solve such problems is for governments to only use free software. If the UK government used Red Hat Enterprise Linux then when Red Hat dropped support for old versions they would have the option of providing their own support for old versions, hiring any other company to support old versions, or paying Red Hat for supporting it. In that case the Red Hat offer would probably be quite reasonable as competition drives the prices down.
It doesn t seem likely that the UK government will start using only free software in the near future. It s not impossible to do so, there are organisations dedicated to this task such as Free-gov.org which aims to develop e-government software that is under GPL licenses [2]. The Wikipedia page List of Linux Adopters [3] has a large section on government use, while not all entries are positive (some have reverted) it shows that it s possible to use Linux for all areas of government. But governments often move slowly and in the case of wealthy countries such as the UK it can be easier to just tax the citizens a little more than to go to the effort of saving money.
But when governments use proprietary software they shouldn t be restricted in support. It seems that the only way to ensure that the government can do what it needs is to have a source escrow system. Then if the company that owned the software ceased supporting it anyone who wanted to offer support would be able to do so. This would probably require that software which is out of support be released to the public domain so that anyone who wanted to tender for such support work could first inspect the code to determine if they were capable of doing the work.
People who believe the myths about secret source software claim that allowing the source code to be released would damage the company that owns it. This has been proved incorrect by the occasions when source code for software such as MS-Windows has been released on the Internet with no apparent harm. Also Microsoft have a long history of licensing their source code to universities, governments, and other companies for various purposes (including porting Windows to other CPUs). It s most likely that some part of the UK government already has the full source code to Windows XP, and it s also quite likely that computer criminals have obtained copies of the source by now for the purpose of exploiting security flaws. Also they stop supporting software when they can t make money from providing the usual support, so by definition the value to a company of the copyright is approaching zero by the time they decide to cease support.
Given the lack of success experienced by companies that specialise in security (for example the attack on RSA to steal the SecurID data [4]) it doesn t seem plausible that Microsoft has had much success in keeping the source to Windows XP (or any other widely used product) secret over the course of 12 years.
In summary source code to major proprietary software products is probably available to criminals long before support expires and is of little value to the copyright owners. But access to it can provide value to governments and other users of the software.
The only possible down-side to the software vendor is if the new version doesn t provide any benefits to the user. This could be a problem for Microsoft who seem to have the users hate every second version of Windows enough to pay extra for the old version. The solution is to just develop quality software that satisfies the needs of the users. Providing a legal incentive for this would be a good idea.
So the Kelly report of the independent review into the events leading to the Co-operative Bank s capital shortfall was published yesterday. During the day, I was putting odd bits from it out in 140 characters with the hashtags #coops #kellylessons. Here they are in one more permanent place. How many of these lessons has your organisation whether a co-op or not learned?
Running a full-service bank is a complex business Bank failed to understand the limits of its own capability
The most important task for any board is to put in place the right Executive leadership for the business
Ownership of a regulated bank requires a clearly articulated statement addressing mgmt & gov nance relationship
Failures in board oversight are inevitable if the criteria used to elect do not require the necessary skills
A bank board must include sufficient numbers of technically competent directors
Boards need good m gmt info and to demand it if it is not forthcoming. Failure to obtain explains failings
A bank should develop&implement robust risk gov nce&oversight and an appropriate control framework
IT transformation keep as simple as poss , phase delivery.., deploy the right resources, plan for contingencies
Bank should have paid closer attention and responded with greater urgency to what the Regulator told it
Pay careful attention to the advice of external advisors. The Group ignored well-founded inconvenient advice
Postponing dealing with problems is almost never a sustainable solution.
Values need to be translated into meaningful guidance The Bank s ethical positioning should be more apparent
Mantras about scale and ethics are no substitute for strategies grounded in a real understanding
Talent management is critical Lack of capability driven by weaknesses in its recruitment&subsequent m gmt
Tolerating culture of underperformance, weak transparency and a lack of accountability, constrains an organisation
And here we go again! We're proud to announce the new version of Smuxi, release
0.11 "Distractions". During the development, 11 bug reports and
2 feature requests in 112 commits were worked on. Notable
highlights in this release are:
User Interface Enhancements
The chat list can be shrunken. This is especially handy with XMPP/Jabber and
long group chat identifiers.
The highlight counter is now a separate column. This enhances the vertical
alignment with other highlights and guarantees to be visible even if the chat
name was truncated.
Multi Identity Support
Smuxi cares for user feedback. Multi identity support was the
most voted feature and thus it has been implemented! Now you can please your
schizo^Wdesire to use different nicks, users and real names depending on the
server. Simply edit the server in preferences and change the details.
Message Patterns
Everybody knows text can be boring because it is all just text. Nothing can
sidetrack you except reading that bare text. Text often has recurring patterns
from which something useful and interactive can be created. For example, someone
writes:
Hey meebey, do you know RFC2812?
RFCs are a recurring pattern with a distinct number behind it and are real
references to something in the internet (collection of protocol specifications).
So I would usually fire up a browser tab, copy/paste or type RFC2812 into my
favorite search engine and click the first hit. Then I'd reply to the question
afterwards. But with Smuxi's message patters, it turns RFC2812 into a link on
which you can simply click to launch the relevant document.
Wow this is very cool, but isn't this already happening with http URLs and email
addresses? Exactly! Why shouldn't more information be used to create useful
things from it? Smuxi message patterns allow you to define text patterns that
are transformed into clickable links. This can be used for RFCs, CVEs, bug
report numbers (#XXX), git commit hashes and much more. Make good use of your
creativity!
By default Smuxi comes with built-in message patterns for:
URLs
heuristic URLs (not starting with http:// etc)
email addresses
RFCs
CVEs
Debian Security Advisories (DSA)
Many popular bug trackers (GNU, GCC, kernel, Launchpad, freedesktop,
GNOME, KDE, Xfce, Debian, Redhat, Novell, Xamarin, openSUSE, Mozilla, Samba,
SourceForge, CPAN, boost, Claws and Smuxi)
If you know more general patterns useful for others, please submit them.
For a full list of built-in message patterns or how to add your own patterns,
head over to the message pattern documentation.
Hooks Enhancements
A bug was fixed that prevented hooks from issuing more than one command
Twitter Enhancements
As of 14 Jan 2014, Twitter disallows unencrypted HTTP requests which broke
Smuxi's Twitter support. Smuxi is now making exclusively encrypted requests
(HTTPS) and thus works with Twitter again.
I'm mostly back into my normal routine now. Next week should be spot on. Today,
after my chiropractic adjustment and another walk to the post office to collect
another package, I got stuck into cleaning the house.
I got that mostly done before my massage, and knocked out the rest of it before
I picked up Zoe from Kindergarten.
Zoe seems to have successfully dropped her day time nap at Kindergarten now,
which certainly makes a huge difference to getting out of the place on time.
I'd underestimated the number of kids coming to Zoe's birthday party, so I
needed to get some extra goody bags made up, so we headed directly out to
Westfield Carindale to raid the The Reject Shop for some more bits and pieces.
After we got home from that, Zoe watched a bit of TV and helped me assemble the
extra bags, and then we had dinner.
After some epic procrastination (on Zoe's behalf) I managed to get her to bed
approximately on time. I really need to try some different approaches to
getting through the bath time routine, because it's just taking too long. I
gave myself a couple of time outs because I could see the situation
deteriorating if I didn't. It's unhelpful that my blog seems to be the third
hit in Google at the moment for "positive parent procrastination". I don't have
the answers.
I hate the days when I wake up at odd hours for no good reason. This morning I
woke up at 4:30am briefly, with no idea why. It makes me wonder if there was
some sort of external noise, and that's what woke Zoe up yesterday morning.
I got myself going at a reasonable hour this morning, and decided to walk to
the Bulimba post office to collect a package that was waiting for me. It was a
nice enough morning for a walk, and I'm glad I decided to do it.
Along the way, I observed multiple grandmothers walking their grandchildren to
school. I've been thinking a lot about next year lately. I feel very strongly
about Zoe not having to go into after school care. It seems that one of the new
societal norms is the grandparents have to step in with the school
transportation and after school care. That's not going to be particularly
practical in our situation though, so I'm currently leaning towards seeking
some sort of flexible employment next year that will allow me to be able to be
available after Zoe finishes school.
I was fairly motivated to get stuck into my to do list after my walk. A long
standing item was to cancel one of my remaining US credit cards, and the time
difference worked out well to do that, so I finally took care of that. I then
realised it was a good time for the US East Coast, so I did a Hangout with one
of my best friends in New York. It was great to have a catch up.
After that, I finished off my US tax return, and also sorted out some other
stuff that needed finishing off. I had to go to the Valley to find a FedEx
location, so I drove over there, and on the way back stopped off in Bulimba to
get some Mother's Day cards. By that stage it was about time to pick up Zoe
from Kindergarten, so I quickly grabbed some lunch and then drove over to pick
her up.
She didn't nap again today, so that made our departure from Kindergarten nice
and easy. I'd booked both of us in for haircuts at 3pm, so we got home with
enough time for Zoe to ride her scooter to the hairdresser. We had our haircuts
and Zoe had a bit of a play in the play corner, and we headed back home.
I'd bought a venus fly trap from Bunnings last week while we were picking up
other bits and pieces. I wanted to show Zoe how they worked, so we watched a
few YouTube videos. This
one was particularly good. After that, we went down to the rubbish skip
with our fly trap to see if we could catch any flies in it, but Zoe quickly
lost interest. So we headed back upstairs, and triggered one with a toothpick.
I probably could have done this on a Friday and called it a Science Friday
activity with a botany bent.
After that, we just watched some TV together on the couch until Sarah arrived
to pick her up.
I ve seen many comments about swap space and SSD claiming that swap will inherently destroy SSD through using too many writes. The latest was in the comments of my post about swap space and SSD performance [1]. Note that I m not criticising the person who commented on my blog, everyone has heard lots of reports about possible problems that they avoid without analysing them in detail.
The first thing to note is that the quality of flash memory varies a lot, the chips that are used in SSDs for workstation/server use are designed to last while those in USB-flash devices aren t. I ve documented my unsuccessful experiments with using USB-flash for the root filesystem of a gateway server [2] (and the flash device that wasn t used for swap died too).
The real issue when determining whether swap will break your SSD is the amount of writes. While swapping can do a lot of writing quickly that usually doesn t happen unless something has gone wrong. The workstation that I m currently using has writes to the root fileystem outnumbering writes to swap by a factor of 130:1 (by volume of data written). On other days I ve seen it as low as 42:1, in either case it s writes to the root filesystem (which is BTRFS and includes /home etc) that will break the SSD if anything. For some other workstations I run I see ratios of 201:1 (that s with 8G of RAM), 57:1, and 23:1. In a quick search I couldn t find a single system I run where even 10% of disk writes were attributed to swap. This really isn t surprising given that adding RAM is a cheap way to improve the performance of most systems. If a SSD didn t do any write leveling (as is rumored to be the case with cheap USB flash devices) then swap use might still cause a problem because of the number of writes in a small area, but if that was the case then filesystem journals and other fixed data structures would be more likely to cause a problem and any swap based breakage would break swap not the root filesystem (although if swap was the first partition then it might also break the MBR).
Of the workstations that are convenient to inspect the one with the most writes to the root filesystem and swap space (IE everything on /dev/sda) had 128G written per day for 1.2 days of uptime, but that involved running a filesystem balance and some torrent downloads (not the typical use). Among the two systems which had been running for more than 48 hours with typical use the most writes was 24G in a day. If a SSD can sustain 10,000 writes per block (which is smaller than quoted by most flash manufacturers nowadays) and has perfect wear leveling (which is unlikely) then the system with a 120G SSD and 128G written in a day could continue like that for almost 10,000 days or 27 years much longer than storage is expected to work or be useful. So for workstation use (where even 24G of writes per day probably counts as heavy use) a 120G SSD that can sustain 10,000 writes per block shouldn t be at great risk of wearing out.
Conclusion
I believe that swap is much less likely to break SSDs than regular file access on every system with a reasonable amount of RAM. For systems which don t have enough RAM you probably want the speed of SSD for swap space anyway in spite of the risks.
If wear leveling works as designed and the 10,000+ writes per block claims are accurate then SSDs will massively outlast their useful life. Long before they wear out they should be too small, too slow, and probably not compatible. 26 years ago I had a 5.25 full height ST-506 disk in my desktop PC, it wouldn t physically fit in most systems I own now (unless I removed the DVD drive), there is no possibility of buying a controller (I don t own a system with an ISA bus), and that disk was too slow and small by today s standards. A 27yo SSD isn t going to be useful for anything, even for archive storage it s no good as no-one has tested long term storage and data could decay before then.
Since my blog post about BTRFS in March [1] not much has changed for me. Until yesterday I was using 2.13 kernels on all my systems and dealing with the occasional kmail index file corruption problem.
Yesterday my main workstation ran out of disk space and went read-only. I started a BTRFS balance which didn t seem to be doing any good because most of the space was actually in use so I deleted a bunch of snapshots. Then my X session aborted (some problem with KDE or the X server I ll never know as logs couldn t be written to disk). I rebooted the system and had kernel threads go into infinite loops with repeated messages about a lack of response for 22 seconds (I should have photographed the screen). When it got into that state the ALT-Fn keys to change a virtual console sometimes worked but nothing else worked the terminal usually didn t respond to input.
To try and stop the kernel from entering an infinite loop on every boot that I used rootflags=skip_balance on the kernel command line to stop it from continuing the balance which made the system usable for a little longer, unfortunately the skip_balance mount option doesn t permanently apply, the kernel will keep trying to balance the filesystem on every mount until a btrfs balance cancel operation succeeds. But my attempts to cancel the balance always failed.
When I booted my system with skip_balance it would sometimes free some space from the deleted snapshots, after two good runs I got to 17G free. But after that every time I rebooted it would report another Gig or two free (according to btrfs filesystem df ) and then hang without committing the changes to disk.
I solved this problem by upgrading my USB rescue image to kernel 3.14 from Debian/Experimental and mounting the filesystem from the rescue image. After letting kernel 3.14 work on the filesystem for a while it was in a stage where I could use it with kernel 3.13 and then boot the system normally to upgrade it to kernel 3.14.
I had a minor extra complication due to the fact that I was running apt-get dist-upgrade at the time the filesystem went read-only do the dpkg records of which packages were installed were a bit messed up. But that was easy to fix by running a diff against /var/lib/dpkg/info on a recent snapshot. In retrospect I should have copied from an old snapshot of the root filesystem, but I fixed the problems faster than I could think of better ways to fix them.
When running a balance the system had a peak IO rate of about 30MB/s reads and 30MB/s writes. That compares to the maximum contiguous file IO speed of 260MB/s for reads and 320MB/s for writes. During that time it had about 50% CPU time used for my Q8400 quad-core CPU. So far the only tasks that I do regularly which have CPU speed as a significant bottleneck are BTRFS filesystem balancing and recoding MP4 files. Compiling hasn t been an issue because recently I haven t been compiling many programs that are particularly big.
Lessons Learned
I should photograph the screen regularly when doing things that won t be logged, those kernel error messages might have been useful to me or someone else.
The fact that the only kernel that runs BTRFS the way I need comes from the Experimental repository in Debian stands in contrast to the recent kernel patch that stops describing BTRFS as experimental. While I have a high opinion of the people who provide support for the kernel in commercial distributions and their ability to back-port fixes from newer kernels I m concerned about their decision to support BTRFS. I m also dubious about whether we can offer BTRFS support in Debian/Jessie (the next version of Debian) without a significant warning. OTOH if you find yourself with a BTRFS system that isn t working well you could always hire me to fix it. I accept payment via Paypal, bank transfer, or Bitcoin. If you want to pay me in Grange then I assure you I will never forget about it. ;)
I thought that I wouldn t have CPU speed issues when I started using the AMD64 architecture, for most tasks that s been the case. But for systems for which storage is important I ll look at getting faster CPUs because of BTRFS. Using faster CPUs for storage isn t that uncommon (I used to work for SGI and dealt with some significant CPU power used for file serving), but needing a fast quad-core CPU to drive a single SSD is a little disappointing. While recovery from file system corner cases isn t going to be particularly common it s something that you want completed quickly, for personal systems you want to be doing something else and for work systems you don t want down-time.
The BTRFS problems with running out of disk space are really serious. It seems that even workstations used at home can t survive without monitoring. For any other filesystem used at home you can just let it get full and then delete stuff.
Include rootflags=skip_balance in the boot loader configuration for every system with a BTRFS root filesystem and in the /etc/fstab for every non-root BTRFS filesystem. I haven t yet encountered a single situation where continuing the balance did any good or when it didn t do any harm.