Migrare da Invision Power Board a Discourse

is this offer still available ?
Getting to the point where I might have to pay IPB :sadpanda:

Want to convert from http://mandrivausers.org/

2 Mi Piace

Hey, i will probably need to do a migration from IP Board v3.4.5 to Discourse at my job, any news about the import script? Would love to test it.

I wont promise that it will work for you, but I will try to clean it up and submit a PR in the next few days. If you have a budget, my contact info is in my profile.

3 Mi Piace

I also need to do a migration from a bitrix based forum, so i’ll have to write a custom script anyway and figure out how all of this works, anything to save me some time would be extremely helpful. Thank you.

Here it is. The two sites that I imported with this code were wildly different. I hope that someone finds it useful.

https://github.com/discourse/discourse/pull/5543

11 Mi Piace

Some version of this is in core now, so you probably don’t want to use what’s in the link above.

4 Mi Piace

Puoi indicarmi dove si trova lo script di importazione per la versione 4 di IP.Board?
Vedo solo script di importazione per IP.Board e IP.Board3 nel repository.
Supportate la migrazione da IP.Board4 a Discourse?

Non lo so. La mia ipotesi è che lo script ipboard.rb sia quello da provare; non ho idea per quale versione di ipboard l’abbia scritto. Dovrai solo provare con i tuoi dati per vedere se funziona. Come ho detto (anni) prima, quando ho originariamente scritto lo script ipboard, i due siti che ho provato erano molto, molto diversi.

Se sei interessato al supporto a pagamento, puoi vedere Redirecting…

Grazie per la risposta.
Ho provato con i miei dati, non riesce a completare perchĂŠ si interrompe.
Tenta di trovare la tabella “profile_portal”, che non esiste nella versione 4.
Suppongo che lo script sia stato scritto per ipb3 o versioni precedenti.

Ci penserò per il supporto a pagamento.

Ciao @pfaffman , per favore fammi sapere se puoi supportare. Voglio importare da v2.3.6, ho problemi a collegare gli argomenti a forum_id poichĂŠ questa versione non ne ha uno, puoi per favore farmi sapere quale tabella contiene il valore per collegare tra argomento e forum?

Questo è quello che ho per importare gli argomenti ora, può importare ma tutti gli argomenti vanno in “non categorizzato”.

def import_topics
  puts "\n📌 Importing Topics..."
  total_count = mysql_query("SELECT count(*) count FROM iBB_posts WHERE new_topic = 1;").first['count']

  batches(BATCH_SIZE) do |offset|
    discussions = mysql_query(<<-SQL
      SELECT pid as tid, topic_id, post_title as title, post as raw,
             FROM_UNIXTIME(post_date) as created_at, author_id
      FROM iBB_posts
      WHERE new_topic = 1
      ORDER BY post_date ASC
      LIMIT #{BATCH_SIZE} OFFSET #{offset};
    SQL
    ).to_a

    break if discussions.empty?

    create_posts(discussions, total: total_count, offset: offset) do |discussion|
      {
        id: "topic-#{discussion['tid']}",
        user_id: user_id_from_imported_user_id(discussion['author_id']) || Discourse::SYSTEM_USER_ID,
        title: format_title(discussion['title']),  # Ensure titles are properly formatted
        raw: discussion['raw'],
        created_at: discussion['created_at'],
        post_number: 1
      }
    end
  end
end
def format_title(title)
  return "Untitled Topic" if title.nil? || title.strip.empty?
  CGI.unescapeHTML(title)
end
def import_replies
  puts "\n📌 Importing Replies..."
  total_count = mysql_query("SELECT count(*) FROM iBB_posts WHERE new_topic = 0;").first['count']

  batches(BATCH_SIZE) do |offset|
    comments = mysql_query(<<-SQL
      SELECT pid, topic_id, post as raw, FROM_UNIXTIME(post_date) as created_at, author_id
      FROM iBB_posts
      WHERE new_topic = 0
      ORDER BY post_date ASC
      LIMIT #{BATCH_SIZE} OFFSET #{offset};
    SQL
    ).to_a

    break if comments.empty?

    create_posts(comments, total: total_count, offset: offset) do |comment|
      topic_id = topic_lookup_from_imported_post_id("topic-#{comment['topic_id']}")
      next unless topic_id

      {
        id: "post-#{comment['pid']}",
        topic_id: topic_id,
        user_id: user_id_from_imported_user_id(comment['author_id']) || Discourse::SYSTEM_USER_ID,
        raw: comment['raw'],
        created_at: comment['created_at']
      }
    end
  end
end

Non stai passando una categoria al creatore dell’argomento, quindi dovrai correggere questo aspetto.

Lo farò, ma non trovo alcun forum_id nel database SQL di ipb da usare

Allora è improbabile che tu possa ricevere aiuto gratuito per risolverlo. Penso che ci siano altri due script di importazione IPB; potrebbero offrire qualche indizio. Devi solo cercare nel database e vedere dove lo mettono.

Se hai un budget, puoi consultare Discourse Migration - Literate Computing . Se mi fornisci un budget, posso provare a eguagliarlo.

2 Mi Piace

Apprezzo la risposta, ma stavo cercando specificamente una guida tecnica sulla questione piuttosto che offerte di servizi, grazie ancora per la rapida risposta

Mi dispiace di non poter conoscere la struttura del tuo database senza poterla vedere.

Tutto quello che posso dirti, e quello che ti ho detto, è di guardare nel database per trovare dove si nasconde la categoria. Ci deve essere qualche campo nel record dell’argomento che ti manca. A volte è un collegamento a qualche altra tabella che contiene l’ID della categoria e devi fare un join. Probabilmente ha solo un nome che non ti aspetti.

1 Mi Piace