-
Junior Member
registered user
Running Server Side Perl Scripts
I have been able to run PHP Server Side Scripts on Apache using the Knoppix Live CD. But cannot run Server Side Perl Scripts. I cannot save a Perl Script in the cgi-bin directory, it is READ ONLY. I have tried changing the File Permissions from the Root Shell but have had NO Luck.
Is there a way to run Server Side Perl Scripts from the Live CD ?
-
Senior Member
registered user
Hi,
Re: perl and bash scripts.
You need to be root to do this.
Use whatever text editor you prefer out of those available (gedit, kate, kwrite, emacs and vim).
Create a file as root with the following.
Code:
#!/bin/bash
printf "Content-type:text/html\r\n\r\n";
printf "<html>hello world</html>\r\n";
This bash script should be saved as hello.cgi and saved in the /usr/lib/cgi-bin directory.
It also needs to be made executable for all users:
At the root prompt type
chmod 755 /usr/lib/cgi-bin/hello.cgi
Then visit the file with a browser e.g. mozilla
http://127.0.0.1/cgi-bin/hello.cgi
Once this works you can do the same for perl. This time saving the file as hello.pl
and using the following code:
Code:
#!/usr/bin/perl
print "Content-type:text/html\n\n";
print "<html>hello world</html>\n";
Once you have got these two programs going then you have a wide choice to start open source web programming under Knoppix Debian/Gnu/Linux.
Regards,
Mark
See also
http://www.knoppix.net/forum/viewtopic.php?t=19300
Similar Threads
-
By brass in forum MS Windows & New to Linux
Replies: 1
Last Post: 05-02-2006, 11:47 AM
-
By Ardil in forum General Support
Replies: 2
Last Post: 05-28-2005, 10:37 PM
-
By bstanard in forum General Support
Replies: 5
Last Post: 01-10-2005, 03:52 PM
-
By Zoplax in forum Customising & Remastering
Replies: 2
Last Post: 10-15-2003, 09:36 PM
-
By majales in forum General Support
Replies: 2
Last Post: 05-15-2003, 04:21 PM
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules

Dell ST6000NM0034 1HT27Z-150 NWCCG 6TB SAS 3.5 7.2K ENTERPRISE SERVER DRIVE
$68.99

Western Digital HUS726T4TAL5204 4TB 7.2K SAS 12Gb/s 3.5" 512e HDD NetApp X375A
$64.00

Toshiba 1TB 2.5" SATA HDD MQ01ABD100V 5400RPM 9.5mm Laptop Internal Hard Drive
$53.99

Seagate ST8000NM0075 Enterprise Capacity 3.5 HDD 8TB SAS Hard Drive 8TB EXOS
$184.99

Western Digital WD2003FYYS-05T9B0 2TB 7.2K SATA 3.5'' Enterprise Hard Drive
$30.76

HGST HUA723030ALA640 3TB SATA 7200 RPM 3.5 in Enterprise HDD | 0F14044 (100%)
$45.00

HGST HUS724040ALA640 4TB 7200 RPM SATA 3.5" Internal Desktop Drive 100% Health
$78.00

Seagate ST6000NM0115 6TB 256MB 7200RPM 3.5" SATA 6.0Gb/s Enterprise Hard Drive
$159.99

HDD 3.5" SATA Hard Drive with Windows 10/Win 11 64x Installed Legacy
$35.00

HGST HUS726060AL5210 0F22791 6TB 7.2K 3.5" SAS HDD Enterprise Storage Drive
$78.99