Can't log in, start Management Server: dead database?

We are running Avast 4.7 server edition on a W2K3 server, and I had reason today to check the logs for a user who had Avast ask to restart his laptop. To make this short, I have encountered the “No connection could be made because the target machine actively refused it” error while logging in. The Avast Management Server service refuses to start, apparently because it can’t talk to the database to verify the login. It can’t talk to the database because the database is corrupt or the ODBC (?) connection is missing. I’ve skimmed previous posts on this and listed answers to some common questions:

  1. When starting the Management Server, Event Viewer lists the %%42000 error.
  2. Using the Maintenance Tool, “Check DB” says “AMS database is not compatible! (0x0000A410) […] Cannot initialize data source, error 0x80040E4D”. Other buttons like “Check DB” and “Delete DB” return “Cannot initialize data source, error 0x80040E4D, Cannot check whether database exists: error 42000”. Deleting (actually moving/renaming) the .mdf and .ldf files manually doesn’t work, because the communication glue (ODBC?) is missing.
  3. The database is running through MSDE. That’s what the readme file in the directory says.
  4. Two database services appear to be running: MSSQL$AVAST and SQLAgent$Avast.
  5. All the files in the MSSQL$AVAST directory are time-stamped the time I originally took Avast down, except for the avast.mdf and avast_log.ldf files, which are stamped roughly 7 hours earlier, at 12:42. Perhaps this is when the trouble started?

Now we do keep backups, but I’m not sure what to restore. I couldn’t find a Knowledge Base document that explains how Avast fits together. Part of the problem is that while I do some network administration here, I didn’t install and configure Avast. That employee no longer works here.

Comments, anybody? Given the day and time I’m posting this, I may have my own solution before getting an official reply. But I’d prefer to not reinstall everything from scratch. And can anyone guess what made the database system implode??

Thanks!

BTW, self-repair options don’t work either. Repairing the Management Tools results in an “Error removing database 0x0000A410” message and these lines at the end of the log:

04.01.2008 21:47:37 system: *: Going to check version of database of avast! on MS SQL Server “MAINFS01\avast”, using user “sa”…
04.01.2008 21:47:37 system: Cannot initialize data source, error 0x80040E4D…
04.01.2008 21:47:41 system: *: Going to drop database of avast! on MS SQL Server “MAINFS01\avast”, using user “sa”…
04.01.2008 21:47:41 system: Cannot initialize data source, error 0x80040E4D…
04.01.2008 21:47:41 system: Going to create database of avast! on MS SQL server “MAINFS01\avast”, using user “sa”…
04.01.2008 21:47:41 system: Cannot initialize data source, error 0x80040E4D…
04.01.2008 21:47:41 system: Error removing database: 0x0000a410

Self-repairing the other services generates a password prompt, which I assume fails because there’s still no database to verify the login…

Fixed this myself. It was apparently a dead database. There were no backups, so I installed ADNM on another computer and copied the database files by hand. Only then did I find the Database Backup task. :frowning: But it’s still good, as Avast is now configured better than before…