Koozali.org: home of the SME Server

Using cgi-bin on SME Server

ghamlin

Using cgi-bin on SME Server
« on: November 30, 2005, 07:37:03 PM »
I'm new to SME server; as in this week. The server and Ibays are up and running but I want to add a few cgi programs for the web users to use like counter or a search.exe utility.

Many of these utilities need write access to the cgi-bin and sub directories in order to work. I uploaded the code using the admin account but when I run them from the html pages they don't work.

For example I have html code that outputs "You are Visitor X since November 11th, 2005"  The actual code is
<p align="center"> You are Visitor <!--#exec cgi="/counter"--> since November 11th, 2005<br></p>
which should give a count.  I maybe missing several things/concepts etc and would appreciated some guidance.  Greg  :roll:

Offline crazybob

  • *****
  • 894
  • +0/-0
    • Stalzer R&D
Using cgi-bin on SME Server
« Reply #1 on: November 30, 2005, 09:39:18 PM »
I don't think the problem is with the cgi-bin folder. You probably need to set permissions on the files and other folders properly. Check the documentatiom that came with the app. There also can be trouble with the way you uploaded the file to the cgi-bin folder. Make sure you use ASCII mode. There are also issues with how some ftp clients have problems setting permissions.

Bob
If you think you know whats going on, you obviously have no idea whats going on!

ghamlin

Setting permisison
« Reply #2 on: November 30, 2005, 09:46:48 PM »
I tend to agree but...
How does one change persmissions on SME Sever. I've used the web server-manager a couple of times but I don't see how one changes permissions on a directory.  Thanks, Greg

Offline crazybob

  • *****
  • 894
  • +0/-0
    • Stalzer R&D
Using cgi-bin on SME Server
« Reply #3 on: November 30, 2005, 10:23:05 PM »
Greg,
   You can't change permissions with server-manager. You have to use an ftp client such as wsftp. use the ftp program to connect to your server, and navigate to the cgi-bin folder. Use the controls of the ftp program to change permissions on the file/folders.

The methodes of doing this are basic to the use of ftp, and linux.

If you are not familiar with linux, as we all were at some point (and in many ways I still am) check out a linux newbie site to get a little feel for how to do things with linux. Keep in mind that this is a very customized version of lunix, and you can't do everything the way they say for most distros. Most everything can be accomplished, just in a different way.
If you think you know whats going on, you obviously have no idea whats going on!

Offline raem

  • *
  • 3,972
  • +4/-0
Using cgi-bin on SME Server
« Reply #4 on: November 30, 2005, 11:12:40 PM »
Greg

logon as root and do
man chown
man chmod
...