LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Newbie (https://www.linuxquestions.org/questions/linux-newbie-8/)
-   -   Problems setting up ProFTP (https://www.linuxquestions.org/questions/linux-newbie-8/problems-setting-up-proftp-315858/)

tjulius 04-21-2005 07:24 PM

Problems setting up ProFTP
 
I'm just getting going on Linux, running RedHat Enterprise edition.

I'm trying to set up ProFTP, and I used the tutorial here but took a wrong turn somewhere. Now I'm trying to follow the instructions at redhat.hostinghacks.net/proftp/ and have made better progress, but am now stuck on one point.

After I set up the proftpd init script (as stored in etc/init.d), I chmod it to 755, add it to chkconfig, and then give the command: service proftpd start.

This calls the start function in the script, which hoses out on this line:
daemon proftpd $OPTIONS

as such:

daemon: command not found.

I did it from the command line and got:

-bash: daemon: command not found

What's not found? Is daemon not found? If not, what should I use, or what should I install? Is proftpd not found? If so, where should it be, and with what permissions?

I think I'm just missing some little step here. Soooo close, and yet soooo far...

Thanks for any insight.

- t

twantrd 04-22-2005 01:17 AM

Quote:

daemon: command not found
It's telling you right there :). It's saying that the command 'daemon' cannot be found. Looks like your startup script is somewhat incorrect as proftpd's binary should not be called daemon. If you can't disect and fix the startup script then I suggest you write your own.

-twantrd

bathory 04-22-2005 01:59 AM

Quote:

This calls the start function in the script, which hoses out on this line:
daemon proftpd $OPTIONS
as such:
daemon: command not found.
Perhaps you have to put the directory where you installed proftpd in your PATH. Or write down the whole path to proftpd in the startup script:
Code:

daemon /path/to/proftpd $OPTIONS

tjulius 04-22-2005 07:00 AM

But if daemon itself is not found....???
 
??

bathory 04-22-2005 08:40 AM

Replace daemon with startproc and see what happens.

tjulius 04-22-2005 09:46 AM

I actually had done that
 
I have used loadproc and startproc, all were not found.

I didn't come running here first; I've actually invested (wasted, maybe) a fair amount of time on this.

I've also compared it to other entries in init.d... for instance, syslog can be started, and is command is:

start() {
echo ... something ....
daemon syslogd $SYSLOGD_OPTIONS
.. some other stuff..
}


so that works just fine. Syntactically it's a little different... it has start(){}, and I have start) ;;

It also starts with bin/bash, and I start with bin/sh.. does that make a difference? I tried bin/bash, but no difference, although I didn't try changing the whole syntax around. And the scripts I referenced were explicitly written for redhat, so one would think they work.

tjulius 04-22-2005 11:15 AM

Found that part of the problem
 
I compared it against syslog, which did seem to run, and traced it to the beginning of the script.

I had:

./etc/rc.d/init.d/functions

Syslog had:

. /etc/init.d/functions

To make a long story short, it was the space between the period and the / (not so much the directory). There is a file called "functions" in /etc/rc.d/init.d/, and there is a function "daemon" in it. Since /etc/... is off the root, and not relative, I realized the space was not a type but was intentional, changed it, and that problem went away.

There's now a new problem "execvp: No such file or directory", but I'm just beginning to look at that.


All times are GMT -5. The time now is 06:19 AM.