On Nov 22, 2003, at 15:57, Dan Carlson wrote:
Thanks very much for those instructions, Brion! I've now gotten the program up and running properly, but I've found a new problem -- the default admin user hasn't been created, and so I can't log in to change some of the internal settings. How do I create the admin user?
I assume you mean a wiki user account; you'll need to manually change the user_rights field through the db:
UPDATE user SET user_rights='sysop' WHERE user_name='My admin account';
I tried the "users.sql" script, but I'm not familiar enough with SQL queries yet to know what all those other various parameters do -- or more specifically, the server addresses. Since I assume that the users.sql file is what I need, what do I need to do to it?
That sets up MySQL user accounts, so the regular wiki scripts can run without the ability to alter the table structure, while the admin scripts do, and the sysop sql query feature can only be used for read-only access and not to read private data from the user tables (email, password hash, watchlist).
User accounts in MySQL are sort of scary and I'm not sure I understand it myself. :) It's perfectly possible to run the whole wiki under an existing all-powerful MySQL user, but could be more damaging if something goes wrong or a hole is exploited. In particular be careful about the SQL user account ($wgDBsqluser/$wgDBsqlpassword), since any wiki user logged in with admin access can issue arbitrary SQL commands executed as the SQL user.
-- brion vibber (brion @ pobox.com)