Skip to main content

You are not logged in. Your edit will be placed in a queue until it is peer reviewed.

We welcome edits that make the post easier to understand and more valuable for readers. Because community members review edits, please try to make the post substantially better than how you found it, for example, by fixing grammar or adding additional resources and hyperlinks.

Required fields*

3
  • 1
    So you try to copy file from remote machine to the clipboard of your local computer, right? Commented Feb 6, 2020 at 10:15
  • 1
    try running it as DISPLAY=:0 xsel -b <foo or ... | DISPLAY=:0 xsel -b instead of DISPLAY=:0 cat ... | xsel -b which will only set the DISPLAY envvar for the cat process. Commented Feb 6, 2020 at 11:39
  • I am getting same issue on remote server (CentOS 7) when working in screen. Commented Aug 1, 2022 at 10:14