2 Replies Latest reply on Nov 9, 2018 6:03 PM by rcorywaugh

    Need Help Resolving PI AF Backup Failing

    rcorywaugh

      This is just an FYI to other users who may be using the cloud environment for this course. I noticed that when I attempt to run a backup I backup the PI archives, but the AF backup folder was empty. Additionally, the backup task was generating error files. Initially, I thought this was because the PI AF Link was not set up, so I used the wizard in order to configure it. However I am still getting the following errors at the end of the log:

       

      ------------------------------------------------------------------------------------------------

       

      Backup AF data...

       

      C:\Windows\system32>SET SQLINSTANCE=.

       

      C:\Windows\system32>sqlcmd -S . -d PIFD -Q "EXEC dbo.usp_backup @outpath = N'F:\PIBackups\Automated\AF\';" -E

      Sqlcmd: Error: Microsoft SQL Server Native Client 11.0 : Login failed for user 'NT AUTHORITY\SYSTEM'..

      Sqlcmd: Error: Microsoft SQL Server Native Client 11.0 : Cannot open database "PIFD" requested by the login. The login failed..

      Backup AF data...done.

      Fri 11/09/2018 15:08:34.62

      No pisitebackup.bat script found. Skipping site-specific backup.

       

      Backup completed: Fri 11/09/2018 -- 15:08:34.65 

      For additional log messages, please examine the PI Server Message Log.

      -------------------------------------

      !!!!!PIBACKUP.BAT SCRIPT FAILED!!!!!!

      AF Server Backup Status =  1

      -------------------------------------

       

      ---------------------------------------------------------------------------------------------------

       

      Any help with this would be appreciated. Thanks in advance!

        • Re: Need Help Resolving PI AF Backup Failing
          yuliu

          Hi Robert,

          The error indicates that the account running the scheduled backup does not have enough permissions to access the PIFD database.

          You will need to identify the account running the backup service and give sysadmin, db_owner, or  db_backup operator role in SQL.

           

          1 of 1 people found this helpful
            • Re: Need Help Resolving PI AF Backup Failing
              rcorywaugh

              Hello Yuling Liu,

               

              Thank you very much for the advice. Going onto the cloud environment and giving the sysadmin role to the SYSTEM user fixed this issue. It may be a good idea to amend the training videos to tell users to set this up, or to have the environment already configured in this way for future users.

               

              Thanks again and kind regards,

               

              Robert Cory Waugh