[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Detached sessions not being created

From: Joe Zbiciak
Subject: Re: Detached sessions not being created
Date: Thu, 22 Nov 2012 21:01:49 -0800 (PST)


I don't have a solution for you, but a question that might lead toward the solution:

In order to launch successfully (even in a detached mode), does screen need a controlling tty, a valid setting for $TERM, and valid termios information (screen dimensions)?  I think it might.

When you launch from Konsole, I'm certain it has all that.  But when you launch from cron, I'd be surprised if it has any of that. 


We sell Spatulas, and that's all!

From: Mark Adams <address@hidden>
To: address@hidden
Sent: Thu, November 22, 2012 10:37:51 PM
Subject: Detached sessions not being created

I have several machines on my network that provide services of one type or another. I'm trying to configure them to create detached screen sessions at boot time. Let's take a representative example.

I have a cron job setup under my user ID:

@reboot /usr/bin/screen -d -m -S pvr

I have also used the syntax "@reboot /usr/bin/screen -dmS pvr".

Neither of these has worked.

I tried creating a bash script:

# This script starts a detached screen session on boot.
su - <my_user> -c "/usr/bin/screen -dmS pvr"

Neither of these work despite the fact that when I run the command "/usr/bin/screen -d -m -S pvr" as my user in a konsole window it creates the screen session as expected (note that I can stack those options to -dmS and it makes no difference).

I should say that I'm also unable to start that screen session from crontab in Webmin (I assume it uses the run-parts command to do that). I get no error - it just doesn't create the screen session.

I set uid root: "chmod a+s /usr/bin/screen" and I have seen references to changed the permissions of /var/run/screen.  I have no /var/run/screen.

Any wisdom?


Mark Adams

reply via email to

[Prev in Thread] Current Thread [Next in Thread]