随笔分类 -  Linux

摘要:1替换安装源 帮助 http://mirrors.ustc.edu.cn/help/ 使用配置生成器 https://mirrors.ustc.edu.cn/repogen/ 2 设置默认编辑器 sudo update-alternatives --config editor 3 修改用户不输入密码 阅读全文
posted @ 2021-06-28 18:49 wolbo 阅读(502) 评论(0) 推荐(0) 编辑
摘要:echo $# if [ $# -lt 2 ]; then echo "input basis folder base:" read src echo "input target folder base:" read target echo "input output folder base:" r 阅读全文
posted @ 2020-10-13 17:55 wolbo 阅读(149) 评论(0) 推荐(0) 编辑
摘要:1 安装软件 rpcbind又叫portmap apt-get install nfs-kernel-server nfs-common rpcbind 2 配置nfs目录 mkdir -p /nfsroot/rootfs root@raspberrypi:/opt/docker/seafile# 阅读全文
posted @ 2020-10-05 21:24 wolbo 阅读(1233) 评论(0) 推荐(0) 编辑
摘要:每天0点备份 4点还原 SHEll=/bin/sh* 0 * * * /opt/backup.sh > /opt/log/backup0.log 2>&1 * 4 * * * /opt/restore.sh > /opt/log/restore4.log 2>&1 分钟 小时 日 月 星期 [用户] 阅读全文
posted @ 2020-09-22 13:24 wolbo 阅读(105) 评论(0) 推荐(0) 编辑
摘要:#!/bin/sh find /cicd/BuildRoot -maxdepth 1 -type d | while read dir; do count=$(find "$dir" -type f | wc -l) echo "$dir : $count" done 阅读全文
posted @ 2020-09-21 10:22 wolbo 阅读(417) 评论(0) 推荐(0) 编辑
摘要:Use a for loop: for d in $(find /path/to/dir -maxdepth 1 -type d) do #Do something, the directory is accessible with $d: echo $d done >output_file It 阅读全文
posted @ 2020-09-01 11:22 wolbo 阅读(388) 评论(0) 推荐(0) 编辑
摘要:1 下载 https://www.archlinux.org/download/ 2 安装 https://wiki.archlinux.org/index.php/Installation_guide_(%E7%AE%80%E4%BD%93%E4%B8%AD%E6%96%87) 安装完grub 记 阅读全文
posted @ 2020-08-27 21:50 wolbo 阅读(433) 评论(0) 推荐(0) 编辑
摘要:解压文件夹:unzip 压缩文件名.zip “*/目录名/*.*” -d 目标文件夹名字 解压指定的文件:unzip 压缩文件名.zip “*/文件名.后缀” -d 目标文件夹名字 以上解压会保留zip中的完整目录结构 如 unzip aaa.zip 'gscloud/gscloud/*' -d / 阅读全文
posted @ 2020-08-25 11:07 wolbo 阅读(21520) 评论(0) 推荐(1) 编辑
摘要:-exec 1.参数是一个一个传递的,传递一个参数执行一次rm 2.文件名有空格等特殊字符也能处理-xargs 1.一次将参数传给命令,可以使用-n控制参数个数 2.处理特殊文件名需要采用如下方式: find . -name "*.txt" print0 |xargs -0 rm {} find / 阅读全文
posted @ 2020-05-23 10:27 wolbo 阅读(292) 评论(0) 推荐(0) 编辑
摘要:#!/bin/bash cd ./tools/patchinstall function handle_int() { kill $BCPID exit } trap handle_int INT ./startpatch-linux.sh & BCPID=$! cd /FIShare/gsclou 阅读全文
posted @ 2020-03-11 18:30 wolbo 阅读(98) 评论(0) 推荐(0) 编辑
摘要:使用find 排除 找到./tools/dbsetup/startlibs/config/suconfig/ 下除了以下文件名的文件 find ./tools/dbsetup/startlibs/config/suconfig/ ! -name 'su_aa.json' \ ! -name 'su_ 阅读全文
posted @ 2020-03-09 12:21 wolbo 阅读(1053) 评论(0) 推荐(0) 编辑
摘要:1 替换文件某一行 将文件./config/patchconfig/patch_config.json 的第二行替换为 "path": "../patchfiles", 将文件aaa.txt中的第三行替换为888 content='"path": "../patchfiles", ' sed -i 阅读全文
posted @ 2020-02-17 09:12 wolbo 阅读(161) 评论(0) 推荐(0) 编辑
摘要:smbclient //10.24.1.1/xx -U username%password << cmd mask "" recurse ON prompt OFF cd \test\test lcd '/Share/target' mget * cmd 阅读全文
posted @ 2020-02-14 15:51 wolbo 阅读(1008) 评论(0) 推荐(0) 编辑
摘要:1 官方文档 dotnet 可代替nuget.exe https://docs.microsoft.com/zh-cn/nuget/install-nuget-client-tools 低版本的nuget 缺少一些参数 2 安装mono https://www.mono-project.com/do 阅读全文
posted @ 2020-01-15 13:30 wolbo 阅读(1477) 评论(0) 推荐(1) 编辑
摘要:1 通过包管理器安装 a 添加包源 最新发行版 yum install -y gcc-c++ make curl -sL https://rpm.nodesource.com/setup_13.x | sudo -E bash - 稳定版 yum install -y gcc-c++ make cu 阅读全文
posted @ 2020-01-10 16:28 wolbo 阅读(174) 评论(0) 推荐(0) 编辑
摘要:1 安装nginx sudo apt-get update sudo apt-get install nginx 配置文件 /etc/nginx/nginx.conf 2 安装redis sudo add-apt-repository universe sudo apt-get update sud 阅读全文
posted @ 2019-12-14 00:51 wolbo 阅读(246) 评论(0) 推荐(0) 编辑
摘要:1 sudo adduser wolbo 2 sudo vim /etc/sudoers root ALL=(ALL) ALLwolbo ALL=(ALL) ALL wolbo ALL=(ALL) NOPASSWD:ALL 免密 阅读全文
posted @ 2019-12-13 18:24 wolbo 阅读(1848) 评论(0) 推荐(0) 编辑
摘要:1 添加apt-get 代理配置文件 sudo vi /etc/apt/apt.conf.d/proxy.conf 2 添加内容 Acquire::http::Proxy "http://wolbo:Test6530@10.24.21.1:8888"; Acquire::https::Proxy " 阅读全文
posted @ 2019-12-13 18:03 wolbo 阅读(252) 评论(0) 推荐(0) 编辑
摘要:1 安装xfce $ sudo yum install -y epel-release $ sudo yum groupinstall -y "Xfce" $ sudo reboot 2 安装xrdp $ sudo yum install -y epel-release $ sudo yum ins 阅读全文
posted @ 2019-12-10 14:10 wolbo 阅读(830) 评论(0) 推荐(0) 编辑
摘要:mount -t cifs //10.100.100.250/产品服务器/待测库/FI\ Cloud/CICD/BuildRoot_Dev/ /cicd --verbose -o vers=1.0,username=xxxxxx,password='xxxxxx' 注意 1 路径空格需要转义 \_ 阅读全文
posted @ 2019-11-29 19:07 wolbo 阅读(355) 评论(0) 推荐(0) 编辑

点击右上角即可分享
微信分享提示