<?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 Re: Run SAS code remotely on a Linux server in SAS Programming</title>
    <link>https://communities.sas.com/t5/SAS-Programming/Run-SAS-code-remotely-on-a-Linux-server/m-p/367660#M87579</link>
    <description>&lt;P&gt;If that remote Linux server is your SAS server, then look at background processing (with &amp;amp;) and the nohup command. You have to convert your SAS code to a batch job first (a .sas file that contains all your code and will run from the command line; additional use of configuration will be necessary, depending on your SAS environment)&lt;/P&gt;
&lt;P&gt;If SAS is not on the remote server, no luck.&lt;/P&gt;</description>
    <pubDate>Fri, 16 Jun 2017 10:19:46 GMT</pubDate>
    <dc:creator>Kurt_Bremser</dc:creator>
    <dc:date>2017-06-16T10:19:46Z</dc:date>
    <item>
      <title>Run SAS code remotely on a Linux server</title>
      <link>https://communities.sas.com/t5/SAS-Programming/Run-SAS-code-remotely-on-a-Linux-server/m-p/367646#M87574</link>
      <description>&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;I need to&amp;nbsp;run SAS code remotely on a Linux server.&lt;/P&gt;&lt;P&gt;I have a code that runs a long time, and I need to execute this code on the remote machine (Linux), without using the remote desktop connection, so I can turn off my local computer and let the code process remotely.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Could you please suggest if there is a way how this can be done, if possible?&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Thanks a lot in advance.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;With best regards,&lt;/P&gt;&lt;P&gt;RD&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Fri, 16 Jun 2017 09:50:17 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/Run-SAS-code-remotely-on-a-Linux-server/m-p/367646#M87574</guid>
      <dc:creator>reginado</dc:creator>
      <dc:date>2017-06-16T09:50:17Z</dc:date>
    </item>
    <item>
      <title>Re: Run SAS code remotely on a Linux server</title>
      <link>https://communities.sas.com/t5/SAS-Programming/Run-SAS-code-remotely-on-a-Linux-server/m-p/367650#M87576</link>
      <description>&lt;P&gt;Is SAS installed on the Linux server in any form?&lt;/P&gt;</description>
      <pubDate>Fri, 16 Jun 2017 09:56:10 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/Run-SAS-code-remotely-on-a-Linux-server/m-p/367650#M87576</guid>
      <dc:creator>RW9</dc:creator>
      <dc:date>2017-06-16T09:56:10Z</dc:date>
    </item>
    <item>
      <title>Re: Run SAS code remotely on a Linux server</title>
      <link>https://communities.sas.com/t5/SAS-Programming/Run-SAS-code-remotely-on-a-Linux-server/m-p/367660#M87579</link>
      <description>&lt;P&gt;If that remote Linux server is your SAS server, then look at background processing (with &amp;amp;) and the nohup command. You have to convert your SAS code to a batch job first (a .sas file that contains all your code and will run from the command line; additional use of configuration will be necessary, depending on your SAS environment)&lt;/P&gt;
&lt;P&gt;If SAS is not on the remote server, no luck.&lt;/P&gt;</description>
      <pubDate>Fri, 16 Jun 2017 10:19:46 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/Run-SAS-code-remotely-on-a-Linux-server/m-p/367660#M87579</guid>
      <dc:creator>Kurt_Bremser</dc:creator>
      <dc:date>2017-06-16T10:19:46Z</dc:date>
    </item>
    <item>
      <title>Re: Run SAS code remotely on a Linux server</title>
      <link>https://communities.sas.com/t5/SAS-Programming/Run-SAS-code-remotely-on-a-Linux-server/m-p/367669#M87581</link>
      <description>&lt;P&gt;Yes, SAS is installed on the Linux server.&lt;/P&gt;</description>
      <pubDate>Fri, 16 Jun 2017 10:49:31 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/Run-SAS-code-remotely-on-a-Linux-server/m-p/367669#M87581</guid>
      <dc:creator>reginado</dc:creator>
      <dc:date>2017-06-16T10:49:31Z</dc:date>
    </item>
    <item>
      <title>Re: Run SAS code remotely on a Linux server</title>
      <link>https://communities.sas.com/t5/SAS-Programming/Run-SAS-code-remotely-on-a-Linux-server/m-p/367675#M87582</link>
      <description>&lt;P&gt;With a server-based SAS, you usually have the configuration tree somewhere (BI Server). Something like /sasconf/Lev1/.....&lt;/P&gt;
