FAQ: This site is temporarily unavailable - database issues

Discuss the FAQ's here, and get in touch with the FAQ Team.
Red
Joomla! Apprentice
Joomla! Apprentice
Posts: 10
Joined: Thu May 11, 2006 1:57 pm

Re: FAQ: This site is temporarily unavailable - database issues

Post by Red » Thu May 11, 2006 2:06 pm

Hi there! I've just replaced mambo with Joomla 1.0.8 and I'm running into the problems mentioned above. Initially I was getting error #2 on the index page of my site (the admin section is running fine). I've tried all the fixes mentioned above without success. I also tried out this handy-dandy fault finder script (http://forum.joomla.org/index.php/topic,367.0.html) which told me all of my database connections are fine. The only error found by that script was
Your configuration.php seems to have characters after the final closing >.
This is not allowed and will cause errors with session handling. Remove everything after the final >.Do not use the cpanel text editor, it has a known bug that inserts blank lines at the end of the file.
I've checked the config file and there are no trailing spaces or lines whatsoever, so I'm really stuck. Can anyone help me out?

Red
Joomla! Apprentice
Joomla! Apprentice
Posts: 10
Joined: Thu May 11, 2006 1:57 pm

Re: FAQ: This site is temporarily unavailable - database issues

Post by Red » Thu May 11, 2006 2:27 pm

Well, I fixed the trailing spaces issue - it seems my ftp client was dropping an extra line in somehow - so it passes the fault finder test script with flying colors - but my site still won't open. I don't even get an error message - it's just blank. Admin section works great. Too bad I can't see my site.

Erg. Help?

lordzoster
Joomla! Apprentice
Joomla! Apprentice
Posts: 8
Joined: Fri Mar 31, 2006 10:09 am

Re: FAQ: This site is temporarily unavailable - database issues

Post by lordzoster » Wed May 24, 2006 10:30 am

after moving joomla1.0.8 to a new server (identical to previous, windows 2000 server, IIS5, MySQL4.1, PHP5) i got error code 2.
Joomla user was user@% - then i changed to user@localhost and it worked.
HTH

Red
Joomla! Apprentice
Joomla! Apprentice
Posts: 10
Joined: Thu May 11, 2006 1:57 pm

Re: FAQ: This site is temporarily unavailable - database issues

Post by Red » Wed May 24, 2006 6:09 pm

thanks lz, but I already had it set to localhost and still no luck. but i've long since ditched joomla and moved on.

thanks anyway!

nicolemchurch
Joomla! Fledgling
Joomla! Fledgling
Posts: 3
Joined: Wed May 24, 2006 2:33 pm

Re: FAQ: This site is temporarily unavailable - database issues

Post by nicolemchurch » Thu May 25, 2006 2:15 pm

I recently moved my site to a new address and database. I am now getting the error 2. I have checked my config file and have tried practically everything this forum said to and still nothing. I am at a loss. I have changed the permissions to match the old site, fixed the config file, switched over my database and still nothing. Is there anything thing in particular that I could try...I did switch from a main directory site to the new site is now in a sub-directory. Anything that would have to do with that, that I have not changed and need to? Please help. I am desperate.

thanks guys! ;D

dribblit
Joomla! Apprentice
Joomla! Apprentice
Posts: 12
Joined: Wed Mar 15, 2006 7:54 pm

Re: FAQ: This site is temporarily unavailable - database issues

Post by dribblit » Tue Jul 25, 2006 3:56 pm

this error2 problem is pretty close to the last thing i can take from joomla....i've followed all the suggestions in this thread and nothing works. username, password and host all match as they should and to none effect. I developed the site locally, then migrated it to a server in the office. please assist.

User avatar
wensveen
Joomla! Apprentice
Joomla! Apprentice
Posts: 24
Joined: Tue Sep 13, 2005 11:32 am

Re: FAQ: This site is temporarily unavailable - database issues

Post by wensveen » Wed Jul 26, 2006 7:31 am

