<?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: How To Show Disc Fill Rates With Sas Scripts? in SAS Programming</title>
    <link>https://communities.sas.com/t5/SAS-Programming/How-To-Show-Disc-Fill-Rates-With-Sas-Scripts/m-p/681882#M206331</link>
    <description>&lt;P&gt;-h is human readable parameter so Size column is scale variant and will show G(igabyte) M(egabyte) K(ilobyte) T(erabyte) P(etabyte) E(xabyte) Z(ettabyte) Y(ottabyte) suffix... You can get consistent byte scale for the size using -B1.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Unix commands stdout can be read by a PIPE fileref.&amp;nbsp; &amp;nbsp;NOTE: Your SAS admin may have prepared a config.sas such that a session is restricted from executing external commands.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Example:&lt;/P&gt;
&lt;PRE&gt;filename DF pipe "df -B1";

data systems;
  infile df firstobs=2;
  length filesystem $50 bytes used avail rate 8 mount $50;
  format rate percent5.;
  input filesystem bytes used avail rate percent. mount;
run;   
&lt;/PRE&gt;</description>
    <pubDate>Sun, 06 Sep 2020 14:32:34 GMT</pubDate>
    <dc:creator>RichardDeVen</dc:creator>
    <dc:date>2020-09-06T14:32:34Z</dc:date>
    <item>
      <title>How To Show Disc Fill Rates With Sas Scripts?</title>
      <link>https://communities.sas.com/t5/SAS-Programming/How-To-Show-Disc-Fill-Rates-With-Sas-Scripts/m-p/681880#M206329</link>
      <description>&lt;P&gt;Hello everybody,&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I am working on unix environment, so as you know with "df -h" command I can see the availability percentage of discs. But also, I need sas scripts which provide me to show disc space rate for my co-workers.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I put the unix screen as below.&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="disc_rates.png" style="width: 359px;"&gt;&lt;img src="https://communities.sas.com/t5/image/serverpage/image-id/49041iF8B73D97EB212695/image-dimensions/359x71?v=v2" width="359" height="71" role="button" title="disc_rates.png" alt="disc_rates.png" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;I expect to see following sas results table:&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="eg_disc.png" style="width: 365px;"&gt;&lt;img src="https://communities.sas.com/t5/image/serverpage/image-id/49042i6235833FEE78D417/image-dimensions/365x42?v=v2" width="365" height="42" role="button" title="eg_disc.png" alt="eg_disc.png" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Can somebody help me about this?&lt;/P&gt;&lt;P&gt;Thanks,&lt;/P&gt;</description>
      <pubDate>Sun, 06 Sep 2020 13:32:20 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/How-To-Show-Disc-Fill-Rates-With-Sas-Scripts/m-p/681880#M206329</guid>
      <dc:creator>tarikbirinci1</dc:creator>
      <dc:date>2020-09-06T13:32:20Z</dc:date>
    </item>
    <item>
      <title>Re: How To Show Disc Fill Rates With Sas Scripts?</title>
      <link>https://communities.sas.com/t5/SAS-Programming/How-To-Show-Disc-Fill-Rates-With-Sas-Scripts/m-p/681882#M206331</link>
      <description>&lt;P&gt;-h is human readable parameter so Size column is scale variant and will show G(igabyte) M(egabyte) K(ilobyte) T(erabyte) P(etabyte) E(xabyte) Z(ettabyte) Y(ottabyte) suffix... You can get consistent byte scale for the size using -B1.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Unix commands stdout can be read by a PIPE fileref.&amp;nbsp; &amp;nbsp;NOTE: Your SAS admin may have prepared a config.sas such that a session is restricted from executing external commands.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Example:&lt;/P&gt;
&lt;PRE&gt;filename DF pipe "df -B1";

data systems;
  infile df firstobs=2;
  length filesystem $50 bytes used avail rate 8 mount $50;
  format rate percent5.;
  input filesystem bytes used avail rate percent. mount;
