---
name: "utmp_register"
section: "8"
platform: "linux"
package: "hxtools"
version: "20221119-1"
release: "Debian 12 (Bookworm)"
platforms: ["linux"]
url: "https://new.carta.tech/utmp_register"
---

# utmp\_register(8)

make entries in the utmp/wtmp database

## Name

utmp\_register — make entries in the utmp/wtmp database

## Syntax

**utmp\_register** \[**-ADUWe**\] \[**-h** *host*\] \[**-l** *user*\] \[**-p** *id1*\] \[**-s** *id2*\] \[**-t** *tty*\] \[**-u** *utmpfile*\] \[**-w** *wtmpfile*\]

## Description

utmp\_register is a helper program for programs which do not want to do the UTMP/WTMP handling within themselves.

## Options

- **-A**

  Add entry.

- **-D**

  Delete entry.

- **-U**

  Perform operation on the utmp file.

- **-W**

  Perform operation on the wtmp file.

- **-e**

  Encode PID into the "ut\_id" field.

- **-h** *host*

  Host field.

- **-l** *user*

  User field.

- **-t** *tty*

  TTY field.

- **-p** *pid*

  Unique ID 1

- **-s** *session*

  Unique ID 2.

- **-u** *file*

  Path to the utmp file, defaults to /var/run/utmp.

- **-w** *file*

  Path to wtmp file, defaults to /var/log/wtmp.

\-A and -D can be specified together, in which case an entry is added and instantly removed again (utmp), or a login of duration zero is recorded (wtmp).

## See also

[**hxtools**(7)](/hxtools/7.md)
