View Full Version : Can't Login After Update
samuch
26th May 2007, 17:14
Just ran the update and it appeared to install fine. However when I go to https://www.sitename.com:81 and attempt to use my admin login it fails.
I noticed I'm now getting this when I start the server:
Ok: Pass Phrase Dialog successful.
/root/ispconfig/httpd/bin/apachectl startssl: httpd started
shell-init: error retrieving current directory: getcwd: cannot access parent directories: No such file or directory
Warning: mysql_fetch_array(): supplied argument is not a valid MySQL result resource in /root/ispconfig/scripts/lib/config.inc.php on line 47
No results found!ISPConfig system is now up and running!
I'm guessing this is the root of the problem. Any thoughts?
Thanks in advance.
samuch
27th May 2007, 16:18
Does anyone have any thoughts or has anyone else experienced this? I'm quite stuck if I can't add or maintain any of my sites. Any thoughts are appreciated.
Thanks.
falko
27th May 2007, 17:30
Did you get any errors during the update?
Can you check if the ISPConfig database exists?
samuch
28th May 2007, 17:44
There were no errors during the update until the very end when it started the services and gave the error I listed.
Do you know the link to phpmyadmin for the default install? I can't remember it as I usually logged in as admin and then clicked the link.
samuch
29th May 2007, 04:29
Anyone have any thoughts? Would it hurt if I ran the setup again just in case something didn't go through? I surely don't want to do any damage but it's important that I get back in.
Do you have the backups in /tmp that were created automatically during the update? It must be 2 tar.gz files and 1 .sql file.
samuch
29th May 2007, 14:31
Do you have the backups in /tmp that were created automatically during the update? It must be 2 tar.gz files and 1 .sql file.
I see home_admispconfig_05_26_2007__09_05_45.tar.gz and root_ispconfig_05_26_2007__09_05_45.tar.gz and existing_db_05_26_2007__09_05_45.sql.
samuch
30th May 2007, 05:10
I figured out the phpmyadmin address and logged in to look for the database. All my databases are there EXCEPT "ispconfig". I checked the config.inc.php to make sure it was looking for this database and it is.
I ran a mysqlcheck on the database and it says "Unknown database".
Why would this database have disappeared? Also, how could the sites be running if the database is gone? How do I restore the database from the backup made when I upgraded?
falko
30th May 2007, 17:15
I see home_admispconfig_05_26_2007__09_05_45.tar.gz and root_ispconfig_05_26_2007__09_05_45.tar.gz and existing_db_05_26_2007__09_05_45.sql.
You can restore /home/admispconfig/ from home_admispconfig_05_26_2007__09_05_45.tar.gz and /root/ispconfig/ from root_ispconfig_05_26_2007__09_05_45.tar.gz.
The ISPConfig db can be restored from existing_db_05_26_2007__09_05_45.sql like this: http://www.howtoforge.com/faq/6_4_en.html
Also, how could the sites be running if the database is gone?The web sites have nothing to do with the database. The datbase is used by ISPConfig to write the configuration files; once that's done the web sites works regardless if there's an ISPConfig database or not.
samuch
31st May 2007, 04:42
New problem. I went to import the last database backup and noticed nothing was imported. I looked in the backup file and this is all that was there:
-- MySQL dump 10.10
--
-- Host: localhost Database: ispconfig
-- ------------------------------------------------------
-- Server version 5.0.26
/*!40101 SET @OLD_CHARACTER_SET_CLIENT=@@CHARACTER_SET_CLIENT */;
/*!40101 SET @OLD_CHARACTER_SET_RESULTS=@@CHARACTER_SET_RESULTS */;
/*!40101 SET @OLD_COLLATION_CONNECTION=@@COLLATION_CONNECTION */;
/*!40101 SET NAMES utf8 */;
/*!40103 SET @OLD_TIME_ZONE=@@TIME_ZONE */;
/*!40103 SET TIME_ZONE='+00:00' */;
/*!40014 SET @OLD_UNIQUE_CHECKS=@@UNIQUE_CHECKS, UNIQUE_CHECKS=0 */;
/*!40014 SET @OLD_FOREIGN_KEY_CHECKS=@@FOREIGN_KEY_CHECKS, FOREIGN_KEY_CHECKS=0 */;
/*!40101 SET @OLD_SQL_MODE=@@SQL_MODE, SQL_MODE='NO_AUTO_VALUE_ON_ZERO' */;
/*!40111 SET @OLD_SQL_NOTES=@@SQL_NOTES, SQL_NOTES=0 */;
Any thoughts on why this would have been emptied? Am I pretty much screwed? Is there anyway to save this? I appreciate all the help so far. I'm getting pretty nervous.
Do you have any backups of your mysql databases?
samuch
1st June 2007, 06:36
Do you have any backups of your mysql databases?
I do have one from March, the last time I updated. But when I go to import it it tells me all the tables don't exist. I'm not sure of what the table structures are so I can't manually create them all and then try to import. Am I missing something on the import? Is it not able to create all the tables as it imports?
Is there any way to create email accounts for site that already exist via command line? I'm pretty stuck if I can't get some emails up by the morning.
Thanks for all the help so far and PLEASE help me get this back up and going. PLEASE.
If you do not have a backup of the data structure, you can get the data structure from the sql database dump that is in the ispconfig installer tar.gz file.
You can not craete email addresses on the command line that can later be used from within ISPConfig.
samuch
2nd June 2007, 22:55
I went ahead and populated the DB using the db_ispconfig.sql file in the install folder. I then imported my sql dump from March. It didn't go very smooth but I got it all in gradually.
However, it appears that it reset my admin login password to admin. I can now login to https://sitename.com:81/admin with admin:admin however none of my clients, or sites are listed here. It's as if it's a new installation.
If I go to Management > Server > Settings I can see those settings are proper but like I said, no sites are listed at all.
Any ideas on how to fix this?
If you do not have a backup of the data structure, you can get the data structure from the sql database dump that is in the ispconfig installer tar.gz file.
You can not craete email addresses on the command line that can later be used from within ISPConfig.
However, it appears that it reset my admin login password to admin. I can now login to https://sitename.com:81/admin with admin:admin however none of my clients, or sites are listed here. It's as if it's a new installation.
Then you either did not import your backup or your backup was empty.
samuch
3rd June 2007, 15:04
If I look in the database itself I can see some of my sites and users so it's not empty. I looked at the backup file as well and confirmed it's not empty.
Is it possible that after I login it's not reading from the correct spots in the database?
Then you either did not import your backup or your backup was empty.
falko
4th June 2007, 18:56
Please do not import the db_ispconfig.sql file. I suggest to restore your database from your SQL dump from March only.
samuch
4th June 2007, 19:01
I was not able to import the March SQL dump as there was no database structure yet. Without the structure it was not able to do simple inserts.
Should the March dump be able to recreate the structure?
Please do not import the db_ispconfig.sql file. I suggest to restore your database from your SQL dump from March only.
falko
5th June 2007, 20:42
Should the March dump be able to recreate the structure?
I'm not sure right now. If it doesn't, you can take the structure from db_ispconfig.sql, but please do not use the INSERTs from that file.
samuch
11th June 2007, 15:18
I was able to get the backup database restored by taking the db_ispconfig.sql file and stripping out all the INSERT commands to rebuild the database, then I imported the March backup file I had.
Now I can login and see sites. However, the backup that attempted when I ran the initial update did not complete so I'm looking back 3 months. This means I have two sites on the server that aren't showing up in ISPConfig.
Is there a way for me to manually add those sites into ISPConfig so I can continue administering them?
Thank you very much for your help in getting the database back up!
samuch
11th June 2007, 15:19
I spoke too soon. I can see the sites in the menu on the left but when I click on them to administer I get the message "The following error occurred:
The requested document type does not exist."
Any thoughts?
I was able to get the backup database restored by taking the db_ispconfig.sql file and stripping out all the INSERT commands to rebuild the database, then I imported the March backup file I had.
Now I can login and see sites. However, the backup that attempted when I ran the initial update did not complete so I'm looking back 3 months. This means I have two sites on the server that aren't showing up in ISPConfig.
Is there a way for me to manually add those sites into ISPConfig so I can continue administering them?
Thank you very much for your help in getting the database back up!
samuch
11th June 2007, 15:55
I ran the update for the latest version of ISPConfig and that took care of this error. Now I just have to get my sites that weren't in the backup db imported.
I spoke too soon. I can see the sites in the menu on the left but when I click on them to administer I get the message "The following error occurred:
The requested document type does not exist."
Any thoughts?
farao
19th December 2007, 12:29
Hi all,
I have this exact same problem: database disappeared, I restored a backup, ISPConfig system is up and running, but when trying to manage stuff, I get the error "The requested document type does not exist".
Reinstallation of version 2.2.18 did not solve my problem, it made the database disappear again. All users still exist and can get mail and web, but administration through ISPConfig is impossible.
Please help.
Farao
EDIT: searching through the forum tought me I need to have MySQL talk LATIN. In PHPMyAdmin, it says MySQL Charset UTF-8. How do I switch it back, and will that solve my problem?
EDIT 2: I have the following errors in my ispconfig_install.log:
WARNING: could not dump old db to existing_db.sql
WARNING: could not read in existing_db.sql
WARNING: could not import existing_db.sql
falko
20th December 2007, 17:09
Did you restore the ISPConfig database from a backup (e.g. as shown here: http://www.howtoforge.com/faq/6_4_en.html )?
farao
21st December 2007, 11:54
Yes I did, twice already. All the data is in there, it's just the document type error when I want to add sites or modify them.
Can I safely remove and reinstall ISPConfig with a backup of the database, or are there more files I need to backup?
falko
22nd December 2007, 16:44
You can try to update ISPConfig (i.e., simply install 2.2.18 again). The installer detects that ISPConfig is already installed and performs an upgrade. In the course of this upgrade the document types will be replaced.
farao
23rd December 2007, 09:16
Like I wrote in my first post, a reinstall of 2.2.18 did not solve my problems. I'm guessing it must have something to do with de characterset, but I'm not sure how to change it.
The steps I took:
- first database restore (no solution)
- reinstall 2.2.18 (no solution)
- second database restore (no solution)
- changed my.cnf (added character_set_server=latin1, no solution)
- removed ispconfig database, made latin1 database through phpmyadmin, third restore (no solution).
I use Ubuntu 6.06, Perfect Setup, upgraded through the package manager, and I did an upgrade of MySQL in that process. Can it be that MySQL somehow defaults to UTF8 now?
When will ISPC work with UTF8?
I'm thinking of migrating to a ubuntu 7.10 server, is that advisable?
Thanks for the help,
Farao
vBulletin® v3.8.4, Copyright ©2000-2009, Jelsoft Enterprises Ltd.