[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: pptpdconfig.pl



On Wed, Sep 20, 2000 at 08:42:20PM -0800, Ethan Benson wrote:
> On Wed, Sep 20, 2000 at 11:21:37PM -0500, will trillich wrote:
> > trying to get VPN going, still, this time with pptpd--and the
> > config script seems kaflooey--
> > 
> > 	# apt-get install pptpd
> > 	<snip>
> > 	# pptpdconfig.pl
> > 	/usr/sbin/pptpdconfig.pl: Permission denied.
> > 	# ls -l /usr/sbin/pptpdconfig.pl
> > 	-rw-r--r--    1 root   root   1581 Feb 22  2000 /usr/sbin/pptpdconfig.pl
> > 
> > <no chmod +x ?>

> not even root can execute the non-executable.  
> 
> file a bug against the package, and run chmod 755 /usr/sbin/pptpdconfig.pl 
> as root

agreed. but that's not the problem. (gotcha!)

as you know...

	$ filename

entered like this, it's being run as a command, so it would need +x permissions.

	$ perl filename

this way, perl reads the file and then runs the script therein, as long as it's
readable.  (a file doesn't need to be executable unless you're trying to run it
as a shell command.) 

perl can even run commands from STDIN, such as

	$ perl < filename
	$ cat filename | perl

so it only needs to be able to READ the file; execute permissions are for the
commands to be run directly from the shell. (saves us lazy folk from typing
a few keystrokes here and there.)

--

UNRESOLVED:

still, when i have perl run the file directly (no chmod +x needed there)
it still bombs with

> > 	# perl /usr/sbin/pptpdconfig.pl

or
# cat < /usr/sbin/pptpdconfig.pl | perl
if you must

> > 	Can't exec "pptpdconfig.pl": Permission denied at /usr/lib/perl5/5.005/IPC/Open3.pm line 188.
> > 	open2: exec of pptpdconfig.pl failed at /usr/lib/perl5/Debian/DebConf/ConfModule.pm line 46
> > 	Use of uninitialized value at /usr/lib/perl5/Debian/DebConf/ConfModule.pm line 303.
> > 
> > am i missing a piece? (i ran this as root, so it wouldn't appear to be
> > a normal user permissions snag...)

what's up with that?



Reply to: