Marc's Public Blog - Linux Hacking


All | Aquariums | Arduino | Btrfs | Cars | Cats | Clubbing | Computers | Diving | Dreamstate | Edc | Electronics | Exercising | Festivals | Flying | Halloween | Hbot | Hiking | Linux | Linuxha | Monuments | Museums | Oshkosh | Outings | Public | Rc | Sciencemuseums | Solar | Tfsf | Trips



This page has a few of my blog entries about linux, but my main linux page is here
Picture of Linus

Here is a list of older linux event reports I made before my blog was started, then the rest are below
1996/11/18-21:Linux Pavillion Comdex Fall 1996 (photos only). I've been going since then to help at the linux pavillion.
1997/11/18-21: Linux Pavillion Comdex Fall 1997 (photos only)
1998/05/28-30: Linuxexpo 1998 (photos only)
1998/11/16-20: Linux Pavillion Comdex Fall 1998 (full report)
1998/11/11: Silicon Valley Tea Party (report with pictures)
1999/02/15: Windows Refund Day (report with pictures)
1999/03/20: SVLUG KTEH night (photos only)
1999/03/01-04: LinuxWorld Expo Winter 99 (complete report with many pictures)
1999/03/31: Mozilla Party one year anniversary (photos only)
1999/05/18-22: Linuxexpo 1999 (complete report with many pictures)
1999/06/07: June 99 Balug meeting with Linus
1999/08/09-12: LinuxWorld Expo Summer 99 (complete report with many pictures)
1999/11/15-19: Linux Business Show at Comdex Fall 1999 (full report with pictures)
2000/08/14-17: LinuxWorld Expo Summer 2000 (complete report with many pictures)
2001/01/17-20: Linux.conf.au/LCA 2001 (complete report with pictures)
2001/07/25-28: OLS 2001 (photos only)
2001/08/25: Linux 10th Anniversary (report with pictures)
2001/09/27-30: LinuxWorld Expo Summer 2001 report with pictures)
2001/11/05-10: ALS 2001 (photos only)
2002/06/26-29: OLS 2002 (photos only)
2003/01/20-25: LCA 2003 (photos only)
2003/07/23-26: OLS 2003 (photos only)
2004/01/12-17: LCA 2004 (photos only)
2004/07/21-24: OLS 2004 (photos only)
2005/04/18-23: LCA 2005 (photos only)
2006/01/24-28: LCA 2006 (photos only)
2007/01/17-21: LCA 2007 (photos only)

Here is a list of all the talks I've given:

And below are my blog posts:

Table of Content for linux:

More pages: July 2002 February 2004 March 2004 November 2004 April 2005 August 2005 January 2006 July 2006 August 2007 November 2007 January 2008 October 2008 November 2008 December 2008 January 2009 May 2009 July 2009 August 2009 September 2009 November 2009 December 2009 January 2010 March 2010 April 2010 June 2010 August 2010 October 2010 January 2011 July 2011 August 2011 December 2011 January 2012 March 2012 May 2012 August 2012 December 2012 January 2013 March 2013 May 2013 September 2013 November 2013 January 2014 March 2014 April 2014 May 2014 October 2014 January 2015 March 2015 May 2015 January 2016 February 2016 June 2016 July 2016 August 2016 October 2016 January 2017 September 2017 January 2018 March 2018 December 2018 January 2019 January 2020 May 2020 January 2021 September 2021 March 2023 April 2023 December 2023 June 2024 November 2024



2004/02/15 Binary hacking bru backup to work over NFS
π 2004-02-15 23:14 by Merlin in Linux

What follows is unix centric, and won't tell you much if you're not a programmer/unix user, but you should enjoy it otherwise (please note that I do own a legal copy of bru backup for personal use, which I got with an old boxed set of Red Hat)


I'm trying to get my backup tape library to work as I've never been able to backup the 1TB+ of media files (don't ask) I have (I've been copying them on my other drives, but now I have too many for that to fit)

So, I decided to move my tape library to another machine, just for testing (to see if the library was bad, or my SCSI connection or host PC was flaky)
But, problem, it wouldn't back up a single file over NFS.

