writeをlogへ