Kendi içinde bir dizin var. Nasıl silebilirim.
~/.local/share/Trash/files$ ls devices/
reg-dummy
~/.local/share/Trash/files$ ls devices/reg-dummy/
subsystem
~/.local/share/Trash/files$ ls devices/reg-dummy/subsystem/
devices
Ayrıca
~/.local/share/Trash/files$ find devices/ | head -n 20
devices/
devices/reg-dummy
devices/reg-dummy/subsystem
devices/reg-dummy/subsystem/devices
devices/reg-dummy/subsystem/devices/reg-dummy
devices/reg-dummy/subsystem/devices/reg-dummy/subsystem
devices/reg-dummy/subsystem/devices/reg-dummy/subsystem/devices
devices/reg-dummy/subsystem/devices/reg-dummy/subsystem/devices/reg-dummy
devices/reg-dummy/subsystem/devices/reg-dummy/subsystem/devices/reg-dummy/subsystem
devices/reg-dummy/subsystem/devices/reg-dummy/subsystem/devices/reg-dummy/subsystem/devices
devices/reg-dummy/subsystem/devices/reg-dummy/subsystem/devices/reg-dummy/subsystem/devices/reg-dummy
devices/reg-dummy/subsystem/devices/reg-dummy/subsystem/devices/reg-dummy/subsystem/devices/reg-dummy/subsystem
devices/reg-dummy/subsystem/devices/reg-dummy/subsystem/devices/reg-dummy/subsystem/devices/reg-dummy/subsystem/devices
devices/reg-dummy/subsystem/devices/reg-dummy/subsystem/devices/reg-dummy/subsystem/devices/reg-dummy/subsystem/devices/reg-dummy
devices/reg-dummy/subsystem/devices/reg-dummy/subsystem/devices/reg-dummy/subsystem/devices/reg-dummy/subsystem/devices/reg-dummy/subsystem
devices/reg-dummy/subsystem/devices/reg-dummy/subsystem/devices/reg-dummy/subsystem/devices/reg-dummy/subsystem/devices/reg-dummy/subsystem/devices
devices/reg-dummy/subsystem/devices/reg-dummy/subsystem/devices/reg-dummy/subsystem/devices/reg-dummy/subsystem/devices/reg-dummy/subsystem/devices/reg-dummy
devices/reg-dummy/subsystem/devices/reg-dummy/subsystem/devices/reg-dummy/subsystem/devices/reg-dummy/subsystem/devices/reg-dummy/subsystem/devices/reg-dummy/subsystem
devices/reg-dummy/subsystem/devices/reg-dummy/subsystem/devices/reg-dummy/subsystem/devices/reg-dummy/subsystem/devices/reg-dummy/subsystem/devices/reg-dummy/subsystem/devices
devices/reg-dummy/subsystem/devices/reg-dummy/subsystem/devices/reg-dummy/subsystem/devices/reg-dummy/subsystem/devices/reg-dummy/subsystem/devices/reg-dummy/subsystem/devices/reg-dummy
Ayrıca, beynim durma problemini çözemese de, sudo rm -rf devices
çıktı üretmeden sonsuza kadar devam ediyor gibi görünüyor .
~/.local/share/Trash/files$ sudo rm -rf devices
^C~/.local/share/Trash/files$
Aynı şey perl -e 'use File::Path qw(remove_tree); remove_tree("$ENV{HOME}/.local/share/Trash/files/devices")'
. Aynı şey du -s devices/
. du -sch ~/.local/share/Trash/
Diğer komutlar için aynı şey
$ cd ~/.local/share/Trash/files/devices/reg-dummy/subsystem/devices/
$ ls -ldi
8131921 drwxr-xr-x 3 theking theking 4096 Mar 17 19:43 .
$ cd reg-dummy/subsystem/devices/
$ ls -dli
8131926 drwxr-xr-x 3 theking theking 4096 Mar 17 19:43 .
$ find .local/share/Trash/files/ -maxdepth 1 -delete
find: cannot delete `.local/share/Trash/files/devices': Directory not empty
find: cannot delete `.local/share/Trash/files/': Directory not empty
Sonsuza kadar çöp kutusuna yapışmasını istemiyorum!
Not: Basitçe kullanarak bir bilgisayarın kaba bir yedeğini alıyordum scp
, ancak alanım bitti ve sonra bu oldu.
ls -dli devices
vels -dli devices/reg-dummy/subsystem/devices/
ls -ldi devices
, değil device
. Bu aslında sabit bağlantılar (aynı inode) olup olmadığını görmek için çalışıyorum. Ancak, eğer bu büyük bir dizin ise, rm -rf
uzun zaman alacaktır ama sonunda çalışacaktır. Buradaki sorun dairesel bağlantılarsa, sonsuz özyineleme hakkında bir hata iletisi alırsınız. Herhangi bir hata mesajı yoksa, sadece rm -rf
yolunu çalıştırın.
rm -rf devices
?