problem with proftpd 1.2.10 installation

Discussion in 'HOWTO-Related Questions' started by Pulkvedis, May 16, 2007.

  1. Pulkvedis

    Pulkvedis New Member

    Hi!

    I download proftpd 1.2.10 and tray to install it...
    when i write comand "make"
    it's say "make: *** No targets specified and no makefile found. Stop."

    What i do wrong?
     
  2. Leszek

    Leszek Member

    Did You run:
    Code:
    ./configure
    
    first ?
     
  3. Pulkvedis

    Pulkvedis New Member

    yes i run it a the write

    linux:~/proftpd-1.2.10 # ./configure
    checking build system type... i686-pc-linux-gnu
    checking host system type... i686-pc-linux-gnu
    checking target system type... i686-pc-linux-gnu
    checking for gcc... no
    checking for cc... no
    checking for cc... no
    checking for cl... no
    configure: error: no acceptable C compiler found in $PATH
    See `config.log' for more details.

    OK i find a problem. I install gcc pack and now it's ok ;)
     
    Last edited: May 16, 2007
  4. Leszek

    Leszek Member

    You don't have any C compilers installed.
    You need to install gcc.
     
  5. Pulkvedis

    Pulkvedis New Member

    yes i install it now.

    and next problem: How can i start this server?
     
  6. Leszek

    Leszek Member

    I depends on Your distribution.
    For example in Debian:

    It is similar in different distributions.
     
  7. Pulkvedis

    Pulkvedis New Member

    yes i tray but result ir bad :(

    linux:~ # /etc/init.d/proftpd start
    Starting ProFTPD Server: failed

    how i understand this file "proftpd" in this init.d. directory i must create my self manualy yes? first time when i create it un tray start server result was:

    linux:~ # /etc/init.d/proftpd start
    bash: /etc/init.d/proftpd: Permission denied

    then i in permission check field execuatable i do wrong?
     
  8. Leszek

    Leszek Member

    This file should be created automatically and must be exacutable.
    Code:
    chmod u+x /etc/init.d/proftpd
    
     
  9. Pulkvedis

    Pulkvedis New Member

    linux:/ # chmod u+x /etc/init.d/proftpd
    chmod: cannot access `/etc/init.d/proftpd': No such file or directory

    what now?
     
  10. Leszek

    Leszek Member

    My /etc/init.d/proftpd looks like this:

    Code:
    #!/bin/sh 
    
    # Start the proftpd FTP daemon.
    
    PATH=/bin:/usr/bin:/sbin:/usr/sbin
    DAEMON=/usr/sbin/proftpd
    NAME=proftpd
    
    # Defaults
    RUN="no"
    OPTIONS=""
    
    PIDFILE=`grep -i 'pidfile' /etc/proftpd/proftpd.conf | sed -e 's/pidfile[\t ]\+//i'`
    if [ "x$PIDFILE" = "x" ];
    then
    	PIDFILE=/var/run/proftpd.pid
    fi
    
    # Read config (will override defaults)
    [ -r /etc/default/proftpd ] && . /etc/default/proftpd
    
    trap "" 1
    trap "" 15
    
    test -f $DAEMON || exit 0
    
    #
    # These compatibility funcs are here just for sarge backports.
    # They will be removed post-etch.
    #
    log_daemon_msg() {
        echo -n "$1: $2"
    }
    
    log_end_msg() {
        if [ $1 -ne 0 ]; then
           echo " failed!"
        else
           echo "."
        fi
    }
    
    [ -f /lib/lsb/init-functions ] && . /lib/lsb/init-functions
    
    #
    # Servertype could be inetd|standalone|none.
    # In all cases check against inetd and xinetd support.
    #
    if ! egrep -qi "^[[:space:]]*ServerType.*standalone" /etc/proftpd/proftpd.conf
    then
        if [ $(dpkg-divert --list xinetd|wc -l) -eq 1 ] 
        then
    	if egrep -qi "server[[:space:]]*=[[:space:]]*/usr/sbin/proftpd" /etc/xinetd.conf 2>/dev/null || \
    	   egrep -qi "server[[:space:]]*=[[:space:]]*/usr/sbin/proftpd" /etc/xinetd.d/* 2>/dev/null
    	then
        		RUN="no"
        		INETD="yes"
    	else
    		if ! egrep -qi "^[[:space:]]*ServerType.*inetd" /etc/proftpd/proftpd.conf
    		then
        			RUN="yes"
    			INETD="no"
    		else
    			RUN="no"
    			INETD="no"
    		fi
    	fi
        else
        	if egrep -qi "^ftp.*/usr/sbin/proftpd" /etc/inetd.conf 2>/dev/null
        	then
        		RUN="no"
        		INETD="yes"
        	else
    		if ! egrep -qi "^[[:space:]]*ServerType.*inetd" /etc/proftpd/proftpd.conf
    		then
        			RUN="yes"
    			INETD="no"
    		else
    			RUN="no"
    			INETD="no"
    		fi
        	fi
        fi
    fi
    
    # /var/run could be on a tmpfs
    
    [ ! -d /var/run/proftpd ] && mkdir /var/run/proftpd
    
    start()
    {
        log_daemon_msg "Starting ftp server" "$NAME"
    
        start-stop-daemon --start --quiet --pidfile "$PIDFILE" --exec $DAEMON -- $OPTIONS  
        if [ $? != 0 ]; then
            log_end_msg 1
            exit 1
        else
            log_end_msg 0
        fi
    }
    
    signal()
    {
    
        if [ "$1" = "stop" ]; then
    	SIGNAL="TERM"
        	log_daemon_msg "Stopping ftp server" "$NAME"
        else
    	if [ "$1" = "reload" ]; then
    	    SIGNAL="HUP"
        	    log_daemon_msg "Reloading ftp server" "$NAME"
    	else
    	    echo "ERR: wrong parameter given to signal()"
    	    exit 1
    	fi
        fi
        if [ -f "$PIDFILE" ]; then
        	start-stop-daemon --stop --signal $SIGNAL --quiet --pidfile "$PIDFILE"
       	 if [ $? = 0 ]; then
            	log_end_msg 0
        	else
    		SIGNAL="KILL"
    		start-stop-daemon --stop --signal $SIGNAL --quiet --pidfile "$PIDFILE"
        		if [ $? != 0 ]; then
            		log_end_msg 1
            		[ $2 != 0 ] || exit 0
        		else
            		log_end_msg 0
        		fi
        	fi
       	if [ "$SIGNAL" = "KILL" ]; then
    		rm -f "$PIDFILE"
        	fi
        else
            log_end_msg 0
        fi
    }
    
    case "$1" in
        start)
    	if [ "x$RUN" = "xyes" ] ; then
    	    start
    	else
    	    if [ "x$INETD" = "xyes" ] ; then
    		echo "ProFTPd is started from inetd/xinetd."
    	    else 
    	    	echo "ProFTPd warning: cannot start neither in standalone nor in inetd/xinetd mode. Check your configuration."
    	    fi
    	fi
    	;;
    
        force-start)
    	if [ "x$INETD" = "xyes" ] ; then
    	    echo "Warning: ProFTPd is started from inetd/xinetd (trying to start anyway)."
    	fi
    	start
    	;;	
        
        stop)
    	if [ "x$RUN" = "xyes" ] ; then
    	    signal stop 0
    	else
    	    if [ "x$INETD" = "xyes" ] ; then
    		echo "ProFTPd is started from inetd/xinetd."
    	    else 
    	    	echo "ProFTPd warning: cannot start neither in standalone nor in inetd/xinetd mode. Check your configuration."
    	    fi
    	fi
    	;;
    
        force-stop)
    	if [ "x$INETD" = "xyes" ] ; then
    	    echo "Warning: ProFTPd is started from inetd/xinetd (trying to kill anyway)."
    	fi
    	signal stop 0
    	;;
    
        reload)
    	signal reload 0
    	;;
    
        force-reload|restart)
    	if [ "x$RUN" = "xyes" ] ; then
    	    signal stop 1
    	    sleep 2
    	    start
    	else
    	    if [ "x$INETD" = "xyes" ] ; then
    		echo "ProFTPd is started from inetd."
    	    else 
    	    	echo "ProFTPd warning: cannot start neither in standalone nor in inetd/xinetd mode. Check your configuration."
    	    fi
    	fi
    	;;
    
        *)
    	echo "Usage: /etc/init.d/$NAME {start|force-start|stop|force-stop|reload|restart|force-reload}"
    	exit 1
    	;;
    esac
    
    exit 0
    
    Maybe You can find this file in the directory where You unpacked Proftp to compile and install it ? Then You should copy it in the right place (/etc/init.d/).
     
  11. Pulkvedis

    Pulkvedis New Member

    yes thanks now its works. i just copy this proftpd file from this folder where i extract it to init.d and now its work. TNX very much ;)
     
  12. Leszek

    Leszek Member

    Your welcome :)
     

Share This Page