next up previous contents
Next: mk-initramfs-oneSIS Up: Utility Programs Previous: update-node   Contents


copy-rootfs

 Usage: copy-rootfs [OPTION]... $<$-l$~\vert~$-r machine$>$ $<$IMAGE_DIR$>$  


This program copies an installed linux distribution to a specified location.

IMAGE_DIR is the destination directory for the root image.

Options:
-l, -local Copy root filesystem from the local machine
-r, -remote=MACHINE Copy root filesystem from a remote machine
-e, -exclude=DIR Exclude contents of DIR from being copied
-d, -dryrun Show local/remote directories that would be copied
-v, -verbose Verbose output (copies much slower)

The copy-rootfs script copies an installed linux distribution into a new location to serve as a new master image for a cluster of nodes. The script recognizes which partitions reside on a local disk, and copies each one over in the correct order without recursively copying itself (for a local copy).

Since copy-rootfs attempts to copy any partitions mounted from a local disk, it may copy more than you want or need to be a part of the master image. To prevent this, run copy-rootfs with the -dryrun option to see a list of what the script intends to do. Any directories that shouldn't be copied over can be excluded with the -exclude option.

When copying the root filesystem from a remote machine, it is easiest if ssh keys are set up such that no password is required to ssh to the machine. If ssh keys are not set up, the script will prompt for a password several times (once for each remote partition being copied, and once to determine remote partitions).

A typical scenario to create a master image may look as follows:

This would copy the root filesystem of the local machine into another directory but exclude the contents of the /home directory.


next up previous contents
Next: mk-initramfs-oneSIS Up: Utility Programs Previous: update-node   Contents
root 2017-02-23