If your server PC shuts down unexpectedly (forced shutdown), it may corrupt your Maria DB. 

If your hard drive is full, it can also corrupt the database as well. 

You can check if your server PC went through a forced shutdown by checking the Windows event viewer. 

The cause may be loss of power or forced shutdown by a user. 

The result is that your BioStar Service will not start because the database is corrupted. 

The service button may appear as 'Error' as below 

Or the BioStar 2 service will stop 1 second after you click Start because Maria DB Service cannot start.

Below is a instance where the database file is corrupted because of a forced shutdown. 

In such cases you can try the solution shown below.

Database Restoration Option

This method may work for some users if past system logs are still available. If this does not work, you will have to proceed with the re-installation option. 

1. Download the attachment files (my.cnf and my.normal.cnf)

2. Open the following folder:

C:\Program Files\BioStar 2(x64)\ta\mariadb-10.1.10-winx64

3. Copy the downloaded my.cnf and overwrite the my.cnf file in the opened folder.

4. Start the BioStar 2 Maria DB service in services.msc. 

* you can search services.msc after clicking the windows start button 


4. Wait 3 minutes. 

5. Stop the BioStar 2 MariaDB service. 

6. Download and copy the my.normal.cnf file. 

7. Paste the file in the opened folder (C:\Program Files\BioStar 2(x64)\ta\mariadb-10.1.10-winx64)

8. Delete the my.cnf file.

9. Change the name of my.normal.cnf to my.cnf. 

10. Start BioStar 2 MariaDB service again in services.msc

11. Open BioStar Setting and start all services


12. Try logging in to BioStar 2 and see that it is working properly. 

Re-installation Option

If the above solution does not work and you do not have a backup of your database, you cannot use MySQLWorkbench backup method as shown in the following link: [BioStar 2] Database Backup and Restore Instructions because Maria DB service will not start. 

In such cases you can use the following instructions to back up your database: [BioStar 2] Script / Manual Database Backup

Follow the steps below to resolve your issue: 

1. Confirm that the hard drive and Windows system files have no issues (you can run a program like Windows sfc). 

2. Back up your database as shown in [BioStar 2] Script / Manual Database Backup.

3. Delete BioStar 2. 

4. Install BioStar 2. 

5. Restore your database following the instructions of : [BioStar 2] Script / Manual Database Backup.

Clean Install Option

You would go with this option if your situation is the following
1. Above options aren't working for you

2. You are not using Maria DB 

In that case follow the steps below to restore your server. 

1. Delete BioStar 2 completely (click Yes when popups appear when you are deleting it).  
* For MSSQL, delete your database in SQL Management Studio because the uninstall will not delete the database. 

2. Install BioStar 2. 

3. Connect your devices to the server. 

4. Upload the users from the device to the server
** Caution: Entry level devices and BioEntry W2 will not be able to upload the user names because the device does not store names.

5. Reconfigure the following items: 

T&A, Access Groups, Doors, User Groups, Zone, Video and other server configurations.