The apache web server.
6
votes
1answer
436 views
httpd running as apache.apache, but logs owned by root.root?
ps shows my httpd processes as
apache 29561 15186 0 15:30 ? 00:00:00 /usr/sbin/httpd
I'm running Centos 5.3
All the log files in /var/log/httpd are owned by root.
Howcome?
6
votes
1answer
952 views
Throttling web crawlers
My website is being DoS'ed by Google webspiders. Google is welcome to index my site, but sometimes it is querying a tagcloud on my site faster than my webserver can produce the results, making my ...
5
votes
2answers
2k views
How to avoid apache reload when rotating logs?
I use logrotate to rotate Apache access-, error- and rewrite-logs. My config file looks like this:
/apache/*log {
compress
dateext
rotate 365
size=+300M
olddir /log/old/apache
...
5
votes
3answers
2k views
How do I create web pages in my home directory and have the web server serve them in my web browser?
I have recently installed the Apache web browser in my Debian Squeeze (using command tasksel and selecting [ ] Web server). Now I get it to start via sudo /etc/init.d/apache2 start and then I go to my ...
5
votes
1answer
336 views
Opening port 80 but remain secure
I have a standard installation of Ubuntu 10.04, and have installed the LAMP stack so I can do some web development locally. On my router I have opened port 80 so I can develop with external services ...
5
votes
4answers
953 views
Case-insensitive file system for production server?
The initial situation looks like this:
The corporate software is PHP-based.
It is delivered by Apache 2 on a Windows 2003 Server.
It is big.
It is a legacy of rather unprofessional developers who ...
5
votes
2answers
3k views
Localhost .htaccess not working on Ubuntu
I have been trying to get my .htaccess file to work on my localhost. I know that the file works because it is on my server and works. However it doesn't seem to be working locally.
I have followed ...
5
votes
3answers
1k views
A Web ssh/telnet client
I'm in kind of a tight spot right now. I wanted to know if someone has seen a HTML, or PHP web ssh client as both my company and school block everything besides port 80. I'm a control freak when it ...
5
votes
1answer
206 views
Unkillable apache2 processes
After upgrading from debian lenny to squeeze (apache2 2.2.16-6+squeeze4 and php 5.3.10-1~dotdeb.1), my apache processes started to exit with segmentation fault. It happens every 5-30 minutes (for 1 ...
5
votes
1answer
304 views
How can I setup Apache on Linux to stream WMV-HD to Xbox 360?
What I am looking for is a free and open source solution. If the distro I use matters, it is Open SUSE. VLC supports only WMV1&2.
5
votes
1answer
82 views
Slow ikiwiki after first run
I have local ikiwiki on my notebook (with apache as local webserver). When I save an edit the first time after booting and logging in, saving is very slow (but the second time saving is at normal ...
4
votes
3answers
4k views
Missing init.d/apache2 file
I am new to linux and just recently messed up my first apache/tomcat configuration. After trying to delete apache and tomcat, and now trying to reinstall apache 2, I am missing the init.d/apache2 file ...
4
votes
2answers
2k views
How can I configure /etc/hosts file to point to apache web server?
I have installed apache web server and I need to point 127.1.1.1 with alias (www.someaddress.lan) to local apache. What is the proper way to do it? How to point someaddress.lan to default apache page ...
4
votes
2answers
14k views
What user should apache and PHP be running as? What permissions should /var/www files have?
I just spun up an Ubuntu 11.10 box and then ran apt-get install apache2 php5 to install apache2 and PHP 5 on the box. Now it is functioning as a "web server" and it loads the "It Works!" page. Now I'm ...
4
votes
1answer
378 views
recovering deleted file held open by apache?
suppose an apache log file gets deleted but its held open by apache then this is what i am doing.
pid=$(lsof | grep text.txt | awk '/deleted/ {print $2}')
fd=$(lsof | grep text.txt | awk '/deleted/ ...
4
votes
1answer
751 views
Bash, remove lines containing string with grep
This is currently deleting the whole contents of the file in question:
#!/bin/bash
rpc_port="9201";
dir="/etc/apache2/ports.conf"
cat $dir | grep -v "Listen $rpc_port" > $dir
The file contents:
...
4
votes
2answers
429 views
apache and php Segmentation fault [closed]
I have recently migrated to Archlinux. I installed Apache, php and mysql according to the Arch Linux LAMP wiki page.
Now I have setup a virtual host for my new Symfony project.
For every request I ...
4
votes
2answers
11k views
How to configure SSL in apache?
I have installed apache in RHEL 6. Everything is working fine. What all changes and configurations should be done to use
https://localhost:443/.
If I change the "Listen 80" to 443 it is throwing an ...
4
votes
1answer
102 views
If I'm logged in as root, how do I restart mysql or apache with options?
I know the commands to restart/stop/start, but when I try to pass options it doesn't seem to work!
CENTOS 6, MySQL 5.14
service mysql restart
service httpd restart
Then I tried this:
...
4
votes
2answers
522 views
Limiting the Size of Apache HTTPD Memory Footprint
I have a web server running Cent OS 5 with Apache. I have over 1GB of Ram and the MaxSpareServers set to 15. This would be fine under most situations, but for some reason my httpd processes are ...
4
votes
2answers
617 views
How to Update Apache to allow Pseudostreaming on CENTOS 5.5 & WHM
I can't figure out how to get pseudostreaming on my Apache server (CENTOS 5.5 i686).
I've read this article and these install instructions.
I cannot install httpd-devel or mod_ssl via yum; I get ...
3
votes
2answers
542 views
Sync with a Directory Listing of An Apache Server
Is there an easy way to keep a folder synced with a directory listing via HTTP?
Edit:
Thanks for the tip with wget! I created a shell script and added it as a cron job:
remote_dirs=( ...
3
votes
3answers
9k views
“Symbolic link not allowed or link target not accessible” / Apache on CentOS 6
I've got a brand new CentOS 6 installation, which has a symlink in the document root to my development files:
[root@localhost html]# ls -l
total 4
-rwxrwxrwx. 1 root root 0 Sep 18 20:16 index.html
...
3
votes
5answers
7k views
Apache won't start on Fedora 15
I can't get Apache to start on Fedora 15. I downloaded a project into /var/www/html and changed myself to the owner (recursively), though I don't think I changed any SELinux contexts or anything like ...
3
votes
1answer
166 views
Blocking visitors that access by server IP address
My Apache Server IP address is 192.168.1.100 and the Domain Name is test.local.
If a user types in the URL, say "http://test.local", then they should be allowed.
If a user tries to access "http:// ...
3
votes
1answer
391 views
Bot requesting odd resource in apache logs
While studying for the RHSCA exam I set up my first home server and quickly found that bots had already started requesting commonly vulnerable files. It was alarming at first, then just purely amusing ...
3
votes
3answers
1k views
Why put some config info in conf/httpd.conf and some in files in the conf.d folder?
The main apache config file is in /etc/httpd/conf/httpd.conf on my CentOS system an in there is a line:
Include conf.d/*.conf
Inside conf.d is mostly files that do something like this:
LoadModule ...
3
votes
1answer
105 views
How to redirect traffic from subdomain to main domain
I have a demo.domain.com and domain.com
they both show the same information and point to the same folder.
How can I redirect all demo.domain.com visitors to domain.com?
3
votes
2answers
2k views
How do I fix the error 403 I am getting with XAMPP while I am using mod_userdir?
I am running Arch Linux and I decided to use XAMPP so I can create and test web pages. Anyway, I followed the instructions given in the site and extracted it to /opt/lampp and I also uncommented the ...
3
votes
1answer
676 views
How can I tell what version of apache I'm running?
I know about the phpinfo() way but is there any other way? I'm using CentOS and I can't find the httpd executable to run httpd -v.
3
votes
1answer
889 views
Apache server 32 binaries vs 64 binaries? what's the difference
not sure if this is a silly question...apples and oranges maybe..but...
For Windows I used to download either 32 bit binaries from ASF site or 64 bit binaries from Apache lounge site (for no ...
3
votes
1answer
61 views
Where do I set FollowSymLinks?
I have just set up an Apache 2.2 server on a new Linux Mint installation. I am recreating a previous set up I had on an old Ubuntu machine.
On my previous computer, I had to enable FollowSymLinks in ...
3
votes
2answers
3k views
Execute shell script from php, as root user?
Need to execute the following line from PHP:
$res = shell_exec('sudo sh /home/nicklas/cronjobs/make_account.sh
username password');
The problem is nothing happens on execution. If i try to ...
3
votes
1answer
352 views
How to configure permissions to allow apache to securely have access to a file in a shared environment?
This is a follow up question from my previous, but I felt it might be more Linux based.
http://serverfault.com/questions/414207/how-to-set-linux-permissions-to-allow-apache-to-have-access-to-a-file
...
3
votes
1answer
80 views
Where to securely place files needed by PHP in Linux filesystem (according to FHS)
I have a PHP script running on my LAMP server that requires certain files in order to produce HTML content. The script is publicly accessible (i.e. http://example.com/script.php) but the files ...
3
votes
3answers
2k views
How to configure permissions to allow gedit, apache, and an IDE play together?
I'm using plain Ubuntu Desktop 11.04 and installed my lamp stack using lamp-server. I am trying to use Netbeans as my IDE.
Currently, all virtual hosts are being run from /var/www/vhostname -- but as ...
3
votes
2answers
1k views
Permissions: What's the right way to give Apache more user permissions?
Context: I am making an in-browser control panel that gives me one button access to a library of scripts (.sh and .php) that I've written to process various kinds of data for a project. It's a "one ...
3
votes
1answer
381 views
Setting SVN permissions with davsvnauthz
There seems to be a path inheritance issue which is boggling me over access restrictions.
For instance, if I grant rw access one group/user, and wish to restrict it some /../../secret to none, it ...
3
votes
1answer
1k views
How do I install mod_pagespeed using apt-get?
I remember seeing an article at one time on how to do this, but now I can't find it. I have seen other install directions. I want to make sure I can easily update it via apt.
3
votes
2answers
235 views
How to set secure permissions for multiple users and multiple websites?
On a Gentoo 3.2.12 server with apache2+php, there are several websites running:
/www
/website1
/website2
...etc
The apache user should have read-only access to all the websites. There ...
3
votes
1answer
71 views
Configuring Apache to Require a Client Certificate
I want to implement mutual authentication (two - way ) with apache web server.
References :
1.Failed to sign CSR with the CA root key
2.Firefox error message when adding client certificate ...
3
votes
0answers
176 views
MySQL stop/waiting issues; “can't connect … through socket”
So this was my first time putting up a LAMP stack on a Bodhi machine (previously experience with WAMP, and LAMP on 10.04); I got Apache going, and a Drupal install begun, then I go to create a new ...
3
votes
3answers
195 views
Use of variables in Apache configuration
I have a number of largely identical configuration files in my Apache2 configuration, for configuring various subdomains. In most of these configuration files, only the name of the subdomain itself is ...
3
votes
0answers
133 views
Traffic getting routed through Apache
for some reason, certain outgoing traffic on my server gets routed to the apache webserver i am running. this problem just started happening. i have the webserver set up to use vhosts, the webserver ...
2
votes
4answers
198 views
Executing programs without having to specify a directory?
Why is it that I have to type /etc/init.d/apache2 (args) in order to run apache??
Isn't there a way to just apache2 args ??
2
votes
4answers
266 views
Creating a public document directory for a normal user
We usually see personal web pages like http://a-site.com/~someone/, in this case, "someone" is a user of "a-site". How to enable this by default, so whenever we add a new user "foo", then ...
2
votes
2answers
42 views
Disadvantages to having www-data able to log in
I run a tiny web server basically just for hosting small data projects and files. This server has a public IP address.
I would like to be able to FTP in and upload files directly to /var/www/*, and ...
2
votes
1answer
609 views
How do I restart apache as non-root (using a git-hook)?
For one specific user I want to be able to restart Apache. This user does have sudo privileges and I could run sudo /etc/init.d/apache2 reload, but I want to include this restart script in a git ...
2
votes
1answer
111 views
How do I stop Apache from running as root?
New on the job, small place, and the security stuff just landed on my desk. I was hired to be a front-end developer. Happy to learn new things, but never had to do sysadmin stuff before.
I started ...
2
votes
1answer
175 views
Remove a directory level from a website URL
Can anyone tell me how to configure apache to not display a website folder name at the end of a base URL, please? - but only for one out of many websites.
Let me describe the scenario ...
I have a ...