<?xml version='1.0' encoding='UTF-8'?><?xml-stylesheet href="http://www.blogger.com/styles/atom.css" type="text/css"?><feed xmlns='http://www.w3.org/2005/Atom' xmlns:openSearch='http://a9.com/-/spec/opensearchrss/1.0/'><id>tag:blogger.com,1999:blog-7800991272705950027.post2124112202010378535..comments</id><updated>2009-11-17T11:58:54.880+09:00</updated><category term='заметка'/><category term='php5'/><category term='статьи'/><category term='mail'/><category term='wiki'/><category term='tablet PC'/><category term='javascript'/><category term='goodbye windows'/><category term='net'/><category term='socks'/><category term='IT'/><category term='perl'/><category term='mpd4'/><category term='asus'/><category term='поднимает настроение'/><category term='openvz'/><category term='ports'/><category term='государство'/><category term='curl'/><category term='юмор'/><category term='вопрос'/><category term='switch'/><category term='suphp'/><category term='pppoe'/><category term='firefox'/><category term='ppp'/><category term='политика'/><category term='find'/><category term='ldap'/><category term='shell'/><category term='законы'/><category term='блог'/><category term='windows'/><category term='irc'/><category term='freebsd'/><category term='ocr'/><category term='firewall'/><category term='kvm'/><category term='raid'/><category term='nic'/><category term='виртуализация'/><category term='hardware'/><category term='xen'/><category term='apache'/><category term='linux'/><category term='уязвимости'/><category term='virtualbox'/><category term='Россия'/><category term='sysctl'/><category term='mysql'/><category term='новости'/><category term='ssh'/><category term='патенты'/><category term='odf'/><category term='Open Source'/><category term='ooxml'/><category term='squid'/><category term='статья'/><category term='android'/><category term='freeradius'/><category term='kernel'/><category term='microsoft'/><category term='samba'/><category term='qemu'/><category term='jail'/><category term='vpn'/><category term='опрос'/><category term='ubuntu'/><category term='утилиты'/><category term='netflow'/><category term='ftp'/><category term='google'/><category term='SCO'/><category term='ссылки'/><category term='зеркало'/><title type='text'>Comments on Propheta: Запрет запуска второй копии скрипта</title><link rel='http://schemas.google.com/g/2005#feed' type='application/atom+xml' href='http://www.propheta.ru/feeds/2124112202010378535/comments/default'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/7800991272705950027/2124112202010378535/comments/default'/><link rel='alternate' type='text/html' href='http://www.propheta.ru/2009/11/blog-post.html'/><author><name>Князь</name><email>noreply@blogger.com</email><gd:image xmlns:gd='http://schemas.google.com/g/2005' rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='32' src='http://bp1.blogger.com/_9z9np6DHLUU/R_YAI5h2o1I/AAAAAAAAAA8/64kDzQcz8CA/S220/1068-square.jpg'/></author><generator version='7.00' uri='http://www.blogger.com'>Blogger</generator><openSearch:totalResults>9</openSearch:totalResults><openSearch:startIndex>1</openSearch:startIndex><openSearch:itemsPerPage>25</openSearch:itemsPerPage><entry><id>tag:blogger.com,1999:blog-7800991272705950027.post-1178719074669264115</id><published>2009-11-17T11:58:54.880+09:00</published><updated>2009-11-17T11:58:54.880+09:00</updated><title type='text'>/proc тоже не везде бывает :)</title><content type='html'>/proc тоже не везде бывает :)</content><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/7800991272705950027/2124112202010378535/comments/default/1178719074669264115'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/7800991272705950027/2124112202010378535/comments/default/1178719074669264115'/><link rel='alternate' type='text/html' href='http://www.propheta.ru/2009/11/blog-post.html?showComment=1258426734880#c1178719074669264115' title=''/><author><name>Князь</name><uri>http://www.blogger.com/profile/11218942243308963007</uri><email>noreply@blogger.com</email><gd:image xmlns:gd='http://schemas.google.com/g/2005' rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='32' src='http://bp1.blogger.com/_9z9np6DHLUU/R_YAI5h2o1I/AAAAAAAAAA8/64kDzQcz8CA/S220/1068-square.jpg'/></author><thr:in-reply-to xmlns:thr='http://purl.org/syndication/thread/1.0' href='http://www.propheta.ru/2009/11/blog-post.html' ref='tag:blogger.com,1999:blog-7800991272705950027.post-2124112202010378535' source='http://www.blogger.com/feeds/7800991272705950027/posts/default/2124112202010378535' type='text/html'/><gd:extendedProperty xmlns:gd='http://schemas.google.com/g/2005' name='blogger.itemClass' value='pid-2127641460'/></entry><entry><id>tag:blogger.com,1999:blog-7800991272705950027.post-26050623075089398</id><published>2009-11-17T02:48:54.185+09:00</published><updated>2009-11-17T02:48:54.185+09:00</updated><title type='text'>Сколько админов, столько и путей решения =)</title><content type='html'>Сколько админов, столько и путей решения =)</content><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/7800991272705950027/2124112202010378535/comments/default/26050623075089398'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/7800991272705950027/2124112202010378535/comments/default/26050623075089398'/><link rel='alternate' type='text/html' href='http://www.propheta.ru/2009/11/blog-post.html?showComment=1258393734185#c26050623075089398' title=''/><author><name>DOMr</name><uri>http://www.blogger.com/profile/17852635722638264280</uri><email>noreply@blogger.com</email><gd:image xmlns:gd='http://schemas.google.com/g/2005' rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:in-reply-to xmlns:thr='http://purl.org/syndication/thread/1.0' href='http://www.propheta.ru/2009/11/blog-post.html' ref='tag:blogger.com,1999:blog-7800991272705950027.post-2124112202010378535' source='http://www.blogger.com/feeds/7800991272705950027/posts/default/2124112202010378535' type='text/html'/><gd:extendedProperty xmlns:gd='http://schemas.google.com/g/2005' name='blogger.itemClass' value='pid-1825987924'/></entry><entry><id>tag:blogger.com,1999:blog-7800991272705950027.post-8752035963777329859</id><published>2009-11-16T18:48:13.823+09:00</published><updated>2009-11-16T18:48:13.823+09:00</updated><title type='text'>Проверку существования процесса по пиду

