MAMBO installation HOW-TO (Notice: Table 'smf.mos_modules' doesn't exist)

Started by marcnyc, November 04, 2004, 07:57:04 PM

Previous topic - Next topic

marcnyc

Hello.
This started out as a request for help, but half way through I got inspired by something I have read somewhere (while searching for people with similar issues) and I was able to solve the issue myself so I decided to post it as a how-to in case somebody faces a similar problem and can't find the solution on the two forums.

Admins can decide if it's worth keeping or they can trash it if they please. No prob.

Once you have successfully installed and integrated Mambo with SMF and once you have followed all the instructions on Orstio's bridge and installed com_smf first, then com_smf_registration and mod_smf_login last you can proceed to install the four universal modules for the smf/mos integration.

At this point you might get this error:

Notice: Table 'Your_SMF_database.mos_modules' doesn't exist in /Library/WebServer/Documents/content/includes/database.php on line 184

Warning: Invalid argument supplied for foreach() in /Library/WebServer/Documents/content/includes/frontend.php on line 58


Which is possibly triggered by code like this:
if ( mosCountModules( 'left' ) )
mosLoadModules('left');


If you get this error it means you have installed Mambo in a different databse (as I did initially).
Turns out the two databases have to be the same database.
The database can be called whatever you please (if you have already installed SMF then it will be the name of the SMF database of course) and instead of the 35 smf_ tables you will have 70 tables of which 35 for SMF with smf_ prefix and 35 from MOS with mos_ prefixes.

I found this http://www.simplemachines.org/community/index.php?topic=18678.0 which is somewhat similar to my situation (I have less problems but a similar error output) and Orstio mentions that the Mambo and SMF tables have to be in the same database.

Good luck to all.
I am loving it so far.

kahuna

Hello,
thanks for your info. Just how exactly do I add the smf_tables to the mambo_tables? I'm not very familiar with mysql, so I wonder how to do it (with phpMyAdmin?) Currently I have two different databases. After putting them together are there just one? Sorry, for its possibly a rather stupid question ...

Thanks!
Volker :)

marcnyc

If you are installing Mambo for the first time in order to integrate it with SMF simply provide Mambo with the SMF database details during the Mambo installation. In other words instead of creating a new database (like the Mambo installation readme file suggests) don't create a new database and when Mambo asks you for the database details type in the details of the database you use for SMF and just leave the mos_ prefix for the tables that mambo will create inside it so you can distinguish the tables of Mambo from the ones of SMF.
If on the other hand you have already installed Mambo it's too late. The only solution is to burn your computer and jump out the window while screaming 'mambooooooooo!'... just kidding...
If you have already installed Mambo and now have two databases, either start from the top and do like I said or use the EXPORT tab section of phpMyAdmin to export all the tables of the mambo database and then import it inside the SMF database (using the SQL tab of phpMyAdmin). Then go to your Mambo administration and change the database details so it connects to the new database (the one where the SMF tables are). After that you can delete the old mambo-only database.

kahuna

OK, thank you! I think I get the point. It's not possible to start from the scratch with mambo, but with smf. So what is the best location for a smf installation? In a subdirectory or outside of mambo? Currently it's outside of mambo, but I can change if necessary. Just if it's a possible problem for exporting the mambo-tables to the smf-tables. Or doesn't this matter?

best wishes!
Volker :)

marcnyc

As far as I know you have to install SMF first and MAMBO after SMF so if both are already installed do NOT reinstall SMF, just do what I said.

kahuna

Well, it's not possible to install SMF first, for mambo was before - and will. Currently I use phpbb as a forum but want to switch to smf (however seems somehow complicated).  OK, I'll keep on trying. ThanX.
Volker

marcnyc

Well if that is the case here is what you have to do:
1. backup your phpBB SQL database.
2. Download this file: http://www.simplemachines.org/download.php?d=phpbb2_to_smf;t=php
(tested with phpBB 2.0.7) to convert your forum to SMF.
3. Once it is successfully converted to SMF export the entire database of phpBB/SMF
4. go inside the MAMBO database and import the tables you have previously exported
5. go inside SMF and change the name of the databse (as well as the username and password) to the same name that is used by the MAMBO database
6. you can now safely remove/delete the phpBB/SMF database (you have two backups anyway, a phpBB backup from before all this started and an exported backup of the newly converted forum)
7. install the MOS/SMF bridge following the instructions carefully
That's all. It's easy really.

Orstio

QuoteAs far as I know you have to install SMF first and MAMBO after SMF so if both are already installed do NOT reinstall SMF, just do what I said.

It makes absolutely no difference what order you install Mambo and SMF.  As long as they are both installed before you start installing the bridge.

QuoteOK, thank you! I think I get the point. It's not possible to start from the scratch with mambo, but with smf. So what is the best location for a smf installation? In a subdirectory or outside of mambo? Currently it's outside of mambo, but I can change if necessary. Just if it's a possible problem for exporting the mambo-tables to the smf-tables. Or doesn't this matter?

You can put the SMF files wherever you wish.  All the Mambo and SMF tables must go in the same database, for now.  You can make sure of that when you install SMF, by telling the installation script
the name of the Mambo database.  The tables all have different prefixes to identify them differently, so there is no fear of over-writing Mambo tables (SMF tables should all start with "smf_", Mambo tables start with "mos_").



kahuna

OK - I've followed your (marcnyc) instructions so far (thanks!!!, now the databases are put together), however I just now get a blank white page (gzip = off) after a first ssi-error (your are not allowed to point directly to ssi) which is fixed by writing the entire path in the smf.php (/home/.../public_html/smf). Hmm ... I used the 2.03beta from mamboforge. Is there still anything more to be aware off? Orstio?

Thanks and best wishes
Volker

Orstio

Quotehowever I just now get a blank white page (gzip = off) after a first ssi-error (your are not allowed to point directly to ssi) which is fixed by writing the entire path in the smf.php (/home/.../public_html/smf). Hmm ... I used the 2.03beta from mamboforge. Is there still anything more to be aware off? Orstio?

You do not need to edit smf.php. 

You need to edit config.smf.php.

Do you have the path to SSI.php in config.smf.php, or do you have the URL?  Remember, it CANNOT start with http://.

kahuna

Ahhhhh! :) Always tried to fix it in the smf.php with getting no results. Didn't recognize that there has to be a relative path (starting with /home/.../smf) and no absolute path (http://.../smf) in the config.smf.php, because in the "readme.txt" there is both offered. What about adding a short note regarding this point to the readme?
Okay, it seems to work! Thanks to both of you!!! Great to have smf and mambo together.

best wishes!
Volker

Orstio

QuoteDidn't recognize that there has to be a relative path (starting with /home/.../smf) and no absolute path (http://.../smf) in the config.smf.php, because in the "readme.txt" there is both offered.

I think you are confused about the definition of a path.

A relative path describes the path from one script to another.  An absolute path begins at the server root.  Neither begins with http://.

Anything beginning in http:// is a URL, not a path.

kahuna

Hmm - you're right!!! I mixed path and URL. Grumpf! However, while reading lots of threads regarding smf_bridge I suppose that many others do the same.  So what about clarifying this point in the "readme"? That path in the config.smf.php is NOT a URL? Even it may be a "beginnermistake". Just a suggestion. :-)

Orstio


Advertisement: