-
Notifications
You must be signed in to change notification settings - Fork 57
Description
The JournalConsumer seems to require a URI where the running user is the instance owner. E.g., when I try to instantiate using the system instance, I am denied:
# system instance on corona
handle = flux.Flux("local:///var/run/local")
# This works ok
consumer = flux.job.JournalConsumer(handle)
consumer.start()
# This is denied
consumer.poll()PermissionError: [Errno 1] Request requires owner credentialsThat is failing here:
flux-core/src/common/libflux/msg_handler.c
Line 314 in f9209c2
| errmsg = "Request requires owner credentials"; |
And I'm wondering if it might be possible to have it work, but filter to events that are owned by me? I was trying to tweak the rpc to set some kind of filter or constraint for that (just throwing salami at the wall, no luck so far)
class JournalConsumer(flux.job.JournalConsumer):
@property
def request_payload(self):
return {"full": False, "userid": os.getuid(), "constraints": {"userid": os.getuid()}}
consumer = JournalConsumer(handle)
consumer.start()
consumer.poll()Is this impossible? if I am submitting jobs on the head node, is there a reason I can't receive my job events? The use case is Genesis and being able to run a local service that can do that. When I do flux start I can only see one node (the head node) and can't submit to the system instance. I can do flux start and submit to the system instance:
flux start
FLUX_URI=local:///var/run/flux/local flux submit hostnameAnd indeed my job is there, but then I think events for that job (given running the consumer under flux start) would not seen because they aren't under my current instance.
Any help would be appreciated - let me know what I might try! The goals are to:
- Be able to submit jobs to the system instance
- Be able to receive events for them to respond to
This all works under an allocation, but the request is for the above.