LinuxQuestions.org
Visit Jeremy's Blog.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie
User Name
Password
Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question? If it is not in the man pages or the how-to's this is the place!

Notices


Reply
  Search this Thread
Old 08-04-2005, 01:43 AM   #1
IanPappas
Member
 
Registered: Aug 2005
Distribution: 10.1 A
Posts: 51

Rep: Reputation: 15
Angry How do I execute .pl files in Mandriva 10.2? Will someone please answer me this time?


How do I execute .pl (perl files)? I know how to open them in Kate or KWrite, but how do you execute the actual file? I know in Windows you can type "cd desktop",then, "perlfile.pl". and it runs it, but now when I do "cd Desktop" in Konsole, then "./perlfile.pl", it says "bash: ./xxxx.pl: Permission denied". Any suggestions?
 
Old 08-04-2005, 01:55 AM   #2
volvogga
Member
 
Registered: Aug 2004
Location: MI, USA
Distribution: Fedora Core 3
Posts: 137

Rep: Reputation: 15
I know that python programs are run by typing 'python python_program.py', so my first thought was to type 'perl perl_program.pl'. If you go to the following site...

http://www.ku.edu/~keds/software.dir/whyperl.html

this seems to be confirmed under the section 'Running Programs on UNIX Machines'.

Hope this helps.
 
Old 08-04-2005, 02:01 AM   #3
IanPappas
Member
 
Registered: Aug 2005
Distribution: 10.1 A
Posts: 51

Original Poster
Rep: Reputation: 15
Aha! Thankyou very much.

Last edited by IanPappas; 08-04-2005 at 02:10 AM.
 
Old 08-04-2005, 06:57 AM   #4
ethics
Senior Member
 
Registered: Apr 2005
Location: London
Distribution: Arch - Latest
Posts: 1,522

Rep: Reputation: 45
that fixed the problem?

if not it looks to me like you don't have the execute permissions set.

man chmod can help here or chmod +x <file> to get you started quickly.
 
Old 08-04-2005, 07:25 AM   #5
abisko00
Senior Member
 
Registered: Mar 2004
Location: Munich
Distribution: Ubuntu
Posts: 3,517

Rep: Reputation: 58
If the script has the correct interpreter set in the first line (e.g. #!/usr/bin/perl) and the script is located in your path and you made it executable (like ethics explained), you can run the script directly from commandline. Otherwise volvogga's method has to be used.
 
  


Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
Mandriva Freezes all the dang time!! jerm1701 Mandriva 9 07-20-2005 09:52 AM
php/max time exceeded/execute via shell? jdc32 Linux - Software 0 01-31-2005 05:22 AM
need answer on ipct and exif info in jpg files jensm Linux - Software 1 02-08-2004 12:10 PM
Cannot execute executable files without ./ brady9953 Linux - Newbie 3 10-13-2003 03:19 PM
NOOB/Please a simple answer installing .bin files bad1drums Linux - Newbie 3 03-31-2003 09:26 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie

All times are GMT -5. The time now is 07:37 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration