Am Donnerstag, den 02.06.2016, 04:45 +0200 schrieb Harald Weidner: > Hallo, > > On Wed, Jun 01, 2016 at 10:35:15PM +0200, Manfred Rebentisch wrote: > > Und: wie greife ich nach dem Reboot auf das alte /var/lib zu, um die > > Daten zu löschen? > > ...das geht bei gemountetem /var/lib gar nicht. Du solltest vor dem Umhängen > der Partition sicher stellen, dass nichts mehr "unter" dem Mountpoint liegt. Sicher geht das, mit bind-mount. Beispiel: # mount | grep /dev/sd.* /dev/sda3 on / type ext4 (rw,relatime,errors=remount-ro,data=ordered) /dev/sda4 on /home type ext4 (rw,relatime,data=ordered) /dev/sda2 on /boot type ext2 (rw,relatime,block_validity,barrier,user_xattr,acl) # ls -l /boot/ insgesamt 46843 -rw-r--r-- 1 root root 177431 Apr 22 19:02 config-4.5.0-0.bpo.1-amd64 -rw-r--r-- 1 root root 177865 Mai 29 19:32 config-4.5.0-0.bpo.2-amd64 drwxr-xr-x 3 root root 1024 Mai 21 2015 extlinux drwxr-xr-x 5 root root 5120 Jun 13 18:08 grub -rw-r--r-- 1 root root 16826991 Mai 7 12:28 initrd.img-4.5.0-0.bpo.1-amd64 -rw-r--r-- 1 root root 16870171 Jun 15 22:54 initrd.img-4.5.0-0.bpo.2-amd64 drwxr-xr-x 2 root root 12288 Mär 29 2013 lost+found -rw-r--r-- 1 root root 3033598 Apr 22 19:02 System.map-4.5.0-0.bpo.1-amd64 -rw-r--r-- 1 root root 3034079 Mai 29 19:32 System.map-4.5.0-0.bpo.2-amd64 -rw-r--r-- 1 root root 3812320 Apr 22 19:01 vmlinuz-4.5.0-0.bpo.1-amd64 -rw-r--r-- 1 root root 3817120 Mai 29 19:32 vmlinuz-4.5.0-0.bpo.2-amd64 # ls -l /mnt/ insgesamt 0 # mount -o bind / /mnt # mount | grep /dev/sd.* /dev/sda3 on / type ext4 (rw,relatime,errors=remount-ro,data=ordered) /dev/sda4 on /home type ext4 (rw,relatime,data=ordered) /dev/sda2 on /boot type ext2 (rw,relatime,block_validity,barrier,user_xattr,acl) /dev/sda3 on /mnt type ext4 (rw,relatime,errors=remount-ro,data=ordered) # ls -l /mnt insgesamt 112 drwxr-xr-x 2 root root 4096 Mär 17 21:43 bin drwxr-xr-x 2 root root 4096 Mär 29 2013 boot drwxr-xr-x 3 root root 4096 Mär 29 2013 dev drwxr-xr-x 156 root root 12288 Jun 15 22:53 etc drwxr-xr-x 2 root root 4096 Mär 29 2013 home lrwxrwxrwx 1 root root 36 Mai 27 21:18 initrd.img -> /boot/initrd.img-4.5.0-0.bpo.2-amd64 lrwxrwxrwx 1 root root 36 Mai 7 12:28 initrd.img.old -> /boot/initrd.img-4.5.0-0.bpo.1-amd64 drwxr-xr-x 21 root root 4096 Mär 3 14:09 lib drwxr-xr-x 2 root root 4096 Mär 3 14:09 lib32 drwxr-xr-x 2 root root 4096 Mär 3 14:09 lib64 drwx------ 2 root root 16384 Mär 29 2013 lost+found drwxr-xr-x 5 root root 4096 Mai 22 2015 media drwxr-xr-x 2 root root 4096 Mai 21 2015 mnt drwxr-xr-x 4 root root 4096 Apr 8 15:56 opt drwxr-xr-x 2 root root 4096 Dez 14 2012 proc drwx------ 13 root root 4096 Mai 6 18:13 root drwxr-xr-x 2 root root 4096 Mär 29 2013 run drwxr-xr-x 2 root root 12288 Jun 13 18:10 sbin drwxr-xr-x 7 root root 4096 Apr 9 2013 srv drwxr-xr-x 2 root root 4096 Nov 16 2012 sys drwxrwxrwt 14 root root 4096 Jun 16 13:04 tmp drwxr-xr-x 11 root root 4096 Mär 3 2015 usr drwxr-xr-x 13 root root 4096 Jul 30 2015 var lrwxrwxrwx 1 root root 32 Mai 27 21:18 vmlinuz -> boot/vmlinuz-4.5.0-0.bpo.2-amd64 lrwxrwxrwx 1 root root 32 Mai 7 12:16 vmlinuz.old -> boot/vmlinuz-4.5.0-0.bpo.1-amd64 # ls -l /mnt/boot/ insgesamt 0 -- mfG Sascha ~~~ Zwei Ordner auf der CeBIT beim passieren des LinuxParks: Sie: Linux? Das ist doch dieses andere Windows. Er überlegen lächelnd: Ja.
Attachment:
signature.asc
Description: This is a digitally signed message part