If you remove the '@' sign before the mysql_connect statements (2 of them) in includes/database.php you'll see the error message from the mysql_connect functions.
If you post that someone (including me) might be able to help you out.

I agree that Joomla's error messages could be more 'message'-like :). However, you can't _demand_ people to help you out in their spare time. If you want that, commercial support might be an option (joomadesk.com for example).

Anyway. Are you sure the database user can connect from the host you are trying to connect from, or any host (%)? Sometimes hosting providers limit the hosts that can connect to localhost only, or a strict list of trusted hosts.

dribblit
Joomla! Apprentice
Joomla! Apprentice
Posts: 12
Joined: Wed Mar 15, 2006 7:54 pm

Re: FAQ: This site is temporarily unavailable - database issues

Post by dribblit » Wed Jul 26, 2006 12:19 pm

So joomla lives to fight another day...i fixed my problem using  MySQL administrator http://dev.mysql.com/downloads/administrator

StartUp Variables >> Security >> check Disable Grant Tables

i found this weird cause i thought it was that the root user had access to all tables by default.

anyway, it worked so see if that will work for you. 1.

alpine jones
Joomla! Fledgling
Joomla! Fledgling
Posts: 4
Joined: Tue Jul 11, 2006 1:30 am

Re: FAQ: This site is temporarily unavailable - database issues

Post by alpine jones » Sun Aug 13, 2006 5:17 pm

I recently moved my site from a subdomain to the domain. Everything was working fine and I left for vacation for a week.  When I got back, error number three is coming up and I cant solve the problem.  I checked the config.php to see the database name and it is correct.  I am really lost where to go next on solving this problem.  Is there anyone who could lead me in the right direction?

cdx
Joomla! Enthusiast
Joomla! Enthusiast
Posts: 148
Joined: Sun Jan 01, 2006 11:44 pm
Contact:

Re: FAQ: This site is temporarily unavailable - database issues

Post by cdx » Thu Sep 07, 2006 3:16 pm

I got Error 2. but it's very wiered.

I saw the website is OFLINE (Without Error 2!) . I thought I got hacked, so I downloaded to see the configuration file - it was somehow, on OFFLINE!!!  $mosConfig_offline = '1'; so I changed it into $mosConfig_offline = '0'; and than I got ERROR 2.

I sent my hosting company an email about that it's probably the connection to the DB.

How can I solve it? I didn't understand after this long thread how to fix it.
Is it a hack ?

Thanks,
Guy

cdx
Joomla! Enthusiast
Joomla! Enthusiast
Posts: 148
Joined: Sun Jan 01, 2006 11:44 pm
Contact:

Re: FAQ: This site is temporarily unavailable - database issues

Post by cdx » Mon Sep 25, 2006 12:25 pm

Site is working fine, suddently error #2 is showing up. This is the second time it's happenning . I can't remember what I did last time .

How come that suddently it's showing up ? Strange, isn't it ?

Guy

garyeqm
Joomla! Explorer
Joomla! Explorer
Posts: 326
Joined: Mon Sep 05, 2005 9:32 am

Re: FAQ: This site is temporarily unavailable - database issues

Post by garyeqm » Mon Nov 13, 2006 11:34 am

I get error 3 but the database details ARE correct !!

flavorgrafix
Joomla! Fledgling
Joomla! Fledgling
Posts: 2
Joined: Fri Nov 11, 2005 7:42 pm

A real SOLUTION: This site is temporarily unavailable - database issues

Post by flavorgrafix » Fri Dec 15, 2006 6:41 pm

I was having the same problem, it seems that the MYsql client is rejecting old passwords on some systems. This is how I fixed it:

Go to your my.ini file in your mySQL directory (e.g., C:\Program Files\MySQL\my.ini), using the Notepad or any editor to open it up.
Add comment out following ignore the text I wrote (between the brackets) :

(this is how it should look before the change)

#Disallow authentication for accounts that have old (pre-4.1) passwords.
secure-auth

