码迷,mamicode.com
首页 > 其他好文 > 详细

备份复制特定以开头的目录下的文件

时间:2020-09-17 21:40:06      阅读:37      评论:0      收藏:0      [点我收藏+]

标签:cal   use   local   conf   ppi   ping   特定   gate   rgs   

备份复制特定以开头的目录下的文件,并查看结果

ls /usr/local/apache-tomcat-*/conf/catalina.properties|xargs -i cp -a {} {}.bak && ll -thr /usr/local/apache-tomcat-*/conf/catalina.properties*
-rwxr-xr-x 1 appuser appuser 6.4K Oct 16  2017 /usr/local/apache-tomcat-shopping/conf/catalina.properties.bak
-rwxr-xr-x 1 appuser appuser 6.4K Oct 16  2017 /usr/local/apache-tomcat-shopping/conf/catalina.properties
-rwxr-xr-x 1 appuser appuser 6.4K Oct 16  2017 /usr/local/apache-tomcat-gateway_ibe/conf/catalina.properties.bak
-rwxr-xr-x 1 appuser appuser 6.4K Oct 16  2017 /usr/local/apache-tomcat-gateway_ibe/conf/catalina.properties
-rwxr-xr-x 1 appuser appuser 6.4K Oct 16  2017 /usr/local/apache-tomcat-fare/conf/catalina.properties.bak
-rwxr-xr-x 1 appuser appuser 6.4K Oct 16  2017 /usr/local/apache-tomcat-fare/conf/catalina.properties

 

备份复制特定以开头的目录下的文件

标签:cal   use   local   conf   ppi   ping   特定   gate   rgs   

原文地址:https://www.cnblogs.com/paul8339/p/13650210.html

(0)
(0)
   
举报
评论 一句话评论(0
登录后才能评论!
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!