---
name: "iscsi_strerror"
section: "3"
platform: "linux"
package: "open-iscsi"
version: "2.1.13-1"
release: "Arch Linux 2026-11-01"
platforms: ["linux"]
url: "https://new.carta.tech/iscsi_strerror"
---

# iscsi\_strerror(3)

Convert error code to string.

## NAME

iscsi\_strerror - Convert error code to string.

## SYNOPSIS

**const char \* iscsi\_strerror** **(int** *rc***);**

## ARGUMENTS

- rc

  int. Return code by libiscsiur functions. When provided error code is not a valid error code, return "Invalid argument".

## DESCRIPTION

Convert error code (int) to string (const char \*):

\* LIBISCSI\_OK -- "OK"

\* LIBISCSI\_ERR\_BUG -- "BUG of libopeniscsiusr library"

\* LIBISCSI\_ERR\_SESS\_NOT\_FOUND - "Specified iSCSI session not found"

\* LIBISCSI\_ERR\_ACCESS - "Permission deny"

\* LIBISCSI\_ERR\_NOMEM - "Out of memory"

\* LIBISCSI\_ERR\_SYSFS\_LOOKUP - "Could not lookup object in sysfs"

\* Other invalid error number -- "Invalid argument"

## RETURN

const char \*. The meaning of provided error code. Don't free returned pointer.
