MobaXterm基本使用 -- 服务器状态、批量操作、修复zsh按键失灵

1. 监控服务器资源

参考网址:https://www.cnblogs.com/144823836yj/p/12126314.html

1. 显示效果

MobaXterm提供有这项功能,在会话窗口底部,显示服务器资源使用情况
如内存、CPU、网速、磁盘使用等:

2. 开启方法


Settings → SSH → 勾选Remote-monitoring

2. 批量操作

1. 批量打开终端

左侧机器选栏,shift / ctrl 多选终端,右键“execute these XX shells”
image.png

2. 批量关闭窗口

在窗口选项卡,点击右键,点击以下两选项,即可批量关闭窗口
image.png

3. 批量操作

将要操作的终端全部打开后,点击“multi exec”,即可对打开的终端进行批量操作
image.png
批量操作界面:
image.png
注意:

  1. 批量操作时,若这台电脑没有记录密码,则登录时需要手动输入密码,且无法记忆。解决方法,在普通模式先单独登录一次记住密码
  2. 批量操作时,直接在其中一个窗口粘贴的内容不能实现批量粘贴,批量粘贴需要点击右上角“批量粘贴”按键

3. 修复使用 zsh 后 home/end 键失灵问题

参考网址:

  1. https://github.com/ohmyzsh/ohmyzsh/issues/4872
  2. https://blog.csdn.net/gatieme/article/details/104170950

解决方法:在 zsh 的配置文件.zshrc中手动设置按键绑定规则:

# key bindings
bindkey "\e[1~" beginning-of-line
bindkey "\e[4~" end-of-line
bindkey "\e[5~" beginning-of-history
bindkey "\e[6~" end-of-history
bindkey "\e[3~" delete-char
bindkey "\e[2~" quoted-insert
bindkey "\e[5C" forward-word
bindkey "\eOc" emacs-forward-word
bindkey "\e[5D" backward-word
bindkey "\eOd" emacs-backward-word
bindkey "\ee[C" forward-word
bindkey "\ee[D" backward-word
bindkey "^H" backward-delete-word
# for rxvt
bindkey "\e[8~" end-of-line
bindkey "\e[7~" beginning-of-line
# for non RH/Debian xterm, can't hurt for RH/DEbian xterm
bindkey "\eOH" beginning-of-line
bindkey "\eOF" end-of-line
# for freebsd console
bindkey "\e[H" beginning-of-line
bindkey "\e[F" end-of-line
# completion in the middle of a line
bindkey '^i' expand-or-complete-prefix

配置文件路径

  1. 用户配置文件:~/.zshrc
  2. root配置文件:/root/.zshrc

修改后要刷新配置文件

# 刷新用户配置文件
source ~/.zshrc
# 刷新 root 用户配置文件
source /root/.zshrc
  • 1
    点赞
  • 5
    收藏
    觉得还不错? 一键收藏
  • 0
    评论

“相关推荐”对你有帮助么?

  • 非常没帮助
  • 没帮助
  • 一般
  • 有帮助
  • 非常有帮助
提交
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值