---
name: "rdma_migrate_id"
section: "3"
platform: "linux"
package: "rdma-core"
version: "65.0-1"
release: "Arch Linux 2026-11-01"
platforms: ["linux", "freebsd"]
url: "https://new.carta.tech/rdma_migrate_id"
---

# rdma\_migrate\_id(3)

Move a communication identifier to a different event channel.

## NAME

rdma\_migrate\_id - Move a communication identifier to a different event channel.

## SYNOPSIS

**#include \<rdma/rdma\_cma.h\>**

**int rdma\_migrate\_id** **(struct rdma\_cm\_id \****id***,** **struct rdma\_event\_channel \****channel***);**

## ARGUMENTS

- id

  An existing communication identifier to migrate.

- channel

  The communication channel that events associated with the allocated rdma\_cm\_id will be reported on.  May be NULL.

## DESCRIPTION

Migrates a communication identifier to a different event channel.

## RETURN VALUE

Returns 0 on success, or -1 on error.  If an error occurs, errno will be set to indicate the failure reason.

## NOTES

This routine migrates a communication identifier to the specified event channel and moves any pending events associated with the rdma\_cm\_id to the new channel.  Users should not poll for events on the rdma\_cm\_id's current event channel or invoke other routines on the rdma\_cm\_id while migrating between channels.  This call will block while there are any unacknowledged events on the current event channel.

If the channel parameter is NULL, the specified rdma\_cm\_id will be placed into synchronous operation mode.  All calls on the id will block until the operation completes.

## SEE ALSO

[rdma\_cm(7)](/rdma_cm/7.md), [rdma\_create\_event\_channel(3)](/rdma_create_event_channel/3.md), [rdma\_create\_id(3)](/rdma_create_id/3.md), [rdma\_get\_cm\_event(3)](/rdma_get_cm_event/3.md)
