Browsing articles tagged with "centos - 5/167 - Admins Goodies"
Nov 7, 2012
tom

Install PHP 5.3 on Centos 6

I am setting up a staging server using CentOS and need to install PHP 5.3 to mirror my production server. Using the standard yum install php I’m sure will give me 5.4 – I’ve had a look and can’t figure out how to specify a version number to install. Can anyone advise? Many thanks. Asked by bsod99 To specify a version you do: yum install php-5.3.3-14 This assumes that php-5.3.3-14 is available in the repos […]

Continue Reading »
Oct 28, 2012
tom

Allow SSH only on one of a servers IP addresses

I have a server with several IP addresses that hosts sites on each IP address. I have one ip address that does not have a site associated with it. I want to allow SSH login only to the one IP address that does not have a site associated with it. Is this possible? If so can anyone tell me how to accomplish this? Asked by Adam Take a look at ListenAddress in your sshd_config. ListenAddress […]

Continue Reading »
Oct 28, 2012
tom

Centos 6.3 install reiserFS support

I’m trying to change an existing ext4 partition to reiserFS in Centos 6.3 64bit. I’ve updated the kernel to Centos Plus: First, I’ve updated /etc/yum.repos.d/CentOS-Base.repo: In the [centosplus] section: enabled=1 includepkgs=kernel* Then I ran yum ypdate and my Kernel was updated to Centos Plus: [root@vappsil disk]# uname -r 2.6.32-279.11.1.el6.centos.plus.x86_64 Then, I’ve added this to /etc/yum.repos.d/CentOS-Base.repo into the [centosplus] section: includepkgs=kernel* jfsutils reiserfs-utils into the [base] and [updates] section: includepkgs=kernel* jfsutils reiserfs-utils But when trying to […]

Continue Reading »
Oct 26, 2012
tom

Virtual hosts in CentOS

I have a server with IP 1.2.3.4 and I want the domain www.something.com to load website from /var/www/html/something/ I’ve tried to configure them as follows: NameVirtualHost 1.2.3.4:80<VirtualHost 1.2.3.4:80>ServerName www.something.com ServerAdmin emai@email.com DocumentRoot /var/www/html/something/ ErrorLog logs/something-error_log CustomLog logs/something-access_log common </VirtualHost> I’ve reloaded apache, but when accesing the domain, it only shows the root of the server /var/www/html/ Any idea what is wrong? Asked by n/a A common mistake is to set the IP address in VirtualHost […]

Continue Reading »
Oct 24, 2012
tom

CentOS 6.2 disable httpd autoindex

I am trying to disable the Auto index of directories in the apache config. <VirtualHost *:80> ServerName example.com ServerAlias www.example.com example.co.uk www.example.co.uk DocumentRoot /var/www/sites/example.com/public ErrorLog /var/log/httpd/error.log CustomLog /var/log/httpd/access.log combined Options -Indexes </VirtualHost> Will putting Options -Indexes into the VirtualHost configuration disable autoindex in these directories? Asked by Alex Yes, by putting in Options -Indexes you disable autoindex for the entire VirtualHost. You can read about it in the Apache Core Features documentation if you would […]

Continue Reading »
Oct 24, 2012
tom

How can I determine when a command was entered?

On a CentOS 5.x server, I’m troubleshooting an issue and need to determine when a service foo stop command was executed. The logs for the respective service don’t indicate this. I only see the command itself in the output for history. This was run from a root shell, not through sudo. Is there another way to determine when commands were run? Asked by Mike B CentOS by default does not keep track of when commands […]

Continue Reading »
Oct 24, 2012
tom

clamd says socket in use by another process but I can’t find one

I’m running CentOS 5.3 (Final) and using rpmforge I installed clamd and prereqs ok. I started clamd and ran a freshclam all ok. But if I run “clamd PING” or clamd /path/to/file I get ERROR: LOCAL: Socket file /var/run/clamav/clamd.sock is in use by another process Further detail below but I’m at a loss where to go from here now, any advice anyone? [root@main ~]# clamd PING ERROR: LOCAL: Socket file /var/run/clamav/clamd.sock is in use by […]

Continue Reading »
Oct 23, 2012
tom

Which services to disable on a CentOs 5.8 web/database server?

I have just setup my CentOS 5.8 64 [final] server as a webserver. Specs: 2x E5620 Intel CPU, DDR3 RAM, Hardware Adaptec RAID 10, 4x SAS drives. I have installed myself: Nginx PHP-FPM MySQL [ourdelta.org version] Sphinx Vsftpd Fail2ban Citadel [ddos flood protection] Munin NTP Htop Iptraf These are all things that I actively use to run my websites. Now my question: I found this article: http://www.vr.org/kb/1002/Optimize-and-disable-default-CentOS-services.html Which talks about a whole list of services […]

Continue Reading »
Oct 22, 2012
tom

WIldcard SSL Subdomain Not Pointing at Correct DocumentRoot

I have a Wildcard SSL installed on my Apache server. With the code snipplet below, the following works: http://test.com (points to /var/www/html) https://test.com (points to /var/www/html) http://s1.test.com (points to /var/www/s1) but https://s1.test.com does not work – it points to /var/www/html rather than /var/www/s1 – how can I get it so it points at it’s own directory? <VirtualHost *:443> DocumentRoot “/var/www/html” ServerAlias test.com *.test.com ServerName *.test.com SSLEngine on SSLCertificateFile /home/test/STAR_test_com.crt SSLCertificateKeyFile /home/test/test.key SSLCertificateChainFile /home/test/PositiveSSL.ca-bundle </VirtualHost> <VirtualHost […]

Continue Reading »
Oct 21, 2012
tom

Puppet yum repo – Pull down 2.7.x vs 3.0.x

So a few weeks ago I started on the path to using puppet to automate all the configs/services. At the time I was using the EPEL repo, which installed version 2.6.x. After some reading I was trying to gain access to the flatten method available via the puppet stdlib, and thought it was available by default in the newer 2.7.x version. So I added a puppet repo with the following settings: [puppetlabs] name=Puppet Labs Packages […]

Continue Reading »
Pages:«12345678...167»