Detach a screen (Mac,Unix,Linux,Ubuntu,Centos,Fedora)

1. First List All screens:

screen -ls
$ screen -lsThere are screens on: 31643.screen_name1 (Attached) 30846.screen_name2 (Detached) 28743.screen_name3 (Detached) 31033.screen_name4 (Detached)4 Sockets in /var/run/screen/S-centos.

2. then detach screen whatever you want

screen -d screen_name1
OR
screen -d 31643

Note: if you want to reattach then use

screen -r screen_name1
OR
screen -r 31643