After a while, I realized:
gargamel:~# bru --version
bru: invalid option -- -
usage: bru -cdeghitx [-#AabBCEfFGjlLmnNoOpPQRSsuUvVwXYZ] file(s)...

Copyright (c) 1994-97, Enhanced Software Technologies, Inc.
All Rights Reserved

BRU is a backup software product licensed by EST.
It is NOT public domain or shareware. Versions are
available for almost any type of Unix system.

This is the Personal Edition version of BRU 2000. It does not offer
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
support for backup or restore of remote/network filesystems.
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
To order a copy of the full version of BRU 2000 or for further
information or technical support, please contact Red Hat Software

Ah, great.
There had to be a way to trick it to backup over NFS anyway (this software is more than 7 years old, I'm probably not able to buy a license today, and I'm not violating the spirit of the license, I'm just doing a backup of one system, but without being able to have the library connected to it)

So, I did a couple of straces, one of a local file and one of an NFS file and diffed them.
What did I see?

open("/bru/.serial_number", O_RDONLY) = -1 ENOENT (No such file or directory)
uname({sys="Linux", node="host.svh.domain.tld", ...}) = 0
-lstat64(0x806e5a4, 0xbffff298) = 0
-lstat64(0x8070978, 0xbffff280) = 0
-statfs("dshelf3_X10:D3_MD5_.bz2", {f_type="NFS_SUPER_MAGIC", f_bsize=8192,
f_blocks=14836773, f_bfree=1564919, f_files=15073280, f_ffree=14353562,
f_namelen=255}) = 0
^^^^^^^^^^^^^^^^^^^^^^^
-lstat64(0x8070978, 0xbfffee1c) = 0
-access("dshelf3_X10:D3_MD5_.bz2", R_OK) = 0
+lstat64(0x806e5a4, 0xbffff2a8) = 0
+lstat64(0x8070978, 0xbffff290) = 0
+lstat64(0x8070978, 0xbfffee2c) = 0
+access("profile", R_OK) = 0
+lstat64(0x8070978, 0xbfffe6f0) = 0
+access("profile", R_OK) = 0
+open("profile", O_RDONLY|O_NONBLOCK) = 4
+write(1, "c 4k of 6k [1] profile\n", 27) = 27


Aaahahh. man statfs said that NFS_SUPER_MAGIC was 0x6969, which is "ii" in ascii.
So, I just opened the bru binary with vi, found one instance of "ii" (I was lucky) and it was around the text strings, so it was definitely in the variable sections of the binary.
I changed the string to "ij", and voila, nfs backups.

Yeepee! :)

The joys of a simple geek may be hard to convey sometimes :)
2004/02/25 SCSI/tape backup woes
π 2004-02-25 18:13 by Merlin in Linux

Current Music: none while my disk array is being rebooted every 5mn :)
Current Mood: Hardware, you will submit :)

So, I can't believe that after two years of having that tape autoloader I finally got the thing to work. It took more sweat and tears than I care to write about, but basically, in the end, one of the two busses on one of the 4 SCSI cards in that machine was flaky (some of the cables were too though).
I can't believe that I ended up fixing the problem by putting no less than 6 SCSI busses in that machine (I had to add yet another card). That just feels wrong...
Anyway, it works now and it's happily backing up data. With a little luck, the backup will be over in a week's time.

Cool, now I only need to fix my Replay TV with its broken hard drive and my older archos jukebox player so that I can ebay it. So much to do, so little time :)
I sometimes wonder how "normal" people manage :) (but seriously, it must suck to have to throw those things away, or pay god knows how much to get them fixed by someone else)

More pages: July 2002 February 2004 March 2004 November 2004 April 2005 August 2005 January 2006 July 2006 August 2007 November 2007 January 2008 October 2008 November 2008 December 2008 January 2009 May 2009 July 2009 August 2009 September 2009 November 2009 December 2009 January 2010 March 2010 April 2010 June 2010 August 2010 October 2010 January 2011 July 2011 August 2011 December 2011 January 2012 March 2012 May 2012 August 2012 December 2012 January 2013 March 2013 May 2013 September 2013 November 2013 January 2014 March 2014 April 2014 May 2014 October 2014 January 2015 March 2015 May 2015 January 2016 February 2016 June 2016 July 2016 August 2016 October 2016 January 2017 September 2017 January 2018 March 2018 December 2018 January 2019 January 2020 May 2020 January 2021 September 2021 March 2023 April 2023 December 2023 June 2024 November 2024

Contact Email