Find the answer to your Linux question:
Results 1 to 4 of 4
I installed Apache using Code: # apt-get install apache2 But I didn't know how to work it, so I went to the apache website, and unpacked apache to /usr/lib/apache/ then ...
  1. #1
    Just Joined!
    Join Date
    Mar 2008
    Posts
    34

    Can't control Apache

    I installed Apache using
    Code:
    # apt-get install apache2
    But I didn't know how to work it, so I went to the apache website, and unpacked apache to /usr/lib/apache/ then ran
    Code:
    # /usr/lib/apache/bin/apachectl start
    Like it told me to in the instructions, but it gave me this:
    Code:
    httpd: 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 0.0.0.0:80
    no listening sockets available, shutting down
    Unable to open logs
    So I decided to check to see what program was using this port so I used netstat (I forgot the actual command), and guess what came up? Apache.
    So I opened a browser and went to "localhost:80" and a webpage came up that said "It works!" just like apaches suppose to do. So I tried to close apache using:
    Code:
    # /usr/lib/apache/bin/apachectl stop
    But this came up:
    Code:
    httpd: Could not reliably determine the server's fully qualified domain name, using 127.0.1.1 for ServerName
    httpd (no pid file) not running
    And so I tried opening localhost:80 and it still said "It works!"
    So I decided to remove apache completely:
    Code:
    # apt-get remove apache2
    And it removed one package, but it still works!
    I have no Idea how this is happening, and I have no idea how to shut it down.

  2. #2
    Linux Guru coopstah13's Avatar
    Join Date
    Nov 2007
    Location
    NH, USA
    Posts
    3,149
    the installed service controller should be in /etc/init.d
    the config files for apache should also be in /etc, probably under apache2 folder

  3. #3
    Just Joined!
    Join Date
    Mar 2008
    Posts
    34
    So, what do I do with these files? I want accomplish either of two things: Have control over the apt-get install or use the one I installed. I believe both have their strengths and weaknesses. The apt-geted one is supported by ubuntu, but the one I installed is easy to control, because its all in one file I believe, I actually know what file is being shared on the webserver, and have edited the index.html. And its a newer version, so I'd rather use the one I installed. So how do I get rid of or disable the other one?

  4. #4
    Just Joined!
    Join Date
    Mar 2008
    Posts
    34
    Ok, I fixed it. I needed to do:
    Code:
    # apt-get autoremove
    I think thats it, maybe something like that. Anyway I that got rid of the old Apache installation completely. Read my other posts to see what I did exactly.

    I'm posting this for people to find this thread if they have the same problem.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
...