(this is how it should look after the change note: I simply added the # symbol to the second line)

#Disallow authentication for accounts that have old (pre-4.1) passwords.
#secure-auth

I hope this helps, I actually just accidentally stumbled upon the solution, I hope it doesn't cause any security vulnerabilities, but at least I got it to work.

"pat myself on the back"

feog
Joomla! Fledgling
Joomla! Fledgling
Posts: 3
Joined: Wed Jan 04, 2006 2:15 am

Re: FAQ: This site is temporarily unavailable - database issues

Post by feog » Fri Dec 22, 2006 2:17 pm

We have run into this problem on our site but it seems to be happening only for some users. While monitoring the database connections on the database, we found that for one of the users that is having problems as he was using the site we could see the number of connections to the database increasing until it reached 21 and then he received the 'site is temporarily unavailable 2' message. The connections to the database disappeared and he was then able to continue working. I am guessing that our mysql server is setup to allow 20 connections.

What is interesting for this user is that the problem only occurs when he connects from one of his computers and not the other. To me this is indicating some browser issue maybe. He is using Firefox.

For users that are not having the problem we only ever see one connection.

I did notice a similar problem from a user post last November. Does anyone have any ideas what is causing this??

Thanks

User avatar
joseph21
Joomla! Enthusiast
Joomla! Enthusiast
Posts: 172
Joined: Fri Jul 07, 2006 2:39 am

Re: FAQ: This site is temporarily unavailable - database issues

Post by joseph21 » Tue Jan 23, 2007 6:20 am

Hello,

Recently our host got down. My J site is fine the first day after the host is back online. But the second day, I receive "site is temporarily unavailable". I didn't touch anything, and the host said they were planning to move to another server but in the same data center. They have also changed their name servers.

I wonder if it is the nameserver causing this problem or the crawls to my site? I got google, yahoo. iktomi slurp, and two unkown crawlers.

Helps guys.

denali
Joomla! Apprentice
Joomla! Apprentice
Posts: 17
Joined: Fri May 19, 2006 5:44 pm
Location: Lawrence, KS
Contact:

Re: FAQ: This site is temporarily unavailable - database issues

Post by denali » Thu Jan 25, 2007 6:42 pm

If you are getting error #2, are running Linux and have SELinux installed (e.g. Fedora Core), make sure your SELinux policy allows access to /var/lib/mysql.  If it doesn't, your Joomla! site will NOT connect to the MySQL server.
I bite.  Hard.

cyfarian
Joomla! Apprentice
Joomla! Apprentice
Posts: 25
Joined: Wed Jan 31, 2007 12:24 pm

Re: FAQ: This site is temporarily unavailable - database issues

Post by cyfarian » Wed Jan 31, 2007 12:29 pm

Hello,
I am new to Joomla and so far LOVE IT!  Yesterday I install Fabrik  and reMOSitory and they worked beautifully.  I set up a few simple forms.  Now today, when I go into the admin interface for Fabrik, everything works fine EXCEPT when I click on the ELEMENTS link.  Then this error appears:

DB function failed with error number 1
Can't create/write to file '/var/tmp/mysql/#sql_329d_0.MYI' (Errcode: 2) SQL=SELECT *,u.name AS editor, jos_fabrik_elements.id AS id, jos_fabrik_elements.checked_out AS checked_out, jos_fabrik_elements.checked_out_time AS checked_out_time, jos_fabrik_elements.state as state FROM jos_fabrik_elements LEFT JOIN jos_fabrik_groups ON jos_fabrik_elements.group_id = jos_fabrik_groups.id LEFT JOIN jos_fabrik_elementtypes ON jos_fabrik_elements.elementtype_id = jos_fabrik_elementtypes.elementtype_id LEFT JOIN jos_users AS u ON jos_fabrik_elements.checked_out = u.id ORDER BY jos_fabrik_groups.id, jos_fabrik_elements.ordering LIMIT 0, 30
Fabrik 1.0 created by pollen 8

I read this entire discussion and it seems that people are receiving the DB failed as a message for the entire site.  Mine is just for this page.  The front end is working fine and I can submit the forms with no problems.  Any ideas?  It was working last night when I went to bed, but not now.

Thanks!
Last edited by cyfarian on Wed Jan 31, 2007 1:52 pm, edited 1 time in total.

cyfarian
Joomla! Apprentice
Joomla! Apprentice
Posts: 25
Joined: Wed Jan 31, 2007 12:24 pm

Re: FAQ: This site is temporarily unavailable - database issues

Post by cyfarian » Wed Jan 31, 2007 1:53 pm

Weird....it works fine now.  An hour ago it didn't.  I didn't make any changes either.  huh.

vitorg
Joomla! Apprentice
Joomla! Apprentice
Posts: 9
Joined: Tue Jan 02, 2007 1:02 pm

Re: FAQ: This site is temporarily unavailable - database issues

Post by vitorg » Sat Feb 24, 2007 12:49 am

I had a Joomla installation that was running fine.
After I upgraded PHP 4 to 5 I'm getting Error #1.

PHP works fine and MySQL is installed and running.
Can someone give me a hint on where should I look? I guess it must be some configuration problem but where?

Thank you for your time.

vitorg
Joomla! Apprentice
Joomla! Apprentice
Posts: 9
Joined: Tue Jan 02, 2007 1:02 pm

Re: FAQ: This site is temporarily unavailable - database issues

Post by vitorg » Sat Feb 24, 2007 2:32 pm

It seems that in PHP 5, MySQL is no longer enabled by default (http://www.php.net/mysql) so I had to reinstall php with the option '--with-mysql=/usr'
I had previously installed only '--with-mysql'.

Works fine now.

Zardoz
Joomla! Apprentice
Joomla! Apprentice
Posts: 32
Joined: Mon Jan 16, 2006 3:59 am
Location: USA
Contact:

Re: FAQ: This site is temporarily unavailable - database issues

Post by Zardoz » Sun Mar 11, 2007 8:42 pm

I had a problem with the 'Could not connect to the database' message for my two Joomla! sites after using fantastico in cpanel to upgrade from 1.0.8 to 1.0.12 because my hosting provider skipped the other releases for some reason. The problem didn't show up immediately, so the upgrade may be coincidental and not the actual source of the issue.

The solution for me turned out to be re-adding the user to the database with all permissions. Because cpanel said they already existed, I expected to get a 'user already exists' message of some sort, but I did not. I think it must have forced some sort of update to the user info in MySQL.

I don't really know why, but both sites are now up and running and appear to be trouble-free.  :D

User avatar
ferrazf
Joomla! Enthusiast
Joomla! Enthusiast
Posts: 120
Joined: Fri Jan 26, 2007 8:23 pm

Re: FAQ: This site is temporarily unavailable - database issues

Post by ferrazf » Tue Mar 13, 2007 5:02 pm

Here we go, my turn to have this problem. I moved from a shared host to an unmanaged dedicated, and here's what I get:

This site is temporarily unavailable.
Please notify the System Administrator
Could not connect to the database server

I do not get the number 1 2 or 3 like the others get. Maybe I'm missing something.

I deleted the @'s before the mysql_connects in /includes/database.php, and I get these errors at the top:
"Warning: mysql_connect(): Access denied for user 'ferrazf_joom1'@'localhost.localdomain' (using password: YES) in /home/ferrazf/public_html/includes/database.php on line 82

Warning: session_start(): Cannot send session cache limiter - headers already sent (output started at /home/ferrazf/public_html/includes/database.php:82) in /home/ferrazf/public_html/offline.php on line 25"
The user ferrazf_joom1 is the one that configuration.php calls for, and I gave that user full database permissions. I tried localhost and 127.0.0.1 in configuration.php.

Any ideas? Thanks

wiggywag
Joomla! Apprentice
Joomla! Apprentice
Posts: 9
Joined: Thu May 25, 2006 10:09 am

Re: FAQ: This site is temporarily unavailable - database issues

Post by wiggywag » Mon Apr 02, 2007 1:08 pm

We have run into this problem on our site but it seems to be happening only for some users. While monitoring the database connections on the database, we found that for one of the users that is having problems as he was using the site we could see the number of connections to the database increasing until it reached 21 and then he received the 'site is temporarily unavailable 2' message. The connections to the database disappeared and he was then able to continue working. I am guessing that our mysql server is setup to allow 20 connections.

What is interesting for this user is that the problem only occurs when he connects from one of his computers and not the other. To me this is indicating some browser issue maybe. He is using Firefox.

For users that are not having the problem we only ever see one connection.

I did notice a similar problem from a user post last November. Does anyone have any ideas what is causing this??

Thanks

I solved the same problem after disconnencting a macintosh firefox user. When he was logged in, it happened all the time. Now suddenly the error message appeared again, with one that have not had problems before, also macintosh firefox user. Wondering if this happens with other browsers? any experience on this.

MY QUESTION IS: Is there a problem with Joomla not disconnectiong mysql connections properly?

This is what my host said:
If you received a max_user_connections error as indicated before this only occurs when your scripts hang database connections,  I am not entirely sure if you expect us to remove this limit, which would mean that your script would hang all of the available connections which in turn would then cause problems for every single user on the server.  mySQL is designed to timeout connections and this is very effective however no matter how mySQL is configured if your script is going to continually hang connections then theres a problem with the script, not the server.

"Actually this is a big issue for me which I need a solution for. Please give me a useful response to this!"

There is no solution from our end,  our servers are configured perfectly fine and have absolutely no problems what so ever.  The only way to fix having max_user_connection errors is to simply stop hanging database connections from your scripts, by either using different scripts or recoding them to close connections efficiently.

stamina
Joomla! Apprentice
Joomla! Apprentice
Posts: 13
Joined: Mon Mar 05, 2007 4:47 pm

Re: FAQ: This site is temporarily unavailable - database issues

Post by stamina » Wed Apr 04, 2007 3:34 pm

hi

my site can't connect to the database. after the upload,
is there any other file you need to edit apart from the configuration.php  ???
maybe I'm missing something :)

thank you

kryps
Joomla! Intern
Joomla! Intern
Posts: 76
Joined: Mon Oct 16, 2006 8:19 pm

Error #2

Post by kryps » Thu Apr 05, 2007 5:16 pm

Error #2:

For anyone who feels their setup is fine, and everything was working before -- check to make sure the DB user account is setup properly, assigned permissions properly to your DB, and user's password.

At one point, I screwed up the DB user account I created with a copy/paste mistake -- left it for a while, and when I came back, I forgot about how I screwed up that account.  Took me a while to figure it out, because Joomla doesn't give specific error message saying that the user account couldn't login.  Instead, the error message says "2", which means "Couldn't connect to the database".  But it was connecting, just the DB user account was messed up.

stamina
Joomla! Apprentice
Joomla! Apprentice
Posts: 13
Joined: Mon Mar 05, 2007 4:47 pm

Re: FAQ: This site is temporarily unavailable - database issues

Post by stamina » Fri Apr 06, 2007 1:51 am

working!
for some reason, I had to upload the whole site again and it's working fine! :)
I was missing the CHMOD permissions.
solved for me

easy :)

ODTV
Joomla! Apprentice
Joomla! Apprentice
Posts: 40
Joined: Fri Sep 22, 2006 12:43 am
Contact:

Re: FAQ: This site is temporarily unavailable - database issues

Post by ODTV » Sat May 12, 2007 1:26 am

I got the error 2 also, connect to database failed.  i tried everything i could understand in this topic and nothing worked.  i decided to make a new connection.  i went to mySQL in my cPanel, created a new DB user, added that user to my joomla database.  next i went to the config.php file and changed 2 things, username and password.  my site was back up instantly.  the only concern left is with the password.  will it encrypt itself again once i start using the admin.?
My internet Tv website www.oceandigital.tv

tony121
Joomla! Fledgling
Joomla! Fledgling
Posts: 2
Joined: Mon Oct 23, 2006 1:26 pm

Re: FAQ: This site is temporarily unavailable - database issues

Post by tony121 » Tue Jul 17, 2007 5:08 pm

I got the error 2 scare, read and tried the possible solutions that were posted, but no luck.  But they lead me in the right direction, so here's my solution for future ppl who are frantically reading this thread for help.

I changed the $mosConfig_host to actual IP # of the mySQL host.  The previously mentioned localhost and 127.0.0.1 are basically the same thing that may be routed to actual SQL server.  Your host's Control Panel should list the SQL host name (something like mysql.hostname.com).  If you're lucky it will also list the IP #, otherwise ask your host for actual #. 

I also have a ticket in with my host b/c the host name, host IP #, localhost, and 127.0.0.1 should all end up at the same SQL server, so there must be a routing problem somewhere.  This is especially the case if this problem just pops up, and is not due to a new install or some other recent update.

Well, if you are reading this, Good Luck  ;)

