<?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 switch users in a script file automatically? in Operating System - HP-UX</title>
    <link>https://community.hpe.com/t5/operating-system-hp-ux/how-to-switch-users-in-a-script-file-automatically/m-p/2527613#M758577</link>
    <description>If you run the script with id=root:&lt;BR /&gt;su - user -c command</description>
    <pubDate>Mon, 14 May 2001 07:36:58 GMT</pubDate>
    <dc:creator>Vincenzo Restuccia</dc:creator>
    <dc:date>2001-05-14T07:36:58Z</dc:date>
    <item>
      <title>How to switch users in a script file automatically?</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/how-to-switch-users-in-a-script-file-automatically/m-p/2527609#M758573</link>
      <description>Hi, there,&lt;BR /&gt;How can I switch from one account to another using "say SU - USER -C .." wothout being prompted for passwd interactively? &lt;BR /&gt;Currently we use "Autosys" to start/stop a batch process that must be run in a specific user account. &lt;BR /&gt;I will summarize all the answers and post it later.&lt;BR /&gt;Thank you for your help  &lt;BR /&gt;</description>
      <pubDate>Fri, 11 May 2001 15:54:27 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/how-to-switch-users-in-a-script-file-automatically/m-p/2527609#M758573</guid>
      <dc:creator>Thomas Qiang</dc:creator>
      <dc:date>2001-05-11T15:54:27Z</dc:date>
    </item>
    <item>
      <title>Re: How to switch users in a script file automatically?</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/how-to-switch-users-in-a-script-file-automatically/m-p/2527610#M758574</link>
      <description>Hi Thomas:&lt;BR /&gt;&lt;BR /&gt;In a simple shell script, you cannot issue and 'su' and avoid the interactive prompt.&lt;BR /&gt;&lt;BR /&gt;...JRF...</description>
      <pubDate>Fri, 11 May 2001 15:59:57 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/how-to-switch-users-in-a-script-file-automatically/m-p/2527610#M758574</guid>
      <dc:creator>James R. Ferguson</dc:creator>
      <dc:date>2001-05-11T15:59:57Z</dc:date>
    </item>
    <item>
      <title>Re: How to switch users in a script file automatically?</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/how-to-switch-users-in-a-script-file-automatically/m-p/2527611#M758575</link>
      <description>Hi Thomas,&lt;BR /&gt;from the man pages:&lt;BR /&gt;"To use su, the appropriate password must be supplied unless the current user is superuser."&lt;BR /&gt;&lt;BR /&gt;maybe "Sudo" can help you on giving superuser permissions on some commands to some users.&lt;BR /&gt;I've never tried it for this kind of problems.&lt;BR /&gt;good luck.</description>
      <pubDate>Fri, 11 May 2001 16:07:25 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/how-to-switch-users-in-a-script-file-automatically/m-p/2527611#M758575</guid>
      <dc:creator>Pedro Sousa</dc:creator>
      <dc:date>2001-05-11T16:07:25Z</dc:date>
    </item>
    <item>
      <title>Re: How to switch users in a script file automatically?</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/how-to-switch-users-in-a-script-file-automatically/m-p/2527612#M758576</link>
      <description>I had the same problem. What I did was to write a C routine that used the setuid and setgid functions. The compiled executable then needs to be owned by root before the command will switch to another user. You must turn off the write bit or you will have a security hole in your system.</description>
      <pubDate>Fri, 11 May 2001 21:45:47 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/how-to-switch-users-in-a-script-file-automatically/m-p/2527612#M758576</guid>
      <dc:creator>Lawrence Mahan</dc:creator>
      <dc:date>2001-05-11T21:45:47Z</dc:date>
    </item>
    <item>
      <title>Re: How to switch users in a script file automatically?</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/how-to-switch-users-in-a-script-file-automatically/m-p/2527613#M758577</link>
      <description>If you run the script with id=root:&lt;BR /&gt;su - user -c command</description>
      <pubDate>Mon, 14 May 2001 07:36:58 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/how-to-switch-users-in-a-script-file-automatically/m-p/2527613#M758577</guid>
      <dc:creator>Vincenzo Restuccia</dc:creator>
      <dc:date>2001-05-14T07:36:58Z</dc:date>
    </item>
    <item>
      <title>Re: How to switch users in a script file automatically?</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/how-to-switch-users-in-a-script-file-automatically/m-p/2527614#M758578</link>
      <description>Would it be possible in your environment to change the job definition in AutoSys to have it run as the user you need it to run as? You can specify the user to run the job as when you create the job. That would eliminate the need to do an "su".&lt;BR /&gt;</description>
      <pubDate>Mon, 14 May 2001 10:45:28 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/how-to-switch-users-in-a-script-file-automatically/m-p/2527614#M758578</guid>
      <dc:creator>Jerry Jordak</dc:creator>
      <dc:date>2001-05-14T10:45:28Z</dc:date>
    </item>
  </channel>
</rss>

