---
title: "oz0-node service install"
description: "Install the node as a service and start it; run it again to update the service, such as after moving the binary."
canonical_url: "https://docs.oz0.ai/reference/cli/oz0-node/service/install"
---
# oz0-node service install

> Install the node as a service and start it; run it again to update the service, such as after moving the binary.

For: Operators and developers looking up a command.

Install the node as a service and start it; run it again to update the service, such as after moving the binary. A service of the machine runs as its own account (Linux: oz0-node, made when it does not exist; macOS: --account, by default the user who ran sudo; Windows: the virtual account NT SERVICE&lt;name>), which gets the data directory and a copy of the binary in \<data-dir>/bin to update.

Join first with the same --data-dir: a service starts only while the node has its identity, so a purged node stays stopped. --dry-run prints the unit, property list or service settings without installing them. A stop drains the node first: the service manager waits for its stop grace (--stop-grace, ten minutes by default) and a minute more before it kills it.

## Usage

```bash
oz0-node service install [flags]
```

## Flags

<table>
<thead>
  <tr>
    <th>
      Flag
    </th>
    
    <th>
      Type
    </th>
    
    <th>
      Default
    </th>
    
    <th>
      Description
    </th>
  </tr>
</thead>

<tbody>
  <tr>
    <td>
      <code>
        --account
      </code>
    </td>
    
    <td>
      string
    </td>
    
    <td>
      <code>
        oz0-node on Linux, the user who ran sudo on macOS, NT SERVICE\&lt;name> on Windows
      </code>
    </td>
    
    <td>
      the account a service of the machine runs as
    </td>
  </tr>
  
  <tr>
    <td>
      <code>
        --check
      </code>
    </td>
    
    <td>
      bool
    </td>
    
    <td>
      
    </td>
    
    <td>
      check that the service can be installed here, as the install scripts do before they join, and change nothing
    </td>
  </tr>
  
  <tr>
    <td>
      <code>
        --dry-run
      </code>
    </td>
    
    <td>
      bool
    </td>
    
    <td>
      
    </td>
    
    <td>
      print the service's definition and where it would go, and change nothing
    </td>
  </tr>
  
  <tr>
    <td>
      <code>
        --no-linger
      </code>
    </td>
    
    <td>
      bool
    </td>
    
    <td>
      
    </td>
    
    <td>
      systemd user service: do not turn on lingering, so the node runs only while you are logged in
    </td>
  </tr>
  
  <tr>
    <td>
      <code>
        --no-start
      </code>
    </td>
    
    <td>
      bool
    </td>
    
    <td>
      
    </td>
    
    <td>
      install and enable the service, but do not start it now
    </td>
  </tr>
  
  <tr>
    <td>
      <code>
        --plugin-sandbox
      </code>
    </td>
    
    <td>
      string
    </td>
    
    <td>
      <code>
        the node's, strict on a node with tier 1
      </code>
    </td>
    
    <td>
      the service's oz0-node run --plugin-sandbox: auto or off, for a node that must not hold its plugins to the sandbox
    </td>
  </tr>
  
  <tr>
    <td>
      <code>
        --plugin-sandbox-exempt
      </code>
    </td>
    
    <td>
      stringArray
    </td>
    
    <td>
      
    </td>
    
    <td>
      the service's oz0-node run --plugin-sandbox-exempt, PLUGIN or PLUGIN@COMMIT (repeatable); installing the service again without it takes the exemption away
    </td>
  </tr>
  
  <tr>
    <td>
      <code>
        --replace-binary
      </code>
    </td>
    
    <td>
      bool
    </td>
    
    <td>
      
    </td>
    
    <td>
      service of the machine: put this binary in place of the service's own copy even when that copy is newer or its version is not known
    </td>
  </tr>
  
  <tr>
    <td>
      <code>
        --service-name
      </code>
    </td>
    
    <td>
      string
    </td>
    
    <td>
      <code>
        orchestrator-zero-node
      </code>
    </td>
    
    <td>
      the service's name, for more than one node on a machine (launchd label ai.oz0.&lt;name>)
    </td>
  </tr>
  
  <tr>
    <td>
      <code>
        --stop-grace
      </code>
    </td>
    
    <td>
      duration
    </td>
    
    <td>
      <code>
        10m0s
      </code>
    </td>
    
    <td>
      how long the node drains when the service stops, at most 1h; the service manager waits a minute more
    </td>
  </tr>
  
  <tr>
    <td>
      <code>
        --system
      </code>
    </td>
    
    <td>
      bool
    </td>
    
    <td>
      <code>
        as root or Administrator
      </code>
    </td>
    
    <td>
      a service of the machine that starts at boot and runs as its own account
    </td>
  </tr>
  
  <tr>
    <td>
      <code>
        --user
      </code>
    </td>
    
    <td>
      bool
    </td>
    
    <td>
      <code>
        when not root
      </code>
    </td>
    
    <td>
      a service of your own user: systemd's user manager, or a launchd agent
    </td>
  </tr>
</tbody>
</table>

## Inherited flags

<table>
<thead>
  <tr>
    <th>
      Flag
    </th>
    
    <th>
      Type
    </th>
    
    <th>
      Default
    </th>
    
    <th>
      Description
    </th>
  </tr>
</thead>

<tbody>
  <tr>
    <td>
      <code>
        --data-dir
      </code>
    </td>
    
    <td>
      string
    </td>
    
    <td>
      <code>
        ~/.local/share/orchestrator-zero-node
      </code>
    </td>
    
    <td>
      where the node keeps its identity, uv, Python, runtimes and state
    </td>
  </tr>
  
  <tr>
    <td>
      <code>
        --log-level
      </code>
    </td>
    
    <td>
      string
    </td>
    
    <td>
      <code>
        info
      </code>
    </td>
    
    <td>
      log level: debug, info, warn or error
    </td>
  </tr>
</tbody>
</table>

See [all `oz0-node` commands](https://docs.oz0.ai/reference/cli/oz0-node) and the [global flags](https://docs.oz0.ai/reference/cli/oz0-node#global-flags).


## Sitemap

See the full [sitemap](https://docs.oz0.ai/sitemap.md) for all pages.
