Why is my custom script running on Red Hat Enterprise Linux is throwing an error: "Invalid cross-device link"?

Updated -

Typically, this error results when the scripts in questions are using ln command and have tried to create a hard-link across filesystems.

Since it is not possible to create hard-links for files across filesystems, the ln command errors. Below is an example of this:

[root@localhost ~]# df -h
Filesystem Size Used Avail Use% Mounted on
/dev/mapper/V...

Subscriber exclusive content

A Red Hat subscription provides unlimited access to our knowledgebase, tools, and much more.

Current Customers and Partners

Log in for full access

Log In

New to Red Hat?

Learn more about Red Hat subscriptions

Using a Red Hat product through a public cloud?

How to access this content