[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: Why or why not back up "/lost+found"



<tomas@tuxteam.de> wrote:
> On Thu, Aug 10, 2023 at 03:42:01PM -0400, Default User wrote:
> > Hi!
> > 
> > When backing up my system I have been using this exclusions list: 
> > 
> > /dev/*
> > /proc/*
> > /sys/*
> > /tmp/*
> > /run/*
> > /mnt/*
> > /media/*
> > /lost+found
> > 
> > There are many sources online that suggest that "/lost+found"
> > should be excluded from backups, but I can't seem to find a good
> > explanation for why.  
> 
> Squinting the other way (which doesn't contradict what others have
> said in this thread): if you see anything in lost+found, the idea
> is that you do something about it (rescue it, throw it away). Thus,
> the content of lost+found is (or should be) as temporary as, say,
> /tmp. And you don't back up that.
> 
> So I'd tend to exclude the special "lost+found" dirs (perhaps not
> any dir called like that). But then, it's not that important.
> 
> Cheers

One other consideration that I haven't seen mentioned elsewhere in this
thread is what happens if you back up filesystems to filesystems? That
is, if the backup for /home is an ext-? filesystem it may well already
have a /lost+found directory. That directory is hopefully empty but if
not then it contains data related to errors on the backup system, so
you do not want to overwrite it! I suspect that may be why it is
conventionally excluded from backups. It's normally empty so there's no
point in copying it. If there's anything in it on the original or the
backup, then that's a more urgent problem than a backup.

FWIW, I just don't use ext-? filesystems so I don't have to worry.


Reply to: