View previous topic :: View next topic |
Author |
Message |
requiem n00b
Joined: 07 Sep 2003 Posts: 23
|
Posted: Wed Sep 17, 2003 5:02 am Post subject: Error when running vsftpd in standalone mode. |
|
|
Hi,
Just a question concerning vsftpd. I have just configured it to start on boot and I am getting this error:
/sbin/runscript.sh: line 21: Network: command not found
* Starting vsftpd... [ ok ]
Thought this was a bit of an odd error. I tracked it down to this line in runscript.sh:
myservice="$(readlink "$1")"
Can anyone work out what is going on or need any further details? I can post my vsftpd config if you think it will help, although I don't think it is related to that.
Cheers,
Req. |
|
Back to top |
|
|
devon l33t
Joined: 23 Jun 2003 Posts: 943
|
Posted: Wed Sep 17, 2003 7:29 am Post subject: |
|
|
Did you write your own script to start vsftpd? Can you post it here? |
|
Back to top |
|
|
requiem n00b
Joined: 07 Sep 2003 Posts: 23
|
Posted: Wed Sep 17, 2003 7:50 am Post subject: |
|
|
Nope did not. I was reading through the bug tracker and found this:
Bug concerning standalone scripts missing for vsftpd.
Seems that these scripts are only new, hence this may be where the problem lies. From what I can gather the script "/sbin/runscript.sh" is called by the interpretter "/sbin/runscript". I am just not sure what is passed by "/sbin/runscript" and thus can't work out why the line:
myservice="$(readlink "$1")"
persists in giving me an error. Any help would be appreciated.
Cheers,
Req.
PS: If anyone wants to load vsftpd standalone I think updating from the latest source should give you all the required scripts. |
|
Back to top |
|
|
devon l33t
Joined: 23 Jun 2003 Posts: 943
|
Posted: Wed Sep 17, 2003 8:01 am Post subject: |
|
|
What version of vsftpd are you using?
Code: | $ emerge -pv vsftpd
These are the packages that I would merge, in order:
Calculating dependencies ...done!
[ebuild R ] net-ftp/vsftpd-1.2.0-r1 +pam +tcpd -ipv6
|
I looked through the /etc/init.d/vsftpd script and didn't see anything obvious. I did see that it appears the vsftpd script does use /sbin/runscript.
Code: | $ file /etc/init.d/vsftpd
/etc/init.d/vsftpd: a /sbin/runscript script text executable |
|
|
Back to top |
|
|
requiem n00b
Joined: 07 Sep 2003 Posts: 23
|
Posted: Wed Sep 17, 2003 8:23 am Post subject: |
|
|
Here is the output from those two commands. I am sure that this is the latest vsftpd as of this afternoon.
Code: |
# emerge -pv vsftpd
These are the packages that I would merge, in order:
Calculating dependencies ...done!
[ebuild R ] net-ftp/vsftpd-1.2.0-r1 +pam +tcpd -ipv6
|
Code: |
# file /etc/init.d/vsftpd
/etc/init.d/vsftpd: a /sbin/runscript script text executable
|
I have tried some additional testing by adding the code to runscript.sh as follows:
Code: |
echo $1
myscript="$1"
if [ -L "$1" -a ! -L "/etc/init.d/${1##*/}" ]
then
myservice="$(readlink "$1")"
else
myservice="$1"
fi
echo $1
|
Which yeilds the results:
Code: |
# /etc/init.d/vsftpd restart
/etc/init.d/vsftpd
/etc/init.d/vsftpd
* Stopping vsftpd... [ ok ]
/sbin/runscript.sh: line 21: Network: command not found
* Starting vsftpd... [ ok ]
|
Thus I think that the $1 may be passed correctly when stop is called, but incorrectly when start is called.
Cheers
Req. |
|
Back to top |
|
|
LJ Apprentice
Joined: 27 Dec 2002 Posts: 156
|
Posted: Sun Oct 05, 2003 8:42 am Post subject: |
|
|
[edit: whoops, wrong thread] |
|
Back to top |
|
|
|