Articles of Debian

失去与DNS的连接

我在我的工作中已经build立了一个“内部”DNS,基本上我们有一个example.com域名,用于互联网,电子邮件等。我在我们的一个linuxnetworking服务器(debian)上创build了一个使用bind9的DNS example.inc。 所以基于我的文件和我所描述的症状; 我能做些什么来解决这个问题? 这些是我修改的关键(我认为)的文件: named.conf.local zone "example.inc" { type master; file "/etc/bind/zones/example.inc.db"; }; zone "201.168.192.in-addr.arpa" { type master; file "/etc/bind/zones/rev.201.168.192.in-addr.arpa"; }; named.conf.options options { directory "/var/cache/bind"; // If there is a firewall between you and nameservers you want // to talk to, you may need to fix the firewall to allow multiple // ports […]

转换Debian的fstab通过Linux的基地使用UUID?

我们有一些在fstab中仍然使用/ dev / hda的Debian 5系统。 我们想转换他们使用UUID。 这应该是通过“linux-base”包(postinst)自动完成的,但由于某种原因,它不能踢(也许有人已经跑了它,并保存在某个地方的某个地方不这样做)。 虽然通过手动编辑一些文件来切换到UUID当然是可能的,但是以某种方式编写脚本会很有用。 debconf和debconf-set-selections的各种咒语似乎不起作用。 所以基本上,如何调用Debian提供的脚本来执行所有的UUID转换?

使用dpkg-set-selections自动configuration后缀

在Ubuntu 12.04上,我试图使用dpkg-set-selections在部署的机器上自动configurationpostfix,如下所示: debconf-set-selections <<EOF postfix postfix/main_mailer_type select Satellite system postfix postfix/root_address string [email protected] postfix postfix/mailname string mydomain.org postfix postfix/relayhost string gw.mydomain.internal postfix postfix/destinations string $(hostname -f), localhost EOF DEBIAN_FRONTEND=noninteractive apt-get install postfix mailutils 不幸的是,configuration程序坚持要将mydomain.org添加到postfix/destinations (aka mydestinations )configuration参数中: postfix postfix/destinations string mydomain.org, myserver.mydomain.internal, localhost 我怎样才能正确地configuration这个? 我想要任何不合格的邮件作为[email protected]出去,并通过smarthost进行中继。

日志中的DHCPREQUEST和DHCPACK垃圾邮件

我最近注意到,我的android手机(droid dna,虽然我以前做过的thunderbolt做同样的事情)正在迅速请求dhcp信息我的dhcp服务器(在debian挤压isc-dhcp服务器上)。 我刚开始以为这是在做雷霆,尽pipe我最近注意到droid dna也在做同样的事情。 这两个手机是唯一的东西在networking上这样做(只有Android手机afaik),没有别的这样做。 现在的设置由服务器处理路由,DHCP等,然后连接到一个24端口交换机(tplink,未pipe理),然后去任何以太网连接和2个Linksys e4200无线路由器(在桥/ ap模式)。 每次手机连接到networking时都会发生这种情况。 这也发生在不同的networking上,其中有dchp3-server,一个dell powerconnect 8端口非pipe理型交换机和一个tplink 1043nd无线路由器在接入点模式。 以下是日志活动本身的屏幕截图: 我的configuration文件isc-dhcp-server由以下内容组成: option domain-name "kingston.org"; subnet 192.168.1.0 netmask 255.255.255.0 { max-lease-time 909200; default-lease-time 604800; #authoritative; option routers 192.168.1.1; option broadcast-address 192.168.1.210; option domain-name-servers 192.168.1.1; option subnet-mask 255.255.255.0; range 192.168.1.2 192.168.1.200; } host duxbury { hardware ethernet 00:24:8c:ea:f0:7d; fixed-address 192.168.1.111; } host lancaster […]

如何configurationrsysloglogin到PostgreSQL没有太多的延迟?

我试图在Debian机器上configurationRSyslog,将所有东西都logging到PostgreSQL中,同时也照常在磁盘上logging日志。 我正在使用一个漂亮的股票Debianconfiguration,并阅读了http://www.rsyslog.com/doc/rsyslog_pgsql.html和http://www.rsyslog.com/doc/rsyslog_high_database_rate文档后激活了相关的configuration指令.html 。 它似乎工作,但消息写入磁盘或发送到PostgreSQL只有当我停止RSyslog,就像它缓冲一切,直到停止命令,并在closures之前写入所有内容。 虽然我可能不会丢失任何消息,但是这不是很方便,因为它引入了大量的延迟(我不知道它是否在closures之前甚至会丢弃任何东西?),有没有办法减less它,所以我可以一个正常的情况(服务器不忙),非常实时的日志? 这是我目前的configuration文件: $ModLoad imuxsock $ModLoad imklog $ActionFileDefaultTemplate RSYSLOG_TraditionalFileFormat $FileOwner root $FileGroup adm $FileCreateMode 0640 $DirCreateMode 0755 $Umask 0022 $WorkDirectory /var/spool/rsyslog $IncludeConfig /etc/rsyslog.d/*.conf auth,authpriv.* /var/log/auth.log *.*;auth,authpriv.none -/var/log/syslog daemon.* -/var/log/daemon.log kern.* -/var/log/kern.log lpr.* -/var/log/lpr.log mail.* -/var/log/mail.log user.* -/var/log/user.log mail.info -/var/log/mail.info mail.warn -/var/log/mail.warn mail.err /var/log/mail.err news.crit /var/log/news/news.crit news.err /var/log/news/news.err news.notice -/var/log/news/news.notice *.=debug;auth,authpriv.none;news.none;mail.none -/var/log/debug *.=info;*.=notice;*.=warn;auth,authpriv.none;cron,daemon.none;mail,news.none […]

OpenSSH服务器接受公钥,然后立即closures连接,没有任何错误消息

我试图连接到一个SSH服务器,我可以连接到过去,但使用不同的OpenSSH客户端版本。 从Cygwin OpenSSH_6.6.1, OpenSSL 1.0.1g 7 Apr 2014客户端,通过使用Cygwin OpenSSH_6.6.1, OpenSSL 1.0.1g 7 Apr 2014通过Squid代理,我很好地连接到中间的Ubuntu 13.10 OpenSSH_6.2p2 Ubuntu-6ubuntu0.3服务器使用转发的代理绕过防止直接访问目标服务器的防火墙。 我可以很好地连接到其他SSH服务器通过这个中间服务器,排除转发的代理configuration或权限问题。 我可以告诉目标服务器失败的唯一区别是,它使用OpenSSH_4.3运行一个旧的Debian版本,虽然几个月前我可以连接到OpenSSH_4.3 ,但几年前还没有更新(在升级中间服务器之前跟随心跳的错误)和升级我的Cygwin客户端之前。 最近和一些较老的OpenSSH用户代理之间是否有任何已知的协议不兼容问题? 从中间服务器连接到目标服务器( s1.hidden.com @63.82.7.10在下面的跟踪)失败,没有任何错误消息,目标服务器已经报告接受我转发的公钥,中间服务器发送公共键。 在下面的跟踪中,到中间服务器的连接和到目标服务器的尝试连接都有选项-vvv ,它解释了涉及转发代理的channel 1debugging消息(地址被编辑): […] debug2: we sent a publickey packet, wait for reply debug1: Server accepts key: pkalg ssh-rsa blen 279 debug2: input_userauth_pk_ok: fp 46:83:33:00:28:48:b2:3c:b1:3f:60:bb:62:80:cc:d2 debug3: sign_and_send_pubkey: RSA 46:83:33:00:28:48:b2:3c:b1:3f:60:bb:62:80:cc:d2 debug2: channel […]

你使用什么来自动testingDebian软件包的安装和更新?

我正在使用一个Debian repo(基于reprepro)Wheezy和自定义包。 我不时修改自定义软件包,并在不同的系统上手动testing它们,例如: testinga)安装新版本的Debian软件包 testingb)在已经安装了旧版本的Debian软件包的系统上更新Debian软件包 testingc)卸载新版本的Debian软件包 通常,我在树不同的服务器上运行这些testing。 由于定制的Debian软件包数量不断增加,手动testing过程消耗的时间越来越多。 所以我正在寻找一个现有的testing框架,自动化的东西。 此外,如果这个testing框架支持在容器/虚拟机内部运行这些testing(例如使用快照,那么我们可以一遍又一遍地重新开始)。 此外,我希望在testing完成后得到一份完整的报告。 我知道我不是这个星球上唯一寻找这种工具的人。 但是,使用Google和本网站上的searchfunction并不能解决问题。 我发现“自动testing”,但我不确定这个工具是否适合我。 那么 – 你用什么来自动化testingDebian软件包的安装和更新? 请注意,我不是在寻找一个testing软件包的工具(例如Jenkins,Hudson)。 我很抱歉,如果这个问题是一个已经存在的条目在这里serverfault重复。 如果是这样的话,我会很高兴,如果你能指向我的权利页面。 编辑:debian项目似乎使用exatly我在找什么: http://ci.debian.net/#package/abi-compliance-checker http://ci.debian.net/data/packages/unstable/amd64/a/abi-compliance-checker/20140703_120145.autopkgtest.log 编辑#2:看起来像debci是我正在寻找(见上面的链接)。 我会看看这个工具,并在这里分享我的经验。 不过,如果你能分享你用于这个特定目的的工具,我会很高兴。

