Pages: 12Next
Current Page: 1 of 2
localhost not working
Posted by: Jimbo (---.lsanca54.dynamic.covad.net)
Date: March 30, 2006 07:33AM

Yes, I've read through everything here, and I've seen a few things mentioned that are close, but did not answer my issue.

My suspicion is that my problem is something really simple and obvious, but I can't see it.

[localhost] in a browser returns an error:

"The connection was refused when attempting to contact localhost."

So, I cannot accesss localhost, or anything below them phpmyadmin/ and sqlitemanager/ for example.

I'm on a Windows XP box, and the hosts file has localhost defined to the default address in it.

How are permissions granted when accessing localhost?

In addition, I believe that the problem I am having with mysql is related. If I run mysql (from c:/wamp/mysql/bin), I receive this error:

ERROR 1045 (28000): Access denided for user 'Jim'@'localhost' (using password: YES)

I can't find this information listed in any file. Password YES???

Thanks in advance for any assistance.

- Jimbo



[www.wire-heads.com]

Options: ReplyQuote
Re: localhost not working
Posted by: CyberSpatium (---.hsd1.or.comcast.net)
Date: March 30, 2006 10:58AM

Make sure apache is running, or you will not be able to connect to localhost.

Options: ReplyQuote
Re: localhost not working
Posted by: Reyyan (---.CITMATEL.NET)
Date: March 30, 2006 05:38PM

If you put in the browser 127.0.0.1 no localhost ... work?
If you have a proxy don´t use it for local address.
meybe that,s the reason. Go to internet options and connections
disable the proxy server for local address.
Or maybe is your mysql server configuration

Options: ReplyQuote
Re: localhost not working
Posted by: Jimbo (160.33.20.---)
Date: March 30, 2006 06:54PM

Thank you both for responding to quickly,

CyberS -- Apache is running according to the WAMP menu. mySQL is not. The error log in mySQL lists the same thing over and over. It launches, and it's ready to recieve requests, then it shutsdown. What is that?

Reyvan -- neither 127.0.0.1 or localhost work in the brower. They both get the "connection refused" error. I will check for the "proxy server" in Internet Options and Connections tonight (at work now).

- Jimbo



[www.wire-heads.com]

Options: ReplyQuote
Re: localhost not working
Posted by: Jimbo (---.lsanca54.dynamic.covad.net)
Date: March 31, 2006 07:22AM

Okay, so my query is NOT answered. Apache is running. (Thanks, CyberS), and I do not see a setting in 'Control Panel'->'Network and Internet Connections'->'Internet Options' OR 'Network Connections.'

If you know where I could look further for the proxy setting, and still believe that to be the issue, I'd be glad to look for them.

