# Continuing a VASP run

> Continue backs up POSCAR, copies CONTCAR over it and resubmits the job's own script, for a VASP relaxation, MD or NEB that stopped before it was done.

Source: https://hiveboard.dev/docs/job-control/continue-a-run · Section: Job control · HiveBoard 0.1.7 · Updated 2026-10-19

## In short

- Continue is offered on your own VASP relaxations, MD runs and NEBs that have started, on a server with job control on — not on a relaxation that has converged.
- It copies POSCAR to POSCAR.bak.<time>, copies CONTCAR to POSCAR, and submits the job's own script from the same folder.
- When HiveBoard cannot tell which script submitted the job, it lists the scripts in the folder and asks; it never submits a guess.
- Nothing is submitted if CONTCAR is empty, the backup fails, or another job is still using the folder.

**Continue** picks up a VASP run where it stopped. HiveBoard backs up POSCAR,
copies CONTCAR (the latest geometry) over it, and submits the job's own
script again from the same folder. It is offered on your own jobs, on a
server with [job control](/docs/job-control/turn-on-job-control) on, and only
where there is something to continue.

## When Continue is offered

| The job | In the job pane |
|---|---|
| VASP relaxation that stopped before converging | **Continue** |
| VASP MD run or NEB that has ended | **Continue** |
| Any of these, still running | **Continue from latest** |
| Converged relaxation, single point, waiting job | nothing |
| Any other code | nothing |

"Stopped" and "ended" mean the job ran and then completed, ran out of time,
failed, was cancelled, ran out of memory, or lost a node. The job must have
ionic steps to continue from; a single point has no geometry to carry on. A
relaxation that has converged is not offered, because there is nothing left
to do.

For codes other than VASP, HiveBoard does not restart runs: neither the button
nor [Guardian](/docs/guardian/guardian)'s second mode applies to them.

## What Continue does

1. Open the job and press **Continue** in the pane's header.
2. The confirmation, **Continue job 419122?**, says HiveBoard will copy
   CONTCAR→POSCAR, backing up the old POSCAR first, and submit a new job from
   the same directory.
3. Press **Continue & submit** — or **Keep it** to do nothing.

On the server, in the job's folder:

1. `POSCAR` is copied to `POSCAR.bak.` followed by the date and time, for
   example `POSCAR.bak.20261019-143005`.
2. `CONTCAR` is copied to `POSCAR`.
3. The job's own script is submitted with `sbatch`, from that folder.

A message gives the new job's number and the name of the backup. For a NEB,
the same is done in each image's folder (`00`, `01`, …); an image whose
CONTCAR is empty is left as it is, and if no image can be prepared, nothing
is submitted.

The script is the one the scheduler recorded for the job, if it is a `.sh`
file in the job's folder; otherwise `sub.sh`, `submit.sh`, `run.sh` or
`job.sh`, whichever is there.

## Continue from latest, on a running job

On a job that is still running, the button reads **Continue from latest**,
and the confirmation warns that the job "is still running in this folder.
The new job goes into the same directory — if it starts before the old one
ends, the two runs overwrite each other's output." Wait for the job to
finish, or cancel it first, unless you know the new job will wait in the
queue behind it. The button then reads **I understand — submit anyway**.

## When HiveBoard is not sure which script

If the scheduler no longer records how the job was submitted and none of the
usual names is in the folder, HiveBoard does not guess. It asks: **Which
script submits this job?**, listing the `.sh` files in the folder — those with
`#SBATCH` lines first, because that is what tells a batch script from a
helper. Pick one and press **Submit with the chosen script** (with a single
candidate, the button names it). Check the job's
[Files tab](/docs/job/files-tab) first if none of them looks right. Only a
`.sh` file in the job's own folder can be chosen.

With no `.sh` file at all, Continue stops: "Could not find a submission
script (*.sh) in the work directory."

## When Continue is refused

- **Another job is using the folder.** If any other job is still waiting or
  running in that folder, nothing is touched: "Job(s) … are already
  queued/running in this directory — refusing to seed another run on top."
  Two jobs never share one folder by accident.
- **The job is running and the page did not know.** Plain **Continue** on a
  job that has meanwhile started is refused; refresh the job and use
  **Continue from latest** if you mean it.
- **Nothing safe to copy.** An empty CONTCAR, a failed backup or a failed
  copy stops everything before the submission, so an old geometry is never
  resubmitted by mistake.
- **Not yours, or job control off.** Refused like every action of job
  control — a job of someone you named under **Highlight users** included,
  even if the page shows the button for it.

> [!WARNING]
> If the backup and copy succeed but the submission fails, the message says
> "Backup done, but resubmission failed". POSCAR now holds the CONTCAR
> geometry and the old one is in the `POSCAR.bak.` file; you can submit the
> job yourself.

## Check yourself

1. What happens to the old POSCAR when you continue a run?
   - It is copied to POSCAR.bak.<time> before CONTCAR is copied over it ← the answer
   - It is deleted
   - It is downloaded to your computer
   - It is overwritten without a copy
   Why: The backup comes first, and if it fails nothing else happens.

2. HiveBoard cannot tell which script submitted the job. What does it do?
   - Lists the .sh scripts in the folder and asks you to pick one ← the answer
   - Submits the first script in alphabetical order
   - Submits sub.sh whether or not it exists
   - Writes a new submit script
   Why: A guess is never submitted on its own authority; scripts with #SBATCH lines are listed first.

## Try it in the app

- This submits a real job. On a VASP relaxation of yours that ran out of wall-time, press **Continue**, read the confirmation, and afterwards find the POSCAR.bak file in its **Files** tab.

## Related

- [Turning on job control](https://hiveboard.dev/docs/job-control/turn-on-job-control.md)
- [Guardian](https://hiveboard.dev/docs/guardian/guardian.md)
- [Guardian's safety rails](https://hiveboard.dev/docs/guardian/safety-rails.md)
- [VASP jobs](https://hiveboard.dev/docs/codes/vasp.md)
- [The Files tab](https://hiveboard.dev/docs/job/files-tab.md)
