我正要在OpenVZ容器中设置一个数据库服务器(MySQL),我想知道应该为它分配多less个CPU。 我决定以此为基准。 我比较了两个OS / MySQL发行版,并testing了它们如何使用1,2,3和4个CPU来执行。 第一个软件configuration是: CentOS版本6.5(最终版) mysql Ver 14.14 Distrib 5.1.71,用于使用readline 5.1的redhat-linux-gnu(x86_64) 第二: Debian GNU / Linux 7 \ n \ l mysql Ver 14.14 Distrib 5.5.31,用于使用readline 6.2的debian-linux-gnu(x86_64) 两者都在同一个内核上运行 – 2.6.32-openvz-042stab083.2-amd64#1 SMP Fri Nov 8 17:59:25 MSK 2013 x86_64 GNU / Linux。 所有的软件都是从软件包中安装的,并且不需要任何自定义configuration就可以直接使用。 硬件:6GB RAM,1-4个CPU 3.5 GHz。 对于基准testing,我使用sysbench和以下情况: sysbench –test=oltp –oltp-table-size=1000000 –mysql-db=test –mysql-user=root –db-driver=mysql […]
我已经设置了以下的PINEN: Package: linux-image-amd64 Pin: release a=wheezy-backports Pin-Priority: 1001 Package: * Pin: release a=wheezy-backports Pin-Priority: 499 我得到以下错误: $ sudo apt-get install linux-image-amd64 Reading package lists… Done Building dependency tree Reading state information… Done Some packages could not be installed. This may mean that you have requested an impossible situation or if you are using the unstable […]
安装 我通过debian 7 ( 7.8.1-omnibus-1_amd64.deb )上的omnibus软件包安装了gitlab软件包。 按照使用非捆绑networking服务器中的描述更改设置 运行reconfigure命令: sudo gitlab-ctl reconfigure (完成没有错误)。 Nginx的 我没有得到这个gitlab的nginxconfiguration,除了这个包可能用下面的/etc/gitlab/gitlab.rb文件创build的: external_url 'http://git.mydomain.fr' web_server['external_users'] = ['www-data'] nginx['enable'] = false ci_nginx['enable'] = false 日志 /var/log/nginx/gitlab_error.log 2015/02/28 14:29:16 [alert] 4137#0: *14738 768 worker_connections are not enough while connecting to upstream, client: xx128.194, server: git.mydomain.fr, request: "GET / HTTP/1.0", upstream : "http://xx128.194:80/", host: "git.mydomain.fr" /var/log/nginx/gitlab_access.log […]
在Debian 7(Wheezy)的nginx初始化脚本中,我阅读了以下exerpt: status) status_of_proc -p /var/run/$NAME.pid "$DAEMON" nginx && exit 0 || exit $? ;; 这段代码运行得很好, sudo service nginx status输出[ ok ] nginx is running 。 然而, status_of_proc没有在bash中定义,在短划线中也没有定义: $ type status_of_proc status_of_proc: not found 虽然如果我把相同的支票插入nginx脚本,我得到了以下结果: status_of_proc is a shell function 而对init文件本身运行bash提供了进一步的解释: status_of_proc is a function status_of_proc () { local pidfile daemon name status OPTIND; pidfile=; […]
我尝试添加一个完整的IPv6(/ 64)块到一个接口使用 ip route add local 2001:41d0:2:ad64::/64 dev lo 就像在我的Debian服务器上描述的那样,但是我似乎错过了一些东西。 如果我在本地ping例如2001:41d0:2:ad64::fe一切正常,但如果我尝试从远程机器不起作用。 然后我尝试在eth0上添加路由: ip route add local 2001::41d0:2:ad64::/64 dev eth0 现在我甚至无法在本地ping任何示例地址! 我有点失落,因为我似乎失去了一些东西,但我在这里找不到答案。 简而言之:我希望2001:41d0:2:ad64::/64绑定到eth0,这样这个块所包含的每个IP都可以从我的机器上的互联网上获得。 我希望有人能指点我的道路。 提前致谢。 ISP提供的指南要求我明确地将每个IPv6添加到接口。 我希望它是隐含的。 使用明确的IP地址绑定进行工作configuration 的/ etc /networking/接口: auto eth0 iface eth0 inet static address my.ip.v4 netmask 255.255.255.0 network my.network.address.ip broadcast my.broadcast.address.ip gateway my.gateway.ip iface eth0 inet6 static address 2001:41d0:2:ad64::fe netmask 64 gateway […]
我有一个Debian服务器,我只需要在启动时运行脚本。 我读到: https : //www.debian-administration.org/article/28/Making_scripts_run_at_boot_time_with_Debian 我现在得到:insserv:警告:脚本'缺lessLSB标签和覆盖 所以看起来我现在必须添加: ### BEGIN INIT INFO # Provides: scriptname # Required-Start: $remote_fs $syslog # Required-Stop: $remote_fs $syslog # Default-Start: 2 3 4 5 # Default-Stop: 0 1 6 # Short-Description: Start daemon at boot time # Description: Enable service provided by daemon. ### END INIT INFO 现在看起来很疯狂:像30行脚本就是为了在启动时运行一个程序。 有没有一种工具可以做到这一点? 问候
服务器运行良好 – 或者至less它似乎 – 但总是有以下错误: apache2/usr/sbin/apache2ctl: 87: ulimit: error setting limit (Operation not permitted) 它发生在Debian Wheezy上的Apache 2.2.22-9上。 # apache2ctl configtest / usr / sbin / apache2ctl:87:ulimit:错误设置限制(操作不允许) 语法OK # service apache2 reload 重新加载Web服务器configuration:apache2 / usr / sbin / apache2ctl:87:ulimit:错误设置限制(操作不允许) 。 好 # service apache2 restart [….]重新启动Web服务器:apache2 / usr / sbin / apache2ctl:87:ulimit:错误设置限制(操作不允许) …等待/ usr / sbin […]
升级到Debian Wheezy(Debian Squeeze以前正在运行)后,Syslog,auth.log,kern.log和消息日志文件不再被更新。 我怎么解决它?
我已经将这些行添加到/etc/apt/sources.list deb http://packages.dotdeb.org wheezy-php56 all deb-src http://packages.dotdeb.org wheezy-php56 all 但仍sudo apt-get update或sudo apt-get upgrade不要碰php。 php –version仍然是 PHP 5.4.39-0+deb7u2 (cli) (built: Mar 25 2015 08:33:29)
jail.local文件是作为jail.conf的替代还是替代 jail.conf? 当我从教程中了解到Fail2Ban的时候 ,他们中的大多数通常会说要将jail.conf复制到jail.local中,并在那里进行编辑,其中一些人说要创build一个新的jail.local文件,并提供一些设置来复制并粘贴。 但是他们没有解决的是jail.local如何与jail.conf配合使用。 这是两种情况: 覆盖:如果jail.local充当jail.conf文件的覆盖,那么我只需要将我想覆盖的必要configuration添加到jail.conf中给定的默认configuration。 在这种情况下,我不需要添加SSHconfiguration等,因为它已经包含在jail.conf。 replace:如果jail.local在jail.local存在时变得无效,那么我需要在jail.local中添加所有的规则,然后编辑我想修改的规则。 当jail.local存在时,你能确认jail.conf发生了什么吗? 如果jail.local在jail.conf文件中的作用只是一个覆盖,那么我只需要添加几行我想添加的规则就更容易了,这也使得维护和可读性变得容易。 什么是最好的办法呢?