2020/10,江端さんの技術メモ

木材から円形(円盤)を切り出すことが必要となり、色々試しています。

このような、電動ドライバーに装着できる、木材用の円切りサークルカッターを使っていました。

しかし、これで作業すると、直径20cmの円を切り出すのに、(慣れてきても)10分以上はかかるので、非常に効率が悪く、恐しく疲労します。

そこで、今回、BOSCH(ボッシュ)の電動ノコギリを使って木板を円形に切ることのできる、BOSCHのジグソー円曲平行ガイドを購入しました(別の会社の電動ノコギリの場合、その会社が提供しているものを購入する方が安全です)

先程、自宅に届いたので、さっそく、自分のメモとしてジグソー円曲平行ガイドを、袋から取り出すところから、切り出すまでの全行程を撮影しました。

 

映像の中では、キレイな円形の切出しに失敗していますが、これは中心線をズラさないようにすれば、必ず成功しますので御安心下さい。

サークルカッターと比較して、もの凄くラクチンに円盤を切り出せました。

電動ノコギリとジグソー円曲平行ガイドを接合した状態の写真↓

接合部分の拡大写真↓

以上

未分類

このコンテンツはパスワードで保護されています。閲覧するには以下にパスワードを入力してください。

2020/10,江端さんの技術メモ

スマホから位置情報を取得するところまできたが、https(wss)対応にしないと位置情報が取り出せないようです(かなりしつこく聞いていましたが、すっかり忘れていました)。

で、今のGolangのサーバプログラムをhttps対応にすべく、色々試したのですが、なんかこれで動いているようなので、要点だけ記載します。

Step.1 

まず、

C:\Users\ebata\WssSample\goClient>go run goClient.go conn.go hub.go tls: first record does not look like a TLS handshake がなんともならない件