run;   
&lt;/PRE&gt;</description>
      <pubDate>Sun, 06 Sep 2020 14:32:34 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/How-To-Show-Disc-Fill-Rates-With-Sas-Scripts/m-p/681882#M206331</guid>
      <dc:creator>RichardDeVen</dc:creator>
      <dc:date>2020-09-06T14:32:34Z</dc:date>
    </item>
    <item>
      <title>Re: How To Show Disc Fill Rates With Sas Scripts?</title>
      <link>https://communities.sas.com/t5/SAS-Programming/How-To-Show-Disc-Fill-Rates-With-Sas-Scripts/m-p/681884#M206332</link>
      <description>&lt;P&gt;Thank you very much for your invaluable response. But, rate column comes missing. What can be the reason?&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="disc_rate_ss.png" style="width: 495px;"&gt;&lt;img src="https://communities.sas.com/t5/image/serverpage/image-id/49043iBDEEDAA3D887F44E/image-dimensions/495x55?v=v2" width="495" height="55" role="button" title="disc_rate_ss.png" alt="disc_rate_ss.png" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;On the other hand, I want to add a condition. I am going to devide used variable to total size variable then I want to get the percentage of the available storage. So, if the percentage of available storage less than 10%, I want to get notification through the e-mail. Is it possible to do this? Thanks,&lt;/P&gt;</description>
      <pubDate>Sun, 06 Sep 2020 15:31:33 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/How-To-Show-Disc-Fill-Rates-With-Sas-Scripts/m-p/681884#M206332</guid>
      <dc:creator>tarikbirinci1</dc:creator>
      <dc:date>2020-09-06T15:31:33Z</dc:date>
    </item>
    <item>
      <title>Re: How To Show Disc Fill Rates With Sas Scripts?</title>
      <link>https://communities.sas.com/t5/SAS-Programming/How-To-Show-Disc-Fill-Rates-With-Sas-Scripts/m-p/681889#M206335</link>
      <description>&lt;P&gt;Make sure to use colon modifier in front of the in-line informat specification in your input statement. Otherwise it reads a fixed number of characters instead of the next "word" in the line.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Once you have the percentage used you can just check if it is too high to find out which volumes are low in space.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;I prefer to use the -k option (I don't care to know the size to the byte level).&lt;/P&gt;
&lt;PRE&gt;&lt;CODE class=" language-sas"&gt;data filesystems ;
  infile 'df -k' pipe truncover firstobs=2;
  input Filesystem :$256. size used available usedpercent :percent. MountPoint $256.;
  low = usedpercent &amp;gt; .90 ;
run;&lt;/CODE&gt;&lt;/PRE&gt;</description>
      <pubDate>Sun, 06 Sep 2020 16:50:51 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/How-To-Show-Disc-Fill-Rates-With-Sas-Scripts/m-p/681889#M206335</guid>
      <dc:creator>Tom</dc:creator>
      <dc:date>2020-09-06T16:50:51Z</dc:date>
    </item>
    <item>
      <title>Re: How To Show Disc Fill Rates With Sas Scripts?</title>
      <link>https://communities.sas.com/t5/SAS-Programming/How-To-Show-Disc-Fill-Rates-With-Sas-Scripts/m-p/681890#M206336</link>
      <description>&lt;P&gt;Use the colon modifier for the PERCENT. informat:&lt;/P&gt;
&lt;PRE&gt;&lt;CODE class=" language-sas"&gt;input filesystem bytes used avail rate :percent. mount;&lt;/CODE&gt;&lt;/PRE&gt;
&lt;P&gt;or assign the informat in a separate INFORMAT statement.&lt;/P&gt;</description>
      <pubDate>Sun, 06 Sep 2020 16:53:18 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/How-To-Show-Disc-Fill-Rates-With-Sas-Scripts/m-p/681890#M206336</guid>
      <dc:creator>Kurt_Bremser</dc:creator>
      <dc:date>2020-09-06T16:53:18Z</dc:date>
    </item>
  </channel>
</rss>

