Automic Workload Automation

  • 1.  How to use alternative login in CONN object?

    Posted Mar 15, 2018 01:04 PM
    We have a couple of CONN objects we use to connect to SQL Server databases. The DB login credentials are saved in the CONN object, but we would like to centralize all DB credentials in a LOGIN object, and then reference that LOGIN object in the "Alternative Login" field in the CONN object.
    The problem is that I could not find any information on how to store DB credentials in the LOGIN object. The login type SQL seems to work only with agent names, not with DB server names. How would an entry in the LOGIN object look like in this case? Is this even possible?


  • 2.  How to use alternative login in CONN object?
    Best Answer

    Posted Mar 15, 2018 03:41 PM
    Hi

    At least in my sandbox ENV its working...
    DB Name: V112 (MS SQL 2014)

    Loginobject @LOGIN.DEFAULT
    ilwbwkieoguf.jpghttps://us.v-cdn.net/5019921/uploads/editor/st/ilwbwkieoguf.jpg" width="637">

    Paremeters in an SQL test job:
    r2um4rvt2xyc.jpghttps://us.v-cdn.net/5019921/uploads/editor/db/r2um4rvt2xyc.jpg" width="667">

    cheers, Wolfgang


  • 3.  How to use alternative login in CONN object?

    Posted Mar 15, 2018 05:01 PM
    From your example, I assumed you are using SQL Server authentication, the SQL Server login having the same name as the database (V112). I tried it in a similar setting and it works, thank you!I also made it work with Oracle. However, it looks like it doesn't work with Windows authentication.
    I was trying to put all credentials in the same LOGIN object, but apparently you have to have only one SQL credential per LOGIN object. Thus, what I think is missing from documentation about alternative login is:
    1. Have one LOGIN object for each unique credential (pair Username/Password), with only one SQL-type entry per LOGIN
    2. Do not use Windows (Active Directory) credentials in the LOGIN object

    Thank you again for making it clear!

    Leonard




  • 4.  How to use alternative login in CONN object?

    Posted Mar 16, 2018 04:31 AM
    You can use WIN Authentication basically BUT the agent has to be started with this OS user!

    https://docs.automic.com/documentation/webhelp/english/ALL/components/AE/11.2/All%20Guides/help.htm#ucacob.htm?Highlight=authentication

    I would recommend using SQL Authentification because otherwise it could lead to some difficulties if someone restarts the agent and "suddenly" authentication does not work any longer and nobody knows why :-)
    (experienced several times :-)  )

    cheers, Wolfgang



  • 5.  How to use alternative login in CONN object?

    Posted Mar 19, 2018 03:24 PM
    We are running the DB agent with an Active Directory service account, and we are careful not to start it under a different account. We added the agent service account on each SQL Server database we need to access, then we use IntegratedSecurity=true in the Connection Properties in the CON object. This way, we don't need to store credentials anywhere. In some cases, we have to access SQL Server or Oracle using local database credentials, and that's where the Alternative Login helps.
    Now I know when and how to use the LOGIN object in CON objects. Thank you FrankMuffke!


  • 6.  How to use alternative login in CONN object?

    Posted Mar 19, 2018 03:47 PM
    Your 're welcome!