1

テスト サーバーで Informix データベースの 1 つを複製しようとしていますが、社内に Informix の専門知識がなければ、何をする必要があるかを推測することしかできません。私はこのことを自分自身でその場で学んでいますが、Informix を効率的に、または非効率的に操作するために必要な専門知識レベルにはほど遠いものです。とにかく... .dat ファイルと .idx ファイルをライブ サーバーからどこかにコピーすることができました。Linux と最新の Informix Dynamic Server をインストールし、稼働させます。

では、ライブ サーバーの .dat ファイルと idx ファイルをどうすればよいでしょうか。それをどこかにコピーすると、自動的に認識されますか?

または、MS SQLServer から DB をアタッチしてデータベース ファイルを新しいデータベースに登録するような同等の方法はありますか?

私のロープエンドで...

4

4 に答える 4

1

.datファイルと.idxファイルはC-ISAMに関連付けられています。または、dbase.dbs(dbaseはデータベースの名前)というディレクトリに編成されている場合、.datファイルと.idxファイルはInformixStandardEngineに関連付けられています。別名InformixSE。SEはC-ISAMを使用してストレージを管理します。SEは、Informix Dynamic Server(IDS)とはかなり異なります(そして、はるかに単純です)。.datファイルと.idxファイルをIDSに関連付けることは不可能ではありません。それは非常にありそうもないことです。

入手可能な情報から、本番サーバーがSEを実行しているように聞こえます。SEからIDSにデータを取得するには、SE側でDB-Exportを使用し、Linux/IDS側でDB-Importを使用することをお勧めします。確かに、それはそれを行うための最も簡単な方法です。

他の可能な解決策があります-C-ISAMデータブレードはそのようなものの1つです-しかし、それらはより高価であり、おそらく保証されていません。HPL(High-Performance Loader)など、他の可能なローディングソリューションがあります。

Informixの詳細については、すでに参照されているさまざまなWebサイト(http://www.informix.comはIBMのWebサイトのInformixセクションへのリンクです)を使用するか、International Informix User Group(IIUG) Webサイトを使用してください。Informixについて詳しく説明するために、利用可能なメーリングリスト(所属する必要がありますが、メンバーシップは無料です)があります。

于 2008-09-25T00:25:00.063 に答える
1

You've asked a pretty complicated question without realizing it. Informix is architected as a shared everything database engine, meaning all resources available to the instance are available to every database in that instance. This means that more than one database can store data in any given dbspace, .dat or .idx file in your case. Most DBA's know better than to do that but it's something to be aware of. Given this knowledge you now know that the .dat and .idx files do not belong to a database but belong the instance. The dbspaces and files were created to contain your databases data but they technically belong to the instance. It's worth noting that the .dat and .idx files are known to the database by the logical dbspace name.

Armed with this background info and assuming that the production and development servers are running the same OS and that your hardware is relatively the same, not a combination of PARISC, Itanium or x86/x64, I'll throw a couple of options out for you.

  1. Create the dbspaces that you need in the new instance and use onunload and onload to copy the database from production to development.
  2. Use ontape or onbar to backup the entire production instance and restore it over your development instance.

Option 1 requires that you know what the dbspaces are named and how large they are. Use onstat -d on the production instance to find this out. BTW, the numbers listed in onstat -d are in pages, I believe that Linux is a 2K page.

Option 2 simply requires that the paths for the data files are the same on both servers. This means that the ROOTDBS needs to be the same in both instances. That can be found by executing onstat -c | grep ROOTDBS

There's a lot that has been left out but I hope that this gives you the info that you need to move forward with your task.

于 2008-09-22T18:49:46.580 に答える
1

SYSTABLES.DAT SYSTABLES.IDX、SYSCOLUMNS、SYSINDEXES など、関連するすべてのカタログ ファイルがない限り、これらの Informix-SE データ ファイル (.DAT) とそれに関連するインデックス ファイル (.IDX) は役に立ちません。

次に、それらを作成した Informix-SE のバージョンについても考慮する必要があります。インデックス ファイルのノード サイズが 2K または 4K のものもあるからです。

最良の方法は、ソース データベースからすべての .DAT および .IDX ファイルを取得し、さらに正しい標準エンジンを取得して、元の同じハードウェアおよびオペレーティング システムにインストールすることです。

簡単に言うと、ソース マシンで「dbexport」を実行してすべてのデータを ASCII ファイルにアンロードし、「dbschema」を実行してすべてのテーブル スキーマとインデックスを生成します。また、ASCII フラット ファイルにアンロードする前に、すべてのファイルに対して "bcheck" を実行しても問題ありません。

于 2016-05-29T23:27:04.027 に答える
0

Informix固有のアドバイスはありませんが、このような状況では、通常、データベースの移動方法(一般的な管理タスクであり、通常はマニュアルで詳しく説明されています)を調べて、その手順をスキップすることで答えを見つけることができます。古いデータベースを削除します。

また、さまざまなシステムアーキテクチャによって引き起こされる問題にも注意してください。一部のDBは、ビッグエンディアンシステム(Solarisなど)からリトルエンディアンシステム(x86 Linuxなど)に移動すると、見事に失敗します。ここでも、DBの移動に関する手動のセクションでは、必要な追加の手順について説明します。

于 2008-09-22T07:27:20.230 に答える