diff --git a/reframe/core/schedulers/oar.py b/reframe/core/schedulers/oar.py index b4431b1fa6..b327da94af 100644 --- a/reframe/core/schedulers/oar.py +++ b/reframe/core/schedulers/oar.py @@ -73,8 +73,8 @@ def emit_preamble(self, job): # avoid writing them in the working dir preamble = [ self._format_option(f'-n "{job.name}"'), - self._format_option(f'-O {os.path.join(job.workdir, job.stdout)}'), - self._format_option(f'-E {os.path.join(job.workdir, job.stderr)}'), + self._format_option(f'-O {job.stdout}'), + self._format_option(f'-E {job.stderr}'), ] if job.time_limit is not None: @@ -98,14 +98,10 @@ def emit_preamble(self, job): else: preamble.append(self._format_option(opt)) - # OAR starts the job in the home directory by default - preamble.append(f'cd {job.workdir}') return preamble def submit(self, job): - # For some reason OAR job manager says that job launching dir is - # working dir of the repo and not stage dir. A workaround is to give - # full path of script to oarsub + # OAR batch submission mode needs full path to the job script job_script_fullpath = os.path.join(job.workdir, job.script_filename) # OAR needs -S to submit job in batch mode