Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

zOS support #751

Open
VitekVlcek-Broadcom opened this issue Sep 13, 2023 · 11 comments
Open

zOS support #751

VitekVlcek-Broadcom opened this issue Sep 13, 2023 · 11 comments

Comments

@VitekVlcek-Broadcom
Copy link

VitekVlcek-Broadcom commented Sep 13, 2023

It would be great if Feilong supported zOS lifecycle, where zOS is 2nd level zVM guest:

  1. IPL zOS,
  2. Stop zOS
  3. invoke MVS commands (D IPLINFO, ...) and capture their response

My understanding is that Feilong runs a zlinux under zVM, what it is resource consumption of this image (average CPU utilization, Memory, Disk). In my case I would ideally avoid extra VM with zlinux to reduce memory and CPU resources because I'm running zVM under zD&T (zPDT)

I already have a POC version implemented off the Feilong project here is an architecture diagram:
zos and feilong

  • In my case I can have many instances of zVM each representing a parallel sysplex, that could be provisioned by a developer, therefore I prefer to avoid zlinux on each zVM and instead have the majority of components off the zVM.
  • Ideally, I would like to combine LXC and observer into a single VM to minimize overhead of infrastructure
  • LXC is used to send commands such as: Q NAMES, CP SEND CP ZOS1 CP IPL ..., CP SEND CP ZOS1 VINPUT VMSG D IPLINFO, CP SET OBSERVER ...
  • OBSERVER - IUCV2Socket - capture console messages sent from zOS vms and forward them via a network socket to a CLI that runs on linux, POC is based on
@bjhuangr
Copy link
Contributor

currently, feilong rely on the IUCV channel to communicate with SMAPI request servers, so it has to stay in the same z/VM system.
We don't have performance data like cpu consumption of feilong services, but according to our daily use, it's relatively a light weight service

@jichenjc
Copy link
Collaborator

from the picture I think you are proposing LXC and other CMS related components to hosting feilong like Linux
but provisioning z/OS Is not hard depend on the LXC related item, is that correct?

@VitekVlcek-Broadcom
Copy link
Author

LXC is used to issue CP commands Q NAMES, CP SEND CP ZOS1 CP IPL ..., CP SEND CP ZOS1 VINPUT VMSG D IPLINFO, CP SET OBSERVER ... from a linux VM running off the zVM. In this scenario, Feilong is not running in zLinux under zVM. This picture covers only the start/stop scenario of zOS. Provisioning of zOS is out of scope.
We could discuss late what it means to provision zOS it is not that easy like in case of linux, provisioning involves multiples volumes.

@jichenjc
Copy link
Collaborator

jichenjc commented Oct 13, 2023 via email

@mfriesenegger
Copy link
Collaborator

@VitekVlcek-Broadcom We mentioned this issue during today's Feilong TSC meeting. I see @jichenjc suggested demoing the env. Is this something you would like to do for the January Feilong meeting?

@Bischoff
Copy link
Contributor

Bischoff commented Jan 10, 2024

Hi Vitek, I have seen with interest your demo of your first PoC relying on LXC.

My observations:

  • I was first confused by "LXC" name, as it is a well known containers system under Linux 😸
  • What you do with LXC could also be done via s3270, the "scripting" version of x3270 terminal emulator: send CP commands, analyze output...
  • I am quite confused whether zthin component of Feilong needs IUCV to communicate with SMAPI. @bjhuangr says above it does, but 1) I think SMAPI can also be driven with IP sockets, and 2) we accidentally got Feilong to work while we forgot IUCV settings 🤔 . If IUCV is not mandatory, then you could put zthin or even a full Feilong outside of the s390 host.
  • Your approach is very different in essence from what Feilong does: your LXC PoC uses CP commands to start and stop an existing z/VM guest, while feilong can deploy a new VM from a preexisting image, by manipulating the z/VM directory via SMAPI. Feilong can also start and stop existing VMs BTW.
  • The fact that the approach is different does not mean you cannot reach the same goal with LXC and Feilong - it's just in a very different way 😸 .
  • However, I do not know whether Feilong assumes it is a Linux system that is being deployed. For example you can access the IP address of the guest, I am not sure how this is achieved and if Feilong needs to access the guest OS to achieve that.

