LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - General (https://www.linuxquestions.org/questions/linux-general-1/)
-   -   Making programs start on power-on (https://www.linuxquestions.org/questions/linux-general-1/making-programs-start-on-power-on-186227/)

orange400 05-26-2004 04:43 PM

Making programs start on power-on
 
I run an FTP server, and I just run the programs needed every time I restart it for whatever reason. But it would be soooooo nice if I could get some progs running when it goes through booting time. I need noip2 and proftpd to start on their own, can anyone help me do that?

Thanks everyone!

Razza2004 05-26-2004 04:52 PM

I can't remember the exact file, but for most distros its in /etc/rc.d (or whatever the folder is)
EDIT: /etc/rc.d/rc.local
Just add the command line thingys to there

Crashed_Again 05-26-2004 04:53 PM

Which distrobution are you talking about? For redhat you can use the command line:

chkconfig --list

tool or in the gui you can use:

redhat-config-services

Not sure about Mandrake or Debian though.

Razza2004 05-26-2004 05:03 PM

Ive used it in Slackware to do things like:
mount -t ntfs /dev/hda1 /mnt/windows
(etc)

So its just non-gui tools, anything that you would run from bash that doesn't need Xwindows I would guess.

orange400 05-26-2004 05:13 PM

Sorry for not providing enough info ... It's a RH9 text-only server.

I'm gonna look at the rc.local stuff, I'll tell you how it goes, thanks!

orange400 05-26-2004 05:29 PM

Well I added /usr/src/pro*/proftpd -n -c /etc/proftpd.conf to the rc.local file and it loads the FTP server, but there's one problem ... it's a standalone server, so when it runs, it sticks there waiting for incoming connections. It doesn't load to the point where it asks me to login, so I can't do anything to the server if I do it this way.

There wouldn't be a way to autologin _then_ run proftpd, is there? I have to start the server as root (it switches to user anonymous before it actually inits), so it might be kinda ~ on security, but nobody's gonna break into my house and start breaking in or anything.

Another thing that would be really great - I use the switching "desktops" a lot (Alt-F1, Alt-F2, etc), so would there be any way to autologin on the Alt-F2 "desktop" to run top? I do this to monitor who's on the server.

orange400 05-26-2004 05:40 PM

Ack, it's really stuck. How can I pass an option to the kernel with grub to tell it to enter runlevel 1?

Nevermind, I figured out the runlevel stuff. Man it's so nice to be somewhat fluent in linux!! :cool: Couldn't have done it all without you guys.

So any ideas on making the server autoboot? Perhaps inetd? I'm not sure how to do that either, I just keep hearing about it.


All times are GMT -5. The time now is 10:01 PM.