If you manually created a backup of your Lansweeper installation, you can always restore it at a later date if necessary. Which restore procedure you should follow depends on which database server you are using, Microsoft SQL Compact or Microsoft SQL Server. If you perform an Easy Install, your database is hosted in SQL Compact. If you perform an Advanced Install, your database can be hosted in SQL Compact or SQL Server. If you are unsure which database server you are using, browse to the following section of the web console: Configuration\Your Lansweeper License

Restoring a backup if you are using SQL Compact
To restore your installation from a backup if your database server is SQL Compact, do the following:
- Stop the Lansweeper Server service in Windows Services
- Stop your web server service in Windows Services. Keep in mind that this will log everyone out of the console. Your web server service is either IIS Express or World Wide Web Publishing Service (IIS).
- Make sure your database backup file is called lansweeperdb.sdf and place it in the following folder, overwriting the database file currently present in the folder:Program Files (x86)\Lansweeper\SQLData
- Restore the Website subfolders and Encryption.txt file you created a backup of.
- Restart the Lansweeper and web server services in Windows Services.
Restoring a backup if you are using SQL Server
To restore your installation from a backup if your database server is SQL Server, do the following:
- Stop the Lansweeper Server service in Windows Services
- Stop your web server service in Windows Services. Keep in mind that this will log everyone out of the console. Your web server service is either IIS Express or World Wide Web Publishing Service (IIS).
- Right-click the lansweeperdb database in SQL Server Management Studio and select Tasks\Restore\Database... to open the restore wizard. If SQL Server Management Studio isn't installed on your Lansweeper server, we recommend downloading it online. (You will need to perform a search for the Management Studio that's compatible with your particular edition and version of SQL Server.)
- In the General tab of the restore wizard, select the correct destination (lansweeperdb) and source for the restore operation. If your backup is a .bak file, select the Device option under Source and hit the button with the three dots to open a popup where you can select your file.
- In the Options tab of the restore wizard, tick Overwrite The Existing Database. Hit OK to perform the database restore.
Make sure the overwrite box is checked. Otherwise, the following error may be generated: "The backup set holds a backup of a database other than the existing 'lansweeperdb' database."
- Execute the script below in SQL Server Management Studio to reset the lansweeperuserIf you install Lansweeper under SQL Server, by performing an Advanced Install, the installer automatically... SQL user used by the Lansweeper service and web console to connect to the database. Replace what's marked in bold with the password you want to set for lansweeperuser, leaving the single quotes in the script./* Makes sure there are no objects in the lansweeperuser schema, so the lansweeperuser SQL user can be reset */
USE lansweeperdb
GO
DECLARE c_ALTSCHEMA CURSOR FOR
SELECT 'ALTER SCHEMA dbo TRANSFER lansweeperuser.'+name +';'
FROM sys.objects
WHERE SCHEMA_NAME(SCHEMA_ID) = 'lansweeperuser'
DECLARE @SQLStmt NVARCHAR(200)
OPEN c_ALTSCHEMA
FETCH NEXT FROM c_ALTSCHEMA INTO @SQLStmt
WHILE @@FETCH_STATUS = 0
BEGIN
EXEC(@SQLStmt)
FETCH NEXT FROM c_ALTSCHEMA INTO @SQLStmt
END
CLOSE c_ALTSCHEMA
DEALLOCATE c_ALTSCHEMA
GO/* Resets the lansweeperuser SQL user */
USE lansweeperdb
GO
DROP SCHEMA lansweeperuser
GO
DROP USER lansweeperuser
GO
EXECUTE sp_droplogin lansweeperuser
GO
USE MASTER
GO
EXEC sp_addlogin 'lansweeperuser', 'lansweeperuserpassword', 'lansweeperdb', [English]
GOUSE lansweeperdb
GO
EXEC sp_grantdbaccess 'lansweeperuser', 'lansweeperuser'
GO
EXEC sp_addrolemember [db_owner], 'lansweeperuser'
GODon't skip this step! Restoring a database backup almost always corrupts the SQL user used by the Lansweeper service and web console to connect to the database. If you don't reset the user, the service and web console will be unable to connect to the database.
- Run the following tool on the server(s) hosting your Lansweeper Server service and web console:Program Files (x86)\Lansweeper\Tools\ConfigEditor.exe
- Click through any warnings the tool may be giving you about your password being incorrect.
- Select the Password field and hit the Edit button.
- Submit the same password you previously used in the database script and hit the Save button.
- If the ConfigEditor tool has multiple tabs due to your server hosting multiple Lansweeper components, select the other tab, click through any warnings and repeat the password changing process.
- Restore the Website subfolders and Encryption.txt file you created a backup of.
- Restart the Lansweeper and web server services in Windows Services.
- If you have multiple scanning servers, update the database password on those servers as well by stopping the Lansweeper service, using the ConfigEditor tool and restarting the service.