Forum archive 2000-2006

luoy@m... - mysql setup

luoy@m... - mysql setup

by Arnold Pizer -
Number of replies: 0
inactiveTopicmysql setup topic started 6/28/2004; 2:53:56 PM
last post 7/1/2004; 9:08:15 AM
userluoy@m... - mysql setup  blueArrow
6/28/2004; 2:53:56 PM (reads: 2088, responses: 10)
I could not find anywhere talking about mysql setup, like what username and password I need to set up for connection, what DB or table needs to be created.

Specifically, I have installed mysql to /usr/local/mysql, and set up root password, and issued following command

bin/addcourse --db-layout=sql --sql-user=root --sql-pass=secret --sql-db=webwork_admin --sql-wwhost=localhost --users=courses/adminClasslist.lst --professors=admin demo_course ERROR 1075 at line 21: Incorrect table definition; There can only be one auto column and it must be defined as a key DBI connect('ProblemLibrary','webworkRead',...) failed: Access denied for user: 'webworkRead@localhost' to database 'ProblemLibrary' at /opt/webwork2/lib/WeBWorK/DB/Driver/SQL.pm line 39 error instantiating DB schema WeBWorK::DB::Schema::SQL for table problem_library_classify: Can't call method "STYLE" without a package or object reference at /opt/webwork2/lib/WeBWorK/DB/Schema.pm line 81. at /opt/webwork2/lib/WeBWorK/Utils/CourseManagement.pm line 161

Any idea, thanks.

<| Post or View Comments |>


userluoy@m... - Re: mysql setup  blueArrow
6/28/2004; 3:11:45 PM (reads: 2291, responses: 0)
BTW, mysql 4.0.20

<| Post or View Comments |>


userJohn Jones - Re: mysql setup  blueArrow
6/28/2004; 4:03:21 PM (reads: 2308, responses: 0)
What version of webwork is this from? It sounds like the same problem discussed in the recent thread on preview release 4. In any case, the same suggestions made there apply here.

John

<| Post or View Comments |>


userluoy@m... - Re: mysql setup  blueArrow
6/29/2004; 2:47:03 PM (reads: 2255, responses: 0)
I have checked out the CVS version, new problem, apache complains that " [Tue Jun 29 09:38:17 2004] [error] [client 134.53.64.177] File does not exist: /usr/local/apache/htdocs/webwork2/test_course/"

(If I relink /opt/webwork2 back to the PR4, at least I can see test_course, this means that apache itself has no problem).

Notice that path to test_course, which is strange,"/usr/local/apache/htdocs/webwork2/test_course"

Thanks.

<| Post or View Comments |>


userluoy@m... - Re: mysql setup  blueArrow
6/29/2004; 3:31:42 PM (reads: 2263, responses: 0)
It seems that WeBwork.pm does not pick up when it gets to http://servername/webwork2/test-course. Why?
<Location /webwork2>
Options FollowSymLinks
PerlSetVar webwork_root /opt/webwork2
PerlSetVar pg_root /opt/pg
<Perl>
use lib "/opt/webwork2/lib";
use lib "/opt/pg/lib";
</Perl>
SetHandler perl-script
PerlHandler Apache::WeBWorK
</Location>

Any idea?

<| Post or View Comments |>


userJohn Jones - Re: mysql setup  blueArrow
6/29/2004; 4:08:17 PM (reads: 2296, responses: 0)
You shouldn't have to put anything in /usr/local/apache/htdocs. This is in contrast to webwork 1. With webwork 2, part of the apache configuration has it adjust urls internally to point them to the right files.

On the other hand, you need the test_course to be at /opt/webwork2/courses/test_course . If /opt/webwork2 is a link to your copy of webwork2 which you are changing, and test_course has only been created in one of those copies of webwork, then test_course won't be visible in the other copy.

John

<| Post or View Comments |>


userluoy@m... - Re: mysql setup  blueArrow
6/29/2004; 4:36:40 PM (reads: 2282, responses: 0)
I didn't. when accessing http://servername/webwork2/test-course, it complains /usr/local/apache/htdocs/webwork2/test_course, which is not found of course.

I mean /webworks/test_course should be handled by the webwork.pm, the apache should not complain /usr/local/apache/htdocs/webwork2/test_course at all.

<| Post or View Comments |>


userSam Hathaway - Re: mysql setup  blueArrow
6/29/2004; 7:16:43 PM (reads: 2294, responses: 0)
Currently, WW2 "declines" a request for a course that doesn't exist, which causes Apache to try to find it under the DocumentRoot. I believe this has been changed in the very latest CVS to give an explicit error message instead.

<| Post or View Comments |>


userluoy@m... - Re: mysql setup  blueArrow
6/30/2004; 8:07:54 AM (reads: 2281, responses: 0)
This test_course does exist.

<| Post or View Comments |>


userSam Hathaway - Re: mysql setup  blueArrow
6/30/2004; 12:25:08 PM (reads: 2263, responses: 0)
Are you able to access http://servername/webwork2/ ? Is test_course listed there?

<| Post or View Comments |>


userluoy@m... - Re: mysql setup  blueArrow
7/1/2004; 9:08:15 AM (reads: 2295, responses: 0)
Yes. test_course is listed there.

<| Post or View Comments |>