赞
踩
wget https://dl.google.com/linux/direct/google-chrome-stable_current_amd64.deb
sudo dpkg -i google-chrome-stable_current_amd64.deb
sudo apt install -y net-tools
sudo apt install -y iputils-ping
sudo apt install -y telnet
sudo apt install -y vim
nohup java -Xdebug -Xrunjdwp:transport=dt_socket,suspend=n,server=y,address=8100 -jar coffee-1.0.jar --spring.config.location=application.yml,application-dev.yml --logging.config=logback.xml 2>&1 &
kill -9 `ps -ef|grep coffee-1.0.jar | grep -v grep|awk '{print $2}'`
ps -ef | grep hello | grep -v grep | awk '{print $2}' | xargs kill -9
sudo apt install -y dos2unix
dos2unix t.sh
dos2unix *
chown -R mm:mm mydir
# 查看镜像信息
qemu-img info bionic-server-cloudimg-amd64.img
# 把 vmware 虚拟机转化成 qcow2
qemu-img convert -f vmdk -O qcow2 Windows_Server_2019_1909-disk1.vmdk w2019.img
终端与服务器保持心跳,编辑文件
vim /etc/ssh/ssh_config
添加配置
ServerAliveInterval 30
ServerAliveCountMax 10
md5sum master.ova
apt update
apt install open-vm-tools open-vm-tools-desktop
reboot
cat xxx.log | grep key
grep -a key xxx.log #解决Binary file (standard input) matches
grep -rn "xxx" * #递归搜索所有文件,并且显示行号
dpkg -l | grep nfs
开启后,客户端包安全错误,可取消加密
gsettings set org.gnome.Vino require-encryption false
使用 Remmina, 可远程连接 windows系统桌面,如下图:
如果连接出现如下错误:
You requested an H264 GFX mode for server app.localhost.com, but your libfreerdp does not support H264. Please check Color Depth Settings
解决:
# 添加 remmina 仓库
sudo apt-add-repository ppa:remmina-ppa-team/remmina-next
sudo apt update
#重新安装 remmina
sudo apt install remmina remmina-plugin-rdp remmina-plugin-secret
#关掉所有 remmina 进程
sudo killall remmina
参考:https://blog.csdn.net/Joker00007/article/details/112950609
#使用当前用户环境
sudo -s
#同时切换到root用户环境
sudo su
大部分时候在windows上开发,有时候需要在linux上调试。因为换行符的差异,linux上看到所有文件都被改变了。在linux系统上项目目录下,执行命令
git config core.autocrlf input
time dd if=/dev/zero of=t.img bs=32k count=102400 #写速度
time dd if=t.img of=/dev/null bs=32k
openssl pkey -in apiserver.key -noout -text #查看秘钥
openssl x509 -in apiserver.crt -noout -text #查看证书
sudo apt install libguestfs-tools
#把root密码设置为123456
virt-customize -a focal-server-cloudimg-amd64.img --root-password password:123456
sudo apt-mark hold linux-image-5.4.0-148-generic
sudo apt-mark hold linux-headers-5.4.0-148-generic
sudo apt-mark hold linux-modules-5.4.0-148-generic
sudo apt-mark hold linux-modules-extra-5.4.0-148-generic
https://old-releases.ubuntu.com/releases/20.04.4/
#dhcp refresh ip
sudo dhclient -r enp0s8
sudo dhclient enp0s8
top 1
or
mpstat -P all 1
vmstat 1
iostat -d -k 1
pidstat -t -p xx 1 #thread
pidstat -w -p xx 1 #上下文切换
docker inspect xxx|grep Pid
taskset -c -p yyy
Copyright © 2003-2013 www.wpsshop.cn 版权所有,并保留所有权利。