Saturday, June 6, 2015

Personal kanban and process-oriented work...

So several weeks have passed since I wrote my last post about doing personal kanban and about using a weekly board and pulling cards on to this board.

The big thing is I'm still using this system - which is a big deal for me.  I've been going at it for many weeks and I feel I'm unlikely to discard it any time soon.  But things have changed (evolved) quite a bit...

The biggest thing I've noticed is that an activity that I had earmarked as an everyday one, that I would do for as little 10 minutes in some cases and record in a tally next to my weekly board, very quickly became part of my daily habit.  It was really "sticking".  And it led me to this realisation: If you want to get good at something, you should do it regularly.

Mind-blowing I know, but I think it bears examining more carefully here.  I'd wager that small, continual, regular sessions learning a skill beat longer and irregular ones any time, though this might depend on the activity you are doing and also the way in which you spend that time.  At any rate if you're trying to build a skill that's really important to you, work on it either everyday or very regularly (think "recurring") even if it's for a short period.  [Note: my context for writing this is that I am trying to make efficient use of the time I have outside of regular work and other commitments that I already have.]

How does this fit in with (personal) kanban and WIP?  I think for the moment I have to make a distinction between activities that have a recurring nature, that don't easily fit into a backlog, and other activities that are more discrete, task-like in nature and which do.  That distinction is the difference between

  • process-oriented work, and
  • goal-oriented work

This is the difference that is described in Thomas Sterner's book "The Practicing Mind".  In his book, Sterner, a musician and piano tuner amongst other things, points out the power of process-oriented work and its de-emphasis in the western mindset and culture.  The Western mindset is goal-oriented; it is one of getting results and measuring success by results to the point that how the result is achieved becomes irrelevant (eg "cheating" an exam or faking a result).  Thinking in terms of outcomes or results isn't intrinsically bad.  I think it can be powerful way to think.  But there is a darker side perhaps symptomatic of a culture that only knows how to think this way.  It is a culture that assesses people's worth and capabilities purely by some abstract metric (a mark or grade), that is materialistic ... "If I get this [thing], *then* I'll have made it / I'll be happy" etc...

By contrast, process-oriented thinking is about focusing on what you are doing, the quality of what you are doing, how you are doing it, what you focus on as you do it. Process-oriented behaviour focuses on the process of achieving a goal rather than focusing on having it.  You don't achieve something, you do it, and in a neurological sense, you are what you do, because you're building connections in your brain as you do something hopefully making you better at doing it, if you do it enough and focus on the right things.

As a quick aside Timothy Gallwey's analogy of the "10 cent computer" which is your conscious mind and the "billion dollar computer" which is the rest of your brain, is apt here.  It is your billion dollar computer (the not-so-conscious part of you) that performs the juggling you spent a week learning how to do, or hit a golf ball effortlessly (if you ever got that far), or a tennis ball, or writes code cleanly in a programming language or framework that you've mastered.  When you're engaging in recurring tasks, in a process-oriented way, your 10 cent computer is directing ("allowing" might be a better word) your billion dollar computer in what to focus on, steadily and regularly, allowing it to learn subtleties and complexities that you could never perform consciously without such an investment.  And every day you wake up to do it again, with your brain having formed new connections overnight from the previous day, ready to make new insights.

So picking something to work on everyday or with similar level of regularity is quite a significant thing.

For me, I can support maybe 2 "everyday"-type things.  There's a limit here, just like there's a limit on the number of discretegoal-oriented / task-oriented things you should be tackling (your WIP); you can only make yourself do so many different things every day, and you might just want to start with one and see how many more you can add from there.  Mine are currently a musical skill I'm trying to work on, and the other is a set of technical skills I'm trying to build.  These things are so important to me, that I make a point of doing them everyday, even if it's just 10 to 20 minutes that I can spare.   

There are other recurring, process-oriented things you can fit into your week that don't have that "everyday" type of intensity.  For instance there are things you might do 2 or 3 times a week, such as  exercise.  These things might require scheduling, so I have cards for these that I put on to my weekly board.  They may be things you want to tally (do "n" times a week) or simply make a habit of doing on a particular day etc... The weekly board really helps me to plan these out and shuffle them around as circumstances change.

