MS SQL info

Remove maintenance plan and its jobs:

https://social.msdn.microsoft.com/Forums/en-US/d836371a-4dc9-40d1-b6b7-df25c6b51211/cannot-delete-a-maintenance-plan?forum=sqltools
https://dba.stackexchange.com/questions/121877/sql-server-cannot-drop-idle-job

#Show all maintenance plans IDs:
select s.name,s.id as [plan_id] from msdb.dbo.sysmaintplan_plans as s
SELECT name, id FROM msdb.dbo.sysmaintplan_plans

#Remove plan, its logs and subplans, selected by ID:
exec msdb.dbo.sp_maintplan_delete_plan @plan_id=N'{PLAN_ID_OF_MAINT_PLAN}’

DELETE FROM msdb.dbo.sysmaintplan_log WHERE plan_id = ”
DELETE FROM msdb.dbo.sysmaintplan_subplans WHERE plan_id = ”
DELETE FROM msdb.dbo.sysmaintplan_plans WHERE id = ”

#Now you can delete the jobs from Management Studio.

SQL SERVER – Unable to Start SQL Server Service or Connect After Incorrectly Setting Max Server Memory to a Low Value:

https://blog.sqlauthority.com/2019/09/26/sql-server-unable-to-start-sql-server-service-or-connect-after-incorrectly-setting-max-server-memory-to-a-low-value/

If you meet this in SQLAGENT.OUT log:

SQLServer Error: 229, The EXECUTE permission was denied on the object 'sp_sqlagent_update_agent_xps'

2018-04-08 19:39:48 – ? [100] Microsoft SQLServerAgent version 12.0.2000.8 (X64 unicode retail build) : Process ID 4440
2018-04-08 19:39:48 – ? [495] The SQL Server Agent startup service account is XXX.
2018-04-08 19:39:48 – ? [393] Waiting for SQL Server to recover database ‘msdb’…
2018-04-08 19:39:48 – ! [298] SQLServer Error: 229, The EXECUTE permission was denied on the object ‘sp_sqlagent_update_agent_xps’, database ‘msdb’, schema ‘dbo’. [SQLSTATE 42000] (DisableAgentXPs)
2018-04-08 19:39:48 – ! [000] The EXECUTE permission was denied on the object ‘sp_sqlagent_update_agent_xps’, database ‘msdb’, schema ‘dbo’. [SQLSTATE 42000] (Error 229)
2018-04-08 19:39:48 – ! [298] SQLServer Error: 229, The EXECUTE permission was denied on the object ‘sp_sqlagent_update_agent_xps’, database ‘msdb’, schema ‘dbo’. [SQLSTATE 42000] (DisableAgentXPs)
2018-04-08 19:39:48 – ! [000] The EXECUTE permission was denied on the object ‘sp_sqlagent_update_agent_xps’, database ‘msdb’, schema ‘dbo’. [SQLSTATE 42000] (Error 229)
2018-04-08 19:39:48 – ? [098] SQLServerAgent terminated (normally)

Then check SQL service is started from user with appropriate rights. Next step is to check security permissions of database(s) inside SQL Manager and on physical drive are adequate.

SQL Backups troubleshoot:

Trouble #1:
https://support.microsoft.com/ru-ru/help/955763/the-sql-server-agent-service-does-not-start-after-you-upgrade-from-sql-server-2008-express-or-from-sql-server-2008-express-with-advanced-services-to-sql-server-2008-developer,-to-sql-server-2008-enterprise,-or-to-sql-server-2008-standard

Trouble #2:
https://msdn.microsoft.com/ru-ru/library/ms178127.aspx

Trouble#3:
https://social.msdn.microsoft.com/Forums/sqlserver/en-US/124bbce8-fed9-49ad-9703-7e4cace1e81d/databases-with-simple-recovery-will-be-excluded-sql-server-2008?forum=sqltools

Restore a Differential Database Backup (SQL Server)

First restore full closest backup with default options.

Then restore defferential backup with “RESTORE WITH NORECOVERY” option.

Then click on database name and choose “Tasks“, “Restore” and then “Transaction Log“.
Place needed transaction log to the folder that SQL tells you it look for backup.

 

https://docs.microsoft.com/en-us/sql/relational-databases/backup-restore/restore-a-differential-database-backup-sql-server?view=sql-server-2017

https://docs.microsoft.com/en-us/sql/relational-databases/backup-restore/restore-a-transaction-log-backup-sql-server?view=sql-server-2017