の、mkcertを使って生成した鍵(“algo.key"と"algo.crt")をディレクトリに放り込む

Step.2

serverXX.goの、サーバ作成部を以下のように変更する

/*
		log.Fatal(http.ListenAndServe(*addr, nil)) // localhost:8080で起動をセット
	*/

	var httpErr error
	if _, err := os.Stat("./algo.crt"); err == nil {
		fmt.Println("file ", "algo.crt found switching to https")
		if httpErr = http.ListenAndServeTLS(*addr, "algo.crt", "algo.key", nil); httpErr != nil {
			log.Fatal("The process exited with https error: ", httpErr.Error())
		}
	} else {
		httpErr = http.ListenAndServe(*addr, nil)
		if httpErr != nil {
			log.Fatal("The process exited with http error: ", httpErr.Error())
		}
	}

Step.3

htmlファイルの、"http://"を、片っ端から"https://"に書き換える。

さくっと動いて気持ち悪いのですけど、まあ動くのであれば、なんでも良いです。

 

2020/10,江端さんの技術メモ

スマホから使えるようにした(今は、ランダムウォークだけ)。

/*
// server22.go ペアはclient9.go

// Copyright 2015 The Gorilla WebSocket Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
// license that can be found in the LICENSE file.

// +build ignore

// 使い方
// go run server13.go      (適当なシェルから)
// http://localhost:8080  (ブラウザ起動)
// http://localhost:8080/smartphone (スマホ起動)
*/

package main

import (
	"flag"
	"fmt"
	"html/template"
	"log"
	"net/http"
	"sync"

	"github.com/gorilla/websocket"
)

// GetLoc GetLoc
type GetLoc struct {
	ID  int     `json:"id"`
	Lat float64 `json:"lat"`
	Lng float64 `json:"lng"`
	//Address string  `json:"address"`
}

//var addr = flag.String("addr", "localhost:8080", "http service address")
var addr = flag.String("addr", "0.0.0.0:8080", "http service address") // テスト

var upgrader = websocket.Upgrader{} // use default options

var chan2_1 = make(chan GetLoc)

var maxid = 0

var mutex sync.Mutex

func echo2(w http.ResponseWriter, r *http.Request) {
	c, err := upgrader.Upgrade(w, r, nil) // cはサーバのコネクション
	if err != nil {
		log.Print("upgrade:", err)
		return
	}
	defer c.Close()

	//mutex := new(sync.Mutex)

	for {
		//mt, message, err := c.ReadMessage() // クライアントからのメッセージの受信(mtはクライアント識別子)
		//_, _, err := c.ReadMessage() // クライアントからのメッセージの受信(mtはクライアント識別子)

		//mutex.Lock()  // ここに置くとデッドロックしてしまう

		gl := new(GetLoc)

		err := c.ReadJSON(&gl) // クライアントからのメッセージの受信

		mutex.Lock()

		// 原因不明の対処処理
		if gl.ID == 0 && gl.Lat < 0.01 && gl.Lng < 0.01 {
			mutex.Unlock()
			break
		} else if gl.ID < -1 { // 受理できないメッセージとして返信する
			//条件分岐 (変なIDが付与されているメッセージは潰す)
			//if (gl.ID > maxid) || (gl.ID < -1) { // 受理できないメッセージとして返信する

			gl.ID = -1
			gl.Lat = -999
			gl.Lng = -999
			err2 := c.WriteJSON(gl)
			if err2 != nil {
				log.Println("write1:", err2)
				mutex.Unlock()
				break
			}
		} else { // それ以外は転送する
			log.Printf("echo2 after c.WriteJSON(gl) ID:%d", gl.ID)
			log.Printf("echo2 after c.WriteJSON(gl) Lat:%f", gl.Lat)
			log.Printf("echo2 after c.WriteJSON(gl) Lng:%f", gl.Lng)

			if err != nil {
				log.Println("read:", err)
				mutex.Unlock()
				break
			}
			fmt.Printf("echo2 before chan2_1 <- *gl\n")
			chan2_1 <- *gl
			fmt.Printf("echo2 after chan2_1 <- *gl\n")

			//で、ここで受けとる
			//gl2 := new(GetLoc)
			fmt.Printf("echo2 before gl2 := <-chan2_1\n")
			gl2 := <-chan2_1
			maxid = gl2.ID // ID最大値の更新
			log.Printf("echo2 after gl2 := <-chan2_1 ID:%d", gl2.ID)
			log.Printf("echo2 after gl2 := <-chan2_1 Lat:%f", gl2.Lat)
			log.Printf("echo2 after gl2 := <-chan2_1 Lng:%f", gl2.Lng)

			fmt.Printf("echo2 before err2 := c.WriteJSON(gl2)\n")
			err2 := c.WriteJSON(gl2)
			fmt.Printf("echo2 after err2 := c.WriteJSON(gl2)\n")
			if err2 != nil {
				log.Println("write2:", err2)
				mutex.Unlock()
				break
			}
			fmt.Printf("end of echo2\n")

		}

		mutex.Unlock()
	}
}

func echo(w http.ResponseWriter, r *http.Request) {

	c, err := upgrader.Upgrade(w, r, nil) // cはサーバのコネクション
	if err != nil {
		log.Print("upgrade:", err)
		return
	}
	defer c.Close()

	/*	ここでロックして待つ */

	for {

		fmt.Printf("echo before gl := <-chan2_1\n")
		gl := <-chan2_1
		fmt.Printf("echo after gl := <-chan2_1\n")

		fmt.Printf("echo before err = c.WriteJSON(gl) gl2.id = %d\n", gl.ID)
		fmt.Printf("echo before err = c.WriteJSON(gl) gl2.lat = %f\n", gl.Lat)
		fmt.Printf("echo before err = c.WriteJSON(gl) gl2.lng= %f\n", gl.Lng)
		err = c.WriteJSON(gl)
		if err != nil {
			log.Println("WriteJSON1:", err)
		}
		fmt.Printf("echo after err = c.WriteJSON(gl)\n")

		fmt.Printf("echo before err = c.RreadJSON(gl)\n")
		gl2 := new(GetLoc)
		err2 := c.ReadJSON(&gl2)
		fmt.Printf("echo after err = c.ReadJSON(&gl2) gl2.id = %d\n", gl2.ID)
		fmt.Printf("echo after err = c.ReadJSON(&gl2) gl2.lat = %f\n", gl2.Lat)
		fmt.Printf("echo after err = c.ReadJSON(&gl2) gl2.lng= %f\n", gl2.Lng)
		if err2 != nil {
			log.Println("ReadJSON:", err2)
		}
		// ここからチャネルで返す
		fmt.Printf("echo before chan2_1 <- *gl2 gl2.id = %d\n", gl2.ID)
		fmt.Printf("echo before chan2_1 <- *gl2 gl2.lat = %f\n", gl2.Lat)
		fmt.Printf("echo before chan2_1 <- *gl2 gl2.lng = %f\n", gl2.Lng)
		chan2_1 <- *gl2
		fmt.Printf("echo after chan2_1 <- *gl2\n")
		fmt.Printf("end of echo\n")
	}

}

func home(w http.ResponseWriter, r *http.Request) {
	homeTemplate.Execute(w, "ws://"+r.Host+"/echo")
}

func smartphone(w http.ResponseWriter, r *http.Request) {
	smartphoneTemplate.Execute(w, "ws://"+r.Host+"/echo2")
}

func main() {
	flag.Parse()
	log.SetFlags(0)

	http.HandleFunc("/echo2", echo2)           // echo関数を登録 (サーバとして必要)
	http.HandleFunc("/echo", echo)             // echo関数を登録 (サーバとして必要)
	http.HandleFunc("/", home)                 // home関数を登録
	http.HandleFunc("/smartphone", smartphone) // smartphone関数を登録
	log.Fatal(http.ListenAndServe(*addr, nil)) // localhost:8080で起動をセット
}

var smartphoneTemplate = template.Must(template.New("").Parse(`
<!DOCTYPE html>
<head>
<meta charset="utf-8">
<script> 

function obj(id, lat, lng){
	this.id = id;
	this.lat = lat;
	this.lng = lng;
}

function random(min, max){
	return  Math.random()*(max-min) + min;
}

// var personal_id;

var lat = 35.654543;
var lng = 139.795534;  

window.addEventListener("load", function(evt) {
    var output = document.getElementById("output");
    var input = document.getElementById("input");
    var ws;
    var print = function(message) {
        var d = document.createElement("div");
        d.textContent = message;
        output.appendChild(d);
	};

	var personal_id = 0;

	
	///// 起動時のボタン
	// disabled属性を削除
	document.getElementById("open").removeAttribute("disabled");
	document.getElementById("open").style.color = "black";

	// disabled属性を設定 (closeボタンを非活性化)
	document.getElementById("close").setAttribute("disabled", true);
	document.getElementById("close").style.color = "White";	

	// disabled属性を設定 (sendボタンを非活性化)
	document.getElementById("send").setAttribute("disabled", true);
	document.getElementById("send").style.color = "White";	


		
	document.getElementById("open").onclick = function(evt) {
		console.log("document.getElementById open");

		// disabled属性を設定 (openボタンを非活性化)
		document.getElementById("open").setAttribute("disabled", true);
		document.getElementById("open").style.color = "White";		

		// disabled属性を削除
		document.getElementById("send").removeAttribute("disabled");
		document.getElementById("send").style.color = "black";	

		// disabled属性を削除
		document.getElementById("close").removeAttribute("disabled");
		document.getElementById("close").style.color = "black";	

		////////// 削除2
		// ws = new WebSocket("{{.}}");
		////////// 削除2終り


		////////// 削除1
		//var send_obj = new obj(0, 35.654543,139.795534);  // 最初は"0"でエントリ

		//console.log("open:send_obj");	
		//console.log(send_obj.id);	
		//console.log(send_obj.lat);
		//console.log(send_obj.lng);		

		//var json_obj = JSON.stringify(send_obj);
		//ws.send(json_obj);
		/////////// 削除1終り


        if (ws) {
            return false;
        }
		
		
		////////// 追加2
		ws = new WebSocket("{{.}}");
		////////// 追加2終り

		
        ws.onopen = function(evt) {
			print("OPEN");
		
			//ws = new WebSocket("{{.}}");
			
			////////// 追加1			
			var send_obj = new obj(0, 35.654543,139.795534);  // 最初は"0"でエントリ

			console.log("open:send_obj");	
			console.log(send_obj.id);	
			console.log(send_obj.lat);
			console.log(send_obj.lng);		

			var json_obj = JSON.stringify(send_obj);
			ws.send(json_obj);
			/////////// 追加1終り

		}
		
        ws.onclose = function(evt) {

			print("CLOSE");
            ws = null;
        }

		ws.onmessage = function(evt) {  // 受信したメッセージはここに飛んでくる
			print("RESPONSE: " + evt.data);  // jsonメッセージの内容を表示
			// データをJSON形式に変更
			var obj = JSON.parse(evt.data);

			personal_id = obj.id; // IDの取得(何回も取る必要はないが)
			console.log("personal_id");			
			console.log(personal_id);

			
			if ((Math.abs(obj.lat) > 90.0) || (Math.abs(obj.lng) > 180.0)){ // 異常な座標が入った場合は、マーカーを消去する
				console.log("before ws.close()");
				ws.close();
				console.log("after ws.close()");
			}
		}
		
        ws.onerror = function(evt) {
            print("ERROR: " + evt.data);
        }
        return false;
    };
	
	document.getElementById("send").onclick = function(evt) {

		console.log("document.getElementById send");

		// disabled属性を設定 (openボタンを非活性化)
		document.getElementById("open").setAttribute("disabled", true);
		document.getElementById("open").style.color = "White";	
	
		// disabled属性を削除
		document.getElementById("send").removeAttribute("disabled");
		document.getElementById("send").style.color = "black";	

		// disabled属性を削除
		document.getElementById("close").removeAttribute("disabled");
		document.getElementById("close").style.color = "black";	
	
		if (!ws) {
			console.log("return false send");
			return false;			
		}

		lat += random(0.5, -0.5) * 0.00001 * 10 * 5;
		lng += random(0.5, -0.5) * 0.00002 * 10 * 5

		
		//var send_obj = new obj(personal_id, 35.654543,139.795534);  // idでエントリ
		var send_obj = new obj(personal_id, lat, lng);  // idでエントリ

		console.log("send:send_obj");	
		console.log(send_obj.id);	
		console.log(send_obj.lat);
		console.log(send_obj.lng);		

		var json_obj = JSON.stringify(send_obj);
		ws.send(json_obj);		

		/*
        print("SEND: " + input.value);
        ws.send(input.value);
		return false;
		*/

		return false;	
    };

	document.getElementById("close").onclick = function(evt) {
		console.log(" document.getElementById close");

		// disabled属性を削除
		document.getElementById("open").removeAttribute("disabled");
		document.getElementById("open").style.color = "black";

		// disabled属性を設定 (closeボタンを非活性化)
		document.getElementById("close").setAttribute("disabled", true);
		document.getElementById("close").style.color = "White";	

		// disabled属性を設定 (sendボタンを非活性化)
		document.getElementById("send").setAttribute("disabled", true);
		document.getElementById("send").style.color = "White";			


        if (!ws) {
            return false;
		}
	
		var send_obj = new obj(personal_id, 999.9, 999.9);  // 最初は"0"でエントリ

		console.log("close:send_obj");
		console.log(send_obj.id);		
		console.log(send_obj.lat);
		console.log(send_obj.lng);		

		var json_obj = JSON.stringify(send_obj);
		ws.send(json_obj);

        //ws.close();  // これはws.onmessageの方で実施
        return false;
    };
});
</script>
</head>
<body>
<table>
<tr><td valign="top" width="50%">
<p>Click "Open" to create a connection to the server, 
"Send" to send a message to the server and "Close" to close the connection. 
You can change the message and send multiple times.
<p>
<form>
<button id="open">Open</button>
<!-- <p><input id="input" type="text" value="Hello world!"> -->
<button id="send">Send</button>
<button id="close">Close</button>
</form>
</td><td valign="top" width="50%">
<div id="output"></div>
</td></tr></table>
</body>
</html>
`))

var homeTemplate = template.Must(template.New("").Parse(`
<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="utf-8" />
    <title>PruneMobile</title>

	<link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/leaflet/1.0.0-beta.2.rc.2/leaflet.css"/>
	<script src="https://cdnjs.cloudflare.com/ajax/libs/leaflet/1.0.0-beta.2.rc.2/leaflet.js"></script>

	<script src="http://kobore.net/PruneCluster.js"></script>           <!-- これ、いずれローカルホストから取れるように換える -->
	<link rel="stylesheet" href="http://kobore.net/examples.css"/>      <!-- これも、いずれローカルホストから取れるように換える -->

	<!-- goのテンプレートのローカルって、どこになるんだろう? -->

</head>
<body>
<div id="map"></div>

<script>

	ws = new WebSocket("{{.}}"); // websocketの確立

	/*
	var print = function(message) {
		var d = document.createElement("div");
		d.textContent = message;
		output.appendChild(d);
	};
	*/

	// 引数にはミリ秒を指定。(例:5秒の場合は5000)
	function sleep(a){
  		var dt1 = new Date().getTime();
  		var dt2 = new Date().getTime();
  		while (dt2 < dt1 + a){
			dt2 = new Date().getTime();
		}
  		return;
	}

    var map = L.map("map", {
        attributionControl: false,
        zoomControl: false
    }).setView(new L.LatLng(35.654543, 139.795534), 18);
    // }).setView(new L.LatLng(35.598563, 139.475528), 18); 広袴

    L.tileLayer('http://{s}.tile.osm.org/{z}/{x}/{y}.png', {
        detectRetina: true,
        maxNativeZoom: 18
    }).addTo(map);

    var leafletView = new PruneClusterForLeaflet(1,1);  // (120,20)がデフォルト

	ws.onopen = function (event) {
	}

	var markers = [];

	//var helicopterIcon = L.icon({ iconUrl: 'http://sintef-9012.github.io/PruneCluster/examples/helicopter.png', iconSize: [48, 48] });
    //var airplaneIcon = L.icon({ iconUrl: 'http://sintef-9012.github.io/PruneCluster/examples/airplane.png', iconSize: [48, 48] });

	// 受信すると、勝手にここに飛んでくる
	ws.onmessage = function (event) {
		// データをJSON形式に変更
		var obj = JSON.parse(event.data);

		console.log("233");	
		console.log(obj.id);
		console.log(obj.lat);						
		console.log(obj.lng);	

		if (obj.id == 0){  // idが未登録の場合
			console.log("obj.id == 0")
			// データをマーカーとして登録
			var marker = new PruneCluster.Marker(obj.lat, obj.lng);

			// 参考資料  http://embed.plnkr.co/WmtpkEqSDJFuFeuiYP54/
			//var marker = new PruneCluster.Marker(obj.lat, obj.lng, {
			//	//popup: "Bell 206 " + i,
			//	icon: helicopterIcon
			//});


			console.log(marker.hashCode);		
			markers.push(marker);
	
			leafletView.RegisterMarker(marker);
	
			console.log(markers);
			console.log(markers.length)

			obj.id = marker.hashCode;
			//ws.send(marker.hashCode); // テキスト送信
			var json_obj = JSON.stringify(obj);
			ws.send(json_obj);			
		} else if ((Math.abs(obj.lat) > 90.0) || (Math.abs(obj.lng) > 180.0)){ // 異常な座標が入った場合は、マーカーを消去する
			console.log("Math.abs(obj.lat) > 180.0)")
			for (let i = 0; i < markers.length; ++i) {
				if (obj.id == markers[i].hashCode){
					console.log(i)
					console.log(obj.id)										
					console.log("obj.id == markers[i].hashCode")

					//leafletView.RemoveMarkers(markers[obj.id]);  // これでは消えてくれません
					// 1つのマーカーを消すのに、面倒でも以下の2行が必要
					var deleteList = markers.splice(i, 1);					
					leafletView.RemoveMarkers(deleteList);

					// 以下失敗例リスト
					//leafletView.RemoveMarkers(markers[i].hashCode);  //これはダメ
					//leafletView.RemoveMarkers(markers[obj.id],'item');
					//leafletView.ProcessView(); // 試しに入れてみる
					//leafletView.RemoveMarkers(markers[i-1]);
					//leafletView.RemoveMarkers(markers);					
					break;
				}
			}
			obj.lat = 91.0;
			obj.lng = 181.0;
			var json_obj = JSON.stringify(obj);
			ws.send(json_obj);				
		} else {
			// 位置情報更新
			console.log("else")
			for (let i = 0; i < markers.length; ++i) {
				if (obj.id == markers[i].hashCode){
					var ll = markers[i].position;
					ll.lat = obj.lat;
					ll.lng = obj.lng;
					break;
				}
			}
			var json_obj = JSON.stringify(obj);
			ws.send(json_obj);	
		}
	}

	// 位置情報の更新
    window.setInterval(function () {
        leafletView.ProcessView();  // 変更が行われたときに呼び出されれなければならない
	}, 1000);

	// サーバを止めると、ここに飛んでくる
	ws.onclose = function(event) {
		//print("CLOSE");
		ws = null;
	}


    map.addLayer(leafletView);
</script>



</body>
</html>
`))

2020/10,江端さんの忘備録

viというのは、Windowsを除く、ほぼ全てのOSに標準実装されている、テキストエディタです。

"vi" is a text editor that comes standard in almost all operating systems, except Windows.

ですので、システムの構築や運用や保守に際しても、viさえ使えれば、最低限のことができます。

Therefore, as long as you can use vi, you can do the least building, operating and maintaining systems.

しかし、viは、分かりにくく、使いにくいことでも、有名です。

However, vi is also notoriously difficult to understand and use.

もちろん、使い込めば、こんなにも便利なツールはないというのも事実で、今なお根強いユーザがいます。

Of course, it's also true that once you use it, there is no tool more useful than this, and it still has power users.

# ちなみに私も、使えるviの操作は、全部で4つです。

# By the way, I also have a total of 4 vi operations that I can use.

-----

1年程前、ラズパイ上で作ったアプリケーションを、社内の事業部に技術移管する作業を行っていた時のことです。

About a year ago, I was in the process of transferring the technology of an application I had created on Raspberry pi to an internal business unit.

そこで集ったメンバは、20代、30代、40代のエンジニアと、その部署の部長を含めた5人でした。

There were five members gathered there, including engineers in their 20s, 30s, and 40s, and the head of the department.

私は、事業部が持ち込んできたラズパイに、アプリケーションを移管する作業と、そのレクチャーを行っていました。

I was working on transferring the application to a Raspberry pi, which was brought in by the division, and giving a lecture on it.

また、ネットワーク環境などに整合性を合わせる為に、構築情報を書き換える必要がありました。

I also had to rewrite the build information to make it more consistent with the network environment and other factors.

-----

私のレクチャーの話をもっとも理解して、私の作業手順のミスを指摘したのは、その「部長さん」だけでした。

It is the "manager" of the department, who understood my lecture deeply, and pointed out the errors in my operating procedures, was

私が、作業中に、

When I was working on it, and just muttering to myself

江端:「ああ、くそ! emacsが入っていなかったか。viは苦手なんだよな」

Ebata: "Oh, shit! Didn't have "emacs" on it. "vi" isn't good for me"

と呟いていたたところ、その部長さんが、

the general manager said

『私が、viで書き換えます』

"I'll rewrite it by "vi".

と申し出られて、ビックリしました。

I was surprised when he offered to do so

部長さんのスキルはさておき、

Aside from skills of the general manager.

―― 20代、30代、40代のエンジニアが、雁首そろえて、沈黙し続けていた

"All engineers in their twenties, thirties, and forties kept silent"

に、驚きました。

was that. I thought,

『こりゃ、UNIXコマンドすら触ったことがない、という感じだな』

"It's like they've never even touched a UNIX command before"

と思いました。

まあ、システムの利用者であれば、「UNIX? 何それ?」と言っても良いと思います。

Well, if you're a user of the system, I think it's safe to say "UNIX? What's that?"

が、システムを構築し、サービスを提供する側のエンジニアが「果たして、それで良いのか?」とは思います。

But as an engineer who builds systems and provides services, I have to ask myself, "Is that really good enough?

私も判断がつきかねています ―― 単なる「じじいのボヤキ」かもしれません。

I'm not sure I can judge it either -- maybe it's just "old man's blabbermouth".

それでも、はっきりと言えることは「ラズパイは、UNIX(Linux)コマンド使えないと、1mmも動かせない」です。

Nevertheless, what I can say clearly is "If you can't use UNIX (Linux) commands, you can't run Raspberry pi".

-----

ちなみに、私の勤務する会社の社是は『技術で社会に貢献する』です。

Incidentally, my companay motto is "Contribute to society through technology".

この一点のみで、会社と私は繋っているといっても、過言ではありません。

It would not be an exaggeration to say that this is the only link between the company and me.

2020/10,江端さんの忘備録

以前、マグカップの代替として、計量カップを購入する話をしました。

I've talked before about buying a measuring cup as a mug.

この計量カップ、絶好調です。

This measuring cup is really great.

例えば、カフェオレを作る場合、計量カップに、インスタントコーヒーを投入した後、100ccの牛乳を入れ、300ccの水を加え、電子レンジに放り込むだけで、

For example, to make a cafe au lait, simply pour the instant coffee into a measuring cup, add 100cc of milk, 300cc of water, and toss it into the microwave.

―― いつでも、一定品質のカフェオレが飲める

"constant quality cafe au lait at all times."

ということは、とても素晴しいことです。

So that's wonderful.

-----

嫁さん:「それが『素晴しい』と思える感性が理解できない」

Wife: "I don't understand the sensitivity of thinking that's 'wonderful'"

江端:「家族全員分、購入しようかと思っているくらいだが・・・」

Ebata: "I'm even thinking of buying one for the whole family..."

嫁さん:「絶対やめてね」

Wife: "Absolutely not"

長女:「そんなものより、お洒落な食器を購入してよ」

Senior daughter: "Don't worry about that, buy me some fancy dishes"

江端:「いいよ。私も食器は好きだ」

Ebata: "Okay. I like the dishes too"

私は観光に行くと、その地方の特産の陶器を、自分用のお土産として購入しています。

Whenever I go sightseeing, I buy local pottery for myself as a souvenir.

-----

江端:「しかし、陶器の内側に、目盛が付いているものが、見あたらなくてな」

Ebata: "But I can't find anything with a scale on the inside of the pottery"

嫁さん:「なんで、そんなもの・・・」

Wife: "Why is that...?"

江端:「いや、これを使えば、『どれくらいのシチューを皿に投入したか』、そして『現在、どれくらいの速度でシチューを食べているか』が、一目瞭然だろう?」

Ebata: "Well, it will tell me at a glance 'how much stew I've thrown into your plate' and 'how fast I're currently eating the stew', won't it?"

嫁さん:「・・・」

Wife: "...

長女:「パパは、そういうことが『嬉しい』んだ」

Senior daughter: "Daddy, that's what makes you 'happy'"

江端:「嬉しい」

Ebata:"It makes me happy"

長女:「そうか・・・。パパが『嬉しい』なら、私も『嬉しい』よ」

Senior daughter: "Well... If Daddy's 'happy', then I'm 'happy' too"

2020/10,江端さんの忘備録

緊急案件発生につき、今、次女に、(超速習で)C言語とGo言語とJavaScriptを教えています。

I'm currently teaching (super-fast) C, Go language and JavaScript to my junior daughter due to an urgent project that has arisen.

もちろん、プログラム初学者であれば、"Python"あたりが常道であることは、よく理解しています。

Of course, you know well that "Python" is the way to go for beginners in programming.

初学者に、"C言語"を履修させるなんぞ、狂気の沙汰であることも、よく理解しています。

I am well aware of the insanity of making a beginner take a course in "C language".

-----

これは、次女からの懇願されて行っていることです。

This is being done at the request of my junior daughter.

しかし、所定の期日までに履修を完了させる為には、私は「私の母国語」しか教えることができないのです。

However, in order to complete the course by the prescribed deadline, I can only teach "my native language".

-----

故に ―― これは「虐待」ではありません。

Therefore -- this is not "abuse",

「教育」です。

but "education"

通報しないで下さい。

Please don't call the police.

2020/10,江端さんの技術メモ

のページをそのまま(ではない)実行

その他の参考メモ

「ブロックチェーン・プログラミング」を読む (bitcoinツールの導入)

Bitcoin Coreを触りながらBitcoinについて理解する - その1(構築~アドレス生成まで)

Bitcoin Bitcoin Core RPC command practice

Dockerをはじめからていねいに?インストールとcentos起動・停止?

C:\Users\ebata\bitcoin>docker-compose build
daemon_two uses an image, skipping
daemon_three uses an image, skipping
Building daemon_one

Traceback (most recent call last):
  File "compose\cli\main.py", line 67, in main
  File "compose\cli\main.py", line 126, in perform_command
  File "compose\cli\main.py", line 302, in build
  File "compose\project.py", line 468, in build
  File "compose\project.py", line 450, in build_service
  File "compose\service.py", line 1147, in build
compose.service.BuildError: (<Service: daemon_one>, {'message': 'Cannot locate specified Dockerfile: Dockerfile'})

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
  File "docker-compose", line 3, in <module>
  File "compose\cli\main.py", line 78, in main
TypeError: can only concatenate str (not "dict") to str
[2852] Failed to execute script docker-compose

C:\Users\ebata\bitcoin>dir
 ドライブ C のボリューム ラベルがありません。
 ボリューム シリアル番号は C8D7-CF4A です

 C:\Users\ebata\bitcoin のディレクトリ

2020/10/17  15:28    <DIR>          .
2020/10/17  15:28    <DIR>          ..
2020/10/17  15:28               581 docker-compose.yml
2020/10/17  15:26               436 Dockerfile.txt
               2 個のファイル               1,017 バイト
               2 個のディレクトリ  359,417,462,784 バイトの空き領域

version: "2"
services:
  daemon_one:
    build: "./"
    image: "bitcoind:regtest"
    container_name: 'bitcoin_1'
    hostname: 'bitcoin_1'
    environment:
      - LINE=50
      - COLUMNS=120
    tty: true
    stdin_open: true
    links:
      - daemon_two
      - daemon_three
  daemon_two:
    image: "bitcoind:regtest"
    container_name: 'bitcoin_2'
    hostname: 'bitcoin_2'
    tty: true
    stdin_open: true
  daemon_three:
    image: "bitcoind:regtest"
    container_name: 'bitcoin_3'
    hostname: 'bitcoin_3'
    tty: true
    stdin_open: true
FROM ubuntu:16.04
RUN apt-get update -y && apt-get upgrade -y
RUN apt-get install -y python-software-properties
RUN apt-get install -y software-properties-common
RUN add-apt-repository ppa:luke-jr/bitcoincore
RUN apt-get update -y
RUN apt-get install -y bitcoind
RUN mkdir ~/.bitcoin
RUN echo "rpcuser=test\nrpcpassword=test\nregtest=1" > ~/.bitcoin/bitcoin.conf
RUN apt-get install iputils-ping net-tools vim -y
CMD ["/bin/bash"]


C:\Users\ebata\bitcoin>mv Dockerfile.txt Dockerfile 
C:\Users\ebata\bitcoin>ls Dockerfile docker-compose.yml 
C:\Users\ebata\bitcoin>docker-compose build daemon_two uses an image, skipping daemon_three uses an image, skipping Building daemon_one 
Step 1/11 : FROM ubuntu:16.04 16.04: Pulling from library/ubuntu 4f53fa4d2cf0: Pull complete 6af7c939e38e: Pull complete 903d0ffd64f6: Pull complete 04feeed388b7: Pull complete Digest: sha256:185fec2d6dbe9165f35e4a1136b4cf09363b328d4f850695393ca191aa1475fd Status: Downloaded newer image for ubuntu:16.04 ---> 096efd74bb89 
Step 2/11 : RUN apt-get update -y && apt-get upgrade -y ---> Running in 3d458b9249b5 
Get:1 http://archive.ubuntu.com/ubuntu xenial InRelease [247 kB] 
Get:2 http://security.ubuntu.com/ubuntu xenial-security InRelease [109 kB] 
Get:3 http://security.ubuntu.com/ubuntu xenial-security/main amd64 Packages [1835 kB] 
Get:4 http://archive.ubuntu.com/ubuntu xenial-updates InRelease [109 kB] 
Get:5 http://archive.ubuntu.com/ubuntu xenial-backports InRelease [107 kB] 
Get:6 http://archive.ubuntu.com/ubuntu xenial/main amd64 Packages [1558 kB] 
Get:7 http://security.ubuntu.com/ubuntu xenial-security/restricted amd64 Packages [15.9 kB] 
Get:8 http://archive.ubuntu.com/ubuntu xenial/restricted amd64 Packages [14.1 kB] 
Get:9 http://security.ubuntu.com/ubuntu xenial-security/universe amd64 Packages [951 kB] 
Get:10 http://archive.ubuntu.com/ubuntu xenial/universe amd64 Packages [9827 kB] 
Get:11 http://security.ubuntu.com/ubuntu xenial-security/multiverse amd64 Packages [9249 B] 
Get:12 http://archive.ubuntu.com/ubuntu xenial/multiverse amd64 Packages [176 kB] 
Get:13 http://archive.ubuntu.com/ubuntu xenial-updates/main amd64 Packages [2350 kB] 
Get:14 http://archive.ubuntu.com/ubuntu xenial-updates/restricted amd64 Packages [16.4 kB] 
Get:15 http://archive.ubuntu.com/ubuntu xenial-updates/universe amd64 Packages [1496 kB] 
Get:16 http://archive.ubuntu.com/ubuntu xenial-updates/multiverse amd64 Packages [26.7 kB] 
Get:17 http://archive.ubuntu.com/ubuntu xenial-backports/main amd64 Packages [10.9 kB] 
Get:18 http://archive.ubuntu.com/ubuntu xenial-backports/universe amd64 Packages [12.6 kB] 
Fetched 18.9 MB in 1min 1s (305 kB/s) Reading package lists... 
Reading package lists... 
Building dependency tree... 
Reading state information... 
Calculating upgrade... 
The following packages will be upgraded: libpam-modules libpam-modules-bin libpam-runtime libpam0g 4 upgraded, 0 newly installed, 0 to remove and 0 not upgraded. Need to get 375 kB of archives. After this operation, 0 B of additional disk space will be used. Get:1 http://archive.ubuntu.com/ubuntu xenial-updates/main amd64 libpam0g amd64 1.1.8-3.2ubuntu2.3 [55.7 kB] Get:2 http://archive.ubuntu.com/ubuntu xenial-updates/main amd64 libpam-modules-bin amd64 1.1.8-3.2ubuntu2.3 [36.9 kB] Get:3 http://archive.ubuntu.com/ubuntu xenial-updates/main amd64 libpam-modules amd64 1.1.8-3.2ubuntu2.3 [244 kB] Get:4 http://archive.ubuntu.com/ubuntu xenial-updates/main amd64 libpam-runtime all 1.1.8-3.2ubuntu2.3 [37.8 kB] debconf: delaying package configuration, since apt-utils is not installed Fetched 375 kB in 2s (160 kB/s) (Reading database ... 4780 files and directories currently installed.) Preparing to unpack .../libpam0g_1.1.8-3.2ubuntu2.3_amd64.deb ... Unpacking libpam0g:amd64 (1.1.8-3.2ubuntu2.3) over (1.1.8-3.2ubuntu2.1) ... Processing triggers for libc-bin (2.23-0ubuntu11.2) ... Setting up libpam0g:amd64 (1.1.8-3.2ubuntu2.3) ... debconf: unable to initialize frontend: Dialog debconf: (TERM is not set, so the dialog frontend is not usable.) debconf: falling back to frontend: Readline debconf: unable to initialize frontend: Readline debconf: (Can't locate Term/ReadLine.pm in @INC (you may need to install the Term::ReadLine module) (@INC contains: /etc/perl /usr/local/lib/x86_64-linux-gnu/perl/5.22.1 /usr/local/share/perl/5.22.1 /usr/lib/x86_64-linux-gnu/perl5/5.22 /usr/share/perl5 /usr/lib/x86_64-linux-gnu/perl/5.22 /usr/share/perl/5.22 /usr/local/lib/site_perl /usr/lib/x86_64-linux-gnu/perl-base .) at /usr/share/perl5/Debconf/FrontEnd/Readline.pm line 7.) debconf: falling back to frontend: Teletype Processing triggers for libc-bin (2.23-0ubuntu11.2) ... (Reading database ... 4780 files and directories currently installed.) Preparing to unpack .../libpam-modules-bin_1.1.8-3.2ubuntu2.3_amd64.deb ... Unpacking libpam-modules-bin (1.1.8-3.2ubuntu2.3) over (1.1.8-3.2ubuntu2.1) ... Setting up libpam-modules-bin (1.1.8-3.2ubuntu2.3) ... (Reading database ... 4780 files and directories currently installed.) Preparing to unpack .../libpam-modules_1.1.8-3.2ubuntu2.3_amd64.deb ... debconf: unable to initialize frontend: Dialog debconf: (TERM is not set, so the dialog frontend is not usable.) debconf: falling back to frontend: Readline debconf: unable to initialize frontend: Readline debconf: (Can't locate Term/ReadLine.pm in @INC (you may need to install the Term::ReadLine module) (@INC contains: /etc/perl /usr/local/lib/x86_64-linux-gnu/perl/5.22.1 /usr/local/share/perl/5.22.1 /usr/lib/x86_64-linux-gnu/perl5/5.22 /usr/share/perl5 /usr/lib/x86_64-linux-gnu/perl/5.22 /usr/share/perl/5.22 /usr/local/lib/site_perl /usr/lib/x86_64-linux-gnu/perl-base .) at /usr/share/perl5/Debconf/FrontEnd/Readline.pm line 7.) debconf: falling back to frontend: Teletype Unpacking libpam-modules:amd64 (1.1.8-3.2ubuntu2.3) over (1.1.8-3.2ubuntu2.1) ... Setting up libpam-modules:amd64 (1.1.8-3.2ubuntu2.3) ... (Reading database ... 4780 files and directories currently installed.) Preparing to unpack .../libpam-runtime_1.1.8-3.2ubuntu2.3_all.deb ... Unpacking libpam-runtime (1.1.8-3.2ubuntu2.3) over (1.1.8-3.2ubuntu2.1) ... Setting up libpam-runtime (1.1.8-3.2ubuntu2.3) ... debconf: unable to initialize frontend: Dialog debconf: (TERM is not set, so the dialog frontend is not usable.) debconf: falling back to frontend: Readline debconf: unable to initialize frontend: Readline debconf: (Can't locate Term/ReadLine.pm in @INC (you may need to install the Term::ReadLine module) (@INC contains: /etc/perl /usr/local/lib/x86_64-linux-gnu/perl/5.22.1 /usr/local/share/perl/5.22.1 /usr/lib/x86_64-linux-gnu/perl5/5.22 /usr/share/perl5 /usr/lib/x86_64-linux-gnu/perl/5.22 /usr/share/perl/5.22 /usr/local/lib/site_perl /usr/lib/x86_64-linux-gnu/perl-base .) at /usr/share/perl5/Debconf/FrontEnd/Readline.pm line 7.) debconf: falling back to frontend: Teletype Removing intermediate container 3d458b9249b5 ---> f00188bd821c Step 3/11 : RUN apt-get install -y python-software-properties ---> Running in b4f5db0d4277 Reading package lists... Building dependency tree... Reading state information... The following additional packages will be installed: ca-certificates cron dbus dh-python distro-info-data file gir1.2-glib-2.0 iso-codes krb5-locales libapt-inst2.0 libasn1-8-heimdal libcap-ng0 libcurl3-gnutls libdbus-1-3 libdbus-glib-1-2 libexpat1 libffi6 libgirepository-1.0-1 libglib2.0-0 libglib2.0-data libgmp10 libgnutls30 libgssapi-krb5-2 libgssapi3-heimdal libhcrypto4-heimdal libheimbase1-heimdal libheimntlm0-heimdal libhogweed4 libhx509-5-heimdal libicu55 libidn11 libk5crypto3 libkeyutils1 libkrb5-26-heimdal libkrb5-3 libkrb5support0 libldap-2.4-2 libmagic1 libmpdec2 libnettle6 libp11-kit0 libpython-stdlib libpython2.7-minimal libpython2.7-stdlib libpython3-stdlib libpython3.5-minimal libpython3.5-stdlib libroken18-heimdal librtmp1 libsasl2-2 libsasl2-modules libsasl2-modules-db libsqlite3-0 libssl1.0.0 libtasn1-6 libwind0-heimdal libxml2 lsb-release mime-support openssl powermgmt-base python python-apt python-apt-common python-minimal python-pycurl python2.7 python2.7-minimal python3 python3-apt python3-dbus python3-gi python3-minimal python3.5 python3.5-minimal sgml-base shared-mime-info ucf unattended-upgrades xdg-user-dirs xml-core xz-utils Suggested packages: anacron logrotate checksecurity exim4 | postfix | mail-transport-agent dbus-user-session | dbus-x11 libdpkg-perl isoquery gnutls-bin krb5-doc krb5-user libsasl2-modules-otp libsasl2-modules-ldap libsasl2-modules-sql libsasl2-modules-gssapi-mit | libsasl2-modules-gssapi-heimdal lsb python-doc python-tk python-apt-dbg python-apt-doc libcurl4-gnutls-dev python-pycurl-dbg python-pycurl-doc python2.7-doc binutils binfmt-support python3-doc python3-tk python3-venv python3-apt-dbg python-dbus-doc python3-dbus-dbg python3.5-venv python3.5-doc sgml-base-doc bsd-mailx default-mta | mail-transport-agent needrestart debhelper The following NEW packages will be installed: ca-certificates cron dbus dh-python distro-info-data file gir1.2-glib-2.0 iso-codes krb5-locales libapt-inst2.0 libasn1-8-heimdal libcap-ng0 libcurl3-gnutls libdbus-1-3 libdbus-glib-1-2 libexpat1 libffi6 libgirepository-1.0-1 libglib2.0-0 libglib2.0-data libgmp10 libgnutls30 libgssapi-krb5-2 libgssapi3-heimdal libhcrypto4-heimdal libheimbase1-heimdal libheimntlm0-heimdal libhogweed4 libhx509-5-heimdal libicu55 libidn11 libk5crypto3 libkeyutils1 libkrb5-26-heimdal libkrb5-3 libkrb5support0 libldap-2.4-2 libmagic1 libmpdec2 libnettle6 libp11-kit0 libpython-stdlib libpython2.7-minimal libpython2.7-stdlib libpython3-stdlib libpython3.5-minimal libpython3.5-stdlib libroken18-heimdal librtmp1 libsasl2-2 libsasl2-modules libsasl2-modules-db libsqlite3-0 libssl1.0.0 libtasn1-6 libwind0-heimdal libxml2 lsb-release mime-support openssl powermgmt-base python python-apt python-apt-common python-minimal python-pycurl python-software-properties python2.7 python2.7-minimal python3 python3-apt python3-dbus python3-gi python3-minimal python3.5 python3.5-minimal sgml-base shared-mime-info ucf unattended-upgrades xdg-user-dirs xml-core xz-utils 0 upgraded, 83 newly installed, 0 to remove and 0 not upgraded. Need to get 27.9 MB of archives. After this operation, 128 MB of additional disk space will be used. Get:1 http://archive.ubuntu.com/ubuntu xenial/main amd64 cron amd64 3.0pl1-128ubuntu2 [68.4 kB] Get:2 http://archive.ubuntu.com/ubuntu xenial-updates/main amd64 libssl1.0.0 amd64 1.0.2g-1ubuntu4.17 [1082 kB] Get:3 http://archive.ubuntu.com/ubuntu xenial-updates/main amd64 libpython3.5-minimal amd64 3.5.2-2ubuntu0~16.04.12 [524 kB] Get:4 http://archive.ubuntu.com/ubuntu xenial-updates/main amd64 libexpat1 amd64 2.1.0-7ubuntu0.16.04.5 [71.5 kB] Get:5 http://archive.ubuntu.com/ubuntu xenial-updates/main amd64 python3.5-minimal amd64 3.5.2-2ubuntu0~16.04.12 [1598 kB] Get:6 http://archive.ubuntu.com/ubuntu xenial/main amd64 python3-minimal amd64 3.5.1-3 [23.3 kB] Get:7 http://archive.ubuntu.com/ubuntu xenial/main amd64 mime-support all 3.59ubuntu1 [31.0 kB] Get:8 http://archive.ubuntu.com/ubuntu xenial/main amd64 libmpdec2 amd64 2.4.2-1 [82.6 kB] Get:9 http://archive.ubuntu.com/ubuntu xenial-updates/main amd64 libsqlite3-0 amd64 3.11.0-1ubuntu1.5 [398 kB] Get:10 http://archive.ubuntu.com/ubuntu xenial-updates/main amd64 libpython3.5-stdlib amd64 3.5.2-2ubuntu0~16.04.12 [2131 kB] Get:11 http://archive.ubuntu.com/ubuntu xenial-updates/main amd64 python3.5 amd64 3.5.2-2ubuntu0~16.04.12 [165 kB] Get:12 http://archive.ubuntu.com/ubuntu xenial/main amd64 libpython3-stdlib amd64 3.5.1-3 [6818 B] Get:13 http://archive.ubuntu.com/ubuntu xenial-updates/main amd64 dh-python all 2.20151103ubuntu1.2 [73.9 kB] Get:14 http://archive.ubuntu.com/ubuntu xenial/main amd64 python3 amd64 3.5.1-3 [8710 B] Get:15 http://archive.ubuntu.com/ubuntu xenial/main amd64 libffi6 amd64 3.2.1-4 [17.8 kB] Get:16 http://archive.ubuntu.com/ubuntu xenial-updates/main amd64 libglib2.0-0 amd64 2.48.2-0ubuntu4.6 [1120 kB] Get:17 http://archive.ubuntu.com/ubuntu xenial/main amd64 sgml-base all 1.26+nmu4ubuntu1 [12.5 kB] Get:18 http://archive.ubuntu.com/ubuntu xenial-updates/main amd64 libpython2.7-minimal amd64 2.7.12-1ubuntu0~16.04.13 [337 kB] Get:19 http://archive.ubuntu.com/ubuntu xenial-updates/main amd64 python2.7-minimal amd64 2.7.12-1ubuntu0~16.04.13 [1259 kB] Get:20 http://archive.ubuntu.com/ubuntu xenial-updates/main amd64 python-minimal amd64 2.7.12-1~16.04 [28.1 kB] Get:21 http://archive.ubuntu.com/ubuntu xenial-updates/main amd64 libpython2.7-stdlib amd64 2.7.12-1ubuntu0~16.04.13 [1886 kB] Get:22 http://archive.ubuntu.com/ubuntu xenial-updates/main amd64 python2.7 amd64 2.7.12-1ubuntu0~16.04.13 [224 kB] Get:23 http://archive.ubuntu.com/ubuntu xenial-updates/main amd64 libpython-stdlib amd64 2.7.12-1~16.04 [7768 B] Get:24 http://archive.ubuntu.com/ubuntu xenial-updates/main amd64 python amd64 2.7.12-1~16.04 [137 kB] Get:25 http://archive.ubuntu.com/ubuntu xenial-updates/main amd64 distro-info-data all 0.28ubuntu0.14 [4674 B] Get:26 http://archive.ubuntu.com/ubuntu xenial-updates/main amd64 libmagic1 amd64 1:5.25-2ubuntu1.4 [216 kB] Get:27 http://archive.ubuntu.com/ubuntu xenial-updates/main amd64 file amd64 1:5.25-2ubuntu1.4 [21.2 kB] Get:28 http://archive.ubuntu.com/ubuntu xenial-updates/main amd64 libapt-inst2.0 amd64 1.2.32ubuntu0.1 [54.5 kB] Get:29 http://archive.ubuntu.com/ubuntu xenial/main amd64 libgmp10 amd64 2:6.1.0+dfsg-2 [240 kB] Get:30 http://archive.ubuntu.com/ubuntu xenial-updates/main amd64 libnettle6 amd64 3.2-1ubuntu0.16.04.1 [93.5 kB] Get:31 http://archive.ubuntu.com/ubuntu xenial-updates/main amd64 libhogweed4 amd64 3.2-1ubuntu0.16.04.1 [136 kB] Get:32 http://archive.ubuntu.com/ubuntu xenial-updates/main amd64 libidn11 amd64 1.32-3ubuntu1.2 [46.5 kB] Get:33 http://archive.ubuntu.com/ubuntu xenial-updates/main amd64 libp11-kit0 amd64 0.23.2-5~ubuntu16.04.1 [105 kB] Get:34 http://archive.ubuntu.com/ubuntu xenial-updates/main amd64 libtasn1-6 amd64 4.7-3ubuntu0.16.04.3 [43.5 kB] Get:35 http://archive.ubuntu.com/ubuntu xenial-updates/main amd64 libgnutls30 amd64 3.4.10-4ubuntu1.8 [548 kB] Get:36 http://archive.ubuntu.com/ubuntu xenial-updates/main amd64 lsb-release all 9.20160110ubuntu0.2 [11.8 kB] Get:37 http://archive.ubuntu.com/ubuntu xenial/main amd64 ucf all 3.0036 [52.9 kB] Get:38 http://archive.ubuntu.com/ubuntu xenial-updates/main amd64 openssl amd64 1.0.2g-1ubuntu4.17 [492 kB] Get:39 http://archive.ubuntu.com/ubuntu xenial-updates/main amd64 ca-certificates all 20190110~16.04.1 [146 kB] Get:40 http://archive.ubuntu.com/ubuntu xenial/main amd64 libcap-ng0 amd64 0.7.7-1 [10.9 kB] Get:41 http://archive.ubuntu.com/ubuntu xenial-updates/main amd64 libdbus-1-3 amd64 1.10.6-1ubuntu3.6 [161 kB] Get:42 http://archive.ubuntu.com/ubuntu xenial-updates/main amd64 dbus amd64 1.10.6-1ubuntu3.6 [141 kB] Get:43 http://archive.ubuntu.com/ubuntu xenial/main amd64 libgirepository-1.0-1 amd64 1.46.0-3ubuntu1 [88.3 kB] Get:44 http://archive.ubuntu.com/ubuntu xenial/main amd64 gir1.2-glib-2.0 amd64 1.46.0-3ubuntu1 [127 kB] Get:45 http://archive.ubuntu.com/ubuntu xenial/main amd64 iso-codes all 3.65-1 [2268 kB] Get:46 http://archive.ubuntu.com/ubuntu xenial-updates/main amd64 krb5-locales all 1.13.2+dfsg-5ubuntu2.1 [13.6 kB] Get:47 http://archive.ubuntu.com/ubuntu xenial-updates/main amd64 libroken18-heimdal amd64 1.7~git20150920+dfsg-4ubuntu1.16.04.1 [41.4 kB] Get:48 http://archive.ubuntu.com/ubuntu xenial-updates/main amd64 libasn1-8-heimdal amd64 1.7~git20150920+dfsg-4ubuntu1.16.04.1 [174 kB] Get:49 http://archive.ubuntu.com/ubuntu xenial-updates/main amd64 libkrb5support0 amd64 1.13.2+dfsg-5ubuntu2.1 [31.2 kB] Get:50 http://archive.ubuntu.com/ubuntu xenial-updates/main amd64 libk5crypto3 amd64 1.13.2+dfsg-5ubuntu2.1 [81.3 kB] Get:51 http://archive.ubuntu.com/ubuntu xenial/main amd64 libkeyutils1 amd64 1.5.9-8ubuntu1 [9904 B] Get:52 http://archive.ubuntu.com/ubuntu xenial-updates/main amd64 libkrb5-3 amd64 1.13.2+dfsg-5ubuntu2.1 [273 kB] Get:53 http://archive.ubuntu.com/ubuntu xenial-updates/main amd64 libgssapi-krb5-2 amd64 1.13.2+dfsg-5ubuntu2.1 [120 kB] Get:54 http://archive.ubuntu.com/ubuntu xenial-updates/main amd64 libhcrypto4-heimdal amd64 1.7~git20150920+dfsg-4ubuntu1.16.04.1 [85.0 kB] Get:55 http://archive.ubuntu.com/ubuntu xenial-updates/main amd64 libheimbase1-heimdal amd64 1.7~git20150920+dfsg-4ubuntu1.16.04.1 [29.3 kB] Get:56 http://archive.ubuntu.com/ubuntu xenial-updates/main amd64 libwind0-heimdal amd64 1.7~git20150920+dfsg-4ubuntu1.16.04.1 [47.8 kB] Get:57 http://archive.ubuntu.com/ubuntu xenial-updates/main amd64 libhx509-5-heimdal amd64 1.7~git20150920+dfsg-4ubuntu1.16.04.1 [107 kB] Get:58 http://archive.ubuntu.com/ubuntu xenial-updates/main amd64 libkrb5-26-heimdal amd64 1.7~git20150920+dfsg-4ubuntu1.16.04.1 [202 kB] Get:59 http://archive.ubuntu.com/ubuntu xenial-updates/main amd64 libheimntlm0-heimdal amd64 1.7~git20150920+dfsg-4ubuntu1.16.04.1 [15.1 kB] Get:60 http://archive.ubuntu.com/ubuntu xenial-updates/main amd64 libgssapi3-heimdal amd64 1.7~git20150920+dfsg-4ubuntu1.16.04.1 [96.1 kB] Get:61 http://archive.ubuntu.com/ubuntu xenial-updates/main amd64 libsasl2-modules-db amd64 2.1.26.dfsg1-14ubuntu0.2 [14.5 kB] Get:62 http://archive.ubuntu.com/ubuntu xenial-updates/main amd64 libsasl2-2 amd64 2.1.26.dfsg1-14ubuntu0.2 [48.7 kB] Get:63 http://archive.ubuntu.com/ubuntu xenial-updates/main amd64 libldap-2.4-2 amd64 2.4.42+dfsg-2ubuntu3.9 [159 kB] Get:64 http://archive.ubuntu.com/ubuntu xenial-updates/main amd64 librtmp1 amd64 2.4+20151223.gitfa8646d-1ubuntu0.1 [54.4 kB] Get:65 http://archive.ubuntu.com/ubuntu xenial-updates/main amd64 libcurl3-gnutls amd64 7.47.0-1ubuntu2.16 [184 kB] Get:66 http://archive.ubuntu.com/ubuntu xenial/main amd64 libdbus-glib-1-2 amd64 0.106-1 [67.1 kB] Get:67 http://archive.ubuntu.com/ubuntu xenial-updates/main amd64 libglib2.0-data all 2.48.2-0ubuntu4.6 [131 kB] Get:68 http://archive.ubuntu.com/ubuntu xenial-updates/main amd64 libicu55 amd64 55.1-7ubuntu0.5 [7650 kB] Get:69 http://archive.ubuntu.com/ubuntu xenial-updates/main amd64 libsasl2-modules amd64 2.1.26.dfsg1-14ubuntu0.2 [47.7 kB] Get:70 http://archive.ubuntu.com/ubuntu xenial-updates/main amd64 libxml2 amd64 2.9.3+dfsg1-1ubuntu0.7 [698 kB] Get:71 http://archive.ubuntu.com/ubuntu xenial/main amd64 powermgmt-base all 1.31+nmu1 [7178 B] Get:72 http://archive.ubuntu.com/ubuntu xenial-updates/main amd64 python-apt-common all 1.1.0~beta1ubuntu0.16.04.9 [16.8 kB] Get:73 http://archive.ubuntu.com/ubuntu xenial-updates/main amd64 python3-apt amd64 1.1.0~beta1ubuntu0.16.04.9 [145 kB] Get:74 http://archive.ubuntu.com/ubuntu xenial/main amd64 python3-dbus amd64 1.2.0-3 [83.1 kB] Get:75 http://archive.ubuntu.com/ubuntu xenial/main amd64 python3-gi amd64 3.20.0-0ubuntu1 [153 kB] Get:76 http://archive.ubuntu.com/ubuntu xenial-updates/main amd64 shared-mime-info amd64 1.5-2ubuntu0.2 [405 kB] Get:77 http://archive.ubuntu.com/ubuntu xenial-updates/main amd64 xdg-user-dirs amd64 0.15-2ubuntu6.16.04.1 [61.8 kB] Get:78 http://archive.ubuntu.com/ubuntu xenial/main amd64 xml-core all 0.13+nmu2 [23.3 kB] Get:79 http://archive.ubuntu.com/ubuntu xenial-updates/main amd64 python-apt amd64 1.1.0~beta1ubuntu0.16.04.9 [147 kB] Get:80 http://archive.ubuntu.com/ubuntu xenial/main amd64 python-pycurl amd64 7.43.0-1ubuntu1 [43.3 kB] Get:81 http://archive.ubuntu.com/ubuntu xenial-updates/universe amd64 python-software-properties all 0.96.20.10 [20.6 kB] Get:82 http://archive.ubuntu.com/ubuntu xenial/main amd64 xz-utils amd64 5.1.1alpha+20120614-2ubuntu2 [78.8 kB] Get:83 http://archive.ubuntu.com/ubuntu xenial-updates/main amd64 unattended-upgrades all 1.1ubuntu1.18.04.7~16.04.6 [42.1 kB] debconf: delaying package configuration, since apt-utils is not installed Fetched 27.9 MB in 1min 50s (252 kB/s) Selecting previously unselected package cron. (Reading database ... 4780 files and directories currently installed.) Preparing to unpack .../cron_3.0pl1-128ubuntu2_amd64.deb ... Unpacking cron (3.0pl1-128ubuntu2) ... Selecting previously unselected package libssl1.0.0:amd64. Preparing to unpack .../libssl1.0.0_1.0.2g-1ubuntu4.17_amd64.deb ... Unpacking libssl1.0.0:amd64 (1.0.2g-1ubuntu4.17) ... Selecting previously unselected package libpython3.5-minimal:amd64. Preparing to unpack .../libpython3.5-minimal_3.5.2-2ubuntu0~16.04.12_amd64.deb ... Unpacking libpython3.5-minimal:amd64 (3.5.2-2ubuntu0~16.04.12) ... Selecting previously unselected package libexpat1:amd64. Preparing to unpack .../libexpat1_2.1.0-7ubuntu0.16.04.5_amd64.deb ... Unpacking libexpat1:amd64 (2.1.0-7ubuntu0.16.04.5) ... Selecting previously unselected package python3.5-minimal. Preparing to unpack .../python3.5-minimal_3.5.2-2ubuntu0~16.04.12_amd64.deb ... Unpacking python3.5-minimal (3.5.2-2ubuntu0~16.04.12) ... Selecting previously unselected package python3-minimal. Preparing to unpack .../python3-minimal_3.5.1-3_amd64.deb ... Unpacking python3-minimal (3.5.1-3) ... Selecting previously unselected package mime-support. Preparing to unpack .../mime-support_3.59ubuntu1_all.deb ... Unpacking mime-support (3.59ubuntu1) ... Selecting previously unselected package libmpdec2:amd64. Preparing to unpack .../libmpdec2_2.4.2-1_amd64.deb ... Unpacking libmpdec2:amd64 (2.4.2-1) ... Selecting previously unselected package libsqlite3-0:amd64. Preparing to unpack .../libsqlite3-0_3.11.0-1ubuntu1.5_amd64.deb ... Unpacking libsqlite3-0:amd64 (3.11.0-1ubuntu1.5) ... Selecting previously unselected package libpython3.5-stdlib:amd64. Preparing to unpack .../libpython3.5-stdlib_3.5.2-2ubuntu0~16.04.12_amd64.deb ... Unpacking libpython3.5-stdlib:amd64 (3.5.2-2ubuntu0~16.04.12) ... Selecting previously unselected package python3.5. Preparing to unpack .../python3.5_3.5.2-2ubuntu0~16.04.12_amd64.deb ... Unpacking python3.5 (3.5.2-2ubuntu0~16.04.12) ... Selecting previously unselected package libpython3-stdlib:amd64. Preparing to unpack .../libpython3-stdlib_3.5.1-3_amd64.deb ... Unpacking libpython3-stdlib:amd64 (3.5.1-3) ... Selecting previously unselected package dh-python. Preparing to unpack .../dh-python_2.20151103ubuntu1.2_all.deb ... Unpacking dh-python (2.20151103ubuntu1.2) ... Processing triggers for systemd (229-4ubuntu21.29) ... Processing triggers for libc-bin (2.23-0ubuntu11.2) ... Setting up libssl1.0.0:amd64 (1.0.2g-1ubuntu4.17) ... debconf: unable to initialize frontend: Dialog debconf: (TERM is not set, so the dialog frontend is not usable.) debconf: falling back to frontend: Readline debconf: unable to initialize frontend: Readline debconf: (Can't locate Term/ReadLine.pm in @INC (you may need to install the Term::ReadLine module) (@INC contains: /etc/perl /usr/local/lib/x86_64-linux-gnu/perl/5.22.1 /usr/local/share/perl/5.22.1 /usr/lib/x86_64-linux-gnu/perl5/5.22 /usr/share/perl5 /usr/lib/x86_64-linux-gnu/perl/5.22 /usr/share/perl/5.22 /usr/local/lib/site_perl /usr/lib/x86_64-linux-gnu/perl-base .) at /usr/share/perl5/Debconf/FrontEnd/Readline.pm line 7.) debconf: falling back to frontend: Teletype Setting up libpython3.5-minimal:amd64 (3.5.2-2ubuntu0~16.04.12) ... Setting up libexpat1:amd64 (2.1.0-7ubuntu0.16.04.5) ... Setting up python3.5-minimal (3.5.2-2ubuntu0~16.04.12) ... Setting up python3-minimal (3.5.1-3) ... Processing triggers for libc-bin (2.23-0ubuntu11.2) ... Selecting previously unselected package python3. (Reading database ... 5794 files and directories currently installed.) Preparing to unpack .../python3_3.5.1-3_amd64.deb ... Unpacking python3 (3.5.1-3) ... Selecting previously unselected package libffi6:amd64. Preparing to unpack .../libffi6_3.2.1-4_amd64.deb ... Unpacking libffi6:amd64 (3.2.1-4) ... Selecting previously unselected package libglib2.0-0:amd64. Preparing to unpack .../libglib2.0-0_2.48.2-0ubuntu4.6_amd64.deb ... Unpacking libglib2.0-0:amd64 (2.48.2-0ubuntu4.6) ... Selecting previously unselected package sgml-base. Preparing to unpack .../sgml-base_1.26+nmu4ubuntu1_all.deb ... Unpacking sgml-base (1.26+nmu4ubuntu1) ... Selecting previously unselected package libpython2.7-minimal:amd64. Preparing to unpack .../libpython2.7-minimal_2.7.12-1ubuntu0~16.04.13_amd64.deb ... Unpacking libpython2.7-minimal:amd64 (2.7.12-1ubuntu0~16.04.13) ... Selecting previously unselected package python2.7-minimal. Preparing to unpack .../python2.7-minimal_2.7.12-1ubuntu0~16.04.13_amd64.deb ... Unpacking python2.7-minimal (2.7.12-1ubuntu0~16.04.13) ... Selecting previously unselected package python-minimal. Preparing to unpack .../python-minimal_2.7.12-1~16.04_amd64.deb ... Unpacking python-minimal (2.7.12-1~16.04) ... Selecting previously unselected package libpython2.7-stdlib:amd64. Preparing to unpack .../libpython2.7-stdlib_2.7.12-1ubuntu0~16.04.13_amd64.deb ... Unpacking libpython2.7-stdlib:amd64 (2.7.12-1ubuntu0~16.04.13) ... Selecting previously unselected package python2.7. Preparing to unpack .../python2.7_2.7.12-1ubuntu0~16.04.13_amd64.deb ... Unpacking python2.7 (2.7.12-1ubuntu0~16.04.13) ... Selecting previously unselected package libpython-stdlib:amd64. Preparing to unpack .../libpython-stdlib_2.7.12-1~16.04_amd64.deb ... Unpacking libpython-stdlib:amd64 (2.7.12-1~16.04) ... Processing triggers for libc-bin (2.23-0ubuntu11.2) ... Setting up libpython2.7-minimal:amd64 (2.7.12-1ubuntu0~16.04.13) ... Setting up python2.7-minimal (2.7.12-1ubuntu0~16.04.13) ... Linking and byte-compiling packages for runtime python2.7... Setting up python-minimal (2.7.12-1~16.04) ... Selecting previously unselected package python. (Reading database ... 6616 files and directories currently installed.) Preparing to unpack .../python_2.7.12-1~16.04_amd64.deb ... Unpacking python (2.7.12-1~16.04) ... Selecting previously unselected package distro-info-data. Preparing to unpack .../distro-info-data_0.28ubuntu0.14_all.deb ... Unpacking distro-info-data (0.28ubuntu0.14) ... Selecting previously unselected package libmagic1:amd64. Preparing to unpack .../libmagic1_1%3a5.25-2ubuntu1.4_amd64.deb ... Unpacking libmagic1:amd64 (1:5.25-2ubuntu1.4) ... Selecting previously unselected package file. Preparing to unpack .../file_1%3a5.25-2ubuntu1.4_amd64.deb ... Unpacking file (1:5.25-2ubuntu1.4) ... Selecting previously unselected package libapt-inst2.0:amd64. Preparing to unpack .../libapt-inst2.0_1.2.32ubuntu0.1_amd64.deb ... Unpacking libapt-inst2.0:amd64 (1.2.32ubuntu0.1) ... Selecting previously unselected package libgmp10:amd64. Preparing to unpack .../libgmp10_2%3a6.1.0+dfsg-2_amd64.deb ... Unpacking libgmp10:amd64 (2:6.1.0+dfsg-2) ... Selecting previously unselected package libnettle6:amd64. Preparing to unpack .../libnettle6_3.2-1ubuntu0.16.04.1_amd64.deb ... Unpacking libnettle6:amd64 (3.2-1ubuntu0.16.04.1) ... Selecting previously unselected package libhogweed4:amd64. Preparing to unpack .../libhogweed4_3.2-1ubuntu0.16.04.1_amd64.deb ... Unpacking libhogweed4:amd64 (3.2-1ubuntu0.16.04.1) ... Selecting previously unselected package libidn11:amd64. Preparing to unpack .../libidn11_1.32-3ubuntu1.2_amd64.deb ... Unpacking libidn11:amd64 (1.32-3ubuntu1.2) ... Selecting previously unselected package libp11-kit0:amd64. Preparing to unpack .../libp11-kit0_0.23.2-5~ubuntu16.04.1_amd64.deb ... Unpacking libp11-kit0:amd64 (0.23.2-5~ubuntu16.04.1) ... Selecting previously unselected package libtasn1-6:amd64. Preparing to unpack .../libtasn1-6_4.7-3ubuntu0.16.04.3_amd64.deb ... Unpacking libtasn1-6:amd64 (4.7-3ubuntu0.16.04.3) ... Selecting previously unselected package libgnutls30:amd64. Preparing to unpack .../libgnutls30_3.4.10-4ubuntu1.8_amd64.deb ... Unpacking libgnutls30:amd64 (3.4.10-4ubuntu1.8) ... Selecting previously unselected package lsb-release. Preparing to unpack .../lsb-release_9.20160110ubuntu0.2_all.deb ... Unpacking lsb-release (9.20160110ubuntu0.2) ... Selecting previously unselected package ucf. Preparing to unpack .../archives/ucf_3.0036_all.deb ... Moving old data out of the way Unpacking ucf (3.0036) ... Selecting previously unselected package openssl. Preparing to unpack .../openssl_1.0.2g-1ubuntu4.17_amd64.deb ... Unpacking openssl (1.0.2g-1ubuntu4.17) ... Selecting previously unselected package ca-certificates. Preparing to unpack .../ca-certificates_20190110~16.04.1_all.deb ... Unpacking ca-certificates (20190110~16.04.1) ... Selecting previously unselected package libcap-ng0:amd64. Preparing to unpack .../libcap-ng0_0.7.7-1_amd64.deb ... Unpacking libcap-ng0:amd64 (0.7.7-1) ... Selecting previously unselected package libdbus-1-3:amd64. Preparing to unpack .../libdbus-1-3_1.10.6-1ubuntu3.6_amd64.deb ... Unpacking libdbus-1-3:amd64 (1.10.6-1ubuntu3.6) ... Selecting previously unselected package dbus. Preparing to unpack .../dbus_1.10.6-1ubuntu3.6_amd64.deb ... Unpacking dbus (1.10.6-1ubuntu3.6) ... Selecting previously unselected package libgirepository-1.0-1:amd64. Preparing to unpack .../libgirepository-1.0-1_1.46.0-3ubuntu1_amd64.deb ... Unpacking libgirepository-1.0-1:amd64 (1.46.0-3ubuntu1) ... Selecting previously unselected package gir1.2-glib-2.0:amd64. Preparing to unpack .../gir1.2-glib-2.0_1.46.0-3ubuntu1_amd64.deb ... Unpacking gir1.2-glib-2.0:amd64 (1.46.0-3ubuntu1) ... Selecting previously unselected package iso-codes. Preparing to unpack .../iso-codes_3.65-1_all.deb ... Unpacking iso-codes (3.65-1) ... Selecting previously unselected package krb5-locales. Preparing to unpack .../krb5-locales_1.13.2+dfsg-5ubuntu2.1_all.deb ... Unpacking krb5-locales (1.13.2+dfsg-5ubuntu2.1) ... Selecting previously unselected package libroken18-heimdal:amd64. Preparing to unpack .../libroken18-heimdal_1.7~git20150920+dfsg-4ubuntu1.16.04.1_amd64.deb ... Unpacking libroken18-heimdal:amd64 (1.7~git20150920+dfsg-4ubuntu1.16.04.1) ... Selecting previously unselected package libasn1-8-heimdal:amd64. Preparing to unpack .../libasn1-8-heimdal_1.7~git20150920+dfsg-4ubuntu1.16.04.1_amd64.deb ... Unpacking libasn1-8-heimdal:amd64 (1.7~git20150920+dfsg-4ubuntu1.16.04.1) ... Selecting previously unselected package libkrb5support0:amd64. Preparing to unpack .../libkrb5support0_1.13.2+dfsg-5ubuntu2.1_amd64.deb ... Unpacking libkrb5support0:amd64 (1.13.2+dfsg-5ubuntu2.1) ... Selecting previously unselected package libk5crypto3:amd64. Preparing to unpack .../libk5crypto3_1.13.2+dfsg-5ubuntu2.1_amd64.deb ... Unpacking libk5crypto3:amd64 (1.13.2+dfsg-5ubuntu2.1) ... Selecting previously unselected package libkeyutils1:amd64. Preparing to unpack .../libkeyutils1_1.5.9-8ubuntu1_amd64.deb ... Unpacking libkeyutils1:amd64 (1.5.9-8ubuntu1) ... Selecting previously unselected package libkrb5-3:amd64. Preparing to unpack .../libkrb5-3_1.13.2+dfsg-5ubuntu2.1_amd64.deb ... Unpacking libkrb5-3:amd64 (1.13.2+dfsg-5ubuntu2.1) ... Selecting previously unselected package libgssapi-krb5-2:amd64. Preparing to unpack .../libgssapi-krb5-2_1.13.2+dfsg-5ubuntu2.1_amd64.deb ... Unpacking libgssapi-krb5-2:amd64 (1.13.2+dfsg-5ubuntu2.1) ... Selecting previously unselected package libhcrypto4-heimdal:amd64. Preparing to unpack .../libhcrypto4-heimdal_1.7~git20150920+dfsg-4ubuntu1.16.04.1_amd64.deb ... Unpacking libhcrypto4-heimdal:amd64 (1.7~git20150920+dfsg-4ubuntu1.16.04.1) ... Selecting previously unselected package libheimbase1-heimdal:amd64. Preparing to unpack .../libheimbase1-heimdal_1.7~git20150920+dfsg-4ubuntu1.16.04.1_amd64.deb ... Unpacking libheimbase1-heimdal:amd64 (1.7~git20150920+dfsg-4ubuntu1.16.04.1) ... Selecting previously unselected package libwind0-heimdal:amd64. Preparing to unpack .../libwind0-heimdal_1.7~git20150920+dfsg-4ubuntu1.16.04.1_amd64.deb ... Unpacking libwind0-heimdal:amd64 (1.7~git20150920+dfsg-4ubuntu1.16.04.1) ... Selecting previously unselected package libhx509-5-heimdal:amd64. Preparing to unpack .../libhx509-5-heimdal_1.7~git20150920+dfsg-4ubuntu1.16.04.1_amd64.deb ... Unpacking libhx509-5-heimdal:amd64 (1.7~git20150920+dfsg-4ubuntu1.16.04.1) ... Selecting previously unselected package libkrb5-26-heimdal:amd64. Preparing to unpack .../libkrb5-26-heimdal_1.7~git20150920+dfsg-4ubuntu1.16.04.1_amd64.deb ... Unpacking libkrb5-26-heimdal:amd64 (1.7~git20150920+dfsg-4ubuntu1.16.04.1) ... Selecting previously unselected package libheimntlm0-heimdal:amd64. Preparing to unpack .../libheimntlm0-heimdal_1.7~git20150920+dfsg-4ubuntu1.16.04.1_amd64.deb ... Unpacking libheimntlm0-heimdal:amd64 (1.7~git20150920+dfsg-4ubuntu1.16.04.1) ... Selecting previously unselected package libgssapi3-heimdal:amd64. Preparing to unpack .../libgssapi3-heimdal_1.7~git20150920+dfsg-4ubuntu1.16.04.1_amd64.deb ... Unpacking libgssapi3-heimdal:amd64 (1.7~git20150920+dfsg-4ubuntu1.16.04.1) ... Selecting previously unselected package libsasl2-modules-db:amd64. Preparing to unpack .../libsasl2-modules-db_2.1.26.dfsg1-14ubuntu0.2_amd64.deb ... Unpacking libsasl2-modules-db:amd64 (2.1.26.dfsg1-14ubuntu0.2) ... Selecting previously unselected package libsasl2-2:amd64. Preparing to unpack .../libsasl2-2_2.1.26.dfsg1-14ubuntu0.2_amd64.deb ... Unpacking libsasl2-2:amd64 (2.1.26.dfsg1-14ubuntu0.2) ... Selecting previously unselected package libldap-2.4-2:amd64. Preparing to unpack .../libldap-2.4-2_2.4.42+dfsg-2ubuntu3.9_amd64.deb ... Unpacking libldap-2.4-2:amd64 (2.4.42+dfsg-2ubuntu3.9) ... Selecting previously unselected package librtmp1:amd64. Preparing to unpack .../librtmp1_2.4+20151223.gitfa8646d-1ubuntu0.1_amd64.deb ... Unpacking librtmp1:amd64 (2.4+20151223.gitfa8646d-1ubuntu0.1) ... Selecting previously unselected package libcurl3-gnutls:amd64. Preparing to unpack .../libcurl3-gnutls_7.47.0-1ubuntu2.16_amd64.deb ... Unpacking libcurl3-gnutls:amd64 (7.47.0-1ubuntu2.16) ... Selecting previously unselected package libdbus-glib-1-2:amd64. Preparing to unpack .../libdbus-glib-1-2_0.106-1_amd64.deb ... Unpacking libdbus-glib-1-2:amd64 (0.106-1) ... Selecting previously unselected package libglib2.0-data. Preparing to unpack .../libglib2.0-data_2.48.2-0ubuntu4.6_all.deb ... Unpacking libglib2.0-data (2.48.2-0ubuntu4.6) ... Selecting previously unselected package libicu55:amd64. Preparing to unpack .../libicu55_55.1-7ubuntu0.5_amd64.deb ... Unpacking libicu55:amd64 (55.1-7ubuntu0.5) ... Selecting previously unselected package libsasl2-modules:amd64. Preparing to unpack .../libsasl2-modules_2.1.26.dfsg1-14ubuntu0.2_amd64.deb ... Unpacking libsasl2-modules:amd64 (2.1.26.dfsg1-14ubuntu0.2) ... Selecting previously unselected package libxml2:amd64. Preparing to unpack .../libxml2_2.9.3+dfsg1-1ubuntu0.7_amd64.deb ... Unpacking libxml2:amd64 (2.9.3+dfsg1-1ubuntu0.7) ... Selecting previously unselected package powermgmt-base. Preparing to unpack .../powermgmt-base_1.31+nmu1_all.deb ... Unpacking powermgmt-base (1.31+nmu1) ... Selecting previously unselected package python-apt-common. Preparing to unpack .../python-apt-common_1.1.0~beta1ubuntu0.16.04.9_all.deb ... Unpacking python-apt-common (1.1.0~beta1ubuntu0.16.04.9) ... Selecting previously unselected package python3-apt. Preparing to unpack .../python3-apt_1.1.0~beta1ubuntu0.16.04.9_amd64.deb ... Unpacking python3-apt (1.1.0~beta1ubuntu0.16.04.9) ... Selecting previously unselected package python3-dbus. Preparing to unpack .../python3-dbus_1.2.0-3_amd64.deb ... Unpacking python3-dbus (1.2.0-3) ... Selecting previously unselected package python3-gi. Preparing to unpack .../python3-gi_3.20.0-0ubuntu1_amd64.deb ... Unpacking python3-gi (3.20.0-0ubuntu1) ... Selecting previously unselected package shared-mime-info. Preparing to unpack .../shared-mime-info_1.5-2ubuntu0.2_amd64.deb ... Unpacking shared-mime-info (1.5-2ubuntu0.2) ... Selecting previously unselected package xdg-user-dirs. Preparing to unpack .../xdg-user-dirs_0.15-2ubuntu6.16.04.1_amd64.deb ... Unpacking xdg-user-dirs (0.15-2ubuntu6.16.04.1) ... Selecting previously unselected package xml-core. Preparing to unpack .../xml-core_0.13+nmu2_all.deb ... Unpacking xml-core (0.13+nmu2) ... Selecting previously unselected package python-apt. Preparing to unpack .../python-apt_1.1.0~beta1ubuntu0.16.04.9_amd64.deb ... Unpacking python-apt (1.1.0~beta1ubuntu0.16.04.9) ... Selecting previously unselected package python-pycurl. Preparing to unpack .../python-pycurl_7.43.0-1ubuntu1_amd64.deb ... Unpacking python-pycurl (7.43.0-1ubuntu1) ... Selecting previously unselected package python-software-properties. Preparing to unpack .../python-software-properties_0.96.20.10_all.deb ... Unpacking python-software-properties (0.96.20.10) ... Selecting previously unselected package xz-utils. Preparing to unpack .../xz-utils_5.1.1alpha+20120614-2ubuntu2_amd64.deb ... Unpacking xz-utils (5.1.1alpha+20120614-2ubuntu2) ... Selecting previously unselected package unattended-upgrades. Preparing to unpack .../unattended-upgrades_1.1ubuntu1.18.04.7~16.04.6_all.deb ... Unpacking unattended-upgrades (1.1ubuntu1.18.04.7~16.04.6) ... Processing triggers for libc-bin (2.23-0ubuntu11.2) ... Processing triggers for systemd (229-4ubuntu21.29) ... Setting up cron (3.0pl1-128ubuntu2) ... Adding group `crontab' (GID 106) ... Done. update-rc.d: warning: start and stop actions are no longer supported; falling back to defaults update-rc.d: warning: stop runlevel arguments (1) do not match cron Default-Stop values (none) invoke-rc.d: could not determine current runlevel invoke-rc.d: policy-rc.d denied execution of start. Setting up mime-support (3.59ubuntu1) ... Setting up libmpdec2:amd64 (2.4.2-1) ... Setting up libsqlite3-0:amd64 (3.11.0-1ubuntu1.5) ... Setting up libpython3.5-stdlib:amd64 (3.5.2-2ubuntu0~16.04.12) ... Setting up python3.5 (3.5.2-2ubuntu0~16.04.12) ... Setting up libpython3-stdlib:amd64 (3.5.1-3) ... Setting up libffi6:amd64 (3.2.1-4) ... Setting up libglib2.0-0:amd64 (2.48.2-0ubuntu4.6) ... No schema files found: doing nothing. Setting up sgml-base (1.26+nmu4ubuntu1) ... Setting up libpython2.7-stdlib:amd64 (2.7.12-1ubuntu0~16.04.13) ... Setting up python2.7 (2.7.12-1ubuntu0~16.04.13) ... Setting up libpython-stdlib:amd64 (2.7.12-1~16.04) ... Setting up python (2.7.12-1~16.04) ... Setting up distro-info-data (0.28ubuntu0.14) ... Setting up libmagic1:amd64 (1:5.25-2ubuntu1.4) ... Setting up file (1:5.25-2ubuntu1.4) ... Setting up libapt-inst2.0:amd64 (1.2.32ubuntu0.1) ... Setting up libgmp10:amd64 (2:6.1.0+dfsg-2) ... Setting up libnettle6:amd64 (3.2-1ubuntu0.16.04.1) ... Setting up libhogweed4:amd64 (3.2-1ubuntu0.16.04.1) ... Setting up libidn11:amd64 (1.32-3ubuntu1.2) ... Setting up libp11-kit0:amd64 (0.23.2-5~ubuntu16.04.1) ... Setting up libtasn1-6:amd64 (4.7-3ubuntu0.16.04.3) ... Setting up libgnutls30:amd64 (3.4.10-4ubuntu1.8) ... Setting up ucf (3.0036) ... debconf: unable to initialize frontend: Dialog debconf: (TERM is not set, so the dialog frontend is not usable.) debconf: falling back to frontend: Readline debconf: unable to initialize frontend: Readline debconf: (Can't locate Term/ReadLine.pm in @INC (you may need to install the Term::ReadLine module) (@INC contains: /etc/perl /usr/local/lib/x86_64-linux-gnu/perl/5.22.1 /usr/local/share/perl/5.22.1 /usr/lib/x86_64-linux-gnu/perl5/5.22 /usr/share/perl5 /usr/lib/x86_64-linux-gnu/perl/5.22 /usr/share/perl/5.22 /usr/local/lib/site_perl /usr/lib/x86_64-linux-gnu/perl-base .) at /usr/share/perl5/Debconf/FrontEnd/Readline.pm line 7.) debconf: falling back to frontend: Teletype Setting up openssl (1.0.2g-1ubuntu4.17) ... Setting up ca-certificates (20190110~16.04.1) ... debconf: unable to initialize frontend: Dialog debconf: (TERM is not set, so the dialog frontend is not usable.) debconf: falling back to frontend: Readline debconf: unable to initialize frontend: Readline debconf: (Can't locate Term/ReadLine.pm in @INC (you may need to install the Term::ReadLine module) (@INC contains: /etc/perl /usr/local/lib/x86_64-linux-gnu/perl/5.22.1 /usr/local/share/perl/5.22.1 /usr/lib/x86_64-linux-gnu/perl5/5.22 /usr/share/perl5 /usr/lib/x86_64-linux-gnu/perl/5.22 /usr/share/perl/5.22 /usr/local/lib/site_perl /usr/lib/x86_64-linux-gnu/perl-base .) at /usr/share/perl5/Debconf/FrontEnd/Readline.pm line 7.) debconf: falling back to frontend: Teletype Setting up libcap-ng0:amd64 (0.7.7-1) ... Setting up libdbus-1-3:amd64 (1.10.6-1ubuntu3.6) ... Setting up dbus (1.10.6-1ubuntu3.6) ... Setting up libgirepository-1.0-1:amd64 (1.46.0-3ubuntu1) ... Setting up gir1.2-glib-2.0:amd64 (1.46.0-3ubuntu1) ... Setting up iso-codes (3.65-1) ... Setting up krb5-locales (1.13.2+dfsg-5ubuntu2.1) ... Setting up libroken18-heimdal:amd64 (1.7~git20150920+dfsg-4ubuntu1.16.04.1) ... Setting up libasn1-8-heimdal:amd64 (1.7~git20150920+dfsg-4ubuntu1.16.04.1) ... Setting up libkrb5support0:amd64 (1.13.2+dfsg-5ubuntu2.1) ... Setting up libk5crypto3:amd64 (1.13.2+dfsg-5ubuntu2.1) ... Setting up libkeyutils1:amd64 (1.5.9-8ubuntu1) ... Setting up libkrb5-3:amd64 (1.13.2+dfsg-5ubuntu2.1) ... Setting up libgssapi-krb5-2:amd64 (1.13.2+dfsg-5ubuntu2.1) ... Setting up libhcrypto4-heimdal:amd64 (1.7~git20150920+dfsg-4ubuntu1.16.04.1) ... Setting up libheimbase1-heimdal:amd64 (1.7~git20150920+dfsg-4ubuntu1.16.04.1) ... Setting up libwind0-heimdal:amd64 (1.7~git20150920+dfsg-4ubuntu1.16.04.1) ... Setting up libhx509-5-heimdal:amd64 (1.7~git20150920+dfsg-4ubuntu1.16.04.1) ... Setting up libkrb5-26-heimdal:amd64 (1.7~git20150920+dfsg-4ubuntu1.16.04.1) ... Setting up libheimntlm0-heimdal:amd64 (1.7~git20150920+dfsg-4ubuntu1.16.04.1) ... Setting up libgssapi3-heimdal:amd64 (1.7~git20150920+dfsg-4ubuntu1.16.04.1) ... Setting up libsasl2-modules-db:amd64 (2.1.26.dfsg1-14ubuntu0.2) ... Setting up libsasl2-2:amd64 (2.1.26.dfsg1-14ubuntu0.2) ... Setting up libldap-2.4-2:amd64 (2.4.42+dfsg-2ubuntu3.9) ... Setting up librtmp1:amd64 (2.4+20151223.gitfa8646d-1ubuntu0.1) ... Setting up libcurl3-gnutls:amd64 (7.47.0-1ubuntu2.16) ... Setting up libdbus-glib-1-2:amd64 (0.106-1) ... Setting up libglib2.0-data (2.48.2-0ubuntu4.6) ... Setting up libicu55:amd64 (55.1-7ubuntu0.5) ... Setting up libsasl2-modules:amd64 (2.1.26.dfsg1-14ubuntu0.2) ... Setting up libxml2:amd64 (2.9.3+dfsg1-1ubuntu0.7) ... Setting up powermgmt-base (1.31+nmu1) ... Setting up python-apt-common (1.1.0~beta1ubuntu0.16.04.9) ... Setting up shared-mime-info (1.5-2ubuntu0.2) ... Setting up xdg-user-dirs (0.15-2ubuntu6.16.04.1) ... Setting up xml-core (0.13+nmu2) ... Setting up python-apt (1.1.0~beta1ubuntu0.16.04.9) ... Setting up python-pycurl (7.43.0-1ubuntu1) ... Setting up xz-utils (5.1.1alpha+20120614-2ubuntu2) ... update-alternatives: using /usr/bin/xz to provide /usr/bin/lzma (lzma) in auto mode Setting up dh-python (2.20151103ubuntu1.2) ... Setting up python3 (3.5.1-3) ... running python rtupdate hooks for python3.5... running python post-rtupdate hooks for python3.5... Setting up lsb-release (9.20160110ubuntu0.2) ... Setting up python3-apt (1.1.0~beta1ubuntu0.16.04.9) ... Setting up python3-dbus (1.2.0-3) ... Setting up python3-gi (3.20.0-0ubuntu1) ... Setting up python-software-properties (0.96.20.10) ... Setting up unattended-upgrades (1.1ubuntu1.18.04.7~16.04.6) ... debconf: unable to initialize frontend: Dialog debconf: (TERM is not set, so the dialog frontend is not usable.) debconf: falling back to frontend: Readline debconf: unable to initialize frontend: Readline debconf: (Can't locate Term/ReadLine.pm in @INC (you may need to install the Term::ReadLine module) (@INC contains: /etc/perl /usr/local/lib/x86_64-linux-gnu/perl/5.22.1 /usr/local/share/perl/5.22.1 /usr/lib/x86_64-linux-gnu/perl5/5.22 /usr/share/perl5 /usr/lib/x86_64-linux-gnu/perl/5.22 /usr/share/perl/5.22 /usr/local/lib/site_perl /usr/lib/x86_64-linux-gnu/perl-base .) at /usr/share/perl5/Debconf/FrontEnd/Readline.pm line 7.) debconf: falling back to frontend: Teletype Creating config file /etc/apt/apt.conf.d/20auto-upgrades with new version Creating config file /etc/apt/apt.conf.d/50unattended-upgrades with new version Processing triggers for systemd (229-4ubuntu21.29) ... Processing triggers for libc-bin (2.23-0ubuntu11.2) ... Processing triggers for ca-certificates (20190110~16.04.1) ... Updating certificates in /etc/ssl/certs... 127 added, 0 removed; done. Running hooks in /etc/ca-certificates/update.d... done. Processing triggers for sgml-base (1.26+nmu4ubuntu1) ... Removing intermediate container b4f5db0d4277 ---> be37f3d13c47 Step 4/11 : RUN apt-get install -y software-properties-common ---> Running in 5dd065b5642f Reading package lists... Building dependency tree... Reading state information... The following additional packages will be installed: python3-pycurl python3-software-properties Suggested packages: libcurl4-gnutls-dev python-pycurl-doc python3-pycurl-dbg The following NEW packages will be installed: python3-pycurl python3-software-properties software-properties-common 0 upgraded, 3 newly installed, 0 to remove and 0 not upgraded. Need to get 72.0 kB of archives. After this operation, 483 kB of additional disk space will be used. Get:1 http://archive.ubuntu.com/ubuntu xenial/main amd64 python3-pycurl amd64 7.43.0-1ubuntu1 [42.3 kB] Get:2 http://archive.ubuntu.com/ubuntu xenial-updates/main amd64 python3-software-properties all 0.96.20.10 [20.2 kB] Get:3 http://archive.ubuntu.com/ubuntu xenial-updates/main amd64 software-properties-common all 0.96.20.10 [9504 B] debconf: delaying package configuration, since apt-utils is not installed Fetched 72.0 kB in 1s (51.3 kB/s) Selecting previously unselected package python3-pycurl. (Reading database ... 8408 files and directories currently installed.) Preparing to unpack .../python3-pycurl_7.43.0-1ubuntu1_amd64.deb ... Unpacking python3-pycurl (7.43.0-1ubuntu1) ... Selecting previously unselected package python3-software-properties. Preparing to unpack .../python3-software-properties_0.96.20.10_all.deb ... Unpacking python3-software-properties (0.96.20.10) ... Selecting previously unselected package software-properties-common. Preparing to unpack .../software-properties-common_0.96.20.10_all.deb ... Unpacking software-properties-common (0.96.20.10) ... Processing triggers for dbus (1.10.6-1ubuntu3.6) ... Setting up python3-pycurl (7.43.0-1ubuntu1) ... Setting up python3-software-properties (0.96.20.10) ... Setting up software-properties-common (0.96.20.10) ... Processing triggers for dbus (1.10.6-1ubuntu3.6) ... Removing intermediate container 5dd065b5642f ---> 02ea2f860a4d Step 5/11 : RUN add-apt-repository ppa:bitcoin/bitcoin ---> Running in e0f89744d2f0 NOT MAINTAINED. The OS-library linking packages here had a series of issues. PLEASE DOWNLOAD DIRECTLY FROM bitcoincore.org (and verify the signatures of said files). IF YOU WANT AUTO-UPDATES, please see the officially-maintained snap package - https://github.com/bitcoin-core/packaging/tree/master/snap More info: https://launchpad.net/~bitcoin/+archive/ubuntu/bitcoin gpg: keyring `/tmp/tmphrg15vnm/secring.gpg' created gpg: keyring `/tmp/tmphrg15vnm/pubring.gpg' created gpg: requesting key 8842CE5E from hkp server keyserver.ubuntu.com gpg: /tmp/tmphrg15vnm/trustdb.gpg: trustdb created gpg: key 8842CE5E: public key "Launchpad PPA for Bitcoin" imported gpg: no ultimately trusted keys found gpg: Total number processed: 1 gpg: imported: 1 (RSA: 1) OK Removing intermediate container e0f89744d2f0 ---> b81c0b64d050 Step 6/11 : RUN apt-get update -y ---> Running in f5e3ffb92318 Hit:1 http://archive.ubuntu.com/ubuntu xenial InRelease Get:2 http://ppa.launchpad.net/bitcoin/bitcoin/ubuntu xenial InRelease [17.5 kB] Hit:3 http://archive.ubuntu.com/ubuntu xenial-updates InRelease Hit:4 http://archive.ubuntu.com/ubuntu xenial-backports InRelease Get:5 http://ppa.launchpad.net/bitcoin/bitcoin/ubuntu xenial/main amd64 Packages [2169 B] Hit:6 http://security.ubuntu.com/ubuntu xenial-security InRelease Fetched 19.7 kB in 5s (3527 B/s) Reading package lists... Removing intermediate container f5e3ffb92318 ---> f9d21b3c9e07 Step 7/11 : RUN apt-get install -y bitcoind ---> Running in afb933e1ded8 Reading package lists... Building dependency tree... Reading state information... E: Unable to locate package bitcoind ERROR: Service 'daemon_one' failed to build : The command '/bin/sh -c apt-get install -y bitcoind' returned a non-zero code: 100 C:\Users\ebata\bitcoin> 

RUN add-apt-repository ppa:bitcoin/bitcoin を ppa:luke-jr/bitcoincore に変更してみたら、Dockerfileが通った

 

 

ターミナルを開いて、コンテナに入ります。
docker exec -it bitcoin_1 /bin/bash
 root@bitcoin_1:/# bitcoind -daemon Bitcoin Core starting root@bitcoin_1:/# bitcoin-cli generate 100 error code: -32601 error message: Method not found

あれ?

bitcoin-cli getinfoで確認出来るって書いてたけど、もう無くなったAPIになっちゃてたみたい

This command doesn't exist anymore since Bitcoin Core 0.19. Use generatetoaddress instead. てなことが記載されている。

ここを読んでみると、

Generate 11 blocks to myaddress
> bitcoin-cli generatetoaddress 11 "myaddress"
If you are running the bitcoin core wallet, you can get a new address to send the newly generated bitcoin to with:
> bitcoin-cli getnewaddress

てな記載がある。

とにかくブロックを作らんことには、金(ビットコイン)が稼げないが、上記の"myaddress"が何ならよう分からん。

ここ の記事にある、bitcoin-cli generatetoaddress 101 `bitcoin-cli getnewaddress`

をやってもいいものなのか?

ちなみに、bitcoin-cli getnewaddress を実行すると、

root@bitcoin_1:/# bitcoin-cli getnewaddress
bcrt1qymag0kvldyw4saejksnssv92ss3awrkp5vz6ef

てな内容が出てくる(アドレス、モロばれだけど、実際の環境では使わないからいいかな)

で、やってみた。

root@bitcoin_1:/# bitcoin-cli generatetoaddress 101 `bitcoin-cli getnewaddress`
[
"4177f527560e47a246ab9c00e88c4255b3b7acc7772ac8f691e2444977005a7e",
"2a5d403754cea5be3dcbead230b24887209c0832b4adbc39deb5c94b9fe02b08",
"56ace4b11685e895b14476863b649996cf0a2be7d99ba90487baebc6f1469f1a",
"4a52e7133141ec90278cfa960db52865b0ae26383d4d54faba1a3011054f82f0",
"5231d7dfcc5a7de895294b4caaae234949179d1978fb08f7c4bea2d460092616",
"165e2c7989a2e7392f573769a7abfda4f0ea31a7cbf6ade5189fc82d605aafe9",
"2c581e76e8bf6441a1a9b9f4f79bb8ec2eb51fcfdc866c2e555bab9a4c6ca286",
"7fed803ad55e2aa646ee49acb903cd82092b73f4486e592493b9733ed2747c2d",
"2f74ea1621a8016f0c726e84710f2b6a8960872e6a384c7a718d31b989f4ccbc",
"0db3f0879ad15be05ae2d345bd68d944c1014b95019e9797c99239346a860ca7",
"62f22bf9f9a37398fb0d05ec02b3dd07484cb82f24a6a0e6e3044f8d0f609138",
"228d3b9a56f3c3553cd828b9dfa0a7d26ad212625d303fe37026432685e9ca8c",
"2bc79a882222d359833d6d502823d18d822cf73389b82f2f91a470e8aa959202",
"1a218e6d2d25f9f4b11a487c596c8550da93dcc9be8588de25b2d6fbfc28d401",
"66bc748557187e1a899e0d1fda8b763344c504124e9e30583facd42d6a711778",
"3ec3631019a691f4da89c29563bef83e82b4da50b552bc17605353c626f991d8",
"03006db53a078364eda8462ad6f33dfe2fb7cb7dc4cbb80f2306887cd02eca07",
"3a3ba0070d431abdce94a894bd88cb436af44cf8841c66e2fd6bbac95d70f06d",
"0b57e21ad6c9f25a95b32cc7e2ccfe5a290d522060dd259312790037de31d64b",
"604ae4c582c4c3fdc8ca8f3ee2bf43ebf6f80b8f4f565d9133e49b4e83cd3d4b",
"31429fef4d34dad0d0dd6ab5da9ba02e363b5b36f63399b9ccd5fd04294a4b32",
"19723216344b0b02e696700d7a96bb343dc7c31b318f87bdc5b5d012794a6ed9",
"4d998f07124795428c6b99749efcfd93df0bbaf6c266d7935c312ad74a86ce0a",
"2448217b611b82631ef8cd3aaf3f5b54237f39092dd4e24dd62b6420cb2224d7",
"41c938ece2f9dcacd7261f90a400646a90d026d545fe9d05cf0fd5d2ff599240",
"50fc0af9714ebbaedb692132895405ce3272e928de96472a1fb9bf9d41e21bcf",
"77348b3afa398920d3e9c4c4c73f9bdae2c9ba2325f91f8229f2d5329abc6067",
"064f502414991675fd0eafdbc013fa437108bf641cdcae6f90d4ceacc4780c8d",
"66291c94d0ba5da56f80ae3c6e0cbf9b8094845239125a0f8211c6c76fee0e66",
"66900f87b1b4a32bff9c46100800ae5e6c42cc407515d5c2d09eca46877c71cf",
"1f6f13ec5cca4a8f00fd7436c1d25d8f9841f2fa51e91857291b6ee5274aa962",
"0423406749eb449c0c94b8d3766555038c6dadda04c4ff0d4e73427df1017b03",
"033a07ca40f30768424cfc10b88d13c0a9750eb898dbdebc5e28d4dcbeab2577",
"4fd38f4eeb9a0201bf08b47765e6179b43aa1a0d6f18677d6af3e4593d4b6ae2",
"41158030deaf4caf1ce37b919e788d168bcdd0ec2f5a28842368e21bfc30c645",
"1af821dd38d22c0d855522635c9089bf0d5ff962d87026e8367458af3b30ac09",
"5ef03f6423957f46adee2fcc957d287418885650057fb1d90a278f7ecbbc4bf0",
"03ec5fef2f98eb7ed818e87d2d95225918523b71625479cba7c78a6280f68660",
"4a4bd1f23ebd6ae5ca9fab7ae2c775c964d061178b355e576e736faaae85d8c7",
"58d3d30078bae0a899d6b7a816283643e09994f7548f5ba53191f0465094042a",
"57e822309588a318f4a7294bf525ec99fb7fd34f9b7a77761de0b58a25b8fc18",
"2994a3bea7669ce10a317686b878be2e84784446e3ad6c455de1f763f903fa44",
"70c80bc118ae9c238ec4a16a068555391efb9cf8b8bf19b14a83f8e6347ac75a",
"3109660d42242062667335463a473d285260e93ec725d442611e71eaf6eb4647",
"6463e5937deea0ec5c7a0e333b78726831440f7da499d27278803483f1b7b159",
"0750647a6e537758065b7ab13955bbe771841c950eceaf84c3b8494f3ef120b2",
"7f73b6998c3f11b3960da9c20828e74085410e37c69efd64779d0672310088b4",
"167f911d6192f5387009dfcc684fd5c882b5bd3be38ee01a918ef5ce89fb36bc",
"12e8937f16ede3cae67f73cefe764bc79aeecf61113d20fc3156d422c338c30c",
"41c9f793360a87528a7b3de4e51f33e6a466c57c11f7760676edb33ebc6a9f7e",
"33a3e607e53b402d68ac2bfd4e829c4c4f741869da4468dbe03a0a2d98f291c4",
"33cac25e7ec93ee93e8f2a95276a808100dcc941242326cb176278415c345ed8",
"6a979424fa152e5996762965189804cd2946c208e1ed68697d3ec8fcdeb2002b",
"411a9f258bf9b7fa455de052c1e80c254d3cf59f545b433c129b3592188e5d09",
"057c705b1556d45eb98e6cc586c9118e2baffeb542ec6943d8a237392c8d4316",
"7ea3a47ae7fa7c57ac80f223964290f132d887e7f6f66c49fda67180da1f4ec5",
"0947a3a9ac627fa3b04c6828c0af9e62ec5bfd506d52c1d5e049b2e677341597",
"4b2b755ba0446662de1a28357bf841007d2e0701f77667170ebe3afc081cf2f8",
"6be55f71c3f4e71467ae0a74b67c298c0caa0c889efbabcc67762f92aaff03c8",
"283a7855e14de3919395ec717b692c3cd990b278d2d5c90699acc85eaa49757a",
"14ac5a3afaca4492060d3dbea2474e918127acb59d4bf2e514e6f384eb0fa53c",
"05c397cd9cdda0f359fd4e915067bf11b195e5d3dc1a5aea34bd64ebdd26f1d5",
"280933eba56163feaf275c0bc2e3b81048539d34788ec22090313518e8aca1b9",
"29c3a23724fc07ced98367affb0f7def6cbb2cfe4fe3289c91bfcbb1d9062884",
"1a8f2665107c50442d01ec3c3b9dead73a7237f3414d7fa438415e78509cb53e",
"436a7fac474736aed85dc7d4e312b9fdfffc6a53b7e19422f478268cb20eb424",
"1f39a851008729db5d7c0aba7888d8ccba06ac847bc4542095e03f574b70eb4e",
"15cfd6f53704ca6e4de027cab4a25149e6a04b8ce03fba4289cb5b9cdb6f9a59",
"650de6dd79484716987c42410a465d5dfa54b2a99fc7d603723df5607e4e20dd",
"1cfeedc95e1acd9cffcb26b0483884134f40d5a283d937b7b43c16b614892931",
"4ea1e49e8a3b717fee3deaf7ba3ee14274d32f9c4a98d02bbb18da2f0cdafde7",
"6d0b95389dcb352a78eab47f9ceabdcd4f9bd3ea589f737bc313bcf24a8b0486",
"4f763813798b72049943d6614a516d37d407e3eaba6779e41bf1ac538350bdab",
"0de431dcee2bbd808a54d1acab883ed5496dc8ccc1d363540ff3ce440f304c43",
"4a199b4331a5fc6a27b8d3a2876e97554aa7113fc0eb667c0c147abeea9b9e1d",
"75f6ba9f84c88b9878ed7b3df63b6c1586be6fce2b5b9f4cd5595343b831651d",
"4f65083dd5077f084e0e4a588ea59207a4a712eec902e31d33c2d4965a80c1a1",
"2987e28e6b7b2383ac206726c4a9ca07a4e4f705fb12adcdfe10cfdcff565d3a",
"3fc9fdd7270744fff4285498c8a7f8619fb8ec89f827a462045ce8c3a8583b02",
"068ab89a648e1e9da4636a63a1a1ff5edea123a4f21667281f58ee7b3f43fccd",
"4df5562e0874f9a4253107f798f5d177640ab44d161b5c0d4fcdfe935e7cc009",
"59e86db93218d2aa4b07105dcd6edd07d2dd85152662a261af1f47d2aac042cc",
"0b15af3d8d1b08b3bde093e85078dffa754a5924c79085c4be1c91a713fe8062",
"00bb8022cea7cf517c41b95db0250e3389f02c2f034dd0e21cf441b35f256db4",
"25c7bad69581eb1c673693c9b5ecea34fd3981292badb90c41fa6fcff925dbac",
"4830bf3b369b0ba3975ab08b3fff07b9546c8fda6e2b7e55f305b8381f18fd6e",
"39855405738ed795c9f23cf933ac66e0b04ebabe50f28e102cd659166f9c7ff0",
"276797adb3a45042cb357525c7bb2053af26f97b158078d87f4965174a61456e",
"3ae64d52d4e9e80c072685e88cfb576c992e49a9f3808c1cee29279bff8fc90d",
"608ae941f8351e5e8bdc936d84009a0d93b79f82afaa69512cb41d4b6b13b2b6",
"20ed7ebbf55105697c6754440f1ffb68f796046b5e9bf9a5bf13fe12b762b915",
"318988c1b686efe428b3d4d9f711f26654a506007a30013d1946f01d3b21a1dd",
"00920ebf768761a74b9c6a89f3a16bbf5fc1cbea6f4c8af17eb3d7bdc1db45be",
"2f547f083680726977aa47a64303fd2fcf88c63e9ab6c0d983aab4e55dfa4011",
"2bfc89a56cec028ef08612e5a700b475baf73eb1d7404e3d4e18d22d0fb84871",
"67ee0490dde106367d715f5dedc13fa9a365b6551edeba1187f2fac260c91840",
"2ab1cff953dc2fecb4647bead68bdf8f27670e55989234ac77be1387437ad04e",
"699a01f27c9f4071ef5fa1db01ecee0b1cea4d717e936f5a689d90b82b40797c",
"50851ed32add0fa33db1b4f665ca8132f2109966811aff6a3b8f7f1d103d6165",
"25cc07422e00d859504bf4f7e072e9550d176860b5217c823cea5e93aef788c4",
"7114500ec4d179a09d609bde6cdf5d7c8f84920eca9d4f1efe102a3869591b37"
]
root@bitcoin_1:/#

うん、なんかブロックできたみたいだ。

root@bitcoin_1:/# bitcoin-cli getblockcount
500

うん、できている。では金額を確認してみよう。

root@bitcoin_1:/# bitcoin-cli getbalance
50.00000000

おお! 凄い。今1BTCが120万円くらいだから、6000万円を作ってしまったぞ! 

では、ここで口座(アカウント)を作ってみよう。

bitcoin-cli getnewaddress testuser1
bcrt1qhzknya5w4qcyxnq0lkcwumu9py2c624ujv79f6

でもって、残高を調べるけど・・・

root@bitcoin_1:/# bitcoin-cli getnewaddress testuser1
bcrt1qhzknya5w4qcyxnq0lkcwumu9py2c624ujv79f6
root@bitcoin_1:/# bitcoin-cli getbalance testuser1
error code: -32
error message:
dummy first argument must be excluded or set to "*".
root@bitcoin_1:/# bitcoin-cli getbalance *
error: Error parsing JSON:boot
root@bitcoin_1:/# bitcoin-cli getbalance bcrt1qhzknya5w4qcyxnq0lkcwumu9py2c624ujv79f6
error code: -32
error message:
dummy first argument must be excluded or set to "*".
root@bitcoin_1:/# bitcoin-cli -regtest getbalance bcrt1qhzknya5w4qcyxnq0lkcwumu9py2c624ujv79f6
error code: -32
error message:
dummy first argument must be excluded or set to "*".
root@bitcoin_1:/# bitcoin-cli getbalance bcrt1qhzknya5w4qcyxnq0lkcwumu9py2c624ujv79f6
error code: -32
error message:
dummy first argument must be excluded or set to "*".
root@bitcoin_1:/# bitcoin-cli getbalance "*"
12462.50000000
root@bitcoin_1:/# bitcoin-cli getbalance "testuser1"
error code: -32
error message:
dummy first argument must be excluded or set to "*".
root@bitcoin_1:/# bitcoin-cli getbalance "bcrt1qhzknya5w4qcyxnq0lkcwumu9py2c624ujv79f6"
error code: -32
error message:
dummy first argument must be excluded or set to "*".
root@bitcoin_1:/#

あれー? 上手く表示されないなぁ。

この当たりを探ってみる。

root@bitcoin_1:/# bitcoin-cli listaddressgroupings
[
  [
    [
      "bcrt1q37qd0chv7he5epgeaycm236zke2kx37esh2we0",
      12462.50000000,
      ""
    ]
  ]
] 二人目のユーザ(アドレス:bcrt1qhzknya5w4qcyxnq0lkcwumu9py2c624ujv79f6)がいない
C:\Users\ebata\bitcoin>docker exec -it bitcoin_1 /bin/bash
root@bitcoin_1:/# ls
bin  boot  dev  etc  home  lib  lib64  media  mnt  opt  proc  root  run  sbin  srv  sys  tmp  usr  var
root@bitcoin_1:/#
root@bitcoin_1:/#
root@bitcoin_1:/#
root@bitcoin_1:/#
root@bitcoin_1:/#
root@bitcoin_1:/#
root@bitcoin_1:/# bitcoin-cli getbalance
50.00000000
root@bitcoin_1:/# bitcoin-cli getbalance "*"
50.00000000
root@bitcoin_1:/# bitcoin-cli getblockchaininfo
{
  "chain": "regtest",
  "blocks": 101,
  "headers": 101,
  "bestblockhash": "7114500ec4d179a09d609bde6cdf5d7c8f84920eca9d4f1efe102a3869591b37",
  "difficulty": 4.656542373906925e-10,
  "mediantime": 1602937028,
  "verificationprogress": 1,
  "initialblockdownload": false,
  "chainwork": "00000000000000000000000000000000000000000000000000000000000000cc",
  "size_on_disk": 30476,
  "pruned": false,
  "softforks": {
    "bip34": {
      "type": "buried",
      "active": false,
      "height": 500
    },
    "bip66": {
      "type": "buried",
      "active": false,
      "height": 1251
    },
    "bip65": {
      "type": "buried",
      "active": false,
      "height": 1351
    },
    "csv": {
      "type": "buried",
      "active": false,
      "height": 432
    },
    "segwit": {
      "type": "buried",
      "active": true,
      "height": 0
    },
    "testdummy": {
      "type": "bip9",
      "bip9": {
        "status": "defined",
        "start_time": 0,
        "timeout": 9223372036854775807,
        "since": 0
      },
      "active": false
    }
  },
  "warnings": ""
}
root@bitcoin_1:/# bitcoin-cli getconnectioncount
0
root@bitcoin_1:/# bitcoin-cli getpeerinfo
[
]
root@bitcoin_1:/# bitcoin-cli getnewaddress
bcrt1qa5wzz2pw85f670fsaqpg26thtddeh5dw6u33he

root@bitcoin_1:/# bitcoin-cli listtransactions
[
  {
    "address": "bcrt1qm7a39u23klsnmp332nz7kez2nhndced6ht23y8",
    "category": "immature",
    "amount": 50.00000000,
    "label": "",
    "vout": 0,
    "confirmations": 10,
    "generated": true,
    "blockhash": "318988c1b686efe428b3d4d9f711f26654a506007a30013d1946f01d3b21a1dd",
    "blockheight": 92,
    "blockindex": 0,
    "blocktime": 1602937028,
    "txid": "ad130241f06c44b88135b1847f8775ebccb73e849caa60bfe9e5db9a7588149b",
    "walletconflicts": [
    ],
    "time": 1602937011,
    "timereceived": 1602937011,
    "bip125-replaceable": "no"
  },
  {
    "address": "bcrt1qm7a39u23klsnmp332nz7kez2nhndced6ht23y8",
    "category": "immature",
    "amount": 50.00000000,
    "label": "",
    "vout": 0,
    "confirmations": 9,
    "generated": true,
    "blockhash": "00920ebf768761a74b9c6a89f3a16bbf5fc1cbea6f4c8af17eb3d7bdc1db45be",
    "blockheight": 93,
    "blockindex": 0,
    "blocktime": 1602937028,
    "txid": "4c2c637433cd55d7809ba3ae842abf91dc3f2795bfad11cd056ac84b13d48b3d",
    "walletconflicts": [
    ],
    "time": 1602937011,
    "timereceived": 1602937011,
    "bip125-replaceable": "no"
  },
  {
    "address": "bcrt1qm7a39u23klsnmp332nz7kez2nhndced6ht23y8",
    "category": "immature",
    "amount": 50.00000000,
    "label": "",
    "vout": 0,
    "confirmations": 8,
    "generated": true,
    "blockhash": "2f547f083680726977aa47a64303fd2fcf88c63e9ab6c0d983aab4e55dfa4011",
    "blockheight": 94,
    "blockindex": 0,
    "blocktime": 1602937028,
    "txid": "25e3578b8da9bc72acef85203d74bc1068bbd5b0f9e0611c07d9876a0cf85e56",
    "walletconflicts": [
    ],
    "time": 1602937011,
    "timereceived": 1602937011,
    "bip125-replaceable": "no"
  },
  {
    "address": "bcrt1qm7a39u23klsnmp332nz7kez2nhndced6ht23y8",
    "category": "immature",
    "amount": 50.00000000,
    "label": "",
    "vout": 0,
    "confirmations": 7,
    "generated": true,
    "blockhash": "2bfc89a56cec028ef08612e5a700b475baf73eb1d7404e3d4e18d22d0fb84871",
    "blockheight": 95,
    "blockindex": 0,
    "blocktime": 1602937028,
    "txid": "c8c75936d15030b0090dd10b2ed8d650d1fa7657c4fcc379aa9c9642eb626b04",
    "walletconflicts": [
    ],
    "time": 1602937011,
    "timereceived": 1602937011,
    "bip125-replaceable": "no"
  },
  {
    "address": "bcrt1qm7a39u23klsnmp332nz7kez2nhndced6ht23y8",
    "category": "immature",
    "amount": 50.00000000,
    "label": "",
    "vout": 0,
    "confirmations": 6,
    "generated": true,
    "blockhash": "67ee0490dde106367d715f5dedc13fa9a365b6551edeba1187f2fac260c91840",
    "blockheight": 96,
    "blockindex": 0,
    "blocktime": 1602937028,
    "txid": "c5f3031c90d5df19667019666d2cb994aaf8202d76b980f0f2a8f3c143ad353a",
    "walletconflicts": [
    ],
    "time": 1602937011,
    "timereceived": 1602937011,
    "bip125-replaceable": "no"
  },
  {
    "address": "bcrt1qm7a39u23klsnmp332nz7kez2nhndced6ht23y8",
    "category": "immature",
    "amount": 50.00000000,
    "label": "",
    "vout": 0,
    "confirmations": 5,
    "generated": true,
    "blockhash": "2ab1cff953dc2fecb4647bead68bdf8f27670e55989234ac77be1387437ad04e",
    "blockheight": 97,
    "blockindex": 0,
    "blocktime": 1602937028,
    "txid": "53fa062b9e0be60e9263e048e941759f09d820b02b1a9352d3ce64bf157c3545",
    "walletconflicts": [
    ],
    "time": 1602937011,
    "timereceived": 1602937011,
    "bip125-replaceable": "no"
  },
  {
    "address": "bcrt1qm7a39u23klsnmp332nz7kez2nhndced6ht23y8",
    "category": "immature",
    "amount": 50.00000000,
    "label": "",
    "vout": 0,
    "confirmations": 4,
    "generated": true,
    "blockhash": "699a01f27c9f4071ef5fa1db01ecee0b1cea4d717e936f5a689d90b82b40797c",
    "blockheight": 98,
    "blockindex": 0,
    "blocktime": 1602937029,
    "txid": "ee516eabe679ae6e54af57180deff4d91ce51c277c74e1b08618a5da56704242",
    "walletconflicts": [
    ],
    "time": 1602937011,
    "timereceived": 1602937011,
    "bip125-replaceable": "no"
  },
  {
    "address": "bcrt1qm7a39u23klsnmp332nz7kez2nhndced6ht23y8",
    "category": "immature",
    "amount": 50.00000000,
    "label": "",
    "vout": 0,
    "confirmations": 3,
    "generated": true,
    "blockhash": "50851ed32add0fa33db1b4f665ca8132f2109966811aff6a3b8f7f1d103d6165",
    "blockheight": 99,
    "blockindex": 0,
    "blocktime": 1602937029,
    "txid": "896f89d0db10a0a1b00bc0bda0e774fa8e46c20d539739b8f59df1adbb358b8f",
    "walletconflicts": [
    ],
    "time": 1602937011,
    "timereceived": 1602937011,
    "bip125-replaceable": "no"
  },
  {
    "address": "bcrt1qm7a39u23klsnmp332nz7kez2nhndced6ht23y8",
    "category": "immature",
    "amount": 50.00000000,
    "label": "",
    "vout": 0,
    "confirmations": 2,
    "generated": true,
    "blockhash": "25cc07422e00d859504bf4f7e072e9550d176860b5217c823cea5e93aef788c4",
    "blockheight": 100,
    "blockindex": 0,
    "blocktime": 1602937029,
    "txid": "47986d3580f9b9e1168f4e16cd78decf982ff7b1f75417025d69689eeb3bd9fd",
    "walletconflicts": [
    ],
    "time": 1602937011,
    "timereceived": 1602937011,
    "bip125-replaceable": "no"
  },
  {
    "address": "bcrt1qm7a39u23klsnmp332nz7kez2nhndced6ht23y8",
    "category": "immature",
    "amount": 50.00000000,
    "label": "",
    "vout": 0,
    "confirmations": 1,
    "generated": true,
    "blockhash": "7114500ec4d179a09d609bde6cdf5d7c8f84920eca9d4f1efe102a3869591b37",
    "blockheight": 101,
    "blockindex": 0,
    "blocktime": 1602937029,
    "txid": "f759b7afcf00a9d037e37193a3d74f8e91250ceef46a8d260fc66c304aa6dc86",
    "walletconflicts": [
    ],
    "time": 1602937011,
    "timereceived": 1602937011,
    "bip125-replaceable": "no"
  }
]

root@bitcoin_1:/# bitcoin-cli getpeerinfo
[
]
root@bitcoin_1:/# bitcoin-cli listtransactions
[
  {
    "address": "bcrt1qm7a39u23klsnmp332nz7kez2nhndced6ht23y8",
    "category": "immature",
    "amount": 50.00000000,
    "label": "",
    "vout": 0,
    "confirmations": 10,
    "generated": true,
    "blockhash": "318988c1b686efe428b3d4d9f711f26654a506007a30013d1946f01d3b21a1dd",
    "blockheight": 92,
    "blockindex": 0,
    "blocktime": 1602937028,
    "txid": "ad130241f06c44b88135b1847f8775ebccb73e849caa60bfe9e5db9a7588149b",
    "walletconflicts": [
    ],
    "time": 1602937011,
    "timereceived": 1602937011,
    "bip125-replaceable": "no"
  },
  {
    "address": "bcrt1qm7a39u23klsnmp332nz7kez2nhndced6ht23y8",
    "category": "immature",
    "amount": 50.00000000,
    "label": "",
    "vout": 0,
    "confirmations": 9,
    "generated": true,
    "blockhash": "00920ebf768761a74b9c6a89f3a16bbf5fc1cbea6f4c8af17eb3d7bdc1db45be",
    "blockheight": 93,
    "blockindex": 0,
    "blocktime": 1602937028,
    "txid": "4c2c637433cd55d7809ba3ae842abf91dc3f2795bfad11cd056ac84b13d48b3d",
    "walletconflicts": [
    ],
    "time": 1602937011,
    "timereceived": 1602937011,
    "bip125-replaceable": "no"
  },
  {
    "address": "bcrt1qm7a39u23klsnmp332nz7kez2nhndced6ht23y8",
    "category": "immature",
    "amount": 50.00000000,
    "label": "",
    "vout": 0,
    "confirmations": 8,
    "generated": true,
    "blockhash": "2f547f083680726977aa47a64303fd2fcf88c63e9ab6c0d983aab4e55dfa4011",
    "blockheight": 94,
    "blockindex": 0,
    "blocktime": 1602937028,
    "txid": "25e3578b8da9bc72acef85203d74bc1068bbd5b0f9e0611c07d9876a0cf85e56",
    "walletconflicts": [
    ],
    "time": 1602937011,
    "timereceived": 1602937011,
    "bip125-replaceable": "no"
  },
  {
    "address": "bcrt1qm7a39u23klsnmp332nz7kez2nhndced6ht23y8",
    "category": "immature",
    "amount": 50.00000000,
    "label": "",
    "vout": 0,
    "confirmations": 7,
    "generated": true,
    "blockhash": "2bfc89a56cec028ef08612e5a700b475baf73eb1d7404e3d4e18d22d0fb84871",
    "blockheight": 95,
    "blockindex": 0,
    "blocktime": 1602937028,
    "txid": "c8c75936d15030b0090dd10b2ed8d650d1fa7657c4fcc379aa9c9642eb626b04",
    "walletconflicts": [
    ],
    "time": 1602937011,
    "timereceived": 1602937011,
    "bip125-replaceable": "no"
  },
  {
    "address": "bcrt1qm7a39u23klsnmp332nz7kez2nhndced6ht23y8",
    "category": "immature",
    "amount": 50.00000000,
    "label": "",
    "vout": 0,
    "confirmations": 6,
    "generated": true,
    "blockhash": "67ee0490dde106367d715f5dedc13fa9a365b6551edeba1187f2fac260c91840",
    "blockheight": 96,
    "blockindex": 0,
    "blocktime": 1602937028,
    "txid": "c5f3031c90d5df19667019666d2cb994aaf8202d76b980f0f2a8f3c143ad353a",
    "walletconflicts": [
    ],
    "time": 1602937011,
    "timereceived": 1602937011,
    "bip125-replaceable": "no"
  },
  {
    "address": "bcrt1qm7a39u23klsnmp332nz7kez2nhndced6ht23y8",
    "category": "immature",
    "amount": 50.00000000,
    "label": "",
    "vout": 0,
    "confirmations": 5,
    "generated": true,
    "blockhash": "2ab1cff953dc2fecb4647bead68bdf8f27670e55989234ac77be1387437ad04e",
    "blockheight": 97,
    "blockindex": 0,
    "blocktime": 1602937028,
    "txid": "53fa062b9e0be60e9263e048e941759f09d820b02b1a9352d3ce64bf157c3545",
    "walletconflicts": [
    ],
    "time": 1602937011,
    "timereceived": 1602937011,
    "bip125-replaceable": "no"
  },
  {
    "address": "bcrt1qm7a39u23klsnmp332nz7kez2nhndced6ht23y8",
    "category": "immature",
    "amount": 50.00000000,
    "label": "",
    "vout": 0,
    "confirmations": 4,
    "generated": true,
    "blockhash": "699a01f27c9f4071ef5fa1db01ecee0b1cea4d717e936f5a689d90b82b40797c",
    "blockheight": 98,
    "blockindex": 0,
    "blocktime": 1602937029,
    "txid": "ee516eabe679ae6e54af57180deff4d91ce51c277c74e1b08618a5da56704242",
    "walletconflicts": [
    ],
    "time": 1602937011,
    "timereceived": 1602937011,
    "bip125-replaceable": "no"
  },
  {
    "address": "bcrt1qm7a39u23klsnmp332nz7kez2nhndced6ht23y8",
    "category": "immature",
    "amount": 50.00000000,
    "label": "",
    "vout": 0,
    "confirmations": 3,
    "generated": true,
    "blockhash": "50851ed32add0fa33db1b4f665ca8132f2109966811aff6a3b8f7f1d103d6165",
    "blockheight": 99,
    "blockindex": 0,
    "blocktime": 1602937029,
    "txid": "896f89d0db10a0a1b00bc0bda0e774fa8e46c20d539739b8f59df1adbb358b8f",
    "walletconflicts": [
    ],
    "time": 1602937011,
    "timereceived": 1602937011,
    "bip125-replaceable": "no"
  },
  {
    "address": "bcrt1qm7a39u23klsnmp332nz7kez2nhndced6ht23y8",
    "category": "immature",
    "amount": 50.00000000,
    "label": "",
    "vout": 0,
    "confirmations": 2,
    "generated": true,
    "blockhash": "25cc07422e00d859504bf4f7e072e9550d176860b5217c823cea5e93aef788c4",
    "blockheight": 100,
    "blockindex": 0,
    "blocktime": 1602937029,
    "txid": "47986d3580f9b9e1168f4e16cd78decf982ff7b1f75417025d69689eeb3bd9fd",
    "walletconflicts": [
    ],
    "time": 1602937011,
    "timereceived": 1602937011,
    "bip125-replaceable": "no"
  },
  {
    "address": "bcrt1qm7a39u23klsnmp332nz7kez2nhndced6ht23y8",
    "category": "immature",
    "amount": 50.00000000,
    "label": "",
    "vout": 0,
    "confirmations": 1,
    "generated": true,
    "blockhash": "7114500ec4d179a09d609bde6cdf5d7c8f84920eca9d4f1efe102a3869591b37",
    "blockheight": 101,
    "blockindex": 0,
    "blocktime": 1602937029,
    "txid": "f759b7afcf00a9d037e37193a3d74f8e91250ceef46a8d260fc66c304aa6dc86",
    "walletconflicts": [
    ],
    "time": 1602937011,
    "timereceived": 1602937011,
    "bip125-replaceable": "no"
  }
]
root@bitcoin_1:/# bitcoin-cli getnewaddress
bcrt1qfleh8qu94p6ec98pkvdqutumt89slr8pfp67x6

root@bitcoin_1:/# bitcoin-cli getnewaddress tomoichi
bcrt1qlqvsucx8kgaz7nqytke7x5af0ggp8xhk30ynxe
root@bitcoin_1:/# bitcoin-cli getbalance
50.00000000
root@bitcoin_1:/# bitcoin-cli listunspent
[
  {
    "txid": "82a2f72c85876bc460d55002edbb5ef6ad160485da1ea56ee53294d2f30a7136",
    "vout": 0,
    "address": "bcrt1qm7a39u23klsnmp332nz7kez2nhndced6ht23y8",
    "label": "",
    "scriptPubKey": "0014dfbb12f151b7e13d863154c5eb644a9de6dc65ba",
    "amount": 50.00000000,
    "confirmations": 101,
    "spendable": true,
    "solvable": true,
    "desc": "wpkh([51903fd0/0'/0'/1']0324020359d38db9f89d1e75fe3a3406b5e66d806214141e0c0ba76b685d08ff4b)#y8d0fgk6",
    "safe": true
  }
]

root@bitcoin_1:/# bitcoind -version
Bitcoin Core version v0.20.1.0-g7ff64311bee570874c4f0dfa18f518552188df08
Copyright (C) 2009-2020 The Bitcoin Core developers

Please contribute if you find Bitcoin Core useful. Visit
<https://bitcoincore.org/> for further information about the software.
The source code is available from <https://github.com/bitcoin/bitcoin>.

This is experimental software.
Distributed under the MIT software license, see the accompanying file COPYING
or <https://opensource.org/licenses/MIT>

root@bitcoin_1:/# bitcoin-cli -getinfo
{
  "version": 200100,
  "blocks": 101,
  "headers": 101,
  "verificationprogress": 1,
  "timeoffset": 0,
  "connections": 0,
  "proxy": "",
  "difficulty": 4.656542373906925e-10,
  "chain": "regtest",
  "balance": 50.00000000,
  "keypoolsize": 999,
  "paytxfee": 0.00000000,
  "relayfee": 0.00001000,
  "warnings": ""
}
root@bitcoin_1:/# bitcoin-cli getblockchaininfo
{
  "chain": "regtest",
  "blocks": 101,
  "headers": 101,
  "bestblockhash": "7114500ec4d179a09d609bde6cdf5d7c8f84920eca9d4f1efe102a3869591b37",
  "difficulty": 4.656542373906925e-10,
  "mediantime": 1602937028,
  "verificationprogress": 1,
  "initialblockdownload": false,
  "chainwork": "00000000000000000000000000000000000000000000000000000000000000cc",
  "size_on_disk": 30476,
  "pruned": false,
  "softforks": {
    "bip34": {
      "type": "buried",
      "active": false,
      "height": 500
    },
    "bip66": {
      "type": "buried",
      "active": false,
      "height": 1251
    },
    "bip65": {
      "type": "buried",
      "active": false,
      "height": 1351
    },
    "csv": {
      "type": "buried",
      "active": false,
      "height": 432
    },
    "segwit": {
      "type": "buried",
      "active": true,
      "height": 0
    },
    "testdummy": {
      "type": "bip9",
      "bip9": {
        "status": "defined",
        "start_time": 0,
        "timeout": 9223372036854775807,
        "since": 0
      },
      "active": false
    }
  },
  "warnings": ""
}

root@bitcoin_1:/# bitcoin-cli getblockhash 100
25cc07422e00d859504bf4f7e072e9550d176860b5217c823cea5e93aef788c4
root@bitcoin_1:/# bitcoin-cli getblock 25cc07422e00d859504bf4f7e072e9550d176860b5217c823cea5e93aef788c4
{
  "hash": "25cc07422e00d859504bf4f7e072e9550d176860b5217c823cea5e93aef788c4",
  "confirmations": 2,
  "strippedsize": 214,
  "size": 250,
  "weight": 892,
  "height": 100,
  "version": 536870912,
  "versionHex": "20000000",
  "merkleroot": "47986d3580f9b9e1168f4e16cd78decf982ff7b1f75417025d69689eeb3bd9fd",
  "tx": [
    "47986d3580f9b9e1168f4e16cd78decf982ff7b1f75417025d69689eeb3bd9fd"
  ],
  "time": 1602937029,
  "mediantime": 1602937028,
  "nonce": 3,
  "bits": "207fffff",
  "difficulty": 4.656542373906925e-10,
  "chainwork": "00000000000000000000000000000000000000000000000000000000000000ca",
  "nTx": 1,
  "previousblockhash": "50851ed32add0fa33db1b4f665ca8132f2109966811aff6a3b8f7f1d103d6165",
  "nextblockhash": "7114500ec4d179a09d609bde6cdf5d7c8f84920eca9d4f1efe102a3869591b37"
}
root@bitcoin_1:/# bitcoin-cli getblockcount
101
root@bitcoin_1:/# bitcoin-cli getbestblockhash
7114500ec4d179a09d609bde6cdf5d7c8f84920eca9d4f1efe102a3869591b37

root@bitcoin_1:/# bitcoin-cli getaddressesbylabel tomoichi
{
  "bcrt1qlqvsucx8kgaz7nqytke7x5af0ggp8xhk30ynxe": {
    "purpose": "receive"
  }
}

root@bitcoin_1:/# bitcoin-cli listlabels
[
  "",
  "tomoichi"
]
root@bitcoin_1:/#

2020/10,江端さんの技術メモ

常日頃から御指導頂いているSさんから、Bad Elf 2300の位置情報をキャプチャするhtmlファイルの内容を教えて頂いた。忘れないように、残しておく。

Bad ElfをBTでリンクしたiPadで稼働を確認済み(iPhoneでは稼働確認できなかった)

<!DOCTYPE html>
<html lang="ja">
<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1, maximum-scale=1">
    <title>geolocation-sample</title>
</head>
<body>
  <div id="output"></div>
 
<script>
    var output = document.getElementById('output');
 
    // 位置情報の取得に成功した際のコールバック
    const successCallback = (position) => {
        console.log(position);
		output.innerHTML += "<P>==========";
		output.innerHTML += "<P>time:" + position.timestamp;
		output.innerHTML += "<P>latitude:" + position.coords.latitude;
		output.innerHTML += "<P>longitude:" + position.coords.longitude;
		output.innerHTML += "<P>altitude:" + position.coords.altitude;
		output.innerHTML += "<P>accuracy:" + position.coords.accuracy;
		output.innerHTML += "<P>altitudeAccuracy:" + position.coords.altitudeAccuracy;
		output.innerHTML += "<P>heading:" + position.coords.heading;	
		output.innerHTML += "<P>speed:" + position.coords.speeed;	
    };
 
    // 位置情報の取得に失敗した際のコールバック
    const errorCallback = (err) => {
        console.log(err);
		output.innerHTML += "Error\n";		
    };
 
    // 位置を監視する構成オプション
    // オプションの内容は次のリンクに書かれています。
    // https://developer.mozilla.org/ja/docs/Web/API/PositionOptions
    const options = {
        enableHighAccuracy: true,
        timeout: 5000,
        maximumAge: 0
    };
 
    let watchPositionID;
 
    window.onload = () => {
        // navigator.geolocation.watchPositionについては次のURLにかかれています。
        // https://developer.mozilla.org/ja/docs/Web/API/Geolocation/watchPosition
        watchPositionID = navigator.geolocation.watchPosition(successCallback, errorCallback, options);
    };
 
    // ブラウザーを閉じる前に位置の監視を止めます
    window.onbeforeunload = () => {
        navigator.geolocation.clearWatch(watchPositionID);
    }
</script>
</body>
</html>

2020/10,江端さんの技術メモ

ワーシャル-フロイド法
(ダイクストラは個別ルートでは早いが、先に全ルート計算しておくなら、
こっちの方法の法が速いこともある)

と、

STLのリストの使い方(ファンクションへのリストの渡し方とか、リストの複製の作り方とか)
などの、便利な技が仕込まれているので貼っておく

/*
  g++ -g wf.cpp -o wf
 
  ワーシャル-フロイド法
  (ダイクストラは個別ルートでは早いが、先に全ルート計算しておくなら、
  こっちの方法の法が速いこともある)
  
  と、

  STLのリストの使い方(ファンクションへのリストの渡し方とか、リストの複製の作り方とか)
  などの、便利な技が仕込まれているので貼っておく


 
*/
 
#include <stdio.h>
#include <stdlib.h>
#include <iostream>
#include <list>   // list 利用のため

using namespace std;

//int d[100][100];  // d[i][k]:ノードiからノードkへの距離 
//int via[100][100];  // d[i][k]の間にある(少くとも1つの)中継ノード

double d[100][100];  // d[i][k]:ノードiからノードkへの距離 
int via[100][100];  //  d[i][k]の間にある(少くとも1つの)中継ノード

list<int> path[100][100];   // int 型の list を宣言  
 

#if 1
// 中継パスの表示ルーチン(再帰呼出し用)
void printPath1_aux(int begin, int end) {
  if (via[begin][end] == begin) {
	if (begin != end)
	  printf("%02d -> ", begin);
	return;
  }
  
  printPath1_aux(begin, via[begin][end]);
  printPath1_aux(via[begin][end], end);
}
#endif

// 中継パスの表示ルーチン(再帰呼出し用)
void printPath1_aux(int begin, int end, list<int>* p) {
  if (via[begin][end] == begin) {
	if (begin != end){
	  // printf("%02d -> ", begin);
	  p->push_back(begin);
	}
	return;
  }
  
  printPath1_aux(begin, via[begin][end], p);
  printPath1_aux(via[begin][end], end, p);
}


 
// 中継パスの表示ルーチン
#if 1
void printPath1(int start, int goal) {
  printPath1_aux(start, via[start][goal]);
  printPath1_aux(via[start][goal], goal);
  printf("%02d\n", goal);
}
#endif 

void printPath1(int start, int goal, list<int> *p ) {
  printPath1_aux(start, via[start][goal], p);
  printPath1_aux(via[start][goal], goal, p);
  // printf("%02d\n", goal);
  p->push_back(goal);

}

 
int main(void)
{
  // 変数の初期化
  for(int i = 0; i < 100; i++){
	for(int j = 0; j < 100; j++){
	  d[i][j] = 999.9; // 距離の初期化(でっかい値を入力しておく(INT_MAXは足し算の時に桁上がりが起こるので使わない)
	  via[i][j] = i; // ノードiからノードkへの経由値の初期化 
	}
  }
 
 #if 0
  // 確認用の表示
  printf("\n[STEP1]\n");
 
  for(int i = 0; i < 100; i++){
	for(int k = 0; k < 100; k++){
	  printf("d[%d][%d]):%f\t",i,k,d[i][k]);
	  printf("via[%d][%d]):%d\n",i,k,via[i][k]);
	}
  }
#endif

  //// ここからは実際の距離を手書き
 
  for(int i = 0; i < 100; i++){
	d[i][i] = 0; //// 同じノードへの距離は0になるので、上書き
  }
 
  //ノード番号の通番を以下のようにする
  // [0][2] → "02", [4][9] → "49", [9][[9] → "99"
  // 座標は1ケタ内に留める

  for (int y = 0; y < 5; y++){
	for (int x = 0; x < 9; x++){

	  int n_num = x * 10 + y;

	  // + ( 1, 0)
	  int x_new = x + 1;
	  int y_new = y;

	  if (x_new < 9){
		int n_num_next = x_new * 10 + y_new;
		d[n_num][n_num_next] = 0.069;
		
		printf("1:d[%02d][%02d]=%f\n",n_num, n_num_next, d[n_num][n_num_next]);

	  }

	  // + (-1, 0)
	  x_new = x - 1;
	  y_new = y;

	  if (x_new > -1 ){
		int n_num_next = x_new * 10 + y_new;
		d[n_num][n_num_next] = 0.069;
		printf("2:d[%02d][%02d]=%f\n",n_num, n_num_next, d[n_num][n_num_next]);
	  }

	  // + ( 0, 1)
	  x_new = x;
	  y_new = y + 1;

	  if (y_new < 5 ){
		int n_num_next = x_new * 10 + y_new;
		d[n_num][n_num_next] = 0.069;
		printf("3:d[%02d][%02d]=%f\n",n_num, n_num_next, d[n_num][n_num_next]);
	  }

	  // + ( 0,-1)
	  x_new = x;
	  y_new = y - 1;

	  if (y_new > -1 ){
		int n_num_next = x_new * 10 + y_new;
		d[n_num][n_num_next] = 0.069;
		printf("4:d[%02d][%02d]=%f\n",n_num, n_num_next, d[n_num][n_num_next]);
	  }
	}
  }

  // 実験用上書き
  d[02][12] = 0.025;  
  d[12][22] = 0.025;  
  d[22][32] = 0.025;  
  d[32][42] = 0.025;  
  d[42][52] = 0.025;  
  d[52][62] = 0.025;  
  d[62][72] = 0.025;  
  d[72][82] = 0.025;  

  d[12][02] = 0.025;  
  d[22][12] = 0.025;  
  d[32][22] = 0.025;  
  d[42][32] = 0.025;  
  d[52][42] = 0.025;  
  d[62][52] = 0.025;  
  d[72][62] = 0.025;  
  d[82][72] = 0.025;  


#if 1
  // 確認用の表示
  printf("\n[STEP2]\n");
 
  for(int i = 0; i < 99; i++){
	for(int k = 0; k < 99; k++){
	  printf("d[%d][%d]):%f\t",i,k,d[i][k]);
	  printf("via[%d][%d]):%d\n",i,k,via[i][k]);
	}
  }
#endif
 

  // 経路長計算
  for (int k =0; k < 99; k++){  
	for (int i =0; i < 99; i++){
	  for(int j = 0; j < 99; j++){
		if(d[i][j] > d[i][k] + d[k][j]){
		  d[i][j] = d[i][k] + d[k][j];
		  via[i][j] = k; //更新処理
		}
	  }
	}
  }

 
#if 0
  // 計算結果
  printf("\n[STEP3]\n");
 
  for(int i = 0; i < 99; i++){
	for(int k = 0; k < 99; k++){
	  printf("d[%d][%d]):%f\t",i,k,d[i][k]);
	  printf("via[%d][%d]):%d\n",i,k,via[i][k]);
	}
  }
#endif 

#if 1
  // 経路パス表示
  printf("\n[Path]\n");
  for(int i = 0; i < 99; i++){
	for(int k = 0; k < 99; k++){
	  if (d[i][k] < 99.9){
		printf("d[%02d][%02d]:%f ",i,k,d[i][k]);
		printPath1(i, k);
		printPath1(i, k, &(path[i][k]));
	  }
	}
  }
#endif
  
  
  // イテレータ (反復子) の定義
  list<int>::iterator pos;

  list<int> l = path[83][04];
  // イテレータをずらしながら、全てのデータを取り出す。
  for(pos = l.begin(); pos!=l.end(); ++pos){
      cout << *pos << "\n";
  }

  printf("\n");


  // https://cpprefjp.github.io/reference/algorithm/copy.html
  // back_inserter を使って l2 へ設定。
  // back_inserter は要素をコピーするときに l2.push_back() するイテレータを作る関数。

  //std::list<int> l2;
  list<int> l2;  

  //std::copy(l.begin(), l.end(), back_inserter(l2));
  copy(l.begin(), l.end(), back_inserter(l2));

  // l2.erase(v.begin() + 2);       //  3番目の要素(9)を削除
  l2.erase(l2.begin());       // 先頭の要素を削除


  for(pos = l2.begin(); pos!=l2.end(); ++pos){
      cout << *pos << "\n";
  }


}