shell中使用sed正则修改文件

sed 使用正则匹配 在shell中 当变量有空格的时候使用双引号包围 “${var}” function change_version_class() { VERSION_CODE_FILE=$1 BUILD_VERSION=$2 if [ -f “${VERSION_CODE_FILE}” ]; then echo ‘change ‘”${VERSION_CODE_FILE}”‘ info’…

Read More

virsh 虚拟机xml信息,留个记录

virsh dumpxml domain 虚拟机dumpxml例,可以参考格式 xml <domain type=’kvm’ id=’12’> <name>ceph-node3</name> <uuid>4f52f828-f538-45cb-9f02-eeb555e96020</uuid> <memory unit=’KiB’>8388608</memory> <currentMemory unit=’KiB’>8388608</currentMemory> <vcpu placement=’static’>2</vcpu> <resource> <partition>/machine</partition> </resource> <os>…

Read More

n2n内穿透

之前一直使用frp.然后看到frp 有个xtcp.试了一下,家里和公司完全穿透不起来.网上一查,n2n的效果很一些.这里是软件地址ntop n2n mac os 需要先安装tuntap brew update && brew upgrade brew-cask && brew cleanup && brew cask cleanup /usr/bin/ruby…

Read More