If I were you, I would just try to start and stop an existing zOS system with Feilong, to see if that works.

I hope that helps.

@mfriesenegger
Copy link
Collaborator

Hello Eric,

  • I was first confused by "LXC" name, as it is a well known containers system under Linux 😸

I believe this LXC - https://www.vm.ibm.com/download/packages/descript.cgi?LXC - predates the Linux LXC technology that you are thinking of.

@jichenjc
Copy link
Collaborator

I am quite confused whether zthin component of Feilong needs IUCV to communicate with SMAPI. @bjhuangr says above it does, but 1) I think SMAPI can also be driven with IP sockets, and 2) we accidentally got Feilong to work while we forgot IUCV settings 🤔 . If IUCV is not mandatory, then you could put zthin or even a full Feilong outside of the s390 host.

IUCV is used for Linux VM communication, SMAPI is for VM management through z/VM DIRMAINT/CPU
SMAPI is pure socket thing and feilong covers both SMAPI and IUCV for different purpose
you can create VM USER DIRECT through DIRAMINT but it might not fit feilong whole purpose which covers Linux part as well

However, I do not know whether Feilong assumes it is a Linux system that is being deployed. For example you can access the IP address of the guest, I am not sure how this is achieved and if Feilong needs to access the guest OS to achieve that.

the access to IP address is beyong feilong scope, we used to use ssh to do management but this means this need management entity need ssh to VM which is some case it's security concern and sometimes the network is not reachable at all, so we use IUCV instead

If I were you, I would just try to start and stop an existing zOS system with Feilong, to see if that works.

if it's z/VM guest, I see no reason why those 2 are not supported (as it will be z/VM Start/Stop through Image_Activate and Deactivate API which is pure SMAPI thing which interpret as CP command only)

@Bischoff
Copy link
Contributor

Thanks for the clarifications @jichenjc. The schema at https://cloudlib4zvm.readthedocs.io/en/latest/architecture.html#internal-architecture had mislead me, I suggest in another issue to fix it.

To summarize this discussion:

  • handling z/OS VMs from Feilong would work as long as we use only the SMAPI part. That includes starting and stopping VMs.
  • to do the same thing with z/OS as Feilong does with Linux, one would need to implement the equivalent functionality. The most "Feilongish" way would be IUCV, but you could continue with LXC, I guess
  • but if you are to continue with LXC, is there still a point to rely on Feilong's SMAPI part? Yes, if provisioning becomes part of your scope.

These are just personal thoughts. I do not represent the Feilong project in any way.

@VitekVlcek-Broadcom
Copy link
Author

Thanks @Bischoff for the summary, I would love to use SMAPI instead of LXC however. LXC is used for:

  1. start/stop zVM - there should be API calls (based on your reply)
  2. send a command to a VM console eg: Q NAMES, CP SEND CP ZOS1 CP IPL ..., CP SEND CP ZOS1 VINPUT VMSG D IPLINFO, CP SET OBSERVER ... - is there a SMAPI endpoint for it?

@jichenjc
Copy link
Collaborator

start/stop zVM - there should be API calls (based on your reply)

yes, this is easier , Image_Activate/Deactivate I shared above

send a command to a VM console eg: Q NAMES, CP SEND CP ZOS1 CP IPL ..., CP SEND CP ZOS1 VINPUT VMSG D IPLINFO, CP SET OBSERVER ... - is there a SMAPI endpoint for it?

we can create a customerized API doing so
https://www.ibm.com/docs/en/zvm/7.3?topic=programming-creating-custom-apis

we used to have a API that can do so and it trigger some security concern as if something like
CP <input command> then it's able to do everything which we don't want

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

5 participants