backing up /sys

Bob McClure Jr robertmcclure at
Thu Jun 30 15:04:19 UTC 2005

On Thu, Jun 30, 2005 at 05:45:29PM +0400, Alexey Fadyushin wrote:
> Bob McClure Jr wrote:
> >I'm in the process of checking out a CD/DVD-based backup package.
> >
> >
> >
> >In my first test, I noticed in the error log a bunch of carps about
> >file sizes changing in /sys.  I know that /proc is a pseudo filesystem
> >comprising nothing but hooks into the kernel, and I know that I don't
> >want to back that up.  /sys looks like the same sort of thing, full of
> >directories that take up 0 bytes, down to files that ls reports as
> >4096 bytes.
> >
> >Is it safe to assume I don't want to backup /sys?
> >
> >Cheers,
> > 
> >
> /sys is a mount point for sysfs filesystem. Sysfs is a virtual 
> filesystem similar to procfs in 2.6 line of Linux kernels.
> From the kerlnel documentation (menuconfig help):
> The sysfs filesystem is a virtual filesystem that the kernel uses to
> export internal kernel objects, their attributes, and their
> relationships to one another.
> Therefore, you do not need to backup it, the filesystem and its content 
> will be recreated by kernel when mounted.
> Alexey Fadyushin.
> Brainbench MVP for Linux

Ok, now I have a question.  "mount" shows (among other things)

  none on /proc type proc (rw)

but no equivalent for /sys.  If I

  cd /
  find . -depth -mount | cpio -o ....

I know it will record /proc but none of its contents.  Will it treat
/sys the same way?  Or would a restore from such a backup be innocuous
as far as the contents of /sys goes?

Bob McClure, Jr.             Bobcat Open Systems, Inc.
robertmcclure at
God doesn't have (or need) a Plan B.

More information about the Redhat-install-list mailing list