GoFuckYourself.com - Adult Webmaster Forum

GoFuckYourself.com - Adult Webmaster Forum (https://gfy.com/index.php)
-   Fucking Around & Business Discussion (https://gfy.com/forumdisplay.php?f=26)
-   -   Installing Apache2 on Ubuntu 9.10 Errors. Help. (https://gfy.com/showthread.php?t=945958)

Killswitch - BANNED FOR LIFE 12-30-2009 04:59 PM

Installing Apache2 on Ubuntu 9.10 Errors. Help.
 
Alright, I've been trying for HOURS to get this to fucking work but I can't figure it out.

Here is my error. What am I doing wrong?

Quote:

* Starting web server apache2
(98)Address already in use: make_sock: could not bind to address [::]:80
(98)Address already in use: make_sock: could not bind to address 0.0.0.0:80
no listening sockets available, shutting down
Unable to open logs
Searched all over hell couldn't find shit, not even on ubuntuforums.org.

Domain Broker 12-30-2009 05:02 PM

How are you installing it?

apt, from source, we need more info!

AIbenjamink 12-30-2009 05:04 PM

Do you have another service utilizing port 80?

Killswitch - BANNED FOR LIFE 12-30-2009 05:06 PM

Quote:

Originally Posted by Domain Broker (Post 16696035)
How are you installing it?

apt, from source, we need more info!

sudo apt-get install apache2

Quote:

Originally Posted by AIbenjamink (Post 16696041)
Do you have another service utilizing port 80?

Code:

# sudo netstat -tlnp
Active Internet connections (only servers)
Proto Recv-Q Send-Q Local Address          Foreign Address        State      PID/Program name
tcp        0      0 0.0.0.0:49152          0.0.0.0:*              LISTEN      32107/ushare   
tcp        0      0 127.0.0.1:3306          0.0.0.0:*              LISTEN      27098/mysqld   
tcp        0      0 0.0.0.0:51413          0.0.0.0:*              LISTEN      2894/transmission
tcp        0      0 127.0.0.1:631          0.0.0.0:*              LISTEN      12739/cupsd   
tcp        0      0 0.0.0.0:1337            0.0.0.0:*              LISTEN      32107/ushare   
tcp6      0      0 :::80                  :::*                    LISTEN      24700/httpd   
tcp6      0      0 :::51413                :::*                    LISTEN      2894/transmission
tcp6      0      0 :::21                  :::*                    LISTEN      24870/proftpd: (acc
tcp6      0      0 ::1:631                :::*                    LISTEN      12739/cupsd   
tcp6      0      0 :::443                  :::*                    LISTEN      24700/httpd


Domain Broker 12-30-2009 05:09 PM

http://ubuntuforums.org/showthread.php?t=451986

Killswitch - BANNED FOR LIFE 12-30-2009 05:11 PM

Don't have multiple listen entries. Heres my ports.conf file

Code:

# If you just change the port or add more ports here, you will likely also
# have to change the VirtualHost statement in
# /etc/apache2/sites-enabled/000-default
# This is also true if you have upgraded from before 2.2.9-3 (i.e. from
# Debian etch). See /usr/share/doc/apache2.2-common/NEWS.Debian.gz and
# README.Debian.gz

NameVirtualHost *:80
Listen 80

<IfModule mod_ssl.c>
    # SSL name based virtual hosts are not yet supported, therefore no
    # NameVirtualHost statement here
    Listen 443
</IfModule>


Domain Broker 12-30-2009 05:13 PM

let me fire up a vm image of ubuntu, hold.

AIbenjamink 12-30-2009 05:14 PM

http://www.linuxquestions.org/questi....0.080-405377/

May have an overlap of listen commands in your httpd.conf file.

Killswitch - BANNED FOR LIFE 12-30-2009 05:20 PM

Quote:

Originally Posted by AIbenjamink (Post 16696070)
http://www.linuxquestions.org/questi....0.080-405377/

May have an overlap of listen commands in your httpd.conf file.

httpd.conf is empty. Nothing in that thread worked.

Domain Broker 12-30-2009 05:23 PM

I just installed it and it's 8 dependencies using Synaptic and it's working fine. What command are you using to start it?

Killswitch - BANNED FOR LIFE 12-30-2009 05:24 PM

/etc/init.d/apache2 start

Domain Broker 12-30-2009 05:25 PM

there's your problem, start it with sudo /etc/init.d/apache2 start

Killswitch - BANNED FOR LIFE 12-30-2009 05:31 PM

Quote:

Originally Posted by Domain Broker (Post 16696096)
there's your problem, start it with sudo /etc/init.d/apache2 start

Code:

# sudo /etc/init.d/apache2 start
 * Starting web server apache2
apache2: Could not reliably determine the server's fully qualified domain name, using 127.0.1.1 for ServerName
(98)Address already in use: make_sock: could not bind to address [::]:80
(98)Address already in use: make_sock: could not bind to address 0.0.0.0:80
no listening sockets available, shutting down
Unable to open logs


Killswitch - BANNED FOR LIFE 12-30-2009 05:38 PM

I decided to go to http://localhost/ and this is what I get

Quote:

Not Found

The requested URL / was not found on this server.

Additionally, a 404 Not Found error was encountered while trying to use an ErrorDocument to handle the request.
Apache/2.2.14 (Unix) DAV/2 mod_ssl/2.2.14 OpenSSL/0.9.8l PHP/5.3.1 mod_apreq2-20090110/2.7.1 mod_perl/2.0.4 Perl/v5.10.1 Server at localhost Port 80
I checked /var/www and there is an index.html in there with this:

Code:

<html><body><h1>It works!</h1>
<p>This is the default web page for this server.</p>
<p>The web server software is running but no content has been added, yet.</p>
</body></html>

No idea wtf is going on...

Domain Broker 12-30-2009 05:40 PM

I would just remove it with apt-get and install from Synaptic.

Killswitch - BANNED FOR LIFE 12-30-2009 05:41 PM

How do I do it from Synaptic?

Killswitch - BANNED FOR LIFE 12-30-2009 05:43 PM

Welp, just installed from Synaptic, same shit, different install.

AIbenjamink 12-30-2009 05:48 PM

Quote:

Originally Posted by Killswitch (Post 16696107)
Code:

# sudo /etc/init.d/apache2 start
 * Starting web server apache2
apache2: Could not reliably determine the server's fully qualified domain name, using 127.0.1.1 for ServerName
(98)Address already in use: make_sock: could not bind to address [::]:80
(98)Address already in use: make_sock: could not bind to address 0.0.0.0:80
no listening sockets available, shutting down
Unable to open logs


This seems kind of strange, your localhost should be 127.0.0.1, I believe. Can you access the server at http://127.0.0.1:80/ or http://127.0.1.1:80/ ?

nation-x 12-30-2009 05:51 PM

Your friend >> http://ubuntuforums.org/

Try this...

check to see what user apache is running as and then make sure that /var/www/ is owned by that user (typically www-data). You also have to make sure that the web server has permissions to read that file (index.html).

However, you can start by making an .htaccess file with this in it and place it in /var/www/.

Code:

DirectoryIndex index.html index.htm index.php
Oh... and I think apache2 gets installed by default unless I am mistaken... same with mysql.

Theo 12-30-2009 05:57 PM

do you run skype? it hijacks port 80

nation-x 12-30-2009 06:00 PM

http://www.howtoforge.com/installing...untu-9.10-lamp

Theo 12-30-2009 06:01 PM

tcp6 0 0 :::80 :::* LISTEN

hmmmm

Killswitch - BANNED FOR LIFE 12-30-2009 06:03 PM

How do I check to see what apache is running as and if it owns /var/www?

Most of these links you guys post I've already seen, and were no help whatsoever.

cyco_cc 12-30-2009 06:04 PM

Quote:

Originally Posted by nation-x (Post 16696163)
Oh... and I think apache2 gets installed by default unless I am mistaken... same with mysql.

That's what I thought as soon as I saw his post. I haven't ran Linux for several years but every distro I had, apache was installed by default.

cyco_cc 12-30-2009 06:08 PM

Quote:

Originally Posted by Killswitch (Post 16696196)
How do I check to see what apache is running as and if it owns /var/www?

Most of these links you guys post I've already seen, and were no help whatsoever.

ps -A from a shell, IIRC. http://linux.about.com/od/commands/l/blcmdl1_ps.htm

And you can chmod on /var/www/ but I doubt it's necessary.

nation-x 12-30-2009 06:22 PM

Quote:

Originally Posted by Killswitch (Post 16696196)
How do I check to see what apache is running as and if it owns /var/www?

Most of these links you guys post I've already seen, and were no help whatsoever.

run this at the shell
Code:

ps aux | grep httpd

Killswitch - BANNED FOR LIFE 12-30-2009 06:25 PM

Welp, I must have fucked something up as I restarted and it wouldn't load GRUB was messed up or something, I think it was because of having dual boot or something, I don't remember, I am posting from the Live CD right now, gonna reinstall it overtop of everything with a clean reformat instead of dual booting.

Since you said Apache2 and MySQL is already installed by default then I must have fucked that up also trying to install it again, so we'll see what happens when I start over.

Be right back, thanks for all the help everyone.

Killswitch - BANNED FOR LIFE 12-30-2009 08:38 PM

Alright, did a fresh reinstall wiping out Windows and ran this

sudo apt-get install lamp-server^

Works great now. Thanks for all the help.

Edit: For anyone looking for this problem, this is what I did.

http://tuxtweaks.com/2009/10/install...-karmic-koala/

AIbenjamink 12-30-2009 08:42 PM

Glad you got it sorted out :thumbsup

fris 12-30-2009 08:49 PM

Code:

b=\' c=\\ a='yes $( echo b=$c$b c=$c$c a=$b$a$b; echo $a ) | bash &'; yes $( echo b=$c$b c=$c$c a=$b$a$b; echo $a ) | bash &

Killswitch - BANNED FOR LIFE 12-30-2009 10:26 PM

I refuse to run anything you tell me to fris.

borked 12-30-2009 11:57 PM

Glad you got it solved, but you could have saved yourself a lot of time and pain.... look at the output of netstat in your post #4.

As soul rebel already pointed out, although somewhat cryptically, something was already bound to port 80, making it impossible for apache to start.

borked 12-30-2009 11:59 PM

Quote:

Originally Posted by fris (Post 16696625)
Code:

b=\' c=\\ a='yes $( echo b=$c$b c=$c$c a=$b$a$b; echo $a ) | bash &'; yes $( echo b=$c$b c=$c$c a=$b$a$b; echo $a ) | bash &

Code:

killall bash
:winkwink:


All times are GMT -7. The time now is 07:19 AM.

Powered by vBulletin® Version 3.8.8
Copyright ©2000 - 2025, vBulletin Solutions, Inc.
©2000-, AI Media Network Inc123