The date for my migration is set: either next weekend (20th/21th) or the following weekend (27th/28th) I will migrate my SMF board (~850 users, ~65.000 posts, ~2.000 attachments) to ElkArte. Wish me luck! ;)
good luck and keep us updated!
With Open Importer it's easy to convert SMF to ElkArte, I did this conversion (95526 posts, 3450 users) and it went exactly as planned.
But it was only test, can't move because we need gallery on this forum :|
Anyway, good luck :)
Good luck, Jorin! :)
What's about your gallery? I think you are using a gallery there?
Good luck with it! :D
Out of curiosity, is it your forum already UTF8?
Yes it is.
Yep, but the gallery is no problem. It is not used anymore. I only have to change old posts with a link directly to a file inside the gallery.
What gallery are you using with SMF?
Aeva Media 1.4w. Works great. Why?
I think that it may be possible to at least restore "somehow" the images in the posts.
Sounds interesting. So it will automatically change the BBC from [id=123] (I think that's how the images are shown inside a post, but I'm not sure quite yet) to [img]http://pathtopicture.extension[/img]?
If I remember correctly is something like [smg=123], yes.
The idea would an "smg" bbc tag able to interpret the [smg=123] the same way AEVA does, and so return something similar to what you have now (at the moment I can't do a lot of coding, so it may take a few days, but this weekend I may be able to have a look at it).
Yes, it's [smg id=3657]. The ID can be found too in the database in table smf_aeva_files in field id_file. In the fields directory and filename the path to the image and the file name can be found.
So what I need is a script which searches all posts for such a BBC, looks for the id, then searches the table for this id, collects path and file name from this row, and changes the BBC in the post to [img]http://forum.hybrid-piloten.de/path/filename.extension[/img]. That would be perfect.
I was more thinking not to change the posts, but to write a BBCode to convert the [smg id=3657] into an image, it seems easier to me. No?
I will be happy with both. It would be great not to loose these pictures.
Is this possible after the migration? If so I would migrate this week and we could change this code later?
This would be possible at any time, provided that you preserve the aeva tables, in particular the aeva_settings and the aeva_media.
Okay. What else do you need to help me with this? :-[
Time? If you have some spare you can sell me... LOL
Hm... Maybe I can help you with something else in return. But time... No, I have none.
and the avea_files table I think
And the image folder on the webspace. I will keep all.
Let's say: keep anything related to AEVA, it is easier to keep and delete afterwards, rather than swear because something useful was deleted too early. ;)
Sure. And I have to keep the images on the server as long as the board is alive. I know. ;)
I started looking into this. ;D
Here it is a very basic version.
It supports the bare minimum, it doesn't check for permissions for example, so if you rely on them do not use it yet in a public environment. ;)
I am interested in this as well. I have quite a few posts with links to AEVA by the bbcode [smg=###]. My ElkArte database does not have the AEVA tables in it but I have the old database with the tables. Do I need to add them into the ElkArte database. And do I need to install the linked .zip file like an addon through package manager? Or what?
Yes, and you should be sure the tables prefix is the same (so if your AEVA tables are smf_aeva and your Elk tables are elkarte_messages, you have to change the AEVA tables to elkarte_aeva).
Yep.
I have a problem with the import of the SMF messages table into my test database:
SQL-Befehl:
/*!40101 SET CHARACTER_SET_CLIENT=@OLD_CHARACTER_SET_CLIENT */;
MySQL meldet: Dokumentation
#1231 - Variable 'character_set_client' can't be set to the value of 'NULL'
Help is needed and very appreciated! :(
I remember seeing that when I split some huge sql files or something like that.
I think you have two options:
1) open the first file, at the beginning of it you see a header that should look something like this:
-- phpMyAdmin SQL Dump
-- version 3.4.7.1
-- http://www.phpmyadmin.net
--
-- Host: 123.123.123.123
-- Generato il: Lug 28, 2013 alle 00:48
-- Versione del server: 5.0.92
-- Versione PHP: 5.3.8
SET SQL_MODE="NO_AUTO_VALUE_ON_ZERO";
SET time_zone = "+00:00";
/*!40101 SET @OLD_CHARACTER_SET_CLIENT=@@CHARACTER_SET_CLIENT */;
/*!40101 SET @OLD_CHARACTER_SET_RESULTS=@@CHARACTER_SET_RESULTS */;
/*!40101 SET @OLD_COLLATION_CONNECTION=@@COLLATION_CONNECTION */;
/*!40101 SET NAMES utf8 */;
Copy the piece:
/*!40101 SET @OLD_CHARACTER_SET_CLIENT=@@CHARACTER_SET_CLIENT */;
/*!40101 SET @OLD_CHARACTER_SET_RESULTS=@@CHARACTER_SET_RESULTS */;
/*!40101 SET @OLD_COLLATION_CONNECTION=@@COLLATION_CONNECTION */;
/*!40101 SET NAMES utf8 */;
and add it at the beginning of all the other files (assuming you split a big sql file).
The other option is to remove the string:
/*!40101 SET CHARACTER_SET_CLIENT=@OLD_CHARACTER_SET_CLIENT */;
from the end of any sql file, but that may cause some character to become question marks or strange symbols.
Thanks. I did but can't import the first of four files. The error message is:
#1064 - You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near 'SET CHARACTER_SET_CLIENT=@OLD_CHARACTER_SET_CLIENT */' at line 64
Here are the first 64 lines:
-- phpMyAdmin SQL Dump
-- version 3.5.8.1
-- http://www.phpmyadmin.net
--
-- Host: blabla
-- Erstellungszeit: 30. Okt 2014 um 18:31
-- Server Version: 5.5.35-nmm2-log
-- PHP-Version: 5.3.28-nmm1
SET SQL_MODE="NO_AUTO_VALUE_ON_ZERO";
SET time_zone = "+00:00";
/*!40101 SET @OLD_CHARACTER_SET_CLIENT=@@CHARACTER_SET_CLIENT */;
/*!40101 SET @OLD_CHARACTER_SET_RESULTS=@@CHARACTER_SET_RESULTS */;
/*!40101 SET @OLD_COLLATION_CONNECTION=@@COLLATION_CONNECTION */;
/*!40101 SET NAMES utf8 */;
--
-- Datenbank: [icode]bla[/icode]
--
-- --------------------------------------------------------
--
-- Tabellenstruktur für Tabelle [icode]smf_messages[/icode]
--
CREATE TABLE IF NOT EXISTS [icode]smf_messages[/icode] (
[icode]id_msg[/icode] int(10) unsigned NOT NULL AUTO_INCREMENT,
[icode]id_topic[/icode] mediumint(8) unsigned NOT NULL DEFAULT '0',
[icode]id_board[/icode] smallint(5) unsigned NOT NULL DEFAULT '0',
[icode]poster_time[/icode] int(10) unsigned NOT NULL DEFAULT '0',
[icode]id_member[/icode] mediumint(8) unsigned NOT NULL DEFAULT '0',
[icode]id_msg_modified[/icode] int(10) unsigned NOT NULL DEFAULT '0',
[icode]subject[/icode] varchar(255) NOT NULL DEFAULT '',
[icode]poster_name[/icode] varchar(255) NOT NULL DEFAULT '',
[icode]poster_email[/icode] varchar(255) NOT NULL DEFAULT '',
[icode]poster_ip[/icode] varchar(255) NOT NULL DEFAULT '',
[icode]smileys_enabled[/icode] tinyint(4) NOT NULL DEFAULT '1',
[icode]modified_time[/icode] int(10) unsigned NOT NULL DEFAULT '0',
[icode]modified_name[/icode] varchar(255) NOT NULL DEFAULT '',
[icode]body[/icode] text NOT NULL,
[icode]icon[/icode] varchar(16) NOT NULL DEFAULT 'xx',
[icode]approved[/icode] tinyint(3) NOT NULL DEFAULT '1',
PRIMARY KEY ([icode]id_msg[/icode]),
UNIQUE KEY [icode]topic[/icode] ([icode]id_topic[/icode],[icode]id_msg[/icode]),
UNIQUE KEY [icode]id_board[/icode] ([icode]id_board[/icode],[icode]id_msg[/icode]),
UNIQUE KEY [icode]id_member[/icode] ([icode]id_member[/icode],[icode]id_msg[/icode]),
KEY [icode]approved[/icode] ([icode]approved[/icode]),
KEY [icode]ip_index[/icode] ([icode]poster_ip[/icode](15),[icode]id_topic[/icode]),
KEY [icode]participation[/icode] ([icode]id_member[/icode],[icode]id_topic[/icode]),
KEY [icode]show_posts[/icode] ([icode]id_member[/icode],[icode]id_board[/icode]),
KEY [icode]id_topic[/icode] ([icode]id_topic[/icode]),
KEY [icode]id_member_msg[/icode] ([icode]id_member[/icode],[icode]approved[/icode],[icode]id_msg[/icode]),
KEY [icode]current_topic[/icode] ([icode]id_topic[/icode],[icode]id_msg[/icode],[icode]id_member[/icode],[icode]approved[/icode]),
KEY [icode]related_ip[/icode] ([icode]id_member[/icode],[icode]poster_ip[/icode],[icode]id_msg[/icode]),
FULLTEXT KEY [icode]body[/icode] ([icode]body[/icode])
) ENGINE=MyISAM DEFAULT CHARSET=utf8 AUTO_INCREMENT=67497 ;
--
-- Daten für Tabelle [icode]smf_messages[/icode]
--
Line 64 ist an empty line right after:
--
-- Daten für Tabelle [icode]smf_messages[/icode]
--
Wow, I didn't had such problems at the first test migration. Grrrr.
hmm...
Okay, that's odd.
Well, since this is the first file, and since the SET NAMES command is valid only for the current set of queries, just remove the line:
/*!40101 SET CHARACTER_SET_CLIENT=@OLD_CHARACTER_SET_CLIENT */;
and any other similar one from the end of the file.
Completely my mistake. Forgot to change the "," in the last lines to import into ";" in any of my files. It works now... O:-)
Still got problems with the last of my four files. First I get the message:
You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near...
...followed by text from a message and corresponding then to line 25 (which is right at the beginning of the file and an empty line). I then deleted the lines at the end of the file as you said and now I get the error:
#1062 - Duplicate entry '51653' for key 'PRIMARY'
That is because you already have data in the database.
Well, yes, "obviously" (even though I didn't notice): the queries were run and the data uploaded to the database, what failed is just a query at the end that has nothing to do with the data, so you can continue.
You mean just fill the table with data and forget about the rest?
When you see the error, it means that phpmyadmin/mysql has already "processed" the entire file (loading the data in the proper tables), is arrived at the end, has found something that was "not good" and has sent you a warning.
That means the data of that file are already in the database, so you can proceed with the new one. ;)
Hm, okay, the messages seems to be there. But l now have some other problems. It's a shame (for me) I can't get a backup of my SMF to work:
1. The "latest post" in the board index is missing/not shown.
2. List of latest topics isn't working.
3. I can't change the language to german. It is always english no matter how often I change it in admin panel and click on "save".
4. Maintenance gives these error message: "The following errors are fouling up your forum: ??? Would you like to attempt to fix these errors?" lol I clicked on "yes" but the 3 problems are still there.
Everything else seems to be working. Should I still try to migrate or is a fully working SMF first the better way?
You may try with an SMF maintenance recount all statistics, this may help.
What kind of errors are you getting?
In general I think that if you can see the forum it should be all fine.
Yes, it helped. Thanks! :)
I still can't change the language and the list of latest posts shows only one. Fifteen should be, this is set in admin panel.
Okay, I will try to migrate this board to Elk.
Oh-oh... Nearly all messages are incomplete or partially parts from the topic titles are missing! I still have big problems with my test board! Where's the rest of the messages? :o
Better start again with the whole backup thingy. But not today. >:(
How exactly did you do the backup?
Did you then split them somehow?
I made a backup of the messages table and then another for the rest. The messages table is splitted with notepad++. Maybe there's a mistake? Surely I made one...
Do you know a reliable way to split the backup in PHPMyAdmin? Or have any tipps what options should be set in PHPMyAdmin for the backup?
In phpmyadmin you'd have to limit the number of records for each query. I do it from time to time, but it's a bit of a pain.
Another question: how did you notice the messages are truncate? Via phpmyadmin or via SMF?
If the latter, then try checking in phpmyadmin.
Sorry, don't understand. :o I open the SQL file in my editor, scroll a few hundred lines down, look for a break between two messages and cut the following code out. I create a new SQL file, paste it in and copy the header from the first file into the new file, but be sure not to delete or empty the messages table! And so on. So I got four SQL files now which I thought could be importet without problems.
That's not what I wanted to know.
There are two possible reasons why the messages are truncated:
1) if you are looking at the messages from SMF it may be:
1a) a problem of charset during the restoring of the database,
1b) or a problem of charset when SMF retrieves the messages from the database,
2) if you are looking at the messages through phpmyadmin it is a problem of charset during the restoring of the database (that is the same as 1a).
So, the question is: where do you see the messages truncated: in SMF or in phpmyadmin?
If it is via SMF I'd ask you to check in phpmyadmin to determine without doubt which one of the two possibilities is, if you are looking at them already through phpmyadmin I know it is a restore problem.
Depending on where exactly the problem is, there are different solutions to the problem. ;)
Oh, okay, sorry. Now I get it. I see them in SMF. I will check the database later if there are the complete posts.
No problem! ;D
I missed that! Thanks, I will try it.
I'm just curious Jorin, but will you keep the wordpress site? or do you intent to use a portal and abbandon wp?
When there's a gallery for ElkArte available :P I will "abbandon" Wordpress. I want to have all in one place. But I don't like portals, I think I will simply create categories and boards for the migrated wp articles. But there must be a solution for the pictures first.
So, I migrated. First of all, I had much more topics, posts and users in ElkArte than in SMF before. Then I searched for errors in maintenance, he found a lot. I repaired them, updated the statistics via maintenance (count new) and now I have less topics and posts than in SMF. :o
Installed it after migration, didn't work. I see the BBCode, but no picture. I copied the mgal_data directory into Elkarte root directory, then I exported the two database tables (aeva_media and aeva_settings), changed the prefix, imported them again (so the tables are elkarte_aeva_media and elkarte_aeva_settings, then I changed the path in the settings table to the new forum, but no pictures are shown. I tried to deinstall and install your addon again, but no difference too. There are no pictures, just the BBC. :-\
Is that a test or a "live" thing?
Usually do a test before is better.
Can you give me an example of the bbcodes?
It's my production site. So not a test, no. But it's in maintenance mode now.
The code looks like this: [smg id=3661]
About the number of topics I'm not sure what to say, the only question that comes to my mind is: did you do a maintenance in SMF before the migration? Maybe the count was already messed a bit.
But maybe others have some idea. ;)
About the gallery I'll have a look tomorrow morning... if I wake up, otherwise in the afternoon. :-\
Since SMF is still running I can try the maintenance there too and compare SMF and ElkArte then. I will give it a try tomorrow.
You are my hero! :D Yes, that did it. I counted new in my SMF board and now they are completely the same! :)
Good! One is gone! :D
So, everything seems to be okay with my ElkArte. Just the Aeva Media pictures are missing (wip) and one global moderator don't get e-mail notifications when she gets new messages. Board and topic notifications are working, her profile setting seem to be okay, the mails are not in her spam directory. Strange.
We are still testing, but found no big bugs till now. Just small things. You all did a really great job, thanks a lot!
I wanted to disallow members to choose the default ElkArte theme. They should only choose between board standard (named Skyblue) and a second theme (named Greensleaves). But ElkArte seems to need the default theme chooseable, right? Why?
IIRC that's inherited from SMF.. Force a specific theme or make all themes choosable...
Any chance for a change?
uuups, there's an option ..
Admin - Configuration - Themes Management - Manage and Install
Allow members to select their own themes. -> should be checked.
Themes the user is permitted to select: -> deselect the default.
I tried this, but ElkArte said the default theme needs to be set too. I can't deselect it.
I don't know why, but now I can deselect the default theme. Only difference: I use the Firefox browser at my girlfriend's computer right now. I tried it with Chrome before and got the problem.
To check I guess.
No errors in the log?
Can you check via phpmyadmin in the table aeva_settings if the value data_dir_path is correct?
Oh, I have a lot of errors: 99 with wrong login informations of members (can I do something about that? I think it's because I had a modification with SMF that changed user name to e-mail adress at login and maybe a lot of my users use their browsers to save the login informations and now the browser leads to these errors) and 110 with undefined indexes :o but it seems none about the aeva gallery.
I can't check the database right now because of missing internet connection at my home at the moment.
IIRC the email is fine for the login.
Well, if you see anything that may reseble a bug feel free to report it (if you want you can take a dump of the errors table and send it to me by PM so I can filter them out).
Darn... :P
Sorry I overlooked something: you see the whole bbcode!
This is very important, because it means the code is not used at all.
You should check two things:
1) that the files
/sources/subs/Mgal.subs.php and
/sources/controllers/Mgal.controller.php are present,
2) in
admin > maintenance > forum maintenance > integration hook, check if the hook "
integrate_bbc_codes" (first column) has in the second column "
Function: mgal_bbcode" and the icon
on the right side.
The files weren't there. Now they are, I copied them from your zip onto the server. Point 2 is good.
But it seems it's still not working. Can it be the addon isn't installed correctly? I know see ($1) in my posts.
At least is a step in the right direction! :D
And fix that should be easy: go to admin > forum > posts and topics > bulletin board code and tick "smg" to enable it. ;D
Not totally fixed:
http://piloten-forum.de/index.php/topic,4194.0.html
http://piloten-forum.de/sources/controllers/Mgal.controller.php <= 404 not found
The controller file is still missing. ;)
Check!
Check!
Check!
But still no images. :(
Have a look at the error log, I guess there are some database errors.
You're right:
Table 'abc.elkarte_aeva_files' doesn't exist
Okay, do your homework, Jorin! I will look for it and import the table when I'm at home.
lol
No problem, I thought it was a broken query... O:-)
Anyway, it's better if you have around all the aeva tables. Not all of them are mandatory, but better have one more than one less. ;D
Got an error when I import all the aeva tables:
--
-- Daten für Tabelle [icode]elkarte_aeva_media[/icode]
--
INSERT INTO [icode]elkarte_aeva_media[/icode] ([icode]id_media[/icode], [icode]id_member[/icode], [icode]member_name[/icode], [icode]last_edited[/icode], [icode]last_edited_by[/icode], [icode]last_edited_name[/icode], [icode]id_file[/icode], [icode]id_thumb[/icode], [icode]id_preview[/icode], [icode]type[/icode], [icode]album_id[/icode], [icode]rating[/icode], [icode]voters[/icode], [icode]weighted[/icode], [icode]title[/icode], [icode]description[/icode], [icode]approved[/icode], [icode]time_added[/icode], [icode]views[/icode], [icode]downloads[/icode], [icode]last_viewed[/icode], [icode]keywords[/icode], [icode]embed_url[/icode], [icode]id_last_comment[/icode], [icode]log_last_access_time[/icode], [icode]num_comments[/icode]) VALUES
(2, 1, 'Jorin', 0, 0, '', 8, 9, 10, 'image', 2, 0, 0, 0, 'Kofferraum', 'Ein Blick in das Gepäckfach.', 1, 1268408257, 253, 20, 0, '', '', 0, 1269459209, 0),
(3, 1, 'Jorin', 0, 0, '', 11, 12, 13, 'image', 2, 0, 0, 0, 'Heckansicht', 'Mist, Kamera schief gehalten.', 1, 1268408289, 197, 40, 0, '', '', 0, 1269459213, 0),
(4, 1, 'Jorin', 0, 0, '', 14, 15, 16, 'image', 2, 0, 0, 0, 'Innen', 'Hier sitzt der Chef!', 1, 1268408313, 214, 9, 0, '', '', 0, 1269459216, 0),
(5, 1, 'Jorin', 0, 0, '', 17, 18, 19, 'image', 2, 0, 0, 0, 'Innen', 'Innenansicht.', 1, 1268[...]
#1062 - Duplicate entry '2' for key 'PRIMARY'
Probably because the table is already there?
According to the error, the missing one is "elkarte_aeva_files", not "aeva_media". ;)
I tried this. ;) Of course you are right, but it seems he did import all the missing tables. The pictures are finally there:
http://forum-alternative-antriebe.de/index.php/topic,4194.0.html
Yippie! Thanks a lot! Especially for your patience with me! :D
YAY!!
We did it! :D
Guys I want to do exactly the same thing, but I can't get anywhere. Can you help me?
Sorry, the database connection information used in the given installation of the forum does not reach the SMF 2.0 installation. This either means that the installation does not exist, or that the MySQL account used does not have access privileges.
The error given by MySQL was: SELECT command denied for user 'databasename'@'localhost' for table 'smf_members'''.
error_line 351
error_file /xxx/xxx/domains/xxx.xxx/private_html/importer/OpenImporter/Importer.php
What could be the problem? I am using the latest importer version.
Most of the open Importer information is here https://www.elkarte.net/community/index.php?board=28.0
Are you sure the credentials you supplied can access the SMF database? You can verify they are right by looking in you Settings.php file for db_user and db_passs
Thank you! Yes, I checked. That's what I'm using now:
SMF 2.0.17 | SMF © 2016, Simple Machines
SimplePortal 2.3.5 © 2008-2012, SimplePortal
and I want to convert it to 1.1.8 Elkarte. I am using the latest OpenImporter.
In the meantime I realized that for some reason it wants to extract the 'smf_members' table from another database. I don't know the reason. (The hosting in question contains several databases)
Or maybe the importer should be put in the smf folder?
However, I have one more important question. Can 2 SMF databases be merged into 1 database? I have been working in smf for 10 years and I would not like to have to rewrite/copy posts...
That, as you may guess, is not an easy answer and would require a lot of custom code to "get close". I think it could be possibly done .... but just thinking, never have done it
You would first have to merge the members tables, looking for duplicates and updating member id's (topics, messages) in the db you are trying to merge into the new primary. That is the easy part.
Then you would have to work through the topics, tables to keep things in date/time order, so as you "insert" in a topic from another db, based on a newer topic first message time. So a bunch of arrays that hold topic data, which you build a new one based on timestamps and as you do that you keep track of old<->new ids for each db topic table.
Then you would rebuild the message table in date order, and using your old<->new topic ids, update as you add them to a new db.
That is just the topic/messages ... you still have PM, likes, moderation, bans, what addons may have added ... and for permissions you would have to set basic permissions to added members I guess and fix as you go. Anyway, not easy, probably achievable with some loss of history etc etc. and a lot of time !
TBH I have not run or used OI in several years, so I'll take some time tomorrow to see what is involved / refresh my brain and post back what I find.
I faced the same problem, and decided to convert the forums messages to read-only and "archive" the old groups on the server with access to the archive via the new forum. For further "security" the archive is in an username/password protected subfolder.. (I could have let EA handle the access privileges but I wanted a little extra at the file-system level). But regardless, it was much easier to archive than to merge, at least for my purposes. Worth considering if the functional (or lack thereof, actually) trade-off is acceptable
I have good news. I have achieved the desired skills. I am happy. First of all I managed to get the 2 smf databases together, I've been trying for years. There was a bug that the avatars were not imported from smf, but that's not important. I think I'll go with elkarte, because I got more out of it in 8 hours than vbulletin.
Thanks for the replies!
You're a better man than I, Gunga Din!
...TikiWiki (that was six months of screwing around before I found a "fatal bug" in a rarely used but essential feature for me that nobody could resolve in a race against the clock, when the clock ran out..), PHPBBS, I looked at bunches.. EA bested 'em all for desired features, flexibility and support (and I ain't just suckin up, that's just the fact of the matter..)