我只想在一个 scp 命令 (Debian Linux) 中传输具有特殊扩展名的文件(例如只有 *.tar.gz、*.war)。这可能吗,如果是的话,语法如何?
应该是这样的:
scp 192.168.1.2:/srv/myfiles/'*.tar.gz *.war' .
Run Code Online (Sandbox Code Playgroud)
但这是行不通的。
我已经设置了 postfix、dovecot 和 roundcube。通过 roundcube 接收和发送电子邮件以及通过 imap 与另一个电子邮件客户端接收电子邮件一样有效。
但我无法使用外部电子邮件客户端发送电子邮件。一旦我连接,我就会看到:
postfix/smtpd[1258]: warning: SASL: Connect to private/auth failed: No such file or directory
postfix/smtpd[1258]: fatal: no SASL authentication mechanisms
Run Code Online (Sandbox Code Playgroud)
在邮件日志中。
这是我的 dovecot 配置:
dovecot -n
# 2.1.7: /etc/dovecot/dovecot.conf
# OS: Linux 3.2.0-4-amd64 x86_64 Debian 7.6
mail_location = mbox:~/mail:INBOX=/var/mail/%u
namespace inbox {
inbox = yes
location =
mailbox Drafts {
special_use = \Drafts
}
mailbox Junk {
special_use = \Junk
}
mailbox Sent {
special_use = \Sent
}
mailbox "Sent Messages" {
special_use …
Run Code Online (Sandbox Code Playgroud) 我有两个安装了 debian 挤压的系统。当我键入时在一个系统上:
service <TAB>
Run Code Online (Sandbox Code Playgroud)
它向我展示了所有可用的服务(来自 /etc/init.d)
在另一个系统上,它显示了当前目录中的所有文件。有谁知道哪个设置会改变这种行为?
更新:
文件 /etc/bash_completion.d/service 丢失。我从它正在工作的机器上复制它。如果我输入complete -p | grep service
它会显示我:
complete -F _service service
Run Code Online (Sandbox Code Playgroud)
在它不工作的机器上,该命令不显示任何内容。我complete -F _service service
在命令行中执行,之后,命令service <TAB>
显示我:
service -su: completion: function `_service' not found
Run Code Online (Sandbox Code Playgroud)
这个函数是在我最近复制的服务文件中定义的,由于某些原因找不到...
我正在使用以下服务从 nagios 监控我们的 postgres 数据库:
define service{
use test-service ; Name of servi$
host_name DEMOCGN002
service_description Postgres State
check_command check_nrpe!check_pgsql!192.168.1.135!test!test!test
notifications_enabled 1
}
Run Code Online (Sandbox Code Playgroud)
在远程机器上,我配置了命令:
command[check_pgsql]=/usr/lib/nagios/plugins/check_pgsql -H $ARG1$ -d $ARG2$ -l $ARG3$ -p $ARG4$
Run Code Online (Sandbox Code Playgroud)
在 syslog 中,我可以看到命令已执行,但只传输了一个参数:
Oct 20 13:18:43 DEMOSRV01 nrpe[1033]: Running command: /usr/lib/nagios/plugins/check_pgsql -H 192.168.1.134 -d -l -p
Oct 20 13:18:43 DEMOSRV01 nrpe[1033]: Command completed with return code 3 and output: check_pgsql: Database name is not valid - -l#012Usage:#012check_pgsql [-H <host>] [-P <port>] [-c <critical time>] [-w <warning time>]#012 …
Run Code Online (Sandbox Code Playgroud) 我们正在寻找一个开源备份工具,它支持 linux 的增量文件备份(如 time machine ion mac)。我们想在我们的服务器上备份文件共享。该工具应尽可能简单,并在每晚通过 cron 作业触发 incemantal 备份。欢迎任何建议。
如果我想使用 PgAdmin 连接到 debian lenny 上的 postgres 9.1.1 db,则需要 15 秒以上的时间才能建立连接。日志中没有看到为什么需要这么长时间。
有什么想法可以分析问题吗?这是我的配置:
pg_hba.conf
# "local" is for Unix domain socket connections only
local all all md5
# IPv4 local connections:
host all all 127.0.0.1/32 md5
host all all 192.168.1.0/24 md5
# IPv6 local connections:
host all all ::1/128 md5
# Allow replication connections from localhost, by a user with the
# replication privilege.
local replication postgres trust
host replication postgres 192.168.1.0/24 trust
host replication postgres ::1/128 trust
Run Code Online (Sandbox Code Playgroud)
配置文件
# …
Run Code Online (Sandbox Code Playgroud) 我想用 postgres 9.1 的 pg_basebackup 工具创建一个 Base Backup。几秒钟后,我收到:
``pg_basebackup: 无法从服务器获取 WAL 结束位置`
此错误消息的原因是什么?
当我同时运行多个服务的 systemctl status 时,就像
sudo systemctl status myservice1 myservice2 myservice3
Run Code Online (Sandbox Code Playgroud)
我看到了输出,但最后我看到了
lines 1-48/48 (END)
Run Code Online (Sandbox Code Playgroud)
或者如果参数更多,输出更大
lines 1-62
Run Code Online (Sandbox Code Playgroud)
我可以滚动或分页输出并使用q退出。
是否可以更改此行为,立即打印所有日志输出并退出命令?
我正在我们的办公室服务器 (debian sqeeze) 上设置一个 samba 共享。是否有推荐的位置将共享放在 debian 的文件系统上?
debian ×4
postgresql ×3
backup ×2
bash ×2
dovecot ×1
filesystems ×1
linux ×1
nagios ×1
postfix ×1
replication ×1
roundcube ×1
samba ×1
scp ×1
shell ×1
systemd ×1