SQL Clone
SQLServerCentral is supported by Redgate
 
Log in  ::  Register  ::  Not logged in
 
 
 

Getting SQL Agent going for SQL Server on Linux–#SQLNewBlogger

It’s actually a simple procedure, but I thought I’d write a short note to help me remember. The procedure is documented in Books Online.

When I first started playing with this version, I noticed that SQL Agent was disabled. That’s not great, since SQL Agent is a great tool for various tasks in SQL Server. I can’t start the agent from here, as the underlying implementation is different, and I’m not really a host OS admin when connecting in SSMS.

2018-05-23 15_19_26-SQLQuery4.sql - ubuntu.master (sa (56))_ - Microsoft SQL Server Management Studi

After checking which patch level I was at (CU6), I changed to my Linux console, and ran the configuration utility. For Linux, this is mssql-conf.

2018-05-23 15_20_34-Ubuntu 64-bit SQL Server .210 - VMware Workstation

The next step is to run the command listed to restart the system. I actually just ran

sudo sysmctl restart mssql-server

Once this was done, I refreshed SSMS.

2018-05-23 15_22_52-SQLQuery4.sql - ubuntu.master (sa (56))_ - Microsoft SQL Server Management Studi

This appears to work, but let’s test it. I’ll create a new job that does a backup of a database. This should be simple, and I’ll use defaults, just a filename for a full backup. I’ll use this command:

backup database dbaadmin to disk = ‘dbaadmin.bak’ with init

I save the job and run it. Sure enough, I have a backup.

2018-05-23 15_28_37-Ubuntu 64-bit SQL Server .210 - VMware Workstation

Tada, now I can move forward with work.

SQLNewBlogger

This is a fairly simple thing to do, but the writing helps me remember, but more importantly, I can document that I’ve done some learning here and experimenting.

The next person thinking about interviewing you wants to know that you can learn and solve problems.

The Voice of the DBA

Steve Jones is the editor of SQLServerCentral.com and visits a wide variety of data related topics in his daily editorial. Steve has spent years working as a DBA and general purpose Windows administrator, primarily working with SQL Server since it was ported from Sybase in 1990. You can follow Steve on Twitter at twitter.com/way0utwest

Comments

Leave a comment on the original post [voiceofthedba.com, opens in a new window]

Loading comments...