parabara
Joomla! Enthusiast
Joomla! Enthusiast
Posts: 103
Joined: Mon Jun 19, 2006 1:34 am
Location: Nepal
Contact:

Re: FAQ: This site is temporarily unavailable - database issues

Post by parabara » Mon Jul 23, 2007 1:57 am

I suddenly got the error message ! I am getting same message on my other sites.

DB function failed with error number 1
Can't create/write to file '/tmp/#sql_1db1_0.MYD' (Errcode: 17) SQL=SELECT c.*, g.name AS groupname, cc.name, u.name AS editor, f.content_id AS frontpage, s.title AS section_name, v.name AS author FROM jos_content AS c LEFT JOIN jos_categories AS cc ON cc.id = c.catid LEFT JOIN jos_sections AS s ON s.id = c.sectionid LEFT JOIN jos_groups AS g ON g.id = c.access LEFT JOIN jos_users AS u ON u.id = c.checked_out LEFT JOIN jos_users AS v ON v.id = c.created_by LEFT JOIN jos_content_frontpage AS f ON f.content_id = c.id WHERE c.state >= 0 AND c.catid = cc.id AND cc.section = s.id AND s.scope = 'content' ORDER BY s.title, c.catid, cc.ordering, cc.title, c.ordering LIMIT 30


