Posted
over 16 years
ago
Paludis 0.34.3 has been released:
Unfortunately std::ifstream and std::ofstream are allowed to fail in unobvious ways when given a duff file. In particular, gcc won’t error out when a std::ifstream is created for a directory until the first read
... [More]
occurs. So we write our own stream buffer classes that do error checking and throw useful exceptions on error, and use those instead.
Posted in paludis releases Tagged: paludis [Less]
|
Posted
over 16 years
ago
Previously I described how to partition your drive using LVM2 and dm-crypt. This time, I'm going to go over how to boot this system.
First off, you're going to want to have your livecd handy, because it's likely something won't quite be right the
... [More]
first time around. Also, you'll want to make sure your kernel is built with support for initramfs. This requires the BLK_DEV_INITRD configure option, named "Initial RAM filesystem and RAM disk (initramfs/initrd) support" in the "General setup" menu. You'll then need to specify the location of a source file for the initramfs.
Probably the easiest thing to do is to grab my current initramfs package and tweak it to suit your needs. You'll at the least need to change some paths in the config.txt and init files. But, it should serve as a good starting point. When you're done, put the path to the config.txt file in the "Initramfs source file(s)" (CONFIG_INITRAMFS_SOURCE) setting in the kernel.
Now, rebuild and reinstall your kernel, reboot, and pray.
I hope this will help people improve their laptop's security. Feel free to post any questions you have in the comments. Good luck! [Less]
|
Posted
over 16 years
ago
Last time I kinda cheated and gave pretty much a redux of an earlier post. This one will hopefully have some more substance to it.
The partitioning scheme I'm currently using is like this:
/dev/sda1 - /boot (ext2)
/dev/sda2 - LUKS encrypted lvm2
... [More]
physical volume
The /boot partition is created like any normal ext2 partition.
The sda2 partition is created like so:
cryptsetup luksFormat /dev/sda2
This usually is sufficient to provide decent encryption, but it is worth checking the documentation for cryptsetup to look for further options -- in particular, the option to use a keyfile.
Once we formatted this partition, we'll need to open it, so that we can then add our lvm pv to it:
cryptsetup luksOpen /dev/sda2 sda2_crypt
We'll now have a new device available as /dev/mapper/sda2_crypt. This can be treated just like any other block device -- we could just format it as a regular ext3 partition, but then we can't really ever resize it. So, we're going to make a LVM2 partition:
pvcreate /dev/mapper/sda2_crypt
Now, we create a volume group. I choose 'Exherbo' as the name, but you can really just use whatever (often people just use 'vg').
vgcreate Exherbo /dev/mapper/sda2_crypt
Now, we just need to make our partitions:
lvcreate -L 1G -n swap Exherbo
lvcreate -n root Exherbo
vgscan
vgchange -a y
This creates a 1G swap partition, and uses the rest of the space for our root (/) partition. Again, see the documentation for lvm2 for more options.
Finally, we need to format those partitions:
mkswap /dev/mapper/Exherbo-swap
mke2fs -T ext3 /dev/mapper/Exherbo-root
Next time, I'll go over how to boot this system. [Less]
|
Posted
over 16 years
ago
Paludis 0.34.2 has been released:
Wildcards are now allowed for –contents and –executables.
A hardlink-merging bug has been fixed.
New appareo client, for manifest generation.
Posted in paludis releases Tagged: paludis
|
Posted
over 16 years
ago
I finished reading Anathem a while ago, and I really do recommend it. It was weird at first, but really nice in the end. It finished a bit fast, I’d say it needs another hundred pages to tie some of the stuff.
Also, Ricardo Cervera (you don’t have an
... [More]
url these days, you do?) sent me Introduction to Algorithms which I’ve been skimming through. Really nice book, of course. — Thanks.
As part of one of the research projects I’m involved, I just started reading/studying Aircraft control and simulation. Fortunately, it is not hurting as much as I expected. Though it is not for the faint of heart.
— ferdy
Tagged: book, reading, thanks [Less]
|
Posted
over 16 years
ago
This year I joined a couple of research projects at the Computer Architecture and Automatics Department of UCM. Since I’m still finishing my Computer Science degree I can’t spend as much time as I’d liked on the projects I’m taking part. I’m mostly
... [More]
doing softwar and learning quite a bit of electronics and such.
Tomorrow morning I’m heading ESA’s ESTEC to attend the first workshop of this year’s RexusBexus campaign. We’ll be there until friday. We’ve worked quite hard and are hoping to get selected for the next phase. Even if we are continuing our research even if we don’t get accepted, it is a great opportunity to test the thing.
Given that I really hate checking luggage at airports I was planning to travel as light as possible. Not needing lots of computing power the Eee came as the best candidate to carry around. I haven’t really done much with it than using it to go to University and back home so this is going to be its firs big test. I get to see whether this netbook thing really works for me, though I think it will.
We’ll see how it works…
— ferdy
Tagged: asus, eee pc, eeepc, esa, estec, netbook, ucm [Less]
|
Posted
over 16 years
ago
I got a Pakuma Choroka K1 for Christmas, to replace my rapidly falling apart generic backpack. I must say, I am extremely impressed.
First up, space. There’s plenty of room for a beast of a laptop, the power supply and a mouse. And a load of paper.
... [More]
And several large books. And a water bottle. And the shopping. And a cat or small dog. No problems there.
Next up, the organisation of said space. Lots of compartments and pockets. Possibly slightly overdoing things, but fortunately the little compartments are inside big compartments, so there’s no wasted space if you decide not to use them.
The foam-cushioned laptop compartment (supposedly using NASA-invented memory foam, and if you believe that I’ve got a bridge for sale) appears to be effective.
Then there’s the strap. My old backpack’s straps were falling off and falling apart thanks to shoddy stitching and cheap materials. No danger of this here.
The clever bits… Two stand out. First, the nifty little hole to allow headphones to go into the bag. Neat. Second, the slightly-shiny light grey inner lining. This makes it much easier to see things inside the bag.
Colour-wise, it’s inoffensive, which is all I care about.
A couple of things I’d possibly consider changing: The big cushioned laptop-holding section does waste a bit of space if there’s no laptop in the bag. Making it removable would be rather nifty, although possibly difficult to do without reducing the strength of the bag. And a small handle on the top of the bag wouldn’t go amiss either — the over-the-shoulder strap is sometimes overkill.
All in all, a rather good buy, especially if someone else is paying for it.
Posted in hardware Tagged: bag, hardware, laptop, pakuma [Less]
|
Posted
over 16 years
ago
Programming — Principles and Practice Using C is the new book by Bjarne Stroustrup, the daddy of C . It’s an introduction to programming rather than an advanced book; I’ve been holding off writing up my impressions of it because I’m not entirely
... [More]
sure what to say.
The overriding theme of this book seems to be “there are lots of complications, special cases and obscure things”. This is of course true, and it’s a refreshing change from most introductory books that go out of their way to construct highly contrived examples that conveniently ignore any obscurity. But I suspect it goes too far — pretty much every example is twice as long as it probably should be. There’s so much focus on dealing with complexities that the underlying “what’s going on?” is lost.
Partly this is down to C . A language designed to handle real world, large scale problems and provide for maintainability over decades isn’t going to be the most elegant. On the other hand, purely teaching languages that dismiss the real world entirely are of no practical use. The question is whether C as a first language is a sensible idea, and I’m not in the least bit convinced that it is.
Partly, though, this is down to the choice of projects. An example: two chapters are devoted to writing a calculator program. These chapters cover lexers, parsers, grammars and error recovery. This isn’t one of those cop-out calculator programs where syntax is carefully selected to hide any kind of mess, either — it almost looks like the book is going to end up implementing a compiler… Unfortunately, there’s nothing in the final program that really needs any of this complexity; a simple “tokenise into a list, then replace all the multiplications with their result, then replace all the divisions with their result and so on” would work just as well for the requirements, and wouldn’t have most of the mess.
The scope of the book is impressive, though. It doesn’t gloss over classes, templates, pointers, exceptions or even dealing with code written in C. It’s extremely comprehensive, even in places where it probably shouldn’t be.
Finally, a note on writing style. The word ‘basically’ appears on average once per page, and sometimes three or four times in a single paragraph. This gets very annoying very quickly. Stroustrup’s other books don’t suffer from this.
I suppose my conclusion is: if you have to learn C as a first language, this is the book to use. If you have a choice, though, learn one of the monkey languages first, and then pick up The C Programming Language and The C Standard Library.
Posted in c Tagged: books, c , programming [Less]
|
Posted
over 16 years
ago
Just a quick note that I was interviewed prior to FOSDEM. The interview is available at FOSDEM interview.
|
Posted
over 16 years
ago
Paludis 0.34.1 has been released:
We can now skip src_ phases where it is safe to do so.
Documentation updates for repository configuration.
Support for managing user and group accounts (requires distribution support).
Posted in paludis releases Tagged: paludis
|