Re: Using WakeUp to cycle a zLinux instance

2008-03-14 Thread Romanowski, John (OFT)
Instead of adding a CP SIGNAL SHUTDOWN option to prevent shutdown
(contrary to the signal name),
it'd be better to extend the CP SIGNAL command to send other types of
signals for other purposes, something like the linux 'kill' command.
 kill sounds like it started out as a stone cold killer but was reformed
to deliver many other useful,  non-fatal signals. 
Something like CP SIGNAL QUIT or SIGNAL STOP

'kill -l' lists these types of special-purpose signals
1) SIGHUP   2) SIGINT   3) SIGQUIT  4) SIGILL
 5) SIGTRAP  6) SIGABRT  7) SIGBUS   8) SIGFPE
 9) SIGKILL 10) SIGUSR1 11) SIGSEGV 12) SIGUSR2
13) SIGPIPE 14) SIGALRM 15) SIGTERM 17) SIGCHLD
18) SIGCONT 19) SIGSTOP 20) SIGTSTP 21) SIGTTIN
22) SIGTTOU 23) SIGURG  24) SIGXCPU 25) SIGXFSZ
26) SIGVTALRM   27) SIGPROF 28) SIGWINCH29) SIGIO
30) SIGPWR  31) SIGSYS  33) SIGRTMIN34) SIGRTMIN+1
35) SIGRTMIN+2  36) SIGRTMIN+3  37) SIGRTMIN+4  38) SIGRTMIN+5
39) SIGRTMIN+6  40) SIGRTMIN+7  41) SIGRTMIN+8  42) SIGRTMIN+9
43) SIGRTMIN+10 44) SIGRTMIN+11 45) SIGRTMIN+12 46) SIGRTMIN+13
47) SIGRTMIN+14 48) SIGRTMIN+15 49) SIGRTMAX-15 50) SIGRTMAX-14
51) SIGRTMAX-13 52) SIGRTMAX-12 53) SIGRTMAX-11 54) SIGRTMAX-10
55) SIGRTMAX-9  56) SIGRTMAX-8  57) SIGRTMAX-7  58) SIGRTMAX-6
59) SIGRTMAX-5  60) SIGRTMAX-4  61) SIGRTMAX-3  62) SIGRTMAX-2
63) SIGRTMAX-1  64) SIGRTMAX



This e-mail, including any attachments, may be confidential, privileged or 
otherwise legally protected. It is intended only for the addressee. If you 
received this e-mail in error or from someone who was not authorized to send it 
to you, do not disseminate, copy or otherwise use this e-mail or its 
attachments.  Please notify the sender immediately by reply e-mail and delete 
the e-mail from your system.


-Original Message-

From: The IBM z/VM Operating System [mailto:[EMAIL PROTECTED] On
Behalf Of Berry van Sleeuwen
Sent: Thursday, March 13, 2008 6:21 PM
To: IBMVM@LISTSERV.UARK.EDU
Subject: Re: Using WakeUp to cycle a zLinux instance

snip

I had a discussion with IBM on that some time ago. I'd liked to see an 
option in signal to prevent the shutdown of guests when they do not 
shutdown within the timeout period. But IBM did not follow me on that. 
When a forced user in not acceptable (databases or jobs cancelled while 
processing) they advised not to use SIGNAL. This is true for zLinux but 
also for guest VM, VSE and SFS (all of them can trap the signal.)
snip


Re: Using WakeUp to cycle a zLinux instance

2008-03-14 Thread Alan Altmark
On Friday, 03/14/2008 at 08:31 EDT, Romanowski, John (OFT) 
[EMAIL PROTECTED] wrote:
 Instead of adding a CP SIGNAL SHUTDOWN option to prevent shutdown
 (contrary to the signal name),
 it'd be better to extend the CP SIGNAL command to send other types of
 signals for other purposes, something like the linux 'kill' command.
 kill sounds like it started out as a stone cold killer but was reformed
 to deliver many other useful,  non-fatal signals.
 Something like CP SIGNAL QUIT or SIGNAL STOP
 
 'kill -l' lists these types of special-purpose signals
 1) SIGHUP   2) SIGINT   3) SIGQUIT  4) SIGILL
 5) SIGTRAP  6) SIGABRT  7) SIGBUS   8) SIGFPE
 9) SIGKILL 10) SIGUSR1 11) SIGSEGV 12) SIGUSR2
 13) SIGPIPE 14) SIGALRM 15) SIGTERM 17) SIGCHLD
 18) SIGCONT 19) SIGSTOP 20) SIGTSTP 21) SIGTTIN
 22) SIGTTOU 23) SIGURG  24) SIGXCPU 25) SIGXFSZ
 26) SIGVTALRM   27) SIGPROF 28) SIGWINCH29) SIGIO
 30) SIGPWR  31) SIGSYS  33) SIGRTMIN34) SIGRTMIN+1
 ...

So define an external interrupt code to go with each one and update Linux 
to convert them to one of the above signals.  Then a simple SENDSIG exec 
takes care of it.  For example, if you bind SIGPWR to code 3000, then 
SENDSIG LINUX01 PWR would result in CP SEND CP LINUX01 EXT 5000. You don't 
need a change in the CP SIGNAL command to do this; SIGNAL is for 
architecturally-defined events.

Alan Altmark
z/VM Development
IBM Endicott


Re: Using WakeUp to cycle a zLinux instance

2008-03-13 Thread Rob van der Heij
On Thu, Mar 13, 2008 at 2:48 PM, Sikich, Frank J.
[EMAIL PROTECTED] wrote:

 I have a zLinux that is having issues and as a temporary bandaid I need
 to cycle the instance every morning.  Will the wake command help me
 accomplish this?  That for everyone input.