I have set the tmp writable !

Please help me

Thanks
Joomla Web site development in Nepal with SEO http://seonepal.com/web-design-nepal/cm ... esign.html

estado3
Joomla! Fledgling
Joomla! Fledgling
Posts: 3
Joined: Fri Nov 10, 2006 11:52 am

Re: FAQ: This site is temporarily unavailable - database issues

Post by estado3 » Sat Aug 04, 2007 1:50 pm

I recently reinstalled mysql (just on my home computer on windows, I am using mysql 4.1, php5, and apache 2.0.59), I understand that since I reinstalled mysql and
deleted the previous version, that my database might be gone, so when I opened up my
local computer's version of joomla, I received this site is temporary down, pls
contact the admin msg, with an error number of 3, I understand this means the
database cannot be found, looking at the configuration.php file, I manually
created the database name, as well as the database user and granted all privileges to them, and I am still met with the same error but this time with
number 2, I have tried to reinstall joomla but I am met with "restricted access",
strangely I have been unable to find the joomla version running on my localhost on the net
(version 1.0.11). Is there a simple step I am missing in getting the admin and index pages working again?  Or failing that where I can download joomla 1.0.11 again?

NB:  Also what is the best application to mirror your localhost on a server, i.e
whatever I have done on my localhost, that I would like mirrored on the server,
with an automatic ftp transfer?
Last edited by estado3 on Sat Aug 04, 2007 1:52 pm, edited 1 time in total.


Locked

Return to “FAQ Discussion Board”