Process-oriented elements in my personal kanban give me something else: balance.
In the past (before personal kanban and visualising my situation), if I wanted to work on a skill, I'd spend long periods on it, usually late into the evening.  Then maybe a day or two later, I'd totally neglect it or be distracted by some other task, eventually I'd lose track of it or revisit it after a long hiatus.  This irregular and lumpy workflow doesn't happen so much now.  I know I can't spend indefinite periods of time on a favoured activity du jour anymore.  If I did, other things both mundane and important would suffer.  On the flip-side, when time is short, I will try to work on an everyday type activity even if I can only spare 10 or 20 minutes of my time for that day.  At least I've kept it "warm".

My personal kanban (if I can call it that) is a marriage of the "smooth": continuous, process-oriented elements and the granular: discrete, task-like goal-oriented elements.  I don't see these 2 ways of thinking as antithetical or incompatible; as I engage in a process-oriented way, specific goals and tasks may emerge that I can put into my backlog.

These roughly are the main elements in my pkb now:
  • a weekly board with days of the week with cards that represent both process-oriented and goal-oriented items of work; I've dispensed with the "blue" cards that I push on
  • an everyday / tally column for recording recurring things
  • a backlog of goal-oriented items, short range and long range; the short range stuff is a bit like a sprint, a small number of things I want to try to achieve that week; I actually have some more specific backlogs for different things that feed into this 
  • skill area columns; I have about 4 of these that represent areas I want to focus on in a process-oriented way; these are the home of my process-oriented efforts.

Saturday, May 9, 2015

Personal kanban evolution

In this blog post I look at the idea of a "daily or day-of-the-week WIP" in the context of a personal week.  Some of this takes its cues from the Personal Kanban book [PKB], which discusses things like sequestering, "large project" approach with "roll up" tasks - basically, techniques to visualise recurring personal tasks and recurring work generated from on-going projects.

Perhaps the biggest idea I've gotten from kanban so far is the importance of visualisation or representing your situation.  It's hard to start thinking about WIP or fine-tuning things until you've had time to do this and evolve it a bit.  So here goes...

It started with...

My situation and context for this article: I'm always trying to do stuff outside of my day job for one reason or another, and I'm interested in how to get the most out of myself given such a huge constraint.   So I started trying out personal kanban after reading the personal kanban book a couple of weeks ago.

The 2 rules of personal kanban are:
  • visualise your work
  • limit your work-in-progress (WIP) (aka "don't multitask or avoid incessantly switching between (unfinished) things")
I started with a backlog of things I wanted to do in trello with a "READY" column for things that I could potentially work on, a "DOING" column where you limit how many things you are working on and a "DONE" column.

This was an interesting exercise as I realised just how much I tend to jump around from one thing to another. Having a WIP limit on my work forces me to focus and it forces me to think about what I want to do next.

What to do with recurring things....

As I was reading through the first part of the book however I started wondering about periodic or recurring things.

There are things I really don't want to record like brushing my teeth - that makes no sense. And I feel like there are definitely things I'd rather leave "unstructured".  But there are other periodic things which are things I want to do but which don't have any kind of immediate goal or end state but which I'm keen to track in some way.  Things like going for a run for instance - especially in winter, when I need to motivate myself. Or doing some weight training or doing some music exercises because I want to train my ear.  These are regular things that I want to coordinate but I don't want to drag them repeatedly into a "done" column.

The appendix A of PKB turns out to be the most interesting part from my perspective because the authors discuss some real case studies where recurring work was important.  One case involves handling both a training regime and a regular study schedule. In these cases additional "value streams" or swim lanes (grids or additional boards of some sort) were created in addition to the main board with the express purpose of visualising the recurring work and tracking it.

Finding a better visualisation...

So, a week into my trello pkb experience I started thinking...   How do I track these little regular things I want to do alongside the bigger projects and things I want to take on... all outside of my regular job?

I can plan big goals and projects; prioritize them,  put them into a backlog,  split them up and manage in a semi-scrum like fashion.

But my initial attempts to visualise the recurring aspects of my life involved having a daily column or a weekly column and using things like trello checklists or cards that recorded tallies for particular activities. One of the limitations I was hitting was my desire to use more grid-like visualisations (ones that had both rows and columns) to explore better ways to do this rather than the columnar approach that trello provides.

The weekly board...

This is what I came up with (still in trello), after allowing my thinking to evolve over about a week...
  • I created a new board I call the "weekly board" separate to my backlog board
  • I created a column for each day of the week (a list in trello) - something I had seen in one of the case studies at the back of the PKB book. 
  • I added an "everyday / tally" column for (a small number of) things that were daily that I wanted to track or tally over weekly or even more extended periods  (one way might be to use a trello checklist inside a card and periodically resetting it). 