&lt;P&gt;Within that, you find the subtree for the SASApp application server; within that, there's a Batchserver directory that contains the sasbatch.sh script.&lt;/P&gt;
&lt;P&gt;This shell script can be used to run batch jobs in the context of the SASApp server.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Convert your SAS code to a .sas file; save it in an appropriate place (eg subdirectory sasprog in your home directory)&lt;/P&gt;
&lt;P&gt;Do a test run (maybe with a smaller program that finishes quickly):&lt;/P&gt;
&lt;PRE&gt;/sasconf/Lev1/SASApp/BatchServer/sasbatch.sh $HOME/sasprog/myprog.sas -log $HOME/sasprog/myprog.log&lt;/PRE&gt;
&lt;P&gt;Review the log file. If everything is OK, you can apply this to run in the background:&lt;/P&gt;
&lt;PRE&gt;nohup /sasconf/Lev1/SASApp/BatchServer/sasbatch.sh $HOME/sasprog/myprog.sas -log $HOME/sasprog/myprog.log &amp;amp;&lt;/PRE&gt;
&lt;P&gt;The &amp;amp; at the end redirects the job into the background; running it with nohup means that a disconnection of the telnet/ssh connection will not terminate the job. Any stdout output will be directed to the file nohup.out in the directory from where you called that commandline.&lt;/P&gt;</description>
      <pubDate>Fri, 16 Jun 2017 11:23:45 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/Run-SAS-code-remotely-on-a-Linux-server/m-p/367675#M87582</guid>
      <dc:creator>Kurt_Bremser</dc:creator>
      <dc:date>2017-06-16T11:23:45Z</dc:date>
    </item>
    <item>
      <title>Re: Run SAS code remotely on a Linux server</title>
      <link>https://communities.sas.com/t5/SAS-Programming/Run-SAS-code-remotely-on-a-Linux-server/m-p/367677#M87583</link>
      <description>Thanks a lot KurtBremser!</description>
      <pubDate>Fri, 16 Jun 2017 11:31:56 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/Run-SAS-code-remotely-on-a-Linux-server/m-p/367677#M87583</guid>
      <dc:creator>reginado</dc:creator>
      <dc:date>2017-06-16T11:31:56Z</dc:date>
    </item>
    <item>
      <title>Re: Run SAS code remotely on a Linux server</title>
      <link>https://communities.sas.com/t5/SAS-Programming/Run-SAS-code-remotely-on-a-Linux-server/m-p/367679#M87585</link>
      <description>&lt;P&gt;Note that it is necessary to supply absolute path names for programs and logs (starting with a forward slash). $HOME provides this (resolves usually to /home/username)&lt;/P&gt;</description>
      <pubDate>Fri, 16 Jun 2017 11:39:22 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/Run-SAS-code-remotely-on-a-Linux-server/m-p/367679#M87585</guid>
      <dc:creator>Kurt_Bremser</dc:creator>
      <dc:date>2017-06-16T11:39:22Z</dc:date>
    </item>
    <item>
      <title>Re: Run SAS code remotely on a Linux server</title>
      <link>https://communities.sas.com/t5/SAS-Programming/Run-SAS-code-remotely-on-a-Linux-server/m-p/519233#M140599</link>
      <description>&lt;P&gt;Kurt,&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;This process requires the user to have direct access to log into the Application server to be able to submit a batch job.&amp;nbsp; Is there any way that a user can submit a batch job directly from their remote client (not including creating a DI Studio job)?&amp;nbsp; Our users would like to be able to run a long running program in batch, so they can shut down their computers and then check on the status later.&amp;nbsp; But would prefer to remotely submit the batch program.&amp;nbsp; I have a feeling that this isn't possible at this time.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Regards,&lt;/P&gt;
