Linux - NewbieThis Linux forum is for members that are new to Linux.
Just starting out and have a question?
If it is not in the man pages or the how-to's this is the place!
Notices
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
assuming that skype (which i've never used, so don't know the behaviour or the binary name...) doesn't fork or have a more complex run logic, just use the fact that it's running to hold a loop...
Code:
while [ 1 ]
do
skype
sleep 3 # could go nuts maybe, worth hanging up for a few seconds
done
use that script as a launcher in X and it'll always respawn automatically.
assuming that skype (which i've never used, so don't know the behaviour or the binary name...) doesn't fork or have a more complex run logic, just use the fact that it's running to hold a loop...
Code:
while [ 1 ]
do
skype
sleep 3 # could go nuts maybe, worth hanging up for a few seconds
done
use that script as a launcher in X and it'll always respawn automatically.
the thing is that [ 1 ]
should maybe be replaced by
no.... if skype crashes then the loop just starts again. there's no need to check if skype itself is running at all, that's the point of the infinite loop, just keep reloading it each time.
you could use pidof or something, but i think you're in danger of overengineering an otherwise very simple scenario.
no.... if skype crashes then the loop just starts again. there's no need to check if skype itself is running at all, that's the point of the infinite loop, just keep reloading it each time.
you could use pidof or something, but i think you're in danger of overengineering an otherwise very simple scenario.
yes
Ah, yes, it is indeed a nice idea, you got. I'd have the following question: how can I close it, when I log in the machine with ssh ?
well if all you want is to literally kill it, close the controlling terminal of ctrl+c it. there is going to be a bash instances which it running skype obviously, so you could easily get the parent process and kill that instance.
well if all you want is to literally kill it, close the controlling terminal of ctrl+c it. there is going to be a bash instances which it running skype obviously, so you could easily get the parent process and kill that instance.
well, that might not be possible since it starts with the fluxbox startup, and I would have only ssh access. no ctrl c. only some kill way...
Good evening & Regards
Last edited by frenchn00b; 12-30-2007 at 05:24 PM.
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.