慢速从nginx下载大的静态文件

我在vmware-esxi虚拟化中使用了debian 7 x64。 每个客户端的最大下载量是1mb / s,nginx不能超过50mbps,我的问题是什么可能导致如此缓慢的传输? 服务器 **Settings for eth1: Supported ports: [ TP ] Supported link modes: 1000baseT/Full 10000baseT/Full** root@www:~# iostat Linux 3.2.0-4-amd64 (www) 09.02.2015 _x86_64_ (4 CPU) avg-cpu: %user %nice %system %iowait %steal %idle 1,75 0,00 0,76 0,64 0,00 96,84 Device: tps kB_read/s kB_wrtn/s kB_read kB_wrtn sda 173,93 1736,11 219,06 354600 44744 root@www:~# […]

设置Umask的正确方法在Debian / Ubuntu上使用php-fpm

我想将umask设置为002来执行php-fpm过程。 我正在读这里 , 在这里 ,在Ubuntu / Debian上它应该通过修改init脚本来完成。 然而,我怀疑这是正确的方法。 只是考虑大小写php5-fpm得到更新,更新修改了init脚本。 我也在这里读到,对于CentOS / Redhat,你可以通过/etc/sysconfig/来设置它。 所以我的问题是Debian / Ubuntu上是否有正确的方法来设置umask而不修改init脚本? 如果没有,可以直接修改init脚本吗?

Debian – 静态IP,/ etc / network / interfaces

我试图设置一个静态IP在我的Debian 8.1(在VirtualBox),所以我编辑了/ etc / network / interface文件: # The loopback network interface auto lo iface lo inet loopback auto eth0 iface eth0 inet static address 192.168.1.51 netmask 255.255.255.0 gateway 192.168.1.1 broadcast 192.168.1.255 这个configuration看起来是正确的(我也试过没有'auto eth0'),这个ip还没有在networking中使用。 但是,当我检查与ifconfig,eth0不会出现,显然是在我的configuration错误。 ifconfig无界面编辑(正常): eth0 Link encap:Ethernet HWaddr 08:00:27:4a:58:ae inet addr:192.168.1.43 Bcast:192.168.1.255 Mask:255.255.255.0 inet6 addr: fe80::a00:27ff:fe4a:58ae/64 Scope:Link UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1 […]