LinuxQuestions.org
Share your knowledge at the LQ Wiki.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie
User Name
Password
Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question? If it is not in the man pages or the how-to's this is the place!

Notices


Reply
  Search this Thread
Old 09-08-2016, 03:17 AM   #1
iFunction
Member
 
Registered: Nov 2015
Posts: 248

Rep: Reputation: Disabled
Default localhost settings


Hi there,

Over the past few weeks I have been trying to learn about building a LAMP server and followed countless tutorials. However it has made a little mess of my system, as I can no longer access localhost from a browser. I am suspecting it is /etc/apache2/sites-enabled/000-default.conf that I changed, and although I can see what I have changed, I have no idea what it said originally. I then tried something that I found online about recovering default set up files using dpkg which also did not work so now I have nothing. I want to go back to the default html page, whilst currently I am now stuck at a 404, which makes learning a little on the tricky side.

Is there an easy way to reset all this without actually reinstalling the whole operating system. This is on a raspberry pi, so there is nothing really important on there, but it would be nice to know what is happening and how to revert changes.

Kind regards
iFunc
 
Old 09-08-2016, 03:31 AM   #2
ferrari
LQ Guru
 
Registered: Sep 2003
Location: Auckland, NZ
Distribution: openSUSE Leap
Posts: 5,804

Rep: Reputation: 1140Reputation: 1140Reputation: 1140Reputation: 1140Reputation: 1140Reputation: 1140Reputation: 1140Reputation: 1140Reputation: 1140
Did you really edit directly and save as file of same name (as opposed to editing and saving as foo.com.conf)? Anyway, it doesn't contain a lot - apart from some comments, it has....

Code:
<VirtualHost *:80>
    ServerAdmin webmaster@localhost
    DocumentRoot /var/www/html
    ErrorLog ${APACHE_LOG_DIR}/error.log
    CustomLog ${APACHE_LOG_DIR}/access.log combined
</VirtualHost>
 
1 members found this post helpful.
Old 09-08-2016, 03:51 AM   #3
iFunction
Member
 
Registered: Nov 2015
Posts: 248

Original Poster
Rep: Reputation: Disabled
Yes, unfortunately I did, however, as this particular pi is my development test thing, the best lesson I have learned from this is to rename the original file as a backup so I don't make the same mistakes twice.

Thanks for this, that is really helpful.

regards
iFunk
 
  


Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
Default IP for LocalHost in RedHat 6 e_oneill4 Linux - Newbie 5 12-01-2014 03:46 PM
Localhost pointing to default page if I don't specify the port number in the address rajaoLQ Linux - Server 6 08-24-2009 02:52 PM
How to reset monitor settings to default autodetected settings in openSUSE? chengas123 Linux - General 2 09-17-2008 11:24 AM
apache2 + mod-ssl keeps loading the default localhost.xxxxxx cert STEBEL Linux - Newbie 3 11-26-2005 07:49 AM
default /etc/ settings? albinojellyfish Linux - Security 6 07-24-2005 02:08 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie

All times are GMT -5. The time now is 08:16 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration