Opened 14 years ago

Closed 13 years ago

Last modified 13 years ago

#68 closed enhancement (fixed)

Process without interaction (handy: cron mode)

Reported by: Joachim Langenbach Owned by: Bruno Cornec
Priority: major Milestone: 0.10.1
Component: pb Version: 0.10.1
Keywords: Cc:

Description

pb should be able to run the whole process cms2vm and test2vm without any gui and user interaction (if ssh is configured correctly by the user).

For example:

We use Project-Builder to run tests during the night on different distributions (results: softqa.engsas.de/meganizer). This test are run by cron without gui and any interaction.

  1. Problem gui less:

We discussed some points concerning making pb guiless on the mailing list, if there are no changes right now, i've appended the patch, which I suggested there. The patch assumes, that the user wants to access the VM only if he launches launchvm. All other launches are done by pb and therefore I assume, that the user does not interact with VM manually.

We started to discuss some other possible solutions, which may be better. This ticket should be ment as a remind, to go on with that discussion.

  1. Sometimes the vm hangs:

Sometimes, the VM hangs (randomly, don't know why), but pb does not detect it, so I suggest to let the user define a default max time per vm, after that time, the vm is halted or killed if halt is not working. This does not solve the problem with the vm, but the process isn't stopped completly and the following vm's are at least processed.

Attachments (1)

autogui.patch (2.1 KB ) - added by Joachim Langenbach 14 years ago.
Enable gui for launchvm and newvm, disable gui for all other calls to pb_launchv2

Download all attachments as: .zip

Change History (7)

by Joachim Langenbach, 14 years ago

Attachment: autogui.patch added

Enable gui for launchvm and newvm, disable gui for all other calls to pb_launchv2

comment:1 by Bruno Cornec, 14 years ago

1/ I'm a bit reluctant to force a no GUI for VMs by default. Especially during the newvm/setupvm phases where it's very useful.

It's easy for each user of the tool to change the conf file and do:

vmopt default = -m 384 -daemonize -nographics

If the patch does it only for the build and tests phases, then I may want to add it, but how would someone remove that then ?

2/ That would require a change in the way the VMs are launched. Fairly possible, to use instead of system a fork, and then monitor what happens, and kill after timeout. Why not indeed !

comment:2 by Bruno Cornec, 13 years ago

You can also use the environment variable PBVMOPT to add the -nographics option at will BTW.

comment:3 by Bruno Cornec, 13 years ago

Do these hints solve your issue ? I'd like to close this BR for 0.9.11

comment:4 by Joachim Langenbach, 13 years ago

I'm not really happy with this solution, but I might accept it. From my point of view, at least the cms2vm command should use the -nographics by default, so that it is easy to use in automatic processes.

If you close the ticket, should I open a new one for point 2 (monitoring VM and killing)?

comment:5 by Bruno Cornec, 13 years ago

Resolution: fixed
Status: newclosed
Ok, so I've also added a new option (-gnographics) so that you can also inoke it directlyon the CLI. Which gives 3 possibilities (CLI, conf file, Env var).

The second part of the ticket is now in #73.

comment:6 by Joachim Langenbach, 13 years ago

Thats also a good solution. Thanks!

Note: See TracTickets for help on using tickets.