[root@localhost ~]# touch /etc/testdb.txt
[root@localhost ~]# touch /etc/sysconfig/testdb.txt
[root@localhost ~]# touch /etc/dhcp/testdb.txt
[root@localhost ~]# find /etc/ -name testdb.txt
/etc/dhcp/testdb.txt
/etc/sysconfig/testdb.txt
/etc/testdb.txt
[root@localhost ~]# find /etc/ -name testdb.txt | xargs rm -rf
[root@localhost ~]# ls /etc/testdb.txt
ls: cannot access /etc/testdb.txt: No such file or directory
巧用find命令在Linux系统中查找并删除文件
最新推荐文章于 2023-10-10 15:16:50 发布