<?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: User cant shutdown the server in Operating System - HP-UX</title>
    <link>https://community.hpe.com/t5/operating-system-hp-ux/user-cant-shutdown-the-server/m-p/3460150#M209971</link>
    <description>Hi Robert,&lt;BR /&gt;   &lt;BR /&gt;   Yes the old server have the /etc/shutdown.allow this file and I do remember i copy also. &lt;BR /&gt;&lt;BR /&gt;regards&lt;BR /&gt;Leon</description>
    <pubDate>Tue, 11 Jan 2005 05:32:03 GMT</pubDate>
    <dc:creator>Leon Shen</dc:creator>
    <dc:date>2005-01-11T05:32:03Z</dc:date>
    <item>
      <title>User cant shutdown the server</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/user-cant-shutdown-the-server/m-p/3460147#M209968</link>
      <description>Hi Experts,&lt;BR /&gt;&lt;BR /&gt;  Currently successfull migration from D350 to rp2470 for customer. All the applications are test ok on rp2470. Just have 2 problems need some helps. &lt;BR /&gt;&lt;BR /&gt;1. On the old D350, customer have write a script  which allow non-unix skill people shutdown the server during administrator not around. Of course there was user call shutdown in /home. I did copy /etc/hosts and /etc/profile and /home from D350 to rp2470. But when customer test the script and it seem cant shutdown the server and the error mesg show:&lt;BR /&gt;&lt;BR /&gt;shutdown cannot be run from a mounted file system --existing shutdown--&lt;BR /&gt;change directory to the root volume ("/" will work) and try again. &lt;BR /&gt;&lt;BR /&gt;I guess something do with the profile. here is the profile for user - shutdown&lt;BR /&gt;&lt;BR /&gt;# script for PBS operators by phuah @ 30.8.93&lt;BR /&gt;# modified for KDU @ 29.7.95&lt;BR /&gt;# modified for Carrier @ 10.4.96&lt;BR /&gt;# modified for In-house use @ 07.08.96&lt;BR /&gt;# modified for Lonpac Singapore use @ 3.1.97&lt;BR /&gt;&lt;BR /&gt;# disable interrupt, quit &amp;amp; termination&lt;BR /&gt;set -u&lt;BR /&gt;trap "echo 'Bye......'" 0&lt;BR /&gt;trap 'echo Hey! That is not allowed!!!!' 2 3 15&lt;BR /&gt;&lt;BR /&gt;# enable std keyboarding&lt;BR /&gt;# stty line 1 erase '^H' kill '^U' intr '^C' echoe&lt;BR /&gt;stty erase "^H" kill "^U" intr "^C" eof "^D"&lt;BR /&gt;&lt;BR /&gt;PATH=/usr/sbin:$PATH:/sbin:/home/shutdown&lt;BR /&gt;&lt;BR /&gt;# default editor variable&lt;BR /&gt;EDITOR=vi&lt;BR /&gt;export EDITOR&lt;BR /&gt;&lt;BR /&gt;# evaluate and set term type for proper screen clearing&lt;BR /&gt;# echo 'TERM=(vt100) \c'&lt;BR /&gt;# read TERM&lt;BR /&gt;# TERM=vt100&lt;BR /&gt;# export TERM&lt;BR /&gt;if [ "$TERM" = "" ]&lt;BR /&gt;then&lt;BR /&gt;eval ` tset -s -Q -m ':?hp' `&lt;BR /&gt;else&lt;BR /&gt;eval `tset -s -Q `&lt;BR /&gt;fi&lt;BR /&gt;clear&lt;BR /&gt;&lt;BR /&gt;# the actual menu driven operation&lt;BR /&gt;while true&lt;BR /&gt;do clear&lt;BR /&gt;echo " "&lt;BR /&gt;echo " "&lt;BR /&gt;echo " -------------------------------------------------------------------"&lt;BR /&gt;echo " "&lt;BR /&gt;echo " # #### # # ##### ## ####"&lt;BR /&gt;echo " # # # ## # # # # # # #"&lt;BR /&gt;echo " # # # # # # # # # # #"&lt;BR /&gt;echo " # # # # # # ##### ###### #"&lt;BR /&gt;echo " # # # # ## # # # # #"&lt;BR /&gt;echo " ###### #### # # # # # #### S'PORE SHUTDOWN MENU"&lt;BR /&gt;echo " "&lt;BR /&gt;echo " -------------------------------------------------------------------"&lt;BR /&gt;echo " "&lt;BR /&gt;echo " [ 1 ] SHUTDOWN SERVER"&lt;BR /&gt;echo " "&lt;BR /&gt;echo " [ 2 ] ACTIVE USERS"&lt;BR /&gt;echo " "&lt;BR /&gt;echo " [ lo ] LOGOUT"&lt;BR /&gt;echo " "&lt;BR /&gt;echo " -------------------------------------------------------------------"&lt;BR /&gt;echo " "&lt;BR /&gt;echo " Please enter your choice"&lt;BR /&gt;read responce&lt;BR /&gt;case "$responce" in&lt;BR /&gt;"chan") sh&lt;BR /&gt;;;&lt;BR /&gt;"") continue&lt;BR /&gt;;;&lt;BR /&gt;"1") echo "Option 1 was selected"&lt;BR /&gt;/usr/sbin/sync;sync&lt;BR /&gt;/sbin/shutdown -h -y 0&lt;BR /&gt;echo "."&lt;BR /&gt;echo "Press ENTER to continue"&lt;BR /&gt;read dummy&lt;BR /&gt;;;&lt;BR /&gt;"2") echo "Option 2 was selected"&lt;BR /&gt;who&lt;BR /&gt;echo "."&lt;BR /&gt;echo "Press ENTER to continue"&lt;BR /&gt;read dummy&lt;BR /&gt;;;&lt;BR /&gt;"lo") echo "Option to logout was selected"&lt;BR /&gt;break&lt;BR /&gt;;;&lt;BR /&gt;*) echo "Huh???? That option doesn't exist!"&lt;BR /&gt;echo "."&lt;BR /&gt;echo "Press ENTER to continue"&lt;BR /&gt;read dummy&lt;BR /&gt;;;&lt;BR /&gt;esac&lt;BR /&gt;done&lt;BR /&gt;exit 0&lt;BR /&gt;#&lt;BR /&gt;# that's all there is to it!&lt;BR /&gt;#&lt;BR /&gt;&lt;BR /&gt;2) If the superuser(root) change the normal user become root user, on which log can capacture all the details from, such as record the all the command he key in. &lt;BR /&gt;&lt;BR /&gt;Best regards&lt;BR /&gt;Leon</description>
      <pubDate>Tue, 11 Jan 2005 05:12:38 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/user-cant-shutdown-the-server/m-p/3460147#M209968</guid>
      <dc:creator>Leon Shen</dc:creator>
      <dc:date>2005-01-11T05:12:38Z</dc:date>
    </item>
    <item>
      <title>Re: User cant shutdown the server</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/user-cant-shutdown-the-server/m-p/3460148#M209969</link>
      <description>Hi Leon,&lt;BR /&gt;&lt;BR /&gt;Quick question, did you have a /etc/shutdown.allow file on your old server ?&lt;BR /&gt;&lt;BR /&gt;Regards,&lt;BR /&gt;Robert-Jan</description>
      <pubDate>Tue, 11 Jan 2005 05:17:23 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/user-cant-shutdown-the-server/m-p/3460148#M209969</guid>
      <dc:creator>Robert-Jan Goossens</dc:creator>
      <dc:date>2005-01-11T05:17:23Z</dc:date>
    </item>
    <item>
      <title>Re: User cant shutdown the server</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/user-cant-shutdown-the-server/m-p/3460149#M209970</link>
      <description>Just do a small change for option1 as below&lt;BR /&gt;Just insert "cd /" changing to root directory.&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;"1") echo "Option 1 was selected"&lt;BR /&gt;cd /&lt;BR /&gt;/usr/sbin/sync;sync&lt;BR /&gt;/sbin/shutdown -h -y 0&lt;BR /&gt;echo "."&lt;BR /&gt;echo "Press ENTER to continue"&lt;BR /&gt;read dummy</description>
      <pubDate>Tue, 11 Jan 2005 05:25:12 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/user-cant-shutdown-the-server/m-p/3460149#M209970</guid>
      <dc:creator>T G Manikandan</dc:creator>
      <dc:date>2005-01-11T05:25:12Z</dc:date>
    </item>
    <item>
      <title>Re: User cant shutdown the server</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/user-cant-shutdown-the-server/m-p/3460150#M209971</link>
      <description>Hi Robert,&lt;BR /&gt;   &lt;BR /&gt;   Yes the old server have the /etc/shutdown.allow this file and I do remember i copy also. &lt;BR /&gt;&lt;BR /&gt;regards&lt;BR /&gt;Leon</description>
      <pubDate>Tue, 11 Jan 2005 05:32:03 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/user-cant-shutdown-the-server/m-p/3460150#M209971</guid>
      <dc:creator>Leon Shen</dc:creator>
      <dc:date>2005-01-11T05:32:03Z</dc:date>
    </item>
    <item>
      <title>Re: User cant shutdown the server</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/user-cant-shutdown-the-server/m-p/3460151#M209972</link>
      <description>Leon,&lt;BR /&gt;the disk the user is trying to run the shutdown from is not root.&lt;BR /&gt;For a correct shutdown best go to the root partition (/) and then issue the shutdown command.&lt;BR /&gt;Q2. Can you please clarify?&lt;BR /&gt;You want to know how to log the commands after a normal users uses the su command?&lt;BR /&gt;The .history file would track the commands.&lt;BR /&gt;&lt;BR /&gt;Regards</description>
      <pubDate>Tue, 11 Jan 2005 05:50:45 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/user-cant-shutdown-the-server/m-p/3460151#M209972</guid>
      <dc:creator>Peter Godron</dc:creator>
      <dc:date>2005-01-11T05:50:45Z</dc:date>
    </item>
    <item>
      <title>Re: User cant shutdown the server</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/user-cant-shutdown-the-server/m-p/3460152#M209973</link>
      <description>Hi Peter,&lt;BR /&gt;&lt;BR /&gt;   1) I understood and i will add cd / in the .profile.&lt;BR /&gt;&lt;BR /&gt;   2) I mean the normal user's access become root access and does all the command he type will capture in /home/user/.history ? &lt;BR /&gt;&lt;BR /&gt;regards&lt;BR /&gt;Leon</description>
      <pubDate>Tue, 11 Jan 2005 05:56:49 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/user-cant-shutdown-the-server/m-p/3460152#M209973</guid>
      <dc:creator>Leon Shen</dc:creator>
      <dc:date>2005-01-11T05:56:49Z</dc:date>
    </item>
    <item>
      <title>Re: User cant shutdown the server</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/user-cant-shutdown-the-server/m-p/3460153#M209974</link>
      <description>Leon,&lt;BR /&gt;&lt;BR /&gt;No - not in the .profile!  That would cause the user to be placed in the root directory every time they log in.  Put the "cd /" into option 1 of the script as TG suggested.&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;Pete</description>
      <pubDate>Tue, 11 Jan 2005 06:01:00 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/user-cant-shutdown-the-server/m-p/3460153#M209974</guid>
      <dc:creator>Pete Randall</dc:creator>
      <dc:date>2005-01-11T06:01:00Z</dc:date>
    </item>
    <item>
      <title>Re: User cant shutdown the server</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/user-cant-shutdown-the-server/m-p/3460154#M209975</link>
      <description>Hi Peter,&lt;BR /&gt;&lt;BR /&gt;   I mean put the "cd /" into option 1 of the .profile which i post out early  under /home/shutdown/.profile. Hope I can got this time right.&lt;BR /&gt;&lt;BR /&gt;regards&lt;BR /&gt;Leon</description>
      <pubDate>Tue, 11 Jan 2005 06:11:17 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/user-cant-shutdown-the-server/m-p/3460154#M209975</guid>
      <dc:creator>Leon Shen</dc:creator>
      <dc:date>2005-01-11T06:11:17Z</dc:date>
    </item>
    <item>
      <title>Re: User cant shutdown the server</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/user-cant-shutdown-the-server/m-p/3460155#M209976</link>
      <description>Leon,&lt;BR /&gt;Q2: When the user switches with su the last command in the users history file would be the su command. All commands executed as root would be logged in roots history file (if set up!). When the user exits su the logging switches back to his user file.&lt;BR /&gt;Regards</description>
      <pubDate>Tue, 11 Jan 2005 06:27:55 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/user-cant-shutdown-the-server/m-p/3460155#M209976</guid>
      <dc:creator>Peter Godron</dc:creator>
      <dc:date>2005-01-11T06:27:55Z</dc:date>
    </item>
  </channel>
</rss>

