two questions

Monty J. Harder lists at kc.rr.com
Tue Feb 5 03:44:33 CST 2002


"Gene Dascher" <gedascher at multiservice.com> wrote:

> Is there an install script that you ran?  Is the script a shell script?
If
> so, then you can look at the script and see what files it put where.  Then
> you can go remove them.  When I install anything non RPM related, I always
> create a log file of the output so I know what files I can safely remove
if
> I need to.

  Well, maybe.  Here's the classic uninstall nightmare.

1.  Install the Fubar package, which requires snafu.o

2.  Install the Fubu package, which also requires snafu.o

3.  Uninstall one of them.

  Depending (heh) on how intelligent the install scripts are, you might be
able to figure out what uses what, and know what's safe to remove.  The only
way to be certain of your bookkeeping is to use some kind of database that
keeps track of exactly which things use each other.  One technique for this
would be to use one of the strengths of Unix - linking.  When
/usr/local/fubar/snafu.o and /usr/local/fubu/snafu.o link to the same actual
inode, removing either one is perfectly safe, and removing the last one
takes the inode with it.

  But this requires that the linked files exist in the same filesystem,
which can't always be assured.  If the actual inodes are to be kept in a
different filesystem, then symbolic links need to be used instead.  The only
problem with symlinks is that they are one-way structures -- the symlink
contains information about the file it points to, but there is no
'backpointer' to keep track of the symlinks.  If the ...fubu/snafu.o were a
symlink to ...fubar/snafu.o, then uninstalling Fubar leaves a broken link in
Fubu.

  I've advocated for some time expanding the idea of the symbolic link to
include 'bidirectional' links.  These would embed information in both the
'source' and 'destination' directory about the link, combining the
advantages of both kinds of links.




More information about the Kclug mailing list