Sunday, March 28, 2010

Feature request: enable stack smashing protector for Arch Linux packages

I've just created a feature request in Arch Linux Bugtracker to enable stack-smashing protector for Arch Linux packages. Stack smashing protector (SSP for short, aka ProPolice) is a GCC extension for protecting applications from stack-smashing attacks. It is available in stock GCC via -fstack-protector and -fstack-protector-all compile flags.

If you care about Arch Linux security, plase speak up and vote for this feature request!

Saturday, March 27, 2010

Backing filesystems up with FSArchiver

If you are going to backup your filesystem and looking for a simple yet powerful backup solution, then you may want to take a look at FSArchiver. This is a tool I've discovered just recently and despite its youth (first version released on November 2008) it did the job just perfectly. If you want more details, read on...

You probably already know tar or partimage: they are good, but have some limitations. Tar does the good job when comes to backups, but is not very convinient or easy to use for big filesystems (you need to be careful about passing it proper options to preserve file attributes, you need to take care of splitting resulting archives into smaller ones by yourself etc.). Partimage makes copies of entire partitions (and does it fast and well, copying only portions which are really used), taking a lot of burden from you, but you can only restore such images on partitions of same or larger size. Other than that, it still doesn't support ext4.

FSArchiver combines best features of tar and partimage: it works at the file level and creates a backup copy of entire filesystem, that can be then restored to a partition of any size (as long as it has enough space to hold the data, of course). When restoring the backup, it recreates target filesystems by issuing mkfs with proper flags and label. It supports many popular filesystems, including ext3, ext4, xfs, reiserfs and ntfs). FSArchiver can take advantage of dual/quad core CPUs (just pass it -jX flag, where X stands for the number of compression threads to run) and it does its job really FAST.I was really amazed that it took me just around 3-4 hours to backup and then recreate two filestystems (around 70GB worth of data in total) and the size of backup archives was only 25GB! So, to me, FSArchiver is a real winner. Sure, partimage may be faster, but if you need to rearrange your partitions with different sizes (this is what I had to do - and yes, I know about parted and gparted, but didn't want to use them), then FSArchiver is the tool you need.

Be warned though... FSArchiver developers claim it shouldn't be used on production environments yet, however it is well tested and has proven the ability to correctly save and restore filesystems on various Linux distributions. You choose.

Monday, March 1, 2010

Playstation 3: February 29 bug

Well... this is actually a bit funny... excluding all the people affected by this problem (well, this includes me ;)) and SONY... We all remember Y2K/Millenkum bug, some may be also aware of 2038 year problem in UNIX systems... But would you ever expect a leap year bug? This is what hit PS3 systems today: the hardware clock of PS3 (which you cannot set/reset) assumes it's February 29th, but the OS rejects this date as incorrect. The consequences are disastrous:
  • some files, e.g. saved games, may get corrupted.
  • trophy information may not be synchronized correctly and new trophies may get lost.
  • most (all?) games cannot be started at all; it doesn't matter whether these are online or single-player (offline) games.
  • PSN cannot be accessed.
Most old ("fat") PS3 systems are affected by this bug and for now the only solution is to not use PS3 today (until the internal clock advances to March 2nd).

From software engineer's perspective I can only say: WOW, that's a nasty BUG. It's amazing what consequences such subtle bug can cause, but on the other hand it's kind of terrifying if you think of other hardware that could suffer from that kind of programming errors, such as planes...