Technique for merging servers

Never overlay it that deep. All or nothing.

Here is the mount - bind method we used to use for moving /var/lib/plexmediaserver before systemd overrides were stabilized.

  1. mkdir /home/plexdir; chown plex:plex /home/plexdir
  2. stop plex
  3. cd /var/lib/plexmedia
  4. tar cf - . | (cd /home/plexdir ; tar xf -)
  5. rm -rf ./Library (removes /var/lib/plexmediaserver/Library)
  6. mount --bind /home/plexdir /var/lib/plexmediaserver
  7. start plex

Here’s how to play with this

mkdir /tmp/a /tmp/b
mkdir /tmp/a/dummy
touch /tmp/a/dummy/foo
mount --bind /tmp/a /tmp/b
ls -laR /tmp/b

This is the mechanism I’m proposing to use