You could tweak the inittab to make the 3-finger-salute do a restart
rather than shutdown. You can then SIGNAL the user...  (not FORCE
since that would make CP take the guest out after some time despite
the reboot)

-- 
Rob van der Heij
Velocity Software GmbH
http://velocitysoftware.com/


Re: Using WakeUp to cycle a zLinux instance

2008-03-13 Thread Huegel, Thomas
I think it should work.
Put something like this in your WAKEUP TIMES
ALL  05:00:00  CP FORCE LINUX WITHIN 300 
ALL  05:10:00  CP XAUTOLOG LINUX 
Will send LINUX a shutdown signal before forcing it to logoff 
And then xautolog him back on 10 minutes later

[Huegel, Thomas]  -Original Message-
From: The IBM z/VM Operating System [mailto:[EMAIL PROTECTED]
Behalf Of Sikich, Frank J.
Sent: Thursday, March 13, 2008 8:49 AM
To: IBMVM@LISTSERV.UARK.EDU
Subject: Using WakeUp to cycle a zLinux instance



To All:

I have a zLinux that is having issues and as a temporary bandaid I need
to cycle the instance every morning.  Will the wake command help me
accomplish this?  That for everyone input.

 

Frank Sikich

NCC




---

***National City made the following annotations


---
This communication is a confidential and proprietary business communication.
It is intended solely for the use of the designated recipient(s). If this
communication is received in error, please contact the sender and delete
this communication.

===






Re: Using WakeUp to cycle a zLinux instance

2008-03-13 Thread Macioce, Larry
Why not just let cron schedule it??

Edit your crontab to look like this:

30 1 * * 1 /sbin/shutdown -r 0

We reboot our guest and it works great.

 

Mace 

 



From: The IBM z/VM Operating System [mailto:[EMAIL PROTECTED] On
Behalf Of Sikich, Frank J.
Sent: Thursday, March 13, 2008 9:49 AM
To: IBMVM@LISTSERV.UARK.EDU
Subject: Using WakeUp to cycle a zLinux instance

 

To All:

I have a zLinux that is having issues and as a temporary bandaid I
need to cycle the instance every morning.  Will the wake command help me
accomplish this?  That for everyone input.

 

Frank Sikich

NCC


---
***National City made the following annotations

---

This communication is a confidential and proprietary business
communication. It is intended solely for the use of the designated
recipient(s). If this communication is received in error, please contact
the sender and delete this communication.

===




-

The information transmitted is intended solely for the individual
or entity to which it is addressed and may contain confidential
and/or
privileged material. Any review, retransmission, dissemination or
other use of or taking action in reliance upon this information by
persons or entities other than the intended recipient is
prohibited. If you have received this email in error please contact
the sender and delete the
material from any computer.



Re: Using WakeUp to cycle a zLinux instance

2008-03-13 Thread Berry van Sleeuwen

Hello Rob,

I agree that FORCE would not be an option. In case of the linux machine 
IBM advised (see below) to setup a secondary console user to shutdown a 
linuxmachine and still have the option of communicating with the guest 
in case of problems during shutdown. This could also be used in a wakeup 
where some wakeup machine issues a shutdown -r on a linux console.


But for the restart triggered by signal, are you sure you could do that? 
A SIGNAL SHUTDOWN LINUX01 WITHIN 300 will log off LINUX01 after 300 
seconds or before that if the user reports a successfull shutdown. So a 
SIGNAL SHUTDOWN will eventually force the user anyway. When the user is 
rebooting, is the signal then canceled somehow?


I had a discussion with IBM on that some time ago. I'd liked to see an 
option in signal to prevent the shutdown of guests when they do not 
shutdown within the timeout period. But IBM did not follow me on that. 
When a forced user in not acceptable (databases or jobs cancelled while 
processing) they advised not to use SIGNAL. This is true for zLinux but 
also for guest VM, VSE and SFS (all of them can trap the signal.)


We had this issue for linuxguests that did not shutdown within the 
timeoutperiod due to running processes on the database. Also, A guest VM 
will signal users within VM (usually only the VMSYS* filepools) and then 
shutdown regardless of the successfull logoff of other services in VM. A 
VSE issues only a message in the hardcopy and some eventprocessing 
(FAQS-ASO comes to mind) has to ensure the correct shutdown of services 
and jobs within VSE. In all of these cases the guest user could still be 
shutting down when the timeoutperiod passes and that would be much the 
same as using FORCE in the first place.


Regards, Berry.

Rob van der Heij schreef:


You could tweak the inittab to make the 3-finger-salute do a restart
rather than shutdown. You can then SIGNAL the user...  (not FORCE
since that would make CP take the guest out after some time despite
the reboot)

 



Re: Using WakeUp to cycle a zLinux instance

2008-03-13 Thread Alan Altmark
On Thursday, 03/13/2008 at 06:25 EDT, Berry van Sleeuwen 
[EMAIL PROTECTED] wrote:

 I had a discussion with IBM on that some time ago. I'd liked to see an
 option in signal to prevent the shutdown of guests when they do not
 shutdown within the timeout period. But IBM did not follow me on that.
 When a forced user in not acceptable (databases or jobs cancelled while
 processing) they advised not to use SIGNAL. This is true for zLinux but
 also for guest VM, VSE and SFS (all of them can trap the signal.)

There is confusion.  SIGNAL SHUTDOWN is not some arbitrary external signal 
meant for general automation.  It is a hardware-architected signal that 
the container (LPAR or virtual machine) is shutting down.  It is meant to 
give the contents of the container time to commune with any or all 
appropriate cyberdeities or perform cleansing rituals before being 
consigned to Oblivion.  And it is a sentence for which there is no Appeal.

Alan Altmark
z/VM Development
IBM Endicott