<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Scheduling upload to CAS task in SAS Viya from .sas code in SAS Programming</title>
    <link>https://communities.sas.com/t5/SAS-Programming/Scheduling-upload-to-CAS-task-in-SAS-Viya-from-sas-code/m-p/491500#M128910</link>
    <description>&lt;P&gt;Hi All,&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;We have just migrated from SAS 9.4 environment to SAS Viya environment. Both the environments are running on Linux servers.&lt;/P&gt;&lt;P&gt;In SAS 9.4 we had created SAS EG projects for data preparation and upload to LASR task was also included in same.&amp;nbsp;These projects were scheduled for daily pulls. After migrating to SAS Viya we are able to run all the codes in SASStudio environment and also in SPRE.&lt;/P&gt;&lt;P&gt;I have 2 questions here:&lt;/P&gt;&lt;P&gt;1. I tried putting upload to CAS snippet in the .sas code and tried running from SPRE but that fails with following error:&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;code :&lt;/STRONG&gt; cas mySession2 sessopts=(caslib=casuser timeout=1800 locale="en_US");&lt;BR /&gt;&lt;STRONG&gt;ERROR:&lt;/STRONG&gt; The request to start or connect to a session failed. Specify a UUID to connect to an existing session or specify a session&lt;BR /&gt;name, port and host name to start a session.&lt;BR /&gt;&lt;BR /&gt;&lt;STRONG&gt;NOTE:&lt;/STRONG&gt; Kerberos authentication failure in function gss_init_sec_context: Unspecified GSS failure. Minor code may provide more&lt;BR /&gt;information.&lt;BR /&gt;&lt;STRONG&gt;NOTE:&lt;/STRONG&gt; Additional information: No Kerberos credentials available (default cache: KEYRING:persistent:0).&lt;BR /&gt;&lt;STRONG&gt;ERROR:&lt;/STRONG&gt; Kerberos initialization failed. Your credential cache is either expired or missing.&lt;BR /&gt;options cashost="apsasvamaster.asianpaints.com" casport=5570 sessref="mySession2";&lt;BR /&gt;cas;&lt;BR /&gt;&lt;STRONG&gt;ERROR:&lt;/STRONG&gt; Kerberos initialization failed. Your credential cache is either expired or missing.&lt;BR /&gt;&lt;STRONG&gt;ERROR:&lt;/STRONG&gt; Unable to connect to Cloud Analytic Services apsasvamaster.asianpaints.com on port 5570. Verify connection parameters and&lt;BR /&gt;retry.&lt;BR /&gt;&lt;STRONG&gt;NOTE:&lt;/STRONG&gt; Kerberos authentication failure in function gss_init_sec_context: Unspecified GSS failure. Minor code may provide more&lt;BR /&gt;information.&lt;BR /&gt;&lt;STRONG&gt;NOTE:&lt;/STRONG&gt; Additional information: No Kerberos credentials available (default cache: KEYRING:persistent:0).&lt;BR /&gt;&lt;STRONG&gt;ERROR:&lt;/STRONG&gt; Kerberos initialization failed. Your credential cache is either expired or missing.&lt;BR /&gt;&lt;BR /&gt;&lt;STRONG&gt;code:&lt;/STRONG&gt; cas mySession2 sessopts=(caslib=casuser timeout=1800 locale="en_US");&lt;BR /&gt;&lt;STRONG&gt;ERROR:&lt;/STRONG&gt; Kerberos initialization failed. Your credential cache is either expired or missing.&lt;BR /&gt;&lt;STRONG&gt;ERROR:&lt;/STRONG&gt; Unable to connect to Cloud Analytic Services apsasvamaster.asianpaints.com on port 5570. Verify connection parameters and&lt;BR /&gt;retry.&lt;BR /&gt;&lt;STRONG&gt;code:&lt;/STRONG&gt; proc casutil;&lt;BR /&gt;&lt;STRONG&gt;ERROR:&lt;/STRONG&gt; A connection to the Cloud Analytic Services session could not be made.&lt;BR /&gt;&lt;STRONG&gt;ERROR:&lt;/STRONG&gt; An error has occurred.&lt;BR /&gt;&lt;STRONG&gt;code:&lt;/STRONG&gt; droptable casdata="SSC_SLA_PERFORMANCE" incaslib="ssc" quiet;&lt;BR /&gt;&lt;STRONG&gt;ERROR:&lt;/STRONG&gt; An error has occurred.&lt;BR /&gt;&lt;STRONG&gt;code:&lt;/STRONG&gt; run;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;NOTE:&lt;/STRONG&gt; The SAS System stopped processing this step because of errors.&lt;BR /&gt;&lt;STRONG&gt;NOTE:&lt;/STRONG&gt; PROCEDURE CASUTIL used (Total process time):&lt;BR /&gt;real time 0.04 seconds&lt;BR /&gt;cpu time 0.05 seconds&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;How to connect to CAS server from SPRE?&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;2. Is there any other way to schedule .sas program to run automatically other than running it in SPRE and scheduling it in crontab?&lt;/P&gt;</description>
    <pubDate>Fri, 31 Aug 2018 03:32:40 GMT</pubDate>
    <dc:creator>madhuramalkar</dc:creator>
    <dc:date>2018-08-31T03:32:40Z</dc:date>
    <item>
      <title>Scheduling upload to CAS task in SAS Viya from .sas code</title>
      <link>https://communities.sas.com/t5/SAS-Programming/Scheduling-upload-to-CAS-task-in-SAS-Viya-from-sas-code/m-p/491500#M128910</link>
      <description>&lt;P&gt;Hi All,&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;We have just migrated from SAS 9.4 environment to SAS Viya environment. Both the environments are running on Linux servers.&lt;/P&gt;&lt;P&gt;In SAS 9.4 we had created SAS EG projects for data preparation and upload to LASR task was also included in same.&amp;nbsp;These projects were scheduled for daily pulls. After migrating to SAS Viya we are able to run all the codes in SASStudio environment and also in SPRE.&lt;/P&gt;&lt;P&gt;I have 2 questions here:&lt;/P&gt;&lt;P&gt;1. I tried putting upload to CAS snippet in the .sas code and tried running from SPRE but that fails with following error:&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;code :&lt;/STRONG&gt; cas mySession2 sessopts=(caslib=casuser timeout=1800 locale="en_US");&lt;BR /&gt;&lt;STRONG&gt;ERROR:&lt;/STRONG&gt; The request to start or connect to a session failed. Specify a UUID to connect to an existing session or specify a session&lt;BR /&gt;name, port and host name to start a session.&lt;BR /&gt;&lt;BR /&gt;&lt;STRONG&gt;NOTE:&lt;/STRONG&gt; Kerberos authentication failure in function gss_init_sec_context: Unspecified GSS failure. Minor code may provide more&lt;BR /&gt;information.&lt;BR /&gt;&lt;STRONG&gt;NOTE:&lt;/STRONG&gt; Additional information: No Kerberos credentials available (default cache: KEYRING:persistent:0).&lt;BR /&gt;&lt;STRONG&gt;ERROR:&lt;/STRONG&gt; Kerberos initialization failed. Your credential cache is either expired or missing.&lt;BR /&gt;options cashost="apsasvamaster.asianpaints.com" casport=5570 sessref="mySession2";&lt;BR /&gt;cas;&lt;BR /&gt;&lt;STRONG&gt;ERROR:&lt;/STRONG&gt; Kerberos initialization failed. Your credential cache is either expired or missing.&lt;BR /&gt;&lt;STRONG&gt;ERROR:&lt;/STRONG&gt; Unable to connect to Cloud Analytic Services apsasvamaster.asianpaints.com on port 5570. Verify connection parameters and&lt;BR /&gt;retry.&lt;BR /&gt;&lt;STRONG&gt;NOTE:&lt;/STRONG&gt; Kerberos authentication failure in function gss_init_sec_context: Unspecified GSS failure. Minor code may provide more&lt;BR /&gt;information.&lt;BR /&gt;&lt;STRONG&gt;NOTE:&lt;/STRONG&gt; Additional information: No Kerberos credentials available (default cache: KEYRING:persistent:0).&lt;BR /&gt;&lt;STRONG&gt;ERROR:&lt;/STRONG&gt; Kerberos initialization failed. Your credential cache is either expired or missing.&lt;BR /&gt;&lt;BR /&gt;&lt;STRONG&gt;code:&lt;/STRONG&gt; cas mySession2 sessopts=(caslib=casuser timeout=1800 locale="en_US");&lt;BR /&gt;&lt;STRONG&gt;ERROR:&lt;/STRONG&gt; Kerberos initialization failed. Your credential cache is either expired or missing.&lt;BR /&gt;&lt;STRONG&gt;ERROR:&lt;/STRONG&gt; Unable to connect to Cloud Analytic Services apsasvamaster.asianpaints.com on port 5570. Verify connection parameters and&lt;BR /&gt;retry.&lt;BR /&gt;&lt;STRONG&gt;code:&lt;/STRONG&gt; proc casutil;&lt;BR /&gt;&lt;STRONG&gt;ERROR:&lt;/STRONG&gt; A connection to the Cloud Analytic Services session could not be made.&lt;BR /&gt;&lt;STRONG&gt;ERROR:&lt;/STRONG&gt; An error has occurred.&lt;BR /&gt;&lt;STRONG&gt;code:&lt;/STRONG&gt; droptable casdata="SSC_SLA_PERFORMANCE" incaslib="ssc" quiet;&lt;BR /&gt;&lt;STRONG&gt;ERROR:&lt;/STRONG&gt; An error has occurred.&lt;BR /&gt;&lt;STRONG&gt;code:&lt;/STRONG&gt; run;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;NOTE:&lt;/STRONG&gt; The SAS System stopped processing this step because of errors.&lt;BR /&gt;&lt;STRONG&gt;NOTE:&lt;/STRONG&gt; PROCEDURE CASUTIL used (Total process time):&lt;BR /&gt;real time 0.04 seconds&lt;BR /&gt;cpu time 0.05 seconds&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;How to connect to CAS server from SPRE?&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;2. Is there any other way to schedule .sas program to run automatically other than running it in SPRE and scheduling it in crontab?&lt;/P&gt;</description>
      <pubDate>Fri, 31 Aug 2018 03:32:40 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/Scheduling-upload-to-CAS-task-in-SAS-Viya-from-sas-code/m-p/491500#M128910</guid>
      <dc:creator>madhuramalkar</dc:creator>
      <dc:date>2018-08-31T03:32:40Z</dc:date>
    </item>
    <item>
      <title>Re: Scheduling upload to CAS task in SAS Viya from .sas code</title>
      <link>https://communities.sas.com/t5/SAS-Programming/Scheduling-upload-to-CAS-task-in-SAS-Viya-from-sas-code/m-p/507741#M136312</link>
      <description>&lt;P&gt;Hi, any luck?&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;To do this, I've created the .authinfo at the home of the user "sas" (eg).&lt;/P&gt;&lt;P&gt;Now on the code.sas add the cas session:&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;cas batchsess authinfo="/home/sas/.authinfo" host="cascontroler.fqdn.com" port=5570 sessopts=(caslib=casuser);&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Remember, user sas is on the Linux servers and on the LDAP, then you can try this on the SASStudio first&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;call it with user sas:&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;/opt/sas/spre/home/SASFoundation/sas&amp;nbsp;code.sas&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT color="#FF0000"&gt;&lt;FONT color="#000000"&gt;OR using the batchserver&lt;/FONT&gt;&lt;STRONG&gt; (do this)&lt;/STRONG&gt;&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;/opt/sas/viya/config/etc/batchserver/default/batchserver.sh&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Using the batchserver you don't need to set the cas host and port, also you can configure the&amp;nbsp;autoexec, sasv9, sasenv_, etc on the batchserver folder&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;The .authinfo contains the following (&lt;A href="https://documentation.sas.com/api/docsets/authinfo/9.4/content/authinfo.pdf?locale=en" target="_blank"&gt;https://documentation.sas.com/api/docsets/authinfo/9.4/content/authinfo.pdf?locale=en&lt;/A&gt;&lt;span class="lia-unicode-emoji" title=":disappointed_face:"&gt;😞&lt;/span&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;default user sas password {sas004}xxxxxx&lt;/STRONG&gt;&lt;/P&gt;</description>
      <pubDate>Wed, 31 Oct 2018 15:30:42 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/Scheduling-upload-to-CAS-task-in-SAS-Viya-from-sas-code/m-p/507741#M136312</guid>
      <dc:creator>nfarinha</dc:creator>
      <dc:date>2018-10-31T15:30:42Z</dc:date>
    </item>
  </channel>
</rss>

