---
name: "function::ns_pgrp"
section: "3stap"
platform: "linux"
package: "systemtap-doc"
version: "5.1-5"
release: "Debian 13 (Trixie)"
platforms: ["linux"]
url: "https://new.carta.tech/function::ns_pgrp"
---

# function::ns\_pgrp(3stap)

Returns the process group ID of the current process as seen in a pid namespace

## NAME

function::ns\_pgrp - Returns the process group ID of the current process as seen in a pid namespace

## SYNOPSIS

```
    ns_pgrp:long()
```

## ARGUMENTS

None

## DESCRIPTION

This function returns the process group ID of the current process as seen in the target pid namespace if provided, or the stap process namespace.

## SEE ALSO0

[*tapset::context*(3stap)](/tapset::context/3stap.md)
