On Mon, 10 Mar 2025 23:56:47 +0100 "uw...@online.de" <uw...@online.de> wrote: > > #root@Server001:~# cp -ax / /mnt > #cp: das Verzeichnis '/mnt/' kann nicht angelegt werden: Datei oder > Verzeichnis nicht gefunden
# LANG=C.UTF-8 cp -ax / /mnt provides English error messages. Are you sure you mounted something to the /mnt target? To achieve your goal you might try: mkdir /srv/rootfs mount --bind / /srv/rootfs mount ${yourdevice} /mnt rsync -au /srv/rootfs/ /mnt/ umount /mnt umount /srv/rootfs rmdir /srv/rootfs The trailing slash at the end of rootfs in the rsync line is mandatory for your use case. You can repeat this to copy newer data and it will run faster, since the rsync -u option will prevent copying files which weren't changed. The -a option archives permissions, ownership etc. as maybe expected from the cp command. -- regards Frank
pgprlgOb_eR2i.pgp
Description: OpenPGP digital signature