Re: [users@httpd] Received 404 not found error on existing CGI script
Hello, Thanks for your reply. I solved the not being able to run a Perl CGI script issue. I now have several of my old Perl CGI scripts up and running. Now one of my other CGI scripts is failing badly. The mysql error log does not show anything useful. All I see on my screen is a '500 internal server error'. I checked the syntax of my perl script and it is ok. Your message stated that setting "my log file level to debug" was a good debugging idea. I have been trying to figure out how to accomplish this task with no success. Which config file do I need to change and what specific change do I need to make to the config file ? Thanks/ On Wed, Jun 24, 2020 at 11:15 AM angel Hall-Coulston wrote: > Try setting your log file level to debug, you will get far more > information. Also at the end of the 'log format' code in your configuration > file (easy double check by command 'httpd -V' which will double check your > conf file) add '%L' which when added to both access_log file formats AND > error_log formats will give matches between the two easily found with the > 'grep' command 'grep > "[long-scrambled-unique-characters-for-that-particular-error] '*_log' . > Make sure you first are in the log directory. > > Another helpful tip… your apache comes with it’s VERY OWN manual pages > which when enabled in your 'includes' section of your config file, will > allow you to access MUCH quicker than going online, where you will find > everything you need to know. > > Angel Hall-Coulston > Scotland. > > On 24 Jun 2020, at 00:35, barry kimelman wrote: > > my system is an ubuntu 20.04 lts laptop. > > I successfully installed apache2. I verified the installation by visiting > http://localhost:80 <http://localhost/> > > Now I am having problems trying to run a Perl CGI script which I had > running under Windows 10 on Apache 2.4 > > I modified the sites-enabled/000-default.conf file by removing the '#' > from the start of the "Include conf-available/serve-cgi-bin.conf" line. I > then created the /usr/lib/cgi-bin directory. I next put a small Perl CGI > script named "printenv.cgi" under /usr/lib/cgi-bin. I then restarted the > apache2 server. When I attempted to run my newly created CGI script gy > visiting localhost:80/cgi-bin/printenv.cgi > <http://localhost/cgi-bin/printenv.cgi> all that happened was I received > a "404 Not Found" error. I looked at the apache logfile and it provided no > further info. > > I even tried using the "wget" command. same 404 error. > > What have I done wrong? > > -- > > Barrry Kimelman > Winnipeg, Manitoba, Canada > > > -- Barrry Kimelman Winnipeg, Manitoba, Canada
[users@httpd] Received 404 not found error on existing CGI script
my system is an ubuntu 20.04 lts laptop. I successfully installed apache2. I verified the installation by visiting http://localhost:80 Now I am having problems trying to run a Perl CGI script which I had running under Windows 10 on Apache 2.4 I modified the sites-enabled/000-default.conf file by removing the '#' from the start of the "Include conf-available/serve-cgi-bin.conf" line. I then created the /usr/lib/cgi-bin directory. I next put a small Perl CGI script named "printenv.cgi" under /usr/lib/cgi-bin. I then restarted the apache2 server. When I attempted to run my newly created CGI script gy visiting localhost:80/cgi-bin/printenv.cgi all that happened was I received a "404 Not Found" error. I looked at the apache logfile and it provided no further info. I even tried using the "wget" command. same 404 error. What have I done wrong? -- Barrry Kimelman Winnipeg, Manitoba, Canada
[users@httpd] Can't get access to CSS stylesheets and javascript files using Apache2.2 on windows
Hello, I have installed apache2.2 on my windows laptop. The basics are working fine. I setup my own directory structure under "C:\apachedata" and modified httpd.conf to point under that directory. Accessing HTML pages works fine. CGI scripts that just generate HTML work fine. However when I try to get access to CSS and JS files the apache error log keeps showing me the dreaded 403 error message I have added the following line into httpd.conf Alias /jslib "C:/apachedata/jslib" Here is the "source code" generated by my CGI script which results in the 403 error emssage http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd;> http://www.w3.org/1999/xhtml; lang="en-US" xml:lang="en-US"> Encrypted Data Management http://127.0.0.1/jslib/styles.css>" /> http://127.0.0.1/jslib/fieldset.css>" /> http://127.0.0.1/jslib/check_all_fields.js>" type="text/JAVASCRIPT"> http://127.0.0.1/jslib/hide_show_divider.js>" type="text/JAVASCRIPT"> Encrypted Data ManagementCGI script parameters No CGI script parameters are defined Sun Sep 6 13:50:40 2015 http://127.0.0.1/cgi-bin/e2.cgi?function=listall>">List Data http://127.0.0.1/cgi-bin/e2.cgi?function=query>">Query Data http://127.0.0.1/cgi-bin/e2.cgi?function=add>">Add New Record http://127.0.0.1/cgi-bin/e2.cgi?function=meta>">List Metadata Here is the contents of the jslib directory Volume in drive C is TI10673200G Volume Serial Number is 5E9D-3D3F Directory of C:\apachedata\jslib 09/06/2015 01:04 PM . 09/06/2015 01:04 PM .. 09/06/2015 01:04 PM 1,396 check_all_fields.js 09/06/2015 11:32 AM 3,294 fieldset.css 09/06/2015 01:04 PM 1,515 hide_show_divider.js 09/06/2015 11:32 AM 5,929 styles.css 4 File(s) 12,134 bytes 2 Dir(s) 591,461,138,432 bytes free Here is the tail end of "access.log" 127.0.0.1 - - [06/Sep/2015:13:53:13 -0400] "GET /jslib/fieldset.css HTTP/1.1" 403 220 127.0.0.1 - - [06/Sep/2015:13:53:13 -0400] "GET /jslib/hide_show_divider.js HTTP/1.1" 403 228 127.0.0.1 - - [06/Sep/2015:13:53:13 -0400] "GET /jslib/check_all_fields.js HTTP/1.1" 403 227 127.0.0.1 - - [06/Sep/2015:13:53:13 -0400] "GET /jslib/styles.css HTTP/1.1" 403 218 Any ideas ? What else do I need to do or change to properly access my CCS and JS files ?
[users@httpd] Problem with HTML datalist tag
Hello, my laptop at the office is windows 7 with internet explorer 10. our apache server is version 2.2.3 running on a Linux system. I have a small HTML test file with a datalist tag that works fine when runlocally through the browser. However when I send the file up to the apache server and then attempt to display the web page with the datalist tag it does not display correctly. I just see an input box with the contents of the datalist tag choices displayed beside it. I have checked the apache error log and there was no entry of any klind for my web page. Why does the apache web server somehow manage to mess up my simple little web page which is as follows : !DOCTYPE HTML HTML HEAD TITLEDatalist/TITLE /HEAD BODY H1Datalist/H1 input type=text name=product list=productName/ datalist id=productName option value=PenPen/option option value=StaplerStapler/option option value=PencilPencil/option option value=EraserEraser/option option value=PaperPaper/option /datalist /BODY /HTML