Next to these I have a whole bunch of other columns, but 2 in particular are:
  • recurring list containing recurring things,  things that are weekly or less regular than weekly; 
  • and a list I call the "try-to-do" list, also a list of recurring things which I'll discuss shortly
  • (An example of another column I have is a "calendar" list; it lists things like particular meetups I want to try to go to or at least be aware of during the week etc)
Where my recurring list consists of regular chores and the stuff of life,  my "try to do" column focuses on recurring things I want to target on a regular basis because they are significant to me in some way.

So for running, I create 2 cards that initially go in my "try to do" column one for each run. Let's also say I want to target doing 3 weight training sessions per week if I can possibly squeeze this in. And maybe I want to do 2 music reading exercises during the week as well.

So:
  • I create the requisite number of cards for each of these activities and have them all start in my "try to do" column
  • Then I push these cards onto my weekly board - onto one of the days of the week. 
I have to space out the running and the weights with rest days between like-exercises.  I regularly review my "recurring" list and drag things from there onto my weekly board as well, things like shopping and cooking (if I don't plan cooking I end up eating badly the whole week).  And there are potentially "one-off" cards that I need to create.

Next to my days of the week is my "everyday / tally" column where I have a small number of cards that are so important to me I want to track or do them every day.  This reduces clutter on my week day columns since I don't have to create a card for each day of the week.

Getting a weekly rhythm - the engine

The final inversion of my PKB experience occurred when I created some additional "try to do" cards explicitly for the purpose of doing "work".  These "work" cards are placeholders to indicate time spent doing "non-recurring" stuff, at the moment each one is roughly equivalent to an hour.   I push these onto my day columns along with my recurring cards.  I colour my "work" cards blue in trello so they stick out as points where I hope to do a solid block of (non-recurring) work.  Knowing where I can put these work cards and how many I can sustain on top of my regular week is one of the key things I want to visualise.

And suddenly... I have a dashboard;  a gauge (or set of gauges??) showing my week.  Each day of the week on my board has a WIP limit of sorts;  I can see if I've got too much on any given day. I can drag things around and make trade-offs as unexpected things happen during the course of the week, and I can prioritise my day, eg "can I try to do this before I go to work" etc .

I say "inversion" because prior to building my weekly board, my main focus was my backlog board with a single WIP (doing) column.  Now my primary dashboard is my weekly board with a column for each day of the week forming a "daily WIP" in conjunction with the "everyday / tally" column.  Is it a WIP in the kanban sense?  Well, maybe it roughly maps to the idea of a "today" column as proposed in the Personal Kanban book.  When I'm ready to do one of my blue "work" cards that I've scheduled for the current day, I can switch to my backlog board to easily see and review what my current focus / WIP for non-recurring work is.

My aim is to build up a "rhythm" between my recurring "try to do's" and my non-recurring "work" items whilst fitting all the other recurring stuff in as necessary.

The PKB book mentions that small tasks can be periodically rounded up and "sweated out" to help you clear out your backlog - these tasks are dubbed "ankle biters".  Small recurring things for me are handled by my weekly board.  I've rounded up the other small non-recurring stuff into a mini-backlog on my weekly board so that I can drag items from there to a day of the week as and when I think I can do them - I could even create a couple of "sweat-out" cards if I wanted. [Actually, I've put the ankle biters backlog list back on my backlog board next to my main backlog.  It's a way to weed out smaller things from my backlog.]

So, my backlog board is allowed to focus on the bigger things I'm trying to do with my life and my weekly board is the engine I need to tune to help do that as best I can given all my other constraints.

Sprinting on (non-recurring) work?

Knowing how my week is going to look when I plan out my weekly board also means I can look to gauge how much (non-recurring) "work" (on my backlog board) I can try achieve in a week and on which day.  So I corral some high-priority cards on my backlog board into a "week" column.  This maybe is a little bit like creating a scrum sprint inside kanban.  This gives me a weekly focus or goal, it makes me think more sharply about what I'm trying to do with my blue non-recurring placeholder "work" cards on my weekly board.

Every gauge needs a dial - using a slider card....

For each day of the week on my weekly board I also have a "slider" card called "-- done --" which starts at the top of the list.  As I complete tasks I drag this slider card down so that only cards not done are below it. This gives me a nice little indicator of where I'm at during the day, and a visual indicator of how much I got done on previous days and what didn't get done... plus I get a small dopamine hit for pushing things above that "--done--" card :)

