<?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: Need help with a script in Operating System - HP-UX</title>
    <link>https://community.hpe.com/t5/operating-system-hp-ux/need-help-with-a-script/m-p/5079463#M440171</link>
    <description>Scripts were most useful, thanks.</description>
    <pubDate>Wed, 09 Jan 2008 00:21:49 GMT</pubDate>
    <dc:creator>S-un-B-ix-S</dc:creator>
    <dc:date>2008-01-09T00:21:49Z</dc:date>
    <item>
      <title>Need help with a script</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/need-help-with-a-script/m-p/5079458#M440166</link>
      <description>One of our junior admins accidentally did a recursive chown in our main home directory and now alot of our user directory have incorrect ownership. I have a list of the users that have the incorrect info. I need to parse out the name and the group ID from the passwd file and then apply it to all of the directories themselves and the files within those directories. &lt;BR /&gt;&lt;BR /&gt;can anyone help me with this? thanks so much.</description>
      <pubDate>Tue, 13 Nov 2007 12:49:06 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/need-help-with-a-script/m-p/5079458#M440166</guid>
      <dc:creator>S-un-B-ix-S</dc:creator>
      <dc:date>2007-11-13T12:49:06Z</dc:date>
    </item>
    <item>
      <title>Re: Need help with a script</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/need-help-with-a-script/m-p/5079459#M440167</link>
      <description>&lt;!--!*#--&gt;Hi:&lt;BR /&gt;&lt;BR /&gt;Hmmm.  OK, you can do this:&lt;BR /&gt;&lt;BR /&gt;# cat .fixme&lt;BR /&gt;#!/usr/bin/sh&lt;BR /&gt;while read NAME&lt;BR /&gt;do&lt;BR /&gt;    GROUP=$(awk -F: -v NAME=${NAME} '$1==NAME {print $4}' /etc/passwd)&lt;BR /&gt;    echo chown -R ${NAME} ${GROUP} /home/${NAME}&lt;BR /&gt;done &amp;lt; usernames&lt;BR /&gt;&lt;BR /&gt;...where 'usernames' has the account names to "fix", one per line.&lt;BR /&gt;&lt;BR /&gt;Regards!&lt;BR /&gt;&lt;BR /&gt;...JRF...&lt;BR /&gt;</description>
      <pubDate>Tue, 13 Nov 2007 13:22:38 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/need-help-with-a-script/m-p/5079459#M440167</guid>
      <dc:creator>James R. Ferguson</dc:creator>
      <dc:date>2007-11-13T13:22:38Z</dc:date>
    </item>
    <item>
      <title>Re: Need help with a script</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/need-help-with-a-script/m-p/5079460#M440168</link>
      <description>Shalom,&lt;BR /&gt;&lt;BR /&gt;Actually you need to compare the system with an undamaged one and make the change.&lt;BR /&gt;&lt;BR /&gt;ls -R &amp;gt; good.sys.txt&lt;BR /&gt;ls -R &amp;gt; bad.sys.txt&lt;BR /&gt;&lt;BR /&gt;You may need to do this directory by directory.&lt;BR /&gt;&lt;BR /&gt;You can't just remap things from /etc/passwd.&lt;BR /&gt;&lt;BR /&gt;If it were Linux, you could do an rpm -qf for every rpm and use that to check and change the ownership.&lt;BR /&gt;&lt;BR /&gt;This is a process that involves manual work. Its also a good way for a junior admin to pay for his/her mistake and learn the importance of permissions.&lt;BR /&gt;&lt;BR /&gt;After that a test plan.&lt;BR /&gt;&lt;BR /&gt;SEP</description>
      <pubDate>Tue, 13 Nov 2007 13:24:33 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/need-help-with-a-script/m-p/5079460#M440168</guid>
      <dc:creator>Steven E. Protter</dc:creator>
      <dc:date>2007-11-13T13:24:33Z</dc:date>
    </item>
    <item>
      <title>Re: Need help with a script</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/need-help-with-a-script/m-p/5079461#M440169</link>
      <description>HI (AGAIN):&lt;BR /&gt;&lt;BR /&gt;Well, is appears that my second comment in your duplicate post in the Language family was deleted by a moderator because you posted your query twice.&lt;BR /&gt;&lt;BR /&gt;Thus:&lt;BR /&gt;&lt;BR /&gt;If by "main home directory" you do NOT mean '/home' but rather something disasterous like '/', then:&lt;BR /&gt;&lt;BR /&gt;# swverify -F \*&lt;BR /&gt;&lt;BR /&gt;...will repair the permissions and ownership of products and patches represented by entries in the IPD (Installed Product Database --- '/var/adm/sw').&lt;BR /&gt;&lt;BR /&gt;Regards!&lt;BR /&gt;&lt;BR /&gt;...JRF...</description>
      <pubDate>Tue, 13 Nov 2007 14:31:59 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/need-help-with-a-script/m-p/5079461#M440169</guid>
      <dc:creator>James R. Ferguson</dc:creator>
      <dc:date>2007-11-13T14:31:59Z</dc:date>
    </item>
    <item>
      <title>Re: Need help with a script</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/need-help-with-a-script/m-p/5079462#M440170</link>
      <description>Hi:&lt;BR /&gt;&lt;BR /&gt;ALSO, please re-examine your earlier thread here:&lt;BR /&gt;&lt;BR /&gt;&lt;A href="https://forums1.itrc.hp.com/service/forums/questionanswer.do?threadId=1144475" target="_blank"&gt;https://forums1.itrc.hp.com/service/forums/questionanswer.do?threadId=1144475&lt;/A&gt;&lt;BR /&gt;&lt;BR /&gt;...to see if the answers therein answered that query.  Thanks!&lt;BR /&gt;&lt;BR /&gt;...JRF...</description>
      <pubDate>Tue, 13 Nov 2007 14:34:28 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/need-help-with-a-script/m-p/5079462#M440170</guid>
      <dc:creator>James R. Ferguson</dc:creator>
      <dc:date>2007-11-13T14:34:28Z</dc:date>
    </item>
    <item>
      <title>Re: Need help with a script</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/need-help-with-a-script/m-p/5079463#M440171</link>
      <description>Scripts were most useful, thanks.</description>
      <pubDate>Wed, 09 Jan 2008 00:21:49 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/need-help-with-a-script/m-p/5079463#M440171</guid>
      <dc:creator>S-un-B-ix-S</dc:creator>
      <dc:date>2008-01-09T00:21:49Z</dc:date>
    </item>
  </channel>
</rss>