[ -d &amp;quo...</title><content type='html'>Проверку существования процесса по пиду&lt;br /&gt;&lt;br /&gt;[ -d &amp;quot;/proc/$pid&amp;quot; ] &amp;amp;&amp;amp; echo Yes || echo No</content><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/7800991272705950027/2124112202010378535/comments/default/8752035963777329859'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/7800991272705950027/2124112202010378535/comments/default/8752035963777329859'/><link rel='alternate' type='text/html' href='http://www.propheta.ru/2009/11/blog-post.html?showComment=1258364893823#c8752035963777329859' title=''/><author><name>Sergey</name><uri>http://www.blogger.com/profile/08243035538176421721</uri><email>noreply@blogger.com</email><gd:image xmlns:gd='http://schemas.google.com/g/2005' rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:in-reply-to xmlns:thr='http://purl.org/syndication/thread/1.0' href='http://www.propheta.ru/2009/11/blog-post.html' ref='tag:blogger.com,1999:blog-7800991272705950027.post-2124112202010378535' source='http://www.blogger.com/feeds/7800991272705950027/posts/default/2124112202010378535' type='text/html'/><gd:extendedProperty xmlns:gd='http://schemas.google.com/g/2005' name='blogger.itemClass' value='pid-392480233'/></entry><entry><id>tag:blogger.com,1999:blog-7800991272705950027.post-5866021264052278767</id><published>2009-11-16T11:33:33.496+09:00</published><updated>2009-11-16T11:33:33.496+09:00</updated><title type='text'>grep&amp;#39;ов много :)</title><content type='html'>grep&amp;#39;ов много :)</content><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/7800991272705950027/2124112202010378535/comments/default/5866021264052278767'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/7800991272705950027/2124112202010378535/comments/default/5866021264052278767'/><link rel='alternate' type='text/html' href='http://www.propheta.ru/2009/11/blog-post.html?showComment=1258338813496#c5866021264052278767' title=''/><author><name>Князь</name><uri>http://www.blogger.com/profile/11218942243308963007</uri><email>noreply@blogger.com</email><gd:image xmlns:gd='http://schemas.google.com/g/2005' rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='32' src='http://bp1.blogger.com/_9z9np6DHLUU/R_YAI5h2o1I/AAAAAAAAAA8/64kDzQcz8CA/S220/1068-square.jpg'/></author><thr:in-reply-to xmlns:thr='http://purl.org/syndication/thread/1.0' href='http://www.propheta.ru/2009/11/blog-post.html' ref='tag:blogger.com,1999:blog-7800991272705950027.post-2124112202010378535' source='http://www.blogger.com/feeds/7800991272705950027/posts/default/2124112202010378535' type='text/html'/><gd:extendedProperty xmlns:gd='http://schemas.google.com/g/2005' name='blogger.itemClass' value='pid-2127641460'/></entry><entry><id>tag:blogger.com,1999:blog-7800991272705950027.post-5649316411754513746</id><published>2009-11-16T04:25:00.213+09:00</published><updated>2009-11-16T04:25:00.213+09:00</updated><title type='text'>А для данной задачи лучше будет так :)

if [ -n &amp;q...</title><content type='html'>А для данной задачи лучше будет так :)&lt;br /&gt;&lt;br /&gt;if [ -n &amp;quot;`ps -ef | grep -v grep | grep &amp;quot;$app&amp;quot;`&amp;quot; ]; then&lt;br /&gt;echo &amp;quot;$app уже запущен&amp;quot;&lt;br /&gt;exit 0&lt;br /&gt;fi</content><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/7800991272705950027/2124112202010378535/comments/default/5649316411754513746'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/7800991272705950027/2124112202010378535/comments/default/5649316411754513746'/><link rel='alternate' type='text/html' href='http://www.propheta.ru/2009/11/blog-post.html?showComment=1258313100213#c5649316411754513746' title=''/><author><name>DOMr</name><uri>http://www.blogger.com/profile/17852635722638264280</uri><email>noreply@blogger.com</email><gd:image xmlns:gd='http://schemas.google.com/g/2005' rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:in-reply-to xmlns:thr='http://purl.org/syndication/thread/1.0' href='http://www.propheta.ru/2009/11/blog-post.html' ref='tag:blogger.com,1999:blog-7800991272705950027.post-2124112202010378535' source='http://www.blogger.com/feeds/7800991272705950027/posts/default/2124112202010378535' type='text/html'/><gd:extendedProperty xmlns:gd='http://schemas.google.com/g/2005' name='blogger.itemClass' value='pid-1825987924'/></entry><entry><id>tag:blogger.com,1999:blog-7800991272705950027.post-2125143271660450167</id><published>2009-11-16T04:11:23.108+09:00</published><updated>2009-11-16T04:11:23.108+09:00</updated><title type='text'>Я делаю так:
if [ &amp;quot;`ps -ef | grep -v grep | g...</title><content type='html'>Я делаю так:&lt;br /&gt;if [ &amp;quot;`ps -ef | grep -v grep | grep &amp;quot;$app&amp;quot;`&amp;quot; == &amp;quot;&amp;quot; ]; then&lt;br /&gt;    echo &amp;quot;$app не запущен&amp;quot;&lt;br /&gt;else&lt;br /&gt;    echo &amp;quot;$app запущен&amp;quot;&lt;br /&gt;fi</content><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/7800991272705950027/2124112202010378535/comments/default/2125143271660450167'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/7800991272705950027/2124112202010378535/comments/default/2125143271660450167'/><link rel='alternate' type='text/html' href='http://www.propheta.ru/2009/11/blog-post.html?showComment=1258312283108#c2125143271660450167' title=''/><author><name>DOMr</name><uri>http://www.blogger.com/profile/17852635722638264280</uri><email>noreply@blogger.com</email><gd:image xmlns:gd='http://schemas.google.com/g/2005' rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:in-reply-to xmlns:thr='http://purl.org/syndication/thread/1.0' href='http://www.propheta.ru/2009/11/blog-post.html' ref='tag:blogger.com,1999:blog-7800991272705950027.post-2124112202010378535' source='http://www.blogger.com/feeds/7800991272705950027/posts/default/2124112202010378535' type='text/html'/><gd:extendedProperty xmlns:gd='http://schemas.google.com/g/2005' name='blogger.itemClass' value='pid-1825987924'/></entry><entry><id>tag:blogger.com,1999:blog-7800991272705950027.post-5753271304431020628</id><published>2009-11-14T22:33:09.780+09:00</published><updated>2009-11-14T22:33:09.780+09:00</updated><title type='text'>Проверку существования процесса можно организовать...</title><content type='html'>Проверку существования процесса можно организовать таким образом&lt;br /&gt;if [ -z &amp;quot;$(ps -p $(cat &amp;quot;$pid_file&amp;quot;) -o pid=)&amp;quot; ]&lt;br /&gt;then&lt;br /&gt;   # Код выполняемый, если&lt;br /&gt;   # процесс с сохраненным pid&lt;br /&gt;   # не обнаружен&lt;br /&gt;fi</content><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/7800991272705950027/2124112202010378535/comments/default/5753271304431020628'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/7800991272705950027/2124112202010378535/comments/default/5753271304431020628'/><link rel='alternate' type='text/html' href='http://www.propheta.ru/2009/11/blog-post.html?showComment=1258205589780#c5753271304431020628' title=''/><author><name>Князь</name><uri>http://www.blogger.com/profile/11218942243308963007</uri><email>noreply@blogger.com</email><gd:image xmlns:gd='http://schemas.google.com/g/2005' rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='32' src='http://bp1.blogger.com/_9z9np6DHLUU/R_YAI5h2o1I/AAAAAAAAAA8/64kDzQcz8CA/S220/1068-square.jpg'/></author><thr:in-reply-to xmlns:thr='http://purl.org/syndication/thread/1.0' href='http://www.propheta.ru/2009/11/blog-post.html' ref='tag:blogger.com,1999:blog-7800991272705950027.post-2124112202010378535' source='http://www.blogger.com/feeds/7800991272705950027/posts/default/2124112202010378535' type='text/html'/><gd:extendedProperty xmlns:gd='http://schemas.google.com/g/2005' name='blogger.itemClass' value='pid-2127641460'/></entry><entry><id>tag:blogger.com,1999:blog-7800991272705950027.post-5792954988818041919</id><published>2009-11-14T22:25:30.313+09:00</published><updated>2009-11-14T22:25:30.313+09:00</updated><title type='text'>вы правы, но лучше такая проверка, чем совсем ника...</title><content type='html'>вы правы, но лучше такая проверка, чем совсем никакой.</content><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/7800991272705950027/2124112202010378535/comments/default/5792954988818041919'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/7800991272705950027/2124112202010378535/comments/default/5792954988818041919'/><link rel='alternate' type='text/html' href='http://www.propheta.ru/2009/11/blog-post.html?showComment=1258205130313#c5792954988818041919' title=''/><author><name>andrey i. mavlyanov</name><uri>http://www.blogger.com/profile/01462095501122800636</uri><email>noreply@blogger.com</email><gd:image xmlns:gd='http://schemas.google.com/g/2005' rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:in-reply-to xmlns:thr='http://purl.org/syndication/thread/1.0' href='http://www.propheta.ru/2009/11/blog-post.html' ref='tag:blogger.com,1999:blog-7800991272705950027.post-2124112202010378535' source='http://www.blogger.com/feeds/7800991272705950027/posts/default/2124112202010378535' type='text/html'/><gd:extendedProperty xmlns:gd='http://schemas.google.com/g/2005' name='blogger.itemClass' value='pid-2012446343'/></entry><entry><id>tag:blogger.com,1999:blog-7800991272705950027.post-120534071939611096</id><published>2009-11-14T20:11:14.929+09:00</published><updated>2009-11-14T20:11:14.929+09:00</updated><title type='text'>А если скрипт умрёт не выполнив rm? Вы pid в файл ...</title><content type='html'>А если скрипт умрёт не выполнив rm? Вы pid в файл пишете, но нигде не проверяете что процесс с таким пидом жив.</content><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/7800991272705950027/2124112202010378535/comments/default/120534071939611096'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/7800991272705950027/2124112202010378535/comments/default/120534071939611096'/><link rel='alternate' type='text/html' href='http://www.propheta.ru/2009/11/blog-post.html?showComment=1258197074929#c120534071939611096' title=''/><author><name>Me</name><uri>http://www.blogger.com/profile/10911718580652862297</uri><email>noreply@blogger.com</email><gd:image xmlns:gd='http://schemas.google.com/g/2005' rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:in-reply-to xmlns:thr='http://purl.org/syndication/thread/1.0' href='http://www.propheta.ru/2009/11/blog-post.html' ref='tag:blogger.com,1999:blog-7800991272705950027.post-2124112202010378535' source='http://www.blogger.com/feeds/7800991272705950027/posts/default/2124112202010378535' type='text/html'/><gd:extendedProperty xmlns:gd='http://schemas.google.com/g/2005' name='blogger.itemClass' value='pid-481101592'/></entry></feed>