Is my week a "value stream"?  Maybe, hopefully, I come out at the end of it a little better and a little closer to what I want to do. For me, Sunday is a good day to review the week, look how far my "-- done --" sliders got, think about which days were good or bad, whether I hit my everyday / tally targets, what rhythms or discoveries I made about how to do things better.   There's usually a relationship between my (recurring) try-to-dos and my "work" items as they represent things that are significant to me, as well as rhythms around the more humdrum stuff I have to do.

Monday, January 5, 2015

Arch linux on Dell XPS13

What?

Installing archlinux on a Dell XPS13 using archboot (instead of the standard archiso installer) via usb stick.

This turned out to be a pretty straightforward process. I also set up dm-crypt / luks and gave btrfs a go.

When: I ordered mine late 2014, got it before xmas.

Specs...

  • XPS 13BASE NBK XPS BTX 9333 WW (if that means anything)
  • i7-4510U processor
  • 8G ram
  • 256G ssd
  • basically this is the high end model

Disclaimer

I only infrequently do installs or set up operating systems. I don't really want to know more about UEFI than I absolutely have to, and I'm not bothered about Secure Boot either, nor am I all that knowledgeable on disk encryption. The commands and steps here should be taken as a guide only. Any security settings such as encryption settings and configurations should be researched by you.

Impressions of the XPS 13

Dell XPS13 just after switching over to Archlinux.

I asked about the developer edition of the XPS 13, aka project sputnik but was told this wasn't available in Australia. I bit my tongue, and went ahead anyway and paid the microsoft tax.

This is a sleek piece of kit. However I was alarmed on first switching this on to have the fans roaring into sudden and furious action. There I was, staring at this thing and trying to reconcile the desire to play with something so obviously new and shiny, with the increasing horror that maybe I had a turkey on my hands. Visions flashed through my head of me on the train or at work having to explain to people around me why the fan was so loud: "All the cool new ultrabooks do it", I'd protest weakly.

Fortunately, a reboot into the firmware (hit f12 at startup and look for Diagnostics) and then running some diagnostics including fan control seemed to quiet the system down and I haven't had a repeat episode since.

When doing nothing, this system is whisper quiet, no whirring and moving parts etc. There is a slight high-pitched and directional "eeeee" sound which goes from a lower pitch when the keyboard lights are off to a higher pitch when the keyboard lights go on - this apparently was a real big issue with earlier models. It feels like the "whine" is louder (at least lower so I can hear) when the lights are off. UPDATE: I feel the noise the keyboard makes when the lights go off (which happens after some inactivity) has gotten louder after a day or two and is potentially an issue.

My main concern at this point is that the XPS 13 may run hot. I'm packing an i7 in there and the base is really not that much thicker then a usb slot - and that's the end that doesn't taper. Time will tell. Browsing (using chromium) seems to provoke the fan almost straight away especially if scrolling. That being said, my experience during the install of arch on this system just got better and better. Working on a bare console (before building a gui) was almost a pleasant experience, probably because the gorgeous screen and keyboard were such a pleasure to use.

First things

  • f2 brings up the UEFI firmware setup utility
  • f12 brings up the UEFI loader
    • which you can also activate the setup utility or do other things
  • fn + arrow keys gives you Home, End, Pg up, Pg down which might be worth knowing if you've got to hit the man pages
  • there is no optical drive; this is a usb job; nothing spins on this thing, which is awesome

Installing Arch...

There are 2 choices up front.

  • which installer to use:
    • archiso
      • when I booted with this in early 2014 on a different system using an optical disk, I was dropped into a shell, and I did some re-partitioning and some fancy mounting and chrooting on the host file system to build the new arch system directly; this was a good experience, but I tried archboot this time...
    • or archboot
      • this is a larger image and seems dedicated to installing arch
      • the key differences are apparently listed here
        • archboot will boot up in ram and will provide a terminal UI (basic installer) to walk you through the setup
        • it won't mount your host system by defaut
        • a welcome script sits on tty1 through tty6 (well, I tested up to 2)
        • you hit enter on any of these and it will launch you into basic install mode which is a UI that walks you through an install (which is what I did below)
        • but if you switch over to another one (eg alt + f2), hit enter, you'll just get dropped into zsh where you'll have a lot more options about what you decide to do; personally I think it would be less confusing if the system just dropped you into zsh and printed a helpful message
        • so archboot can be used as a rescue utility: I was able to rescue my system this way after I b0rked my xorg input settings and lost my keyboard, so archboot can function as a rescue utility
  • and secondly either:
    • writing the image to the usb stick
      • this will limit your usb stick to the size of the image
    • or installing to a partition on the usb stick; involves copying files to the partition, more complicated, but you can still use the left over free space on your usb stick

