<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
	>

<channel>
	<title>Seyhan Tekelioglu &#124; Blog &#124; Oracle - Linux - Network &#187; bash script</title>
	<atom:link href="http://www.seyhan.biz/index.php/tag/bash-script/feed/" rel="self" type="application/rss+xml" />
	<link>http://www.seyhan.biz</link>
	<description>OCP - RHCE - CCNA - MCSE - MCDBA</description>
	<lastBuildDate>Wed, 08 Sep 2010 07:56:27 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.0.1</generator>
		<item>
		<title>Sisman</title>
		<link>http://www.seyhan.biz/index.php/2009/12/04/sisman/</link>
		<comments>http://www.seyhan.biz/index.php/2009/12/04/sisman/#comments</comments>
		<pubDate>Fri, 04 Dec 2009 11:25:30 +0000</pubDate>
		<dc:creator>Seyhan Tekelioglu</dc:creator>
				<category><![CDATA[Scriptlerim]]></category>
		<category><![CDATA[ara]]></category>
		<category><![CDATA[bash script]]></category>
		<category><![CDATA[boyut]]></category>
		<category><![CDATA[dosya]]></category>
		<category><![CDATA[file search]]></category>
		<category><![CDATA[linux]]></category>

		<guid isPermaLink="false">http://www.seyhan.biz/?p=266</guid>
		<description><![CDATA[Bu script ile sistemdeki yüksek boyutlu dosyaları bulabilirsiniz. Yapmanız gereken tek sey hangi dizinde ne boyuttan büyük dosyaları aratacağınızı yazmak. Eğer boyut yazmazsanız script otomatik olarak 100000k ve üstü dosyaları arayacaktır. #!/bin/bash #!/bin/bash #Sistemdeki buyuk dosyalari bulan script boyut=$2 : ${boyut:="100000"} [[ -n "$1" ]] &#124;&#124; { echo "###################################################" echo "# sisman #" echo "# [...]]]></description>
			<content:encoded><![CDATA[<p>Bu script ile sistemdeki yüksek boyutlu dosyaları bulabilirsiniz. Yapmanız gereken tek sey hangi dizinde ne boyuttan büyük dosyaları aratacağınızı yazmak. Eğer boyut yazmazsanız script otomatik olarak 100000k ve üstü dosyaları arayacaktır.</p>
<p><span id="more-266"></span></p>
<pre style="background-image: initial; background-repeat: initial; background-attachment: initial; -webkit-background-clip: initial; -webkit-background-origin: initial; background-color: #ededff; font-size: 11px; line-height: 1.3em; overflow-x: auto; overflow-y: auto; width: 525px; clear: both; background-position: initial initial; padding: 11px; margin: 0px; border: 1px solid #dadada;">
<div id="_mcePaste" style="position: absolute; left: -10000px; top: 40px; width: 1px; height: 1px; overflow-x: hidden; overflow-y: hidden;">#!/bin/bash</div>

#!/bin/bash

#Sistemdeki buyuk dosyalari bulan script
boyut=$2

: ${boyut:="100000"}

[[ -n "$1" ]] || { 

     echo "###################################################"
     echo "#                    sisman                       #"
     echo "#                                                 #"
     echo "#           Buyuk Dosya Tespit Scripti            #"
     echo "#                                                 #"
     echo "#           Son Guncelleme : 21.09.2008           #"
     echo "#                                                 #"
     echo "#            (c)2008  Seyhan Tekelioglu           #"
     echo "###################################################"
     echo ""
     echo -e "Scriptin Kullanimi:\n\n./sisman &lt;dizin&gt; &lt;maksimum boyut&gt;\n\nNot:Maksimum boyut verilmezse 100000k ve uzeri dosyalar aranir.\n"; exit 0 ; }

find $1 -type f -size "+"$boyut"k" -exec ls -lh {} \; | awk '{ print $9 ": " $5 }'
</pre>
<p>Scripti indirmek için <a href="http://www.seyhan.biz/scripts/sisman.rar">tıklayın</a>.</p>

<p class="sayac_bilgi">Bu yazı toplamda 525, bugün ise 0 kez görüntülenmiş. Son okunma tarihi 09.09.2010</p>
<h4  class="related_post_title">Benzer Yazılar</h4><ul class="related_post"><li><a href="http://www.seyhan.biz/index.php/2009/12/04/kuyruksil/" title="Kuyruksil">Kuyruksil</a></li><li><a href="http://www.seyhan.biz/index.php/2010/06/07/linux-uzerine-oracle-e-business-suite-11-5-10-2-kurulumu/" title="Linux Üzerine Oracle E-Business Suite 11.5.10.2 Kurulumu">Linux Üzerine Oracle E-Business Suite 11.5.10.2 Kurulumu</a></li><li><a href="http://www.seyhan.biz/index.php/2009/12/03/ara/" title="Ara">Ara</a></li></ul>]]></content:encoded>
			<wfw:commentRss>http://www.seyhan.biz/index.php/2009/12/04/sisman/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Kuyruksil</title>
		<link>http://www.seyhan.biz/index.php/2009/12/04/kuyruksil/</link>
		<comments>http://www.seyhan.biz/index.php/2009/12/04/kuyruksil/#comments</comments>
		<pubDate>Fri, 04 Dec 2009 11:13:09 +0000</pubDate>
		<dc:creator>Seyhan Tekelioglu</dc:creator>
				<category><![CDATA[Scriptlerim]]></category>
		<category><![CDATA[bash script]]></category>
		<category><![CDATA[kuyruk]]></category>
		<category><![CDATA[linux]]></category>
		<category><![CDATA[printer]]></category>
		<category><![CDATA[spool]]></category>

		<guid isPermaLink="false">http://www.seyhan.biz/?p=257</guid>
		<description><![CDATA[Linux&#8217;ta tanımlı printerlarda kuyruk temizlemeye yarar. Kullanımı kolaydır. kuyruksil yazıp bir boşluk bırakın ve printer adını yazın. O printer&#8217;ın kuyruğunda bekleyen tüm talepler silinecektir. Sadece kuyruksil yazarsanız sistemde kayıtlı printerların listesini verir. #!/bin/bash E_NO_ARGS=65 if [ $# -eq 0 ] then echo &#8220;##############################################&#8221; echo &#8220;#                kuyruksil     [...]]]></description>
			<content:encoded><![CDATA[<p>Linux&#8217;ta tanımlı printerlarda kuyruk temizlemeye yarar. Kullanımı kolaydır. <strong>kuyruksil </strong>yazıp bir boşluk bırakın ve printer adını yazın. O printer&#8217;ın kuyruğunda bekleyen tüm talepler silinecektir. Sadece <strong>kuyruksil </strong>yazarsanız sistemde kayıtlı printerların listesini verir.<br />
<span id="more-257"></span></p>
<div id="_mcePaste" style="position: absolute; left: -10000px; top: 0px; width: 1px; height: 1px; overflow-x: hidden; overflow-y: hidden;">#!/bin/bash</div>
<div id="_mcePaste" style="position: absolute; left: -10000px; top: 0px; width: 1px; height: 1px; overflow-x: hidden; overflow-y: hidden;">E_NO_ARGS=65</div>
<div id="_mcePaste" style="position: absolute; left: -10000px; top: 0px; width: 1px; height: 1px; overflow-x: hidden; overflow-y: hidden;">if [ $# -eq 0 ]</div>
<div id="_mcePaste" style="position: absolute; left: -10000px; top: 0px; width: 1px; height: 1px; overflow-x: hidden; overflow-y: hidden;">then</div>
<div id="_mcePaste" style="position: absolute; left: -10000px; top: 0px; width: 1px; height: 1px; overflow-x: hidden; overflow-y: hidden;">echo &#8220;##############################################&#8221;</div>
<div id="_mcePaste" style="position: absolute; left: -10000px; top: 0px; width: 1px; height: 1px; overflow-x: hidden; overflow-y: hidden;">echo &#8220;#                kuyruksil                   #&#8221;</div>
<div id="_mcePaste" style="position: absolute; left: -10000px; top: 0px; width: 1px; height: 1px; overflow-x: hidden; overflow-y: hidden;">echo &#8220;#                                            #&#8221;</div>
<div id="_mcePaste" style="position: absolute; left: -10000px; top: 0px; width: 1px; height: 1px; overflow-x: hidden; overflow-y: hidden;">echo &#8220;#     Printer Kuyruk Temizleme Scripti       #&#8221;</div>
<div id="_mcePaste" style="position: absolute; left: -10000px; top: 0px; width: 1px; height: 1px; overflow-x: hidden; overflow-y: hidden;">echo &#8220;#                                            #&#8221;</div>
<div id="_mcePaste" style="position: absolute; left: -10000px; top: 0px; width: 1px; height: 1px; overflow-x: hidden; overflow-y: hidden;">echo &#8220;#        Son Guncelleme : 22.01.2008         #&#8221;</div>
<div id="_mcePaste" style="position: absolute; left: -10000px; top: 0px; width: 1px; height: 1px; overflow-x: hidden; overflow-y: hidden;">echo &#8220;#                                            #&#8221;</div>
<div id="_mcePaste" style="position: absolute; left: -10000px; top: 0px; width: 1px; height: 1px; overflow-x: hidden; overflow-y: hidden;">echo &#8220;#         (c)2008  Seyhan Tekelioglu         #&#8221;</div>
<div id="_mcePaste" style="position: absolute; left: -10000px; top: 0px; width: 1px; height: 1px; overflow-x: hidden; overflow-y: hidden;">echo &#8220;##############################################&#8221;</div>
<div id="_mcePaste" style="position: absolute; left: -10000px; top: 0px; width: 1px; height: 1px; overflow-x: hidden; overflow-y: hidden;">echo &#8220;&#8221;</div>
<div id="_mcePaste" style="position: absolute; left: -10000px; top: 0px; width: 1px; height: 1px; overflow-x: hidden; overflow-y: hidden;">echo &#8220;Scriptin Kullanimi:&#8221;</div>
<div id="_mcePaste" style="position: absolute; left: -10000px; top: 0px; width: 1px; height: 1px; overflow-x: hidden; overflow-y: hidden;">echo &#8220;&#8221;</div>
<div id="_mcePaste" style="position: absolute; left: -10000px; top: 0px; width: 1px; height: 1px; overflow-x: hidden; overflow-y: hidden;">echo &#8220;./kuyruksil &lt;printer_adi&gt;&#8221;<span style="white-space: pre;"> </span></div>
<div id="_mcePaste" style="position: absolute; left: -10000px; top: 0px; width: 1px; height: 1px; overflow-x: hidden; overflow-y: hidden;">echo &#8220;&#8221;</div>
<div id="_mcePaste" style="position: absolute; left: -10000px; top: 0px; width: 1px; height: 1px; overflow-x: hidden; overflow-y: hidden;">echo &#8220;Printer Listesi:&#8221;</div>
<div id="_mcePaste" style="position: absolute; left: -10000px; top: 0px; width: 1px; height: 1px; overflow-x: hidden; overflow-y: hidden;">echo &#8220;&#8221;</div>
<div id="_mcePaste" style="position: absolute; left: -10000px; top: 0px; width: 1px; height: 1px; overflow-x: hidden; overflow-y: hidden;">lpstat -a # Sistemde tanimli printerlar listelenir.</div>
<div id="_mcePaste" style="position: absolute; left: -10000px; top: 0px; width: 1px; height: 1px; overflow-x: hidden; overflow-y: hidden;">echo &#8220;&#8221;</div>
<div id="_mcePaste" style="position: absolute; left: -10000px; top: 0px; width: 1px; height: 1px; overflow-x: hidden; overflow-y: hidden;"><span style="white-space: pre;"> </span></div>
<div id="_mcePaste" style="position: absolute; left: -10000px; top: 0px; width: 1px; height: 1px; overflow-x: hidden; overflow-y: hidden;">exit $E_NO_ARGS</div>
<div id="_mcePaste" style="position: absolute; left: -10000px; top: 0px; width: 1px; height: 1px; overflow-x: hidden; overflow-y: hidden;">fi</div>
<div id="_mcePaste" style="position: absolute; left: -10000px; top: 0px; width: 1px; height: 1px; overflow-x: hidden; overflow-y: hidden;">lpstat $1 &gt; print_list  # Kuyrukta bekleyen istekler print_list dosyasina aktarilir.</div>
<div id="_mcePaste" style="position: absolute; left: -10000px; top: 0px; width: 1px; height: 1px; overflow-x: hidden; overflow-y: hidden;">declare -a ARRAY # Kuyrul listesini saymak icin aralik tanimlanir.</div>
<div id="_mcePaste" style="position: absolute; left: -10000px; top: 0px; width: 1px; height: 1px; overflow-x: hidden; overflow-y: hidden;">exec 2&lt;print_list</div>
<div id="_mcePaste" style="position: absolute; left: -10000px; top: 0px; width: 1px; height: 1px; overflow-x: hidden; overflow-y: hidden;">let count=0</div>
<div id="_mcePaste" style="position: absolute; left: -10000px; top: 0px; width: 1px; height: 1px; overflow-x: hidden; overflow-y: hidden;">while read LINE &lt;&amp;2; do</div>
<div id="_mcePaste" style="position: absolute; left: -10000px; top: 0px; width: 1px; height: 1px; overflow-x: hidden; overflow-y: hidden;">ARRAY[$count]=$LINE</div>
<div id="_mcePaste" style="position: absolute; left: -10000px; top: 0px; width: 1px; height: 1px; overflow-x: hidden; overflow-y: hidden;">((count++))</div>
<div id="_mcePaste" style="position: absolute; left: -10000px; top: 0px; width: 1px; height: 1px; overflow-x: hidden; overflow-y: hidden;">echo `cancel $LINE` # Silme islemi yapilir.</div>
<div id="_mcePaste" style="position: absolute; left: -10000px; top: 0px; width: 1px; height: 1px; overflow-x: hidden; overflow-y: hidden;">echo &#8220;$LINE &#8211;&gt; SILINDI!&#8221;</div>
<div id="_mcePaste" style="position: absolute; left: -10000px; top: 0px; width: 1px; height: 1px; overflow-x: hidden; overflow-y: hidden;">done</div>
<div id="_mcePaste" style="position: absolute; left: -10000px; top: 0px; width: 1px; height: 1px; overflow-x: hidden; overflow-y: hidden;">echo `rm print_list` # print_list dosyasi silinir.</div>
<div id="_mcePaste" style="position: absolute; left: -10000px; top: 0px; width: 1px; height: 1px; overflow-x: hidden; overflow-y: hidden;">echo &#8220;&#8221;</div>
<div id="_mcePaste" style="position: absolute; left: -10000px; top: 0px; width: 1px; height: 1px; overflow-x: hidden; overflow-y: hidden;">echo TOPLAM SILINEN : ${#ARRAY[@]} # Kuyruktan silinen istek sayisi yazdirilir.</div>
<div id="_mcePaste" style="position: absolute; left: -10000px; top: 0px; width: 1px; height: 1px; overflow-x: hidden; overflow-y: hidden;">echo &#8220;&#8221;</div>
<div id="_mcePaste" style="position: absolute; left: -10000px; top: 0px; width: 1px; height: 1px; overflow-x: hidden; overflow-y: hidden;">echo &#8220;(c)2008 Seyhan Tekelioglu&#8221;</div>
<div id="_mcePaste" style="position: absolute; left: -10000px; top: 0px; width: 1px; height: 1px; overflow-x: hidden; overflow-y: hidden;">echo &#8220;&#8221;</div>
<div id="_mcePaste" style="position: absolute; left: -10000px; top: 0px; width: 1px; height: 1px; overflow-x: hidden; overflow-y: hidden;">exec 2&gt;&amp;-</div>
<div id="_mcePaste" style="position: absolute; left: -10000px; top: 0px; width: 1px; height: 1px; overflow-x: hidden; overflow-y: hidden;">exit 0</div>
<p><span style="font-family: 'Lucida Grande', Verdana, 'Bitstream Vera Sans', Arial, sans-serif; line-height: 22px; color: #555555;"></p>
<pre style="background-image: initial; background-repeat: initial; background-attachment: initial; -webkit-background-clip: initial; -webkit-background-origin: initial; background-color: #ededff; font-size: 11px; line-height: 1.3em; overflow-x: auto; overflow-y: auto; width: 525px; clear: both; background-position: initial initial; padding: 11px; margin: 0px; border: 1px solid #dadada;">#!/bin/bash

E_NO_ARGS=65

if [ $# -eq 0 ]
then
  echo "##############################################"
  echo "#                kuyruksil                   #"
  echo "#                                            #"
  echo "#     Printer Kuyruk Temizleme Scripti       #"
  echo "#                                            #"
  echo "#        Son Guncelleme : 22.01.2008         #"
  echo "#                                            #"
  echo "#         (c)2008  Seyhan Tekelioglu         #"
  echo "##############################################"
  echo ""
  echo "Scriptin Kullanimi:"
  echo ""
  echo "./kuyruksil &lt;printer_adi&gt;"
  echo ""
  echo "Printer Listesi:"
  echo ""
  lpstat -a # Sistemde tanimli printerlar listelenir.
  echo ""

  exit $E_NO_ARGS
fi  

lpstat $1 &gt; print_list  # Kuyrukta bekleyen istekler print_list dosyasina aktarilir.

declare -a ARRAY # Kuyrul listesini saymak icin aralik tanimlanir.

exec 2&lt;print_list
let count=0

while read LINE &lt;&amp;2; do

    ARRAY[$count]=$LINE
    ((count++))

echo `cancel $LINE` # Silme islemi yapilir.

echo "$LINE --&gt; SILINDI!"

done

echo `rm print_list` # print_list dosyasi silinir.

echo ""
echo TOPLAM SILINEN : ${#ARRAY[@]} # Kuyruktan silinen istek sayisi yazdirilir.
echo ""
echo "(c)2008 Seyhan Tekelioglu"
echo ""

exec 2&gt;&amp;-

exit 0</pre>
<p></span></p>
<p>Scripti indirmek için <a href="http://www.seyhan.biz/scripts/kuyruksil.rar">tıklayın</a>.</p>

<p class="sayac_bilgi">Bu yazı toplamda 547, bugün ise 1 kez görüntülenmiş. Son okunma tarihi 10.09.2010</p>
<h4  class="related_post_title">Benzer Yazılar</h4><ul class="related_post"><li><a href="http://www.seyhan.biz/index.php/2009/12/04/sisman/" title="Sisman">Sisman</a></li><li><a href="http://www.seyhan.biz/index.php/2010/06/07/linux-uzerine-oracle-e-business-suite-11-5-10-2-kurulumu/" title="Linux Üzerine Oracle E-Business Suite 11.5.10.2 Kurulumu">Linux Üzerine Oracle E-Business Suite 11.5.10.2 Kurulumu</a></li><li><a href="http://www.seyhan.biz/index.php/2010/05/14/solaris-sistemlerde-printer-tanimlama/" title="Solaris Sistemlerde Printer Tanımlama">Solaris Sistemlerde Printer Tanımlama</a></li></ul>]]></content:encoded>
			<wfw:commentRss>http://www.seyhan.biz/index.php/2009/12/04/kuyruksil/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
	</channel>
</rss>
