Troubleshooting backup and restoration issues

Get all the help that you need

ServiceDesk PlusSupport TroubleshootingBackup and restoration issues
  • 1. Duplicate entry while restoring data

    Cause:

    When inserting a word in mssql with trailing space like "service desk", the word is inserted as it is. However, when inserting the same word in mysql, the word "service desk " is trimmed as "servicedesk".

    Also, non English characters (characters with dot / double dot on top of words) might be taken differently across databases. Hence inserting those words could also cause this issue.

    Error Trace in logs:

    At times while restoring data duplicate entry error may occur and the restore process is stopped. The error contains the name of the table which has the duplicate entry i.e., Table name = word occurrences. This table has to be ignored while restoring the data.

    Example trace:

    Please wait ! Restoring in Progress...................

    0-----------------------50------------------------100(%)

    ============QUERY = INSERT INTO ComponentDefinition (COMPONENTID, COMPONENTNAME, MANUFACTURERNAME, COMPONENTTYPEID, PARTNO, COMMENTS) VALUESnull

    java.sql.BatchUpdateException: null, message from server: "Duplicate entry 'SATELLITE A100' for key 2"

    at com.mysql.jdbc.Statement.executeBatch(Statement.java:1057)

    at com.adventnet.servicedesk.tools.RestoreSDBackup.restoreTableData(RestoreSDBackup.java:404)

    Solution:

    1. Step 1: Go to the bin directory from the command prompt C:\Adventnet\Me\Servicedesk\bin
    2. Step 2: Edit the restoredata.bat by using the command.
    3. Step 3: On opening the restoredata.bat file, edit the below entry

      %JAVA% %JAVA_OPTS% -Xms128m -Xmx512m -cp %CLASS_PATH% com.adventnet.servicedesk.tools.RestoreDialog %1 %2 to %JAVA% %JAVA_OPTS% -Xms128m -Xmx512m -cp %CLASS_PATH% -Dsdp.restore.error.ignoretables=Errortable name com.adventnet.servicedesk.tools.RestoreDialog %1 %2

      NOTE: Replace Error table name with the table name with the duplicate entry (ie) in our case the table name = wordoccurrences

      Example:

      %JAVA% %JAVA_OPTS% -Xms128m -Xmx512m -cp %CLASS_PATH% -Dsdp.restore.error.ignoretables=wordoccurrences com.adventnet.servicedesk.tools.RestoreDialog %1 %2

    4. Step 4: Now try to restore the data again. The data should get restored.

    2. Connection Rest or Communication link failure error while performing backup.

    Cause:

    The ServiceDesk Plus database file namely ibdata file would have got corrupted.

    Error trace in logs:

    While taking backup Connection Reset or Communication link failure error while taking the backup.

    Solution:

    1. Take a Forced Backup (applicable only for MYSQL).
    2. Append --innodb_force_recovery=4 to Startdb.bat script under Servicedesk[home]/bin as shown in the image.
    3. ServiceDesk Plus backup scheduling errors
    4. Try performing a backup again.

      Note: You will not be able to start ServiceDesk Plus when you have appended this keyword to Startdb.bat script. After performing the backup remove the entry from the file.

    5. On taking the backup, you can either un-install or reinstall ServiceDesk plus and then restore the data. Or, you can try the following steps to save time.
    1. Go to the following location in your installation ServiceDesk Home\mysql\data
    2. Rename all the files and folder except the mysql and test folder.
    3. Go to the command prompt and start the application using the RUN command. All the containers should be created and this is equivalent to a fresh installation of ServiceDesk Plus.
    4. Restore the data and perform the backup.

    Information required for further analysis:

    Zip the mysql folder under C:\AdventNet\ME\ServiceDesk and upload to us.

    3. Critical Errors while performing Backup Scheduling (8 different critical errors and their solution)

    When Backup Scheduling is enabled in ServiceDesk Plus under Admin -> Backup Scheduling -> Edit Scheduling, and at the specified time if the application is unable to perform the backup for various reasons, an exception is thrown and this exception is send as an email configured under Backup Scheduling.

    The mail sent will look like this:

    Dear Admin,

    ServiceDesk Plus database seems to be corrupted, So please contact your database Administrator [OR]

    ServiceDesk support for further assistance to recover your data forward this mail and support file -> support tab to support@servicedeskplus.com

    Error Trace in logs:

    java.io.IOException: The system cannot find the path specified at java.io.WinNTFileSystem.createFileExclusively(Native Method) at java.io.File.createNewFile(Unknown Source) at com.adventnet.servicedesk.tools.SDBackUp.createBuildInfoXml(SDBackUp.java:838) at com.adventnet.servicedesk.tools.SDBackUp.initBackup(SDBackUp.java:174) at com.adventnet.servicedesk.tools.SDBackUp.process(SDBackUp.java:77) at com.adventnet.servicedesk.setup.task.ScheduledBackupTask.executeTask(ScheduledBackupTa

    Trouble Shooting Tips:

    If the server crashed on received this email, contact your DBA to update the following sql query update Task_Input SET OPERATIONAL_STATUS = 4 where SCHEDULE_ID = (select SCHEDULE_ID from schedule where SCHEDULE_NAME = 'BackupSchedule')

    The above sql query will stop your backup scheduling.

    NOTE: In very rare cases the server may get crashed and in all the cases if you study first 2 lines of the Error Trace on the email, you yourself will be able to troubleshoot the error.

    Below are some of the most common Error traces listed along with the solutions.

    a. Error trace in logs:

    java.io.IOException: The system cannot find the path specified at java.io.WinNTFileSystem.createFileExclusively(Native Method) at java.io.File.createNewFile(Unknown Source) at com.adventnet.servicedesk.tools.SDBackUp.createBuildInfoXml(SDBackUp.java:838) at com.adventnet.servicedesk.tools.SDBackUp.initBackup(SDBackUp.java:174) at........

    Cause:

    Under Admin -> Backup Scheduling -> Edit Scheduling, the location mentioned for the backup maybe invalid.

    Solution:

    Make sure you have mentioned the correct location for the backup.

    b. Error trace in logs:

    java.io.IOException: Access is denied at java.io.WinNTFileSystem.createFileExclusively(Native Method) at java.io.File.createNewFile(Unknown Source) at com.adventnet.servicedesk.tools.SDBackUp.createBuildInfoXml(SDBackUp.java:838) at com.adventnet.servicedesk.tools.SDBackUp.initBackup(SDBackUp.java:174) at........ java.io.FileNotFoundException: C:\AdventNet\ME\ServiceDesk\backup\backup_info.xml (The system cannot find the file specified) at java.io.FileInputStream.open(Native Method) at java.io.FileInputStream.(Unknown Source) at com.adventnet.servicedesk.tools.SDBackUp.addToZip(SDBackUp.java:421) at com.adventnet.servicedesk.tools.SDBackUp.endBackup(SDBackUp.java:298) at..........

    Solution:

    Check if the folder name mentioned in location under Admin -> Backup Scheduling -> Edit Scheduling is like 'folder name' i.e. name with space (use the folder name without any space). Also, if this folder is shared, make sure the folder have all the read and write permissions.

    c. Error trace in logs:

    java.io.IOException: There is not enough space on the disk at java.io.FileOutputStream.writeBytes(Native Method) at java.io.FileOutputStream.write(Unknown Source) at sun.nio.cs.StreamEncoder$CharsetSE.writeBytes(Unknown Source) at.........

    Cause:

    The location mentioned under Admin -> Backup Scheduling -> Edit Scheduling may not have enough disk space.

    Solution:

    Make sure the disk have enough disk space. As of now ServiceDesk Plus does not provide an automated way of deleting the older backup so you can retain the last 5 to 10 backups and delete the rest manually.

    d. Error trace in logs:

    java.sql.SQLException: Login failed for user 'administrator'. Reason: The password of the account has expired. at

    net.sourceforge.jtds.jdbc.SQLDiagnostic.addDiagnostic(SQLDiagnostic.java:365) at net.sourceforge.jtds.jdbc.TdsCore.tdsErrorToken(TdsCore.java:2781) at ........

    Cause:

    The error occurs only in installation using MSSQL database. The password for the account 'administrator' in the SQL server would have got expired.

    Solution:

    Configure a new password from the installation folders Adventnet\ME\ServiceDesk\bin and run the script Changedbserver.bat to change the password.

    NOTE: You will find the application connected to the database because of an existing open connection to the SQL Server. But while restarting ServiceDesk Plus with an expired password, you will be unable to start the application.

    e. Error trace in logs:

    java.lang.Exception: Unable to get the data from [aaaaccadminprofile] table at com.adventnet.servicedesk.tools.SDBackUp.dumpTable(SDBackUp.java:492) at com.adventnet.servicedesk.tools.SDBackUp.dumpTable(SDBackUp.java:511) at......... java.lang.Exception: Unable to get the data from [acboxconfig] table at com.adventnet.servicedesk.tools.SDBackUp.dumpTable(SDBackUp.java:492) at com.adventnet.servicedesk.tools.SDBackUp.startBackup(SDBackUp.java:240) at......

    Cause:

    This error occurs when ServiceDesk Plus is configured using MSSQL database and the database is set with case sensitive mode in the SQL server.

    Solution:

    Change the 'COLLATION' in the MSSQL server for the database for ServiceDesk Plus as CASE-INSENSITIVE. You can use the following query to update the same in MSSQL on the query editor:

    ALTER DATABASE MyDatabase COLLATE SQL_Latin1_General_CP1_CI_AS;

    NOTE: 'MyDatabase' in the query you have to replace with the database name. In most cases it is be 'servicedesk'.

    f. Error Trace in logs:

    java.io.IOException: The device is not ready at java.io.WinNTFileSystem.createFileExclusively(Native Method at java.io.File.createNewFile (Unknown Source) at com.adventnet.servicedesk.tools.SDBackUp.createBuildInfoXml(SDBackUp.java:838) at .....

    Cause:

    The error occurs

    When the location mentioned under Admin -> Backup Scheduling -> Edit Scheduling is being used by another application for a similar kind of backup or may be for some other purpose at the time scheduled for the backup to run in ServiceDesk Plus. The folder gets locked up such that ServiceDesk Plus will not be able to access it.

    Solution:

    Please make sure you configure the location which is not used by any other application.

    g. Error trace in logs:

    java.sql.SQLException: No operations allowed after connection closed. Connection was closed due to the following exception: ** BEGIN NESTED EXCEPTION **

    java.sql.SQLException MESSAGE: Communication link failure: java.net.SocketException, underlying cause: Software caused

    connection abort: recv failed ** BEGIN NESTED EXCEPTION ** java.net.SocketException MESSAGE: Software caused connection abort: recv failed STACKTRACE:

    java.net.SocketException: Software caused......

    Cause:

    The error occurs with installations configured using MSSQL database. While the scheduled backup is being performed, due to some network issue if the connection between the ServiceDesk Plus and MSSQL server is closed, the backup process stops and ServiceDesk Plus triggers an error email.

    Solution:

    Try running a manual backup on executing backupdata.bat script under Adventnet\ME\ServiceDesk\bin and if you are able to take a complete backup, you can discard the error you received. So the next time a scheduled backup runs, it should complete without any issues.

    NOTE: When the application looses connection with MSSQL database, it will retry automatically to connect back to MSSQL. But the scheduled backup process will not retry and hence once a connection is closed the backup process will be stopped and you will receive an error mail.

    h. Error trace in logs:

    java.io.IOException: The specified network name is no longer available at java.io.FileOutputStream.writeBytes(Native Method) at java.io.FileOutputStream.write(Unknown Source) at sun.nio.cs.StreamEncoder$CharsetSE.writeBytes(Unknown Source) at sun.nio.cs.StreamEncoder$CharsetSE.implWrite(Unknown Source) at......

    Cause:

    This error usually occurs when the location field mentioned under Admin -> Backup Scheduling -> Edit Scheduling is on a network drive, and that drive is unreachable from the server (ServiceDesk Plus) at that particular time when scheduled backup is suppose to run.

    Solution:

    Make sure the path mentioned in the location field is correct and reachable from the ServiceDesk Plus server. Also, make sure the network folder has full read and write permission and path is specified with a format as below: \\machine_name\drive$\folder_name

    4. How to revert when an upgrade fails?

    Off late all the upgrade related issue is handled in our environment. We recommend you to revert to the old build and send us the data for further analysis.

    Solution:

    Instruction to revert to the old build.

    1. Check the build number of the latest backup, probably the one you would have taken before the upgrade.
    2. Un-install ServiceDesk Plus.
    3. Reinstall the version build of ServiceDesk Plus for which you have taken the backup.
    4. Start and stop the server once.
    5. Restore the data by following the instruction below.
    6. Go to [ServiceDesk Plus-Home]\bin directory and execute restoredata.bat. Choose the backup file while prompted.

      Example:

      cmd> [ServiceDesk Plus Home]\bin

      cmd> restoreData.bat

      And locate the backup file.

    7. Start ServiceDesk Plus.
    8. Information required for further analysis:

      updatemanager.log under Servicedesk[home]/server/default/log.

Let's support faster, easier, and together

Let's support faster, easier, and together