I went with archboot and wrote the image directly onto the usb stick because this seemed like the most expedient option:

dd bs=4M if=archlinux-2014.11-1-archboot.iso of=/dev/sdX && sync

... which turned my 4G stick into a 1G stick.

This can be reset afterwards.

dd count=1 bs=512 if=/dev/zero of=/dev/sdx && sync

...and re-partition.

Booting the usb

At the beginning of this process my Phoenix SecureCore uefi was set to

  • boot mode: UEFI
  • Secure boot: ON
  • Legacy mode: disabled

These settings were the default.

I could cut a long story short here and just say disable secure boot . But I did initally try to go with these settings.

I gave up trying to set boot order in the UEFI firmware setup utility (f2); I was able to add a usb entry to the top of the list (only after plugging the usb in) but windows would always boot; maybe it was falling through to windows, but it wasn't terribly obvious.

Instead, I used f12 to load the uefi loader which showed the usb I had inserted into the laptop.

Selecting the usb entry from this menu gave an error dialog:

### Secure Boot ###
Image failed to verify with *ACCESS DENIED*.
Press any key to continue.

This led to another screen:

Failed to start loader
It should be called loader.efi (in the current directory)
Please enrol its hash and try again
I will now execute HashTool for you to do this
OK

This led to another screen

### Select Binary ###
The Selected Binary will have its hash Enrolled.
This means it will subsequently boot with no prompting
Remember to make sure it is a genuine binary before Enrolling its hash.
[a selection box with files in it including loader.efi]

