[14:41:05] I have an older wiki .sql dump which is titled like this: MySQL dump 10.14 Distrib 5.5.64-MariaDB, for Linux (x86_64) [14:41:10] I've been told to install MW 1.31 in order to upgrade the schema, however 1.31. either skips over the upgrade or does it very fast during the LocalSettings create process. [14:41:45] At the end it crashes on database spectacularly. [14:42:22] Am I on the right track? Or should I use MW 1.30? [14:42:47] (BTW my ISP is very crashy, so please pardon any interruptions) [14:44:45] In the database dump, everything is in the 'text' field. [14:45:02] you should use a supported MediaWiki version. 1.35 at least [14:45:23] "Dump completed on 2020-02-25 11:10:44" [14:46:31] the idea of "upgrade the schema" is to use a more recent version of MediaWiki. If you use the exact same version of MediaWiki of the dump, there's no need to run update.php [14:48:12] ... so I was told to revert to an older MW so it would upgrade the schema. [14:49:22] that makes no sense [14:51:41] Would 1.35 upgrade the database if I reinstall LocalSettings? [15:06:48] {I don't know, why don't you try it?} [15:06:53] Ok. [15:07:35] Indeed 1.39 dies ask to upgrade my database, but the upgrade crashes. [15:07:56] I'd post a screenshot, but imgur is down. [15:12:16] https://pasteboard.co/IzRtXuEwFc8w.jpg [15:12:58] A table doesn't exist. No sh*t, why doesn't it create it? [15:13:54] Probably because you're trying to upgrade from a too old version of MW [15:14:06] Update.php won't create missing tables [15:14:07] It only applies updates [15:14:19] It will create them in some circumstances [15:14:29] We only support upgrading from a certain number of versions ago now [15:14:29] But you were told to do it in steps I believe [15:14:33] So I also tried 1.31, but it skips upgrade and crashes at the end. [15:15:14] I mean, categorylinks has existed since MW 1.3 [15:15:20] So either your backup... [15:16:08] Idk what to do at this point. [15:16:38] [16:15:14] I mean, categorylinks has existed since MW 1.3 [15:16:44] [16:15:20] So either your backup... [15:16:58] "Dump completed on 2020-02-25 11:10:44" [15:17:19] Everything is in the text field. [15:22:36] According to this it would have been on version 1.34. https://en.wikipedia.org/wiki/MediaWiki_version_history [15:22:42] 1.35 is a LTS so maybe it would recover me? [15:23:02] Man, I wanted to be so careful with this. But now it's a complete tarbaby. [15:24:00] if the backup didn't include all the tables, that's a big problem [15:24:33] If you had 1.34 then yeah, 1.31 wouldn't have worked [15:26:46] I suspect the problem is not your connection but your irc client. Have you tried connecting through webchat? [15:28:14] Nah it's def my VPN. Extensively troubleshot and they don't know what's wrong. I think it's either time setting or MTU. [15:28:34] Direct connexion is normal but I can't use that. [15:29:31] Some tables can be recreated from scratch, and running rebuildAll.php would regenerate the info. However, having missing tables is concerning, and the backup may be corrupt or incomplete [15:30:13] categorylinks is one table that can be recreated, for example [15:30:13] Agh. [15:30:37] I'm trying 1.35 now, which still seems to be supported. [15:35:59] when i try to use visual edtior it goes to read mode no error how do i fix this [15:38:43] GAH! 1.35 database upgrade crashes. [15:39:29] https://pasteboard.co/cwDiQt72e2s8.jpg [15:40:56] what was the last thing you changed on it @rooter0_ [15:41:15] A bunch of api's. It's really got me this time. [15:41:20] try reverting the last action you did than run it [15:41:40] ... except this time I didn't drop/reload the database to start fresh. [15:42:35] Cocopuff2018: I don't understand? I'm trying to restore an old sql dump. [15:43:07] whatever you put last may be causing the update.php to fail [15:45:47] Cocopuff2018: you're not being very helpful at the moment, to be frank [15:46:39] @tavvi what i do is take the last action i did and revert it than update php again usually it works after [15:48:25] rooter0_: could you paste the full output from the 1.35 updater? your screenshot seems to only include the last bit [15:53:27] Agh, 1.35 just skipped the db upgrade... [15:57:21] https://pasteboard.co/SelRTPp8uMRI.jpg [15:57:24] "Did you forget to run your application's database schema updater after upgrading?" [15:57:29] Huh? [15:57:57] It skipped the upgrader. [15:58:52] the upgrader is trying to install a new database instead of upgrading [15:59:08] O [15:59:42] can you run the updater from the command line? [15:59:44] But I specify the databse name as part of the install. It hould find it. [16:00:12] How do I run the updater? Does it operate on the dump or on the database? [16:00:23] Yes, your screenshot shows it's a database update (upgrading existing installation), but at the same time it's trying to source(tables.sql) [16:00:54] Weird. [16:01:12] you should conect through ssh to the server, and then run "php maintenance/update.php" on the mediawiki installation path [16:01:46] Ok. I'll drop/rebuild from the dump again to start fresh. [16:01:51] this requires an existing LocalSettings.php file, though, with the database credentials [16:02:01] O [16:02:28] I have one created before. [16:07:41] I'm borne to lose. This is v1.35.10: https://paste.ec/paste/wVHvzks8#MXXzlJKm2x8MZV5s0utrvKCoPhS2mboj5XVbY7nqwxx [16:08:22] Oh sh*t I'll just comment out Math. [16:11:39] comment out all extensions [16:19:40] If success I have to dump this update as fast as if I have to go to the bathroom... [16:20:58] Anyone know whether this is good? https://paste.ec/paste/r2t0z7Ef#OguetiTDqhYJVlg219ktATiLMqsZXNafFJdtysfy8Hy [16:22:20] >Error 1054: Unknown column 'iw_api' in 'field list' (localhost) [16:23:07] a little odd when it's literally just created the table [16:23:39] https://github.com/wikimedia/mediawiki/blob/REL1_35/maintenance/tables.sql#L1435 [16:25:37] Is there anything I can do? [16:25:58] Run it again? [16:26:21] well, if you run it again, it isn't going to fix the table [16:26:42] I'm somewhat confused how it can create a table, and it not being as it should be based on the definition... [16:27:26] "Creating interwiki table ...done" --> maybe the "done" doesn't mean it has created the table, but the table exists already [16:27:59] I can check. [16:28:38] Also, update.php doesn't read tables.sql. If it creates any table, it does so by running an sql "patch" [16:28:57] https://github.com/wikimedia/mediawiki/blob/REL1_35/includes/installer/DatabaseUpdater.php#L809-L821 [16:29:06] it would say it exists if it exists... or it should [16:31:03] if ( $this->db->tableExists( $name, __METHOD__ ) ) { [16:31:03] $this->output( "...$name table already exists.\n" ); [16:31:03] } [16:31:24] Then it created it by using this patch https://github.com/wikimedia/mediawiki/blob/REL1_35/maintenance/archives/patch-interwiki.sql [16:31:30] which doesn't include iw_api [16:31:42] ah ffs, yeah [16:31:46] incremental updating... [16:32:19] iw_api was added in MediaWiki 1.17 [16:33:47] Yes for tables I only have interwiki and text. [16:33:53] For columns in interwiki I have iw_prefix, iw_url, and iw_local. [16:34:43] what [16:34:58] (after the update) [16:35:02] you *only* have interwiki and text? [16:35:07] Yes [16:35:11] lmao [16:35:20] rip [16:35:35] You don't have most of the data the wiki needs... [16:35:49] This is MW 1.35. [16:36:16] Should I use 1.39 upgrade? [16:36:18] no matter what version is. Text only contains text, you don't have page names, histories, users... nothing [16:36:37] Gah [16:36:56] So continuing trying to "upgrade" is pointless unless you have a complete backup [16:37:28] at least of the tables that contain data... As said before, some like categorylinks are computed, so it's not the end of the world if they are empty [16:37:35] (they can be populated again) [16:37:46] best you can do is export the contents of the text table into plain text files, and figure out the corresponding title of each table... and even then, you may have several revisions of each page and there's no way to tell who or when were they created [16:38:39] Ok. Luckily archive.org has a backups. I guess I have to recreate by hand. [16:39:17] I thought it was strange that everything's in text. [16:39:25] You can import text files into individual articles. But you need to know the title of each page... [16:39:42] I do, from archive. [16:39:55] best of luck! [16:40:22] There will be lots of handcrafting tho. It's my punishment for being alive. [16:40:41] Thanks for your help chaps. [16:42:33] I do have an .xml file. Is that any good? [16:44:34] I do have an .xml file. Is that any good? [16:45:04] Potentially, yes [16:45:10] If it's a proper export [16:46:08] TLDR... Install a new wiki, visit Special:Import (or import.php maintenance script) [16:46:23] Cool, thx. [16:46:33] Look at the header [19:14:27] is it possible at all to fix visual edtior which keeps going to read mode i tried f12