&lt;P&gt;&lt;BR /&gt;Fred&lt;/P&gt;</description>
      <pubDate>Thu, 06 Dec 2018 17:45:43 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/Run-SAS-code-remotely-on-a-Linux-server/m-p/519233#M140599</guid>
      <dc:creator>FredGIII</dc:creator>
      <dc:date>2018-12-06T17:45:43Z</dc:date>
    </item>
    <item>
      <title>Re: Run SAS code remotely on a Linux server</title>
      <link>https://communities.sas.com/t5/SAS-Programming/Run-SAS-code-remotely-on-a-Linux-server/m-p/519243#M140605</link>
      <description>&lt;P&gt;The SAS Management Console client tool provides the functionality to submit SAS batch jobs on your remote SAS application server using Schedule Manager.&lt;/P&gt;</description>
      <pubDate>Thu, 06 Dec 2018 19:07:20 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/Run-SAS-code-remotely-on-a-Linux-server/m-p/519243#M140605</guid>
      <dc:creator>SASKiwi</dc:creator>
      <dc:date>2018-12-06T19:07:20Z</dc:date>
    </item>
    <item>
      <title>Re: Run SAS code remotely on a Linux server</title>
      <link>https://communities.sas.com/t5/SAS-Programming/Run-SAS-code-remotely-on-a-Linux-server/m-p/519255#M140614</link>
      <description>&lt;P&gt;UNIX provides tools for this:&lt;/P&gt;
&lt;PRE&gt;nohup /sasconf/Lev1/SASApp/BatchServer/sasbatch.sh $HOME/sas/myprog.sas -log $HOME/log/myprog.log &amp;amp;&lt;/PRE&gt;
&lt;P&gt;The &amp;amp; at the end sends the command to the background, and the nohup wrapper prevents a premature termination when the terminal connection breaks.&lt;/P&gt;</description>
      <pubDate>Thu, 06 Dec 2018 19:58:33 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/Run-SAS-code-remotely-on-a-Linux-server/m-p/519255#M140614</guid>
      <dc:creator>Kurt_Bremser</dc:creator>
      <dc:date>2018-12-06T19:58:33Z</dc:date>
    </item>
    <item>
      <title>Re: Run SAS code remotely on a Linux server</title>
      <link>https://communities.sas.com/t5/SAS-Programming/Run-SAS-code-remotely-on-a-Linux-server/m-p/604133#M175101</link>
      <description>&lt;P&gt;Hi Kurt,&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I have couple of users, they want to run SAS Program on remote Linux SAS Server as backend process using SAS EG.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;SAS EG has been installed on Windows 10, then users connect to SAS Server(to remote Linux) to access code/data and run programs.&lt;/P&gt;&lt;P&gt;How to enable users to schedule the sas code to run on remote Linux SAS Server as backend process at after business hours?&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Thank,&lt;/P&gt;&lt;P&gt;CG&lt;/P&gt;</description>
      <pubDate>Thu, 14 Nov 2019 15:23:23 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/Run-SAS-code-remotely-on-a-Linux-server/m-p/604133#M175101</guid>
      <dc:creator>chenchug</dc:creator>
      <dc:date>2019-11-14T15:23:23Z</dc:date>
    </item>
    <item>
      <title>Re: Run SAS code remotely on a Linux server</title>
      <link>https://communities.sas.com/t5/SAS-Programming/Run-SAS-code-remotely-on-a-Linux-server/m-p/604151#M175109</link>
      <description>&lt;P&gt;As long as you do not run SAS with token authentication (and a generic user on the backend), there's really nothing you must do. Users save their code to .sas files on the server, log on to the server with any SSH client, and use the method I described previously to run the code in batch. Once it is verified that the code does run in batch correctly, you can use the UNIX system's &lt;A href="https://en.wikipedia.org/wiki/Cron" target="_blank" rel="noopener"&gt;cron&lt;/A&gt; tool to schedule the jobs.&lt;/P&gt;
&lt;P&gt;Search the net for the documentations of the &lt;A href="https://en.wikipedia.org/wiki/At_(command)" target="_blank" rel="noopener"&gt;at&lt;/A&gt; and &lt;A href="https://www.computerhope.com/unix/ucrontab.htm" target="_blank" rel="noopener"&gt;crontab&lt;/A&gt; commands.&lt;/P&gt;</description>
      <pubDate>Thu, 14 Nov 2019 16:04:31 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/Run-SAS-code-remotely-on-a-Linux-server/m-p/604151#M175109</guid>
      <dc:creator>Kurt_Bremser</dc:creator>
      <dc:date>2019-11-14T16:04:31Z</dc:date>
    </item>
  </channel>
</rss>