(At this point I think I should have just turned Secure Boot off since I don't need it, but I persisted for a bit longer...)

I selected loader.efi from the selection box.

Which led to

Enroll this hash in MOK database?
Hash: big scary hash

Restarting with f12 and selecting the usb brought up the ACCESS DENIED error again. BUT this time, hitting ok brought up the archboot loader with the following selection

* Arch Linux x86_64 Archboot EFISTUB
* GRUB X64 - if EFISTUB boot fails
* UEFI Shell X64 v1
* UEFI Shell X64 v2
* EFI Default Loader
* Reboot into firmware interface

I tried the EFISTUB option 1. This ultimately failed for me. I got ACCESS DENIED again and a message about "enroll /boot/vmlinuz..." (I can't remember the last bit). I tried to enrol this using the Select Binary screen.

I did this, but then hit another crop of errors:

Failed to open file: boot\intel-uecode.img
Trying to load files to higher address
Failed to open file: boot\intel-uecode.img

I tried option 2. This time I had to enrol a grub file. I can't remember which one, I think it was /boot/EFI/grub/grubx64.efi . Rebooting, hitting f12 and hitting the 2nd option as before, getting ACCESS DENIED but clicking passed this, I eventually got the usb to boot.

As I mentioned, I should have turned secure boot off to avoid this rigmarole.

Archboot installer

You should see a message like this on booting the usb:

Welcome to Arch Linux (archboot environment)

Hitting enter put me straight into the basic install utility which is a series of sections you can enter and configure things.

  • Keyboard and console font
    • Pretty much skipped over this
  • Networking
    • I was able to get wireless working straight away. archboot will up a wireless profile in /etc/netctl and it also asked me if I preferred to use dhclient over dhcpcd, which from previous experience I did. So I had wireless working straight away which was super encouraging.
  • Prepare Storage Drive
    • I went with a GUID partition table (GPT)
    • I made a 2G swap partition; overkill? probably
    • archboot seems to make you setup separate / and /home partitoins; I didn't like this initially, but after some consideration I went with it; I selected ext4 for both and gave / root 20G. Not sure if that is enough, hopefully it will be.
    • selected /boot as the UEFISYS mountpoint
    • select the device name scheme
      • PARTUUID and PARTLABEL are specific to GPT disks, PARTUUID is recommended for GPT
      • I went with PARTUUID
  • Select a source
    • we are given 2 options: peripheral device cd/usb or network
    • I went with usb
  • Install packages
    • I selected BASE and SUPPORT
  • there were some steps around configuring the system
    • I set /etc/hostname
    • mirror list (enabled australian sites)
    • set root password
  • Install bootloader
    • Setup has detected that you are using "X64 UEFI", do you want to install a X64 UEFI bootloader?
      • yes
    • now it gets tricky, we have 3 choices
      • EFISTUB
      • GRUB_UEFI
      • SYSLINUX_UEFI
    • I went with GRUB_UEFI
      • Got this cryptic message

        You have entered /boot as the mountpoitn of your EFISYS partition. Any other partioin using /boot as mountpoint will be ignored. You may have to re-install kernel and bootloader files (currently existing in /boot) to the EFISYS partition once it is setup at /boot.

      • asked to edit grub.conf file; I did, but didn't change anything
      • then: do you want to copy /boot/EFI/grub/grubx64.efi to /boot/EFI/BOOT/bootx64.efi? This might be needed in some systems where efibootmgr may not work due to firmware issues.
        • yes

Booting Arch

After going through the options, I then exited the installer and rebooted the system and removed the usb.

Rebooting gave me the ACCESS DENIED dialog again. It appeared to try twice, then gave up with this message:

No bootable devices - strike F1 to retry boot, F2 for setup utility.
Press F5 to run onboard diagnostics.

Time to give secure boot the boot. I hit f2 to get back into setup, and when to Boot tab, and set 'Secure Boot' to Disabled.

And voila, it boots.

Might be a good time to do

pacman -Syu

While you're at it, get rid of the console beep:

echo "blacklist pcspkr" > /etc/modprobe.d/nobeep.conf

or

rmmod pcspkr  # for immediate non-permanent relief

Modifications

At this point I had a system with /, /home using ext4, and swap.

I decided I wanted to:

  • encrypt swap and /home
  • and also try btrfs on /home for snapshots, bitrot and compression and also for eventually super fast syncing.
  • I also wanted to tune the system a little for the solid state drive.

There is still debate about the stability of btrfs, but things look like they are getting to a point where it's becoming ok to use. One of the big motivations was this article (a year ago now). Since that time at least one major distro has made it the default.

And then there is https://btrfs.wiki.kernel.org/index.php/FAQ#Is_btrfs_stable.3F from 2 years ago:

Pragmatic answer: (2012-12-19) Many of the developers and testers run btrfs as their primary filesystem for day-to-day usage, or with various forms of "real" data. With reliable hardware and up-to-date kernels, we see very few unrecoverable problems showing up. As always, keep backups, test them, and be prepared to use them.

I've used zfs on my backup media for some time now via the arch AUR zfs-git package which requires kernel modules so I'm hoping to replace this eventually with just btrfs.

Crypting Swap

This turned out to be super easy. I'm not bothered about hibernating aka suspend-to-disk, so this simplified the task.

See:

I need gdisk for my partiion:

pacman -S gptfdisk # gdisk

This identified my swap partition:

gdisk -l /dev/sda  # for me /dev/sda3 was swap type=82

This shows what swap you're using if any:

swapon -s

You can turn swap off like this:

swapoff /dev/sdaX

Use

blkid

to give you UUID and PARTUUID etc.

So, all I had to do to get this working was adding a line like this to /etc/crypttab:

swap           PARTUUID=d4ae0d26-8df6-4005-aaf7-f419418134c2 /dev/urandom           swap,cipher=aes-cbc-essiv:sha256,size=256,discard

and adding this to /etc/fstab:

/dev/mapper/swap    none    swap    sw  0 0

Later I experimented with an alternative setting in /etc/crypttab:

swap           PARTUUID=d4ae0d26-8df6-4005-aaf7-f419418134c2 /dev/urandom           swap,cipher=aes-xts-plain64:sha256,size=512,discard

Originally, I tried to use UUID but this failed on a second reboot. Turned out the UUID for /dev/sda3 (my swap partition) was no longer present. So I switched to PARTUUID.

That's pretty much it. Reboot and see if it works. If it doesn't, the system may hang for a while at bootup and then give up and boot the system without any swap devices.

You might be able to get some information this way:

systemctl list-units | grep swap
journal -xe -u swap.target

you'll see not-so-helpful messages like:

Dependency failed for Swap.
Job swap.target/start failed with result 'dependency'.

If you forget the /etc/fstab entry, the system may also hang for a while at startup and ask for a password. You'll just have to sit it out.

fstab

I should note that my fstab had no uncommented entries in it.

genfstab might help in this regard:

genfstab -U -p  # prints entries you could put in fstab

Get it using: pacman -S arch-install-scripts .

Crypting Home

ae2-cbc-essiv looks to no longer be the standard for encryption (see https://wiki.archlinux.org/index.php/Dm-crypt/Device_encryption ):

Please note that with release 1.6.0, the defaults have changed to an AES cipher in XTS mode. It is advised against using the previous default --cipher aes-cbc-essiv, because of its known issues and practical attacks against them.

Also see for cbc vs xts etc:

You should have an empty /home directory courtesy of archboot.

Unmount it and prepare it for block encryption:

umount /dev/sdaX  # /home partition (for me /dev/sda5)
cryptsetup -s 512 luksFormat /dev/sdaX

Check:

cryptsetup luksDump /dev/sdaX

should show aes plain xts.

Now we can open this device and put a filesystem on it:

cryptsetup luksOpen /dev/sdaX home
mkfs.btrfs /dev/mapper/home

I have this entry in my /etc/crypttab - the system can boot without an entry in here, but i want to use the discard option:

home           PARTUUID=df5ba5f5-9492-4ae2-b1aa-2ac548841394 none                   home,luks,size=512,discard

Using discard may have security implications if you're using block encryption. Also confession: I don't know if this is actually enabling TRIM support, it is listed in man 5 crypttab.

And in /etc/fstab:

UUID=3f05ccbe-137b-4fb0-9236-be2520fda140   /           ext4        rw,noatime,discard,data=ordered 0 1
/dev/mapper/home    /home   btrfs   rw,compress=zlib,discard,ssd,relatime   0 0

I've included / above which I added with some additional flags: noatime / relatime, discard and ssd are used.

If this is all working, your system will ask for a password to open the /home partition as part of the boot up process. This is separate to your user account password(s) that you may have.

GUI

I won't cover xorg set up. I do use infinality to improve fonts especially in the browser.

Sound

I had some system sounds, but nothing when playing video.

Alsamixer and pavucontrol both showed 2 devices, the second one was the one I wanted: HDA Intel PCH. Following the advice of

I found this setting worked:

cat /etc/modprobe.d/modprobe.conf 
options snd_hda_intel enable=0,1

After this, earphones and pc speakers worked as expected.

Touchpad and touchscreen

The system is almost impossible to type on with the touchpad default settings. A slight glance will either click or scroll.

I have /etc/X11/xorg.conf.d/50-synaptics.conf with:

Section "InputClass"
    Identifier "touchpad"
    Driver "synaptics"
    MatchIsTouchpad "on"
        Option "TapButton1" "-1"
        Option "TapButton2" "-1"
        Option "TapButton3" "3"
        Option "VertEdgeScroll" "-1"
        Option "VertTwoFingerScroll" "on"
        Option "HorizEdgeScroll" "-1"
        Option "HorizTwoFingerScroll" "on"
        Option "CircularScrolling" "on"
        Option "CircScrollTrigger" "2"
        Option "EmulateTwoFingerMinZ" "40"
        Option "EmulateTwoFingerMinW" "8"
        Option "CoastingSpeed" "0"
        Option "FingerLow" "35"
        Option "FingerHigh" "40"
EndSection

This disables tap clicking (you can still depress the end of the touchpad for a normal click), and it enables 2-finger scrolling. I can still trigger 2-finger scrolling when both hands glance the trackpad so nothing's perfect.

The touchscreen is a bit of a mystery. It is recognised and looks to be treated like a mouse / pointer device (xinput --list). I can touch links in chromium but they are not clicked. What I really want is the ability to scroll but I haven't figured this out.

cat /proc/bus/input/devices  | egrep 'Bus|Name'
...
I: Bus=0018 Vendor=06cb Product=2734 Version=0100
N: Name="DLL060A:00 06CB:2734"
I: Bus=0003 Vendor=06cb Product=0af8 Version=0111
N: Name="SYNAPTICS Synaptics Large Touch Screen"
...

So I'm assuming DLL060A is the touchpad and the second set of entries is my screen.

I'm wondering if I can set up another Section in xorg.conf.d with

MatchIsTouchscreen "on"

But haven't got anywhere yet.

Links