I am writing a custom scheduler and I am getting pretty close to success. Right now I am able to communicate with our farm, get job/task statuses and logs all working.
The issue that I am having is that whenever a farm machine picks up the “rop geometry output” task, Houdini does not write a rop.py to the /pdgtemp/<process_id>/scripts/ folder. Hence giving me the error: /opt/sidefx/hfs-17.5.258/bin/hython-bin: can't open file ‘/PATH/TO/PDG FOLDER/pdgtemp/<process_id>/scripts/rop.py’: No such file or directory
The local scheduler works just fine, I see the bgeo end up where it needs to be. However during this process I don't see a “pdgtemp” being created and thus no scripts folder.
I have tested the permissions on the folder, they are fully writeable by both (and any other) machines. From any machine on our network I can also view/write the folder just by it's path. My onStartCook looks like this:
wd = self["pdg_workingdir"].evaluateString() self.setWorkingDir(wd, wd) if not os.path.exists(self.tempDir(True)): os.makedirs(self.tempDir(True)) if not os.path.exists(self.workingDir(True)): os.makedirs(self.workingDir(True)) if not os.path.exists(self.scriptDir(True)): os.makedirs(self.scriptDir(True)) if not self.isCallbackServerRunning(): self.startCallbackServer() self.tick_timer = TickTimer(0.25, self.tick) self.tick_timer.start() return True
Just a part of my onSchedule (due to sensitive code):
temp_dir = self.tempDir(False) work_dir = self.workingDir(False) script_dir = self.scriptDir(False) item_command = item_command.replace("__PDG_ITEM_NAME__", item_name) item_command = item_command.replace("__PDG_SHARED_TEMP__", temp_dir) item_command = item_command.replace("__PDG_TEMP__", temp_dir) item_command = item_command.replace("__PDG_SHARED_ROOT__", work_dir) item_command = item_command.replace("__PDG_DIR__", work_dir) item_command = item_command.replace("__PDG_SCRIPTDIR__", script_dir) item_command = item_command.replace("__PDG_RESULT_SERVER__", self.workItemResultServerAddr()) item_command = item_command.replace("__PDG_PYTHON__", "python") item_command = item_command.replace("__PDG_HYTHON__", "hython") # Ensure directories exist and serialize the work item self.createJobDirsAndSerializeWorkItems(work_item)
My onSchedule contains self.createJobDirsAndSerializeWorkItems(work_item). The SideFX changelog [www.sidefx.com] tells me: createJobDirsAndSerializeWorkItems: creates job directories (log, data), and serializes work items. This indeed creates the log and data folder but not scripts, that's why I create them myself in the onStartCook.
I think I am missing something somewhere, I just can't figure it out?
Thanks for future replies.