摘要:os_config: fedora38 ~ bash config 1. bash config (~/.bashrc) 1 [wit@fedora null]$ cat ~/.bashrc 2 # .bashrc 3 4 # Source global definitions 5 if [ -f
阅读全文
随笔分类 - os
操作系统内容
摘要:os: ubuntu23.10 -- 更新脚本(update) 一、ubuntu23.10 更 1 [wit@ubuntu:null]$ cat ~/user/tools/update 2 #!/usr/bin/env bash 3 4 5 6 echo " update " ; 7 echo ;
阅读全文
摘要:os: Ubuntu23.10.1之命令提示符:PS1 一、命令提示符【PS1】(位置:~/.bashrc) 1 # PS1='${debian_chroot:+($debian_chroot)}\[\033[01;32m\]\u@\h\[\033[00m\]:\[\033[01;34m\]\w\[
阅读全文
摘要:zsh:config(ubuntu22.04.2) 1. zsh : PS1 1 [wit@on ~]$ cat ~/.oh-my-zsh/themes/david.zsh-theme 2 PROMPT="%(?:%{$fg_bold[green]%}:%{$fg_bold[red]%})[%{$f
阅读全文
摘要:Linux: bash builtin commands(fedora38-GNU Bash 5.2) 1. bash builtin commands(fedora38-GNU Bash 5.2) 1 BASH_BUILTINS(1) General Commands Manual BASH_BU
阅读全文
摘要:linux: date 命令的用法 一、date 命令的用法 1、zsh(ubuntu22.04.2) 1 ➜ null date "+%Y-%m-%d %H:%M" 2 2023-09-10 03:10 3 ➜ null 4 ➜ null 5 ➜ null date "+%F %T" 6 2023
阅读全文
摘要:os: fedora38 系统更新脚本 - update - (echo 'PASSWORD' | sudo -S <command>) 一、update脚本内容(echo "PASSWORD" | sudo -S <command>) 1、update 1 [wit@fedora null]$ c
阅读全文
摘要:os: pv 命令 - 显示数据处理的进度条 一、pv 命令 1、pv 命令功能:显示数据处理的进度条 2、pv 命令安装: sudo apt install -y pv dnf install -y pv 3、pv 命令说明: [wit@on tmp]$ pv --help Usage: pv [
阅读全文
摘要:os:ubuntu 使用防火墙firewalld 一、ubuntu22.04安装防火墙firewalld 1、安装防火墙 sudo apt install -y firewalld 2、开启防火墙 sudo systemctl start firewalld 3、开机启动防火墙 sudo syste
阅读全文
摘要:Debian和Ubuntu系统更新和垃圾清理 一、 查看系统启动时间 1. systemd-analyze 二、 一键纯净更新和垃圾清理 1、 命令: sudo apt update -y && sudo apt full-upgrade -y && sudo apt autoremove -y &
阅读全文
摘要:os: ubuntu22.04 - 关闭欢迎消息 一、关闭欢迎信息 1 wit@on:update-motd.d$ pwd 2 /etc/update-motd.d 3 wit@on:update-motd.d$ 4 wit@on:update-motd.d$ 5 wit@on:update-mot
阅读全文
摘要:os: rockylinux9.1 - 网络配置 一、nmcli - 网络配置 1 [root@rocky system-connections]# pwd 2 /etc/NetworkManager/system-connections 3 [root@rocky system-connectio
阅读全文
摘要:os: ubuntu22.04 - 网络配置 一、ubuntu22.04.2(lts)网络配置 wit@on:netplan$ pwd /etc/netplan wit@on:netplan$ wit@on:netplan$ wit@on:netplan$ ls 01-network-manager
阅读全文
摘要:os: ubuntu - apt - sources.list 一、[wit@eagle tmp]$ man sources.list 1 SOURCES.LIST(5) APT SOURCES.LIST(5) 2 3 NAME 4 sources.list - List of configured
阅读全文
摘要:apache: config virtual host - apache2.4 - rockylinux9.0 1. httpd.conf( /etc/httpd/conf/httpd.conf; apache2.4) #httpd.conf position: /etc/httpd/conf/ht
阅读全文
摘要:bash:多重选择 - CASE 一、说明 1、“case” 使用 二、代码 1 [root@rocky shell]# cat mcondition 2 #!/usr/bin/env bash 3 4 5 # file_name = mcondtion 6 7 8 run() 9 { 10 if
阅读全文
摘要:bash:"IF command"命令作为条件 一、说明 1、IF的条件部分,可以使用linux“命令”。 1 if command 2 then 3 command if $?=0 4 else 5 command if $?!=0 6 fi 二、代码 1 [root@rocky shell]#
阅读全文
摘要:os:计算机术语之“编码”和“解码” 一、基本说明 1、信息,被赋予特定涵义的一组符号。 2、文字,能被人类识别出涵义的一组符号;文字,是被赋予特定涵义的一组符号。 3、机器码,能被机器识别出涵义的一组符号。 二、编码和解码 1、编码(编码:“文字” —> “机器码”): 编码,将“文字”转换为“机
阅读全文
摘要:os:linux移除旧内核的脚本(rockylinux9) 一、移除旧内核脚本的说明(使用root账户) 1、脚本的参数($1):输入“将要移除内核的版本号” 1.1、示例:[root@fedora ~]# remove_old_kernel 6.1.6-200.fc37 2、应用示例 1 [roo
阅读全文
摘要:FOR syntax learning 一、代码及注释 1 @echo off 2 3 dir 4 g: 5 cd .\tmpWorkspaces 6 7 8 9 10 11 12 rem -- FOR Learning -- 13 14 15 16 17 18 19 rem == for /d d
阅读全文

浙公网安备 33010602011771号