PHP is running, so I have to assume that Apache is running (other than the Wamp Menu saying that it is running, does anyone know a sure fire test for Apache>winking smiley. I do not have a good method to determine is mysql is running, but I still cannot get my browser to login to 'localhost.'

Any help? I see that question asked a lot by people who are trying to assist "Can you connect to localhost?" So, I was hoping there would be someone forthcoming with an answer if one could not.

Thanks in advance.
- Jimbo



[www.wire-heads.com]

Options: ReplyQuote
Re: localhost not working
Posted by: Jimbo (---.lsanca54.dynamic.covad.net)
Date: April 01, 2006 09:55AM

Uninstalled wamp. Cleaned out all apache, Php, mysql, then re-installed. localhost refusing connection still. Suggestions?



[www.wire-heads.com]

Options: ReplyQuote
Re: localhost not working
Posted by: CyberSpatium (---.hsd1.or.comcast.net)
Date: April 01, 2006 05:49PM

Do you any software installed that uses port 80? Like Skype or IIS or a previous install of Apache (or any other web server)? If you have Norton firewall installed a few people have complained of not getting Apache to work with Norton.

What version of Win XP do you have? if you have the home version, then it does not come with IIS. IIS only comes on the pro version of XP.

If you still cannot get Apache started, try changing the default port apache uses in your httpd.conf file

Find this line:
Listen 80

Change it to:
Listen 81

Save the file, and try to start Apache now, and use your web browser and connect to:
[localhost]'

If you get any error messages, post them here.

Good luck smiling smiley

Options: ReplyQuote
Re: localhost not working
Posted by: Jimbo (160.33.20.---)
Date: April 01, 2006 09:39PM

Thanks, CyberS.

Firewall was problem
I went to my firewall, and turned it off. I couldn't figure out how to allow the localhost to not appear as a threat to the firewall (Norton Utilities). It was blocking the localhost access everytime I tried to access it. I know, I know, there should be a way to allow an approved localhost to communicate, but I couldn't figure it out.

But how to tell Norton Localhost is not a threat?
I do recall one thing, however, whenever the localhost tried to communicate and was intercepted by Norton, there was always a number listed in parens next to the localhost; like localhost (1139) or something. This number would change everytime I tried the access. In the allow approved hosts settings in Norton, I put localhost everywhere I could imagine, and still it was not approved.

So... I turned off my firewall (eg. sure that I would regret it), and I could easily access localhost through my browser. The default Wamp page come up.

But the behaviour of the sqlitemanager and phpmyadmin pages didn't strike me as optimal. The sqlitemanageer page (accessed through the Wamp Menu) was blank, and sorry, I forget what the phpmyadmin did, but there wasn't a page there either. Perhaps these are supposed to look this way?

Firewall Down
So, the next morning when I turned on my computer, there were more virus invastions than ever. Thank God for Xoftspy. I guess the rule is more like (turn off the firewall while using WAMP, then turn it back on when done. That is, until I figure out how to allow localhost to not be deemed a threat.

MySQL Testing
I wasn't sure how I was supposed to test the mysql install, so I tried reading several .php files under phpmyadmin, and they all came in as text. Now, I've read that there is possibly a username and password that I am supposed to add in the config.inc.php under phpmyadmin/ dir? If this is so, can I put anything I like, or is something in particular expected? And also, do I add the name and passwd in the [client] location, just above port [3306]?

Thanks for everything.
- Jimbo



[www.wire-heads.com]

Options: ReplyQuote
Re: localhost not working
Posted by: andrewkinyua86 (---.lmdaca.adelphia.net)
Date: April 02, 2006 02:09AM

one make sure the Apache server is running, second is your server has a password that you already set, you need to that to connect <$conn = mysql_connect("localhost","YOURUSENAME","YOURPASSWORD"winking smiley or die(mysql_error());
$db = mysql_select_db("YOURDATABASE",$conn) or die(mysql_error());>
otherwise if you have never set a password then you need to use 'root' as your username and ' ' foryour passwword, i mean leave the password field blank since its supposed to be nothing when you installed it.



Andrew

Options: ReplyQuote
Re: localhost not working
Posted by: CyberSpatium (---.hsd1.or.comcast.net)
Date: April 02, 2006 06:07AM

Make sure MySQL is running or phpmyadmin will not work.

To make norton work with WAMP you need to set norton to allow apache and mysql to connect to the internet.

You can also find a WAMP help file in the main WAMP directory, you should read it.
C:\wamp\wamp5.chm



Post Edited (04-02-06 06:13)

CyberSpatium
----------------------
WAMP Forum Admin

Web Development for Newbie's Blog - Check out my new blog. It is for web developers, and especially tailored for the web development newbie. If you are not fluent in “geek speak”, then this incredible resource is just you. And even if you are a web development pro, this is a great resource to check out some of the latest web development tips, news, tutorials, codes and more.

Options: ReplyQuote
Re: localhost not working
Posted by: Jimbo (---.lsanca54.dynamic.covad.net)
Date: April 02, 2006 07:29PM

Thanks for the assistance, Andrew & CyberS. I will be following up.

CyberS, on the Norton set to allow business. Currently, Norton Security is set to allow any and all of the mysql executables to run, and Apache.exe to run, yet the localhost is still refused access when using these executables. Localhost (####) seen as a threat.

I will definitely read through the wamp .chm file listed for more insight.

Andrew, the wamp setup is allowing me to run everything even with no login at the moment. I would imagine once online this would be a security issue, so I will be looking for specific information on how to create secure logins for the system. Any direction to docs, procedures or files to read would be most appreciated!

- Jimbo



[www.wire-heads.com]

Options: ReplyQuote
Re: localhost not working
Posted by: onewiththeclay (---.ipt.aol.com)
Date: April 03, 2006 12:11AM

I am having the same problem of not being able to connect to the local host. I get this error message: Direct Access to this location is not allowed.
I have set my fire wall to allow my apache to access the internet as suggested . I'm using Zone Alarm pro version 5.1.
I use the home version of XP
I've tried to follow these instructions:

"If you still cannot get Apache started, try changing the default port apache uses in your httpd.conf file

Find this line:
Listen 80

Change it to:
Listen 81"

but I can't open the file to do that (Yes, I am a real newbie at this, if I can't open it up in an editor then I'm lost)


All my servers are running and I've read the help files

I'd appreciate any suggestions,
Thanks
owc

Options: ReplyQuote
Re: localhost not working
Posted by: CyberSpatium (---.hsd1.or.comcast.net)
Date: April 03, 2006 09:59AM

I too have WinXP sp2 w/Zone Alarm Pro, and I have no problems with Zone Alarm blocking apache and mysql

Options: ReplyQuote
Re: localhost not working
Posted by: onewiththeclay (---.ipt.aol.com)
Date: April 04, 2006 12:34AM

I'll continue to look in other area then. I'll try uninstalling and reinstalling one more time.

Options: ReplyQuote
Re: localhost not working
Posted by: onewiththeclay (---.ipt.aol.com)
Date: April 04, 2006 03:11AM

Okay I reinstalled it and now everything is working fine. Thanks

Options: ReplyQuote
Re: localhost not working
Posted by: CyberSpatium (---.hsd1.or.comcast.net)
Date: April 04, 2006 01:44PM

onewiththeclay, did you do anything different to get WAMP working, or just reinstall it, that way if anyone else out there has this same problem, they know what you did to solve your problem.



CyberSpatium
----------------------
WAMP Forum Admin

Web Development for Newbie's Blog - Check out my new blog. It is for web developers, and especially tailored for the web development newbie. If you are not fluent in “geek speak”, then this incredible resource is just you. And even if you are a web development pro, this is a great resource to check out some of the latest web development tips, news, tutorials, codes and more.

Options: ReplyQuote
Re: localhost not working
Posted by: mn5800@yahoo.com (---.dhcp.roch.mn.charter.com)
Date: April 05, 2006 06:36PM

I had these same problems, I had my firewalls down and virus protection shutoff and then figured out it was the ISP, i and found out my ISP was blocking port 80 and there is nothing I could do about it. I had to set up a subdomain and redirect to port 8000 at zonneedit.com. That should get you online if that is what is ailing your pc. If you do not know how to set that up they can help you at zoneedit. Now that I am on a different port I am having problems I suspect may be because of that so I may be on here later askking for help! Good luck!

Options: ReplyQuote
Re: localhost not working
Posted by: shahramsfamily (---.dsl.irvnca.pacbell.net)
Date: May 29, 2006 03:09AM

I need to know how to set up the login for Apache server.
Thank you

Options: ReplyQuote
Re: localhost not working
Posted by: CyberSpatium (67.170.181.---)
Date: May 29, 2006 03:22AM

if you want to password protect a directory, use .htaccess and .htpasswd

Options: ReplyQuote
Re: localhost not working
Posted by: shahramsfamily (---.dsl.irvnca.pacbell.net)
Date: May 29, 2006 03:27AM

Thank you.
Yet, What I am asking is what is the root password and user name for Apache, if I want to telenet to it or set up some kind of Admin panel, etc.



Post Edited (05-29-06 03:38)

Options: ReplyQuote
Pages: 12Next
Current Page: 1 of 2


Sorry, only registered users may post in this forum.