2012年5月30日水曜日

Windbgで .NETFrameworkのバージョンが違うよと怒られたら

Windbgでダンプファイル解析時にSos.dllを読み込んでコマンドを実行してもエラーになってしまう。。 ダンプファイルを取得したPCの.NETFrameworkのバージョンと 解析時に使っているPCの.NETFrameworkのバージョンが異なっていると起こるみたい。

以下エラー内容


0:000> !threads
Failed to load data access DLL, 0x80004005
Verify that 1) you have a recent build of the debugger (6.2.14 or newer)
            2) the file mscordacwks.dll that matches your version of mscorwks.dll is 
                in the version directory
            3) or, if you are debugging a dump file, verify that the file 
                mscordacwks___.dll is on your symbol path.
            4) you are debugging on the same architecture as the dump file.
                For example, an IA64 dump file must be debugged on an IA64
                machine.

You can also run the debugger command .cordll to control the debugger's
load of mscordacwks.dll.  .cordll -ve -u -l will do a verbose reload.
If that succeeds, the SOS command should work on retry.

If you are debugging a minidump, you need to make sure that your executable
path is pointing to mscorwks.dll as well.


【対処】
以下のシンボルファイルのパスに以下を追加して再起動すれば実行できました。

symsrv*symsrv.dll*c:\localcache*http://msdl.microsoft.com/download/symbols

2012年5月14日月曜日

editor typeの設定


treegridのドキュメントを見ても載ってないんですよ。
で、似たようなgridのドキュメントが参考になりそうです。
多分同じです。
http://www.jeasyui.com/documentation/datagrid.php

editorのtypeは以下の通り。
text,textarea,checkbox,numberbox,validatebox,datebox,combobox,combotree.

treegridのドキュメントはいろいろ足りてないなー。


easyui treegrid サンプル


一通りの設定を確認できるのがGoogleCodeにあった。
http://code.google.com/p/jquery-easyui/source/browse/trunk/demo/treegrid.html?r=498



2012年5月7日月曜日

Redmine1.4.0をWindowsにインストールしてみる。


データベースはSQLiteを使う。

■Rubyのインストーラ
http://rubyinstaller.org/downloads/

今回使用したバージョン
Ruby 1.9.3-p125

exeを実行しインストールする。
OKの連続で問題ない。

環境変数のPATHに以下を追加。
C:\Ruby193\bin;

インストール後にコマンドプロンプトを起動してインストール確認
>ruby -v
ruby 1.9.3p125 (2012-02-16) [i386-mingw32]
>gem -v
1.8.16

■Redmineのインストール
http://rubyforge.org/frs/?group_id=1850

今回使用したバージョン
redmine-1.4.0.zip


解凍してC:\redmine-1.4.0に移動する。


■データベース設定
C:\redmine-1.4.0\config\database.yml.exampleを
C:\redmine-1.4.0\config\database.ymlに名前を変更

database.ymlのデフォルトのmysqlの設定をコメントアウトしてSQLiteに書き換える
------------
#production:
#  adapter: mysql
#  database: redmine
#  host: localhost
#  username: root
#  password:
#  encoding: utf8
production:
  adapter: sqlite3
  database: db/redmine.db
------------


■Bundlerのインストール
>gem install bundler


■Bundleで必要なGemのインストール
>bundle install --without development test rmagick


■秘密鍵を生成
>rake generate_session_store

■データベース上にテーブルを作成
>rake db:migrate RAILS_ENV=production

■データベースに初期データを設定
>rake redmine:load_default_data RAILS_ENV=production

■実行する。
ruby c:\redmine-1.4.0\script\server -e production

ブラウザより以下のアドレスでアクセス出来るようになっているはず!
http://localhost:3000/


おまけ。
■公開設定
C:\redmine-1.4.0\config\setting.ymlを変更

動作するPCのIPアドレスに変更すると他のPCから見えるようになる。
---
host_name:
#  default: localhost:3000
  default: 192.168.1.1:3000
---



Redmine バージョンアップ 1.1.2→1.3.2


windowsで使っていたRedmineをバージョンアップした時の手順を残しておきます。

■Redmineのリリース済みパッケージをダウンロード
http://rubyforge.org/frs/?group_id=1850
今回は1.3.2にバージョンアップするのでredmine-1.3.2.zipを取得

■zipを展開
C:\redmine-1.3.2に展開しました。

ちなみに既存の1.1.2はC:\redmine-1.1.2にあります。

■インストールしているプラグインを確認
インストールしているプラグインの一覧を控えておく。
・Redmineに管理者でログイン
・管理→プラグイン
ここに一覧で出ているプラグイン名を記録しておくこと。
後でプラグインフォルダをコピーする時に使う。

■1.3.2に必要なライブラリをgemでインストール。
gem install rack -v=1.1.1
gem install rdoc -v=2.4.2

■データの移行
・データベース設定
redmine-1.1.2/config/database.yml

・データベース
データベースのデータはsqliteを使っていたので以下のフォルダにあるファイルをコピーした。
redmine-1.1.2/db/*

・添付ファイル
redmine-1.1.2/files/*

・ログ
redmine-1.1.2/log/production.log

・プラグイン(自分がインストールしたプラグインのみを移動すること)
redmine-1.1.2/vendor/plugins/*

■秘密鍵の生成
rake generate_session_store

■データベースの更新
rake db:migrate RAILS_ENV="production"
rake db:migrate:upgrade_plugin_migrations RAILS_ENV=production
rake db:migrate_plugins RAILS_ENV=production

■キャッシュのクリーンナップ
rake tmp:cache:clear
rake tmp:sessions:clear

■実行する。
今まで通りの方法で実行する。

無事に動きましたとさ。


ラベル