我在一台运行 16.04 的服务器上遇到了一个问题:没有剩余的磁盘空间。
我不知道是什么占用了空间。是否有命令列出当前目录大小,以便我可以遍历并最终进入占用所有空间的目录?
此处声明未找到包 gtk+-3.0:
karl@karl-ux303ln:~$ pkg-config --cflags gtk+-3.0
Package gtk+-3.0 was not found in the pkg-config search path.
Perhaps you should add the directory containing `gtk+-3.0.pc'
to the PKG_CONFIG_PATH environment variable
No package 'gtk+-3.0' found
Run Code Online (Sandbox Code Playgroud)
但是我显然已经安装了 gtk3:
karl@karl-ux303ln:~$ dpkg -l libgtk* | grep -e '^i' | grep -e 'libgtk-*[0-9]'
ii libgtk-3-0:amd64 3.14.15-0ubuntu1~14.04~ricotz1 amd64 GTK+ graphical user interface library
ii libgtk-3-bin 3.14.15-0ubuntu1~14.04~ricotz1 amd64 programs for the GTK+ graphical user interface library
ii libgtk-3-common 3.14.15-0ubuntu1~14.04~ricotz1 all common files for the GTK+ graphical user interface …Run Code Online (Sandbox Code Playgroud) 我已经看到一些帖子想要关于使用的相同内容,但是答案总是指安装一些第三方工具。
我不想安装任何东西。
有内衬吗?以下将是一个不错的输出:
CPU 11% RAM 20% HDD 85%
Run Code Online (Sandbox Code Playgroud) 我想加快连接到特定服务器的速度。
我有服务器让我们说:
123.123.123.1
123.123.123.2
123.123.123.3
Run Code Online (Sandbox Code Playgroud)
我通常连接以下内容:
ssh -p 12345 my_user@123.123.123.1
Run Code Online (Sandbox Code Playgroud)
这很痛苦,因为服务器之间的唯一区别是 ip 的最后一个数字。
我尝试了以下代码:
alias ssht='{ ip=$(cat -); ssh -p 12345 my_user@"123.123.123.$ip"; }<<<'
Run Code Online (Sandbox Code Playgroud)
但是我收到一个错误:
karl@karls-laptop ~/scripts $ ssht 1
Pseudo-terminal will not be allocated because stdin is not a terminal.
Run Code Online (Sandbox Code Playgroud)
有没有办法让这个工作?
我目前:
root@sensu-server-client:/#
Run Code Online (Sandbox Code Playgroud)
我想改为:
sensu@sensu-server-client:/#
Run Code Online (Sandbox Code Playgroud)
一个人如何做到这一点。我试过:su sensu但没有任何反应。
root@dev-demo-karl:/srv/www# supervisord -v
3.3.1
Run Code Online (Sandbox Code Playgroud)
试图让supervisorctl工作:
root@dev-demo-karl:/srv/www# supervisorctl
http://localhost:9001 refused connection
Run Code Online (Sandbox Code Playgroud)
我的配置:
[supervisord]
nodaemon=true
[supervisorctl]
Run Code Online (Sandbox Code Playgroud) #!/bin/bash
ids=$(xinput list | awk '/SteelSeries Sensei Raw Gaming Mouse .*pointer/ {print $8}' | sed 's/id=\(.*\)/\1/')
if [ -z "$ids" ]; then
exit 0;
fi
read -a ids_array <<< $ids
echo fixing id ${ids_array[0]}
xinput set-prop ${ids_array[0]} 'Device Accel Profile' -1
xinput set-prop ${ids_array[0]} 'Device Accel Constant Deceleration' 2.5
xinput set-prop ${ids_array[0]} 'Device Accel Adaptive Deceleration' 1
xinput set-prop ${ids_array[0]} 'Device Accel Velocity Scaling' 1
echo fixing id ${ids_array[1]}
xinput set-prop ${ids_array[1]} 'Device Accel Profile' -1
xinput set-prop ${ids_array[1]} 'Device …Run Code Online (Sandbox Code Playgroud) Supervisorctl 似乎不让我进来:
$ supervisorctl -c /etc/supervisor/supervisord.conf
Error: .ini file does not include supervisorctl section
For help, use /usr/bin/supervisorctl -h
$ cat /etc/supervisor/supervisord.conf
[supervisord]
nodaemon=true
Run Code Online (Sandbox Code Playgroud)
我都指定了 config 和[supervisord]. 我的配置有可能在错误的地方吗?
16.04 ×4
command-line ×4
bash ×3
supervisor ×2
14.04 ×1
alias ×1
disk-usage ×1
files ×1
gtk ×1
monitoring ×1
paths ×1
scripts ×1
ssh ×1
su ×1
systemd ×1