t_wの輪郭

Feedlyでフォローするボタン
YugabyteDB2025年4月6日
あれyugabyte-pod.yamlあれあれあれあれ

あれ

2025/4/6 14:08:00

「YugabyteDB試すついでに、podman-kubeの勉強もしちゃお」ってやったら見事にkubernetesわからんくて撃沈した。

後日kube使わずにYugabyteDBやる。

やっぱり未経験の技術を複数同時に進めるのはうまくいかない。

あれ

2025/4/6 12:40:00

YugabeteDBで単一のノードが動くところまでは確かめられたので、複数ノードを試していく。

あれ

2025/4/6 11:40:00

わぁい

PS C:\Users\tw\work\try\yube> podman exec -it yugabyte-pod-yugabyted yugabyted status

+--------------------------------------------------------------------------------------------------------+
|                                               yugabyted                                                |
+--------------------------------------------------------------------------------------------------------+
| Status              : Running.                                                                         |
| YSQL Status         : Ready                                                                            |
| Replication Factor  : 1                                                                                |
| YugabyteDB UI       : http://10.89.0.9:15433                                                           |
| JDBC                : jdbc:postgresql://10.89.0.9:5433/yugabyte?user=yugabyte&password=yugabyte        |
| YSQL                : bin/ysqlsh -h 10.89.0.9  -U yugabyte -d yugabyte                                 |
| YCQL                : bin/ycqlsh 10.89.0.9 9042 -u cassandra                                           |
| Data Dir            : /root/var/data                                                                   |
| Log Dir             : /root/var/logs                                                                   |
| Universe UUID       : 85286c81-f9bb-4bb3-aa66-3dc0604dc45c                                             |
+--------------------------------------------------------------------------------------------------------+
PS C:\Users\tw\work\try\yube> podman exec -it yugabyte-pod-yugabyted ysqlsh -h 10.89.0.9  -U yugabyte -d yugabyte
ysqlsh (15.2-YB-2.25.1.0-b0)
Type "help" for help.

yugabyte=# SELECT 42;
 ?column?
----------
       42
(1 row)

yugabyte=# exit
PS C:\Users\tw\work\try\yube> psql -h localhost -p 5433 -U yugabyte
psql (17.4, server 15.2-YB-2.25.1.0-b0)
Type "help" for help.

yugabyte=# SELECT 42;
 ?column?
----------
       42
(1 row)


yugabyte=# exit

yugabyte-pod.yaml

2025/4/6 11:33:00

yugabyte-pod.yaml

apiVersion: v1
kind: Pod
metadata:
  annotations:
    io.kubernetes.cri-o.SandboxID/yugabyted: 5b7a8a7dd16ecc351fe28affd5556d6603e80b0adfb4d52f89b47ce188a69e36
  creationTimestamp: "2025-04-06T02:25:32Z"
  labels:
    app: yugabyte-pod
  name: yugabyte-pod
spec:
  containers:
  - args:
    - yugabyted
    - start
    - --daemon=false
    env:
    - name: TERM
      value: xterm
    image: docker.io/yugabytedb/yugabyte:latest
    name: yugabyted
    ports:
    - containerPort: 5433
      hostPort: 5433
    - containerPort: 15433
      hostPort: 15433
    securityContext: {}
    tty: true
    volumeMounts:
    - mountPath: /mnt/disk0
      name: de03ab176ebb69ce40528b3fec54f4d2266a6a761f11875fb9effaff3406143d-pvc
    - mountPath: /mnt/disk1
      name: 09c3e8b43afc0af0ffdcce861a65a6b8a61a556663fda1e98003c9971e667da3-pvc
  volumes:
  - name: de03ab176ebb69ce40528b3fec54f4d2266a6a761f11875fb9effaff3406143d-pvc
    persistentVolumeClaim:
      claimName: de03ab176ebb69ce40528b3fec54f4d2266a6a761f11875fb9effaff3406143d
  - name: 09c3e8b43afc0af0ffdcce861a65a6b8a61a556663fda1e98003c9971e667da3-pvc
    persistentVolumeClaim:
      claimName: 09c3e8b43afc0af0ffdcce861a65a6b8a61a556663fda1e98003c9971e667da3

あれ

2025/4/6 9:28:00

YugabyteDB試してみてる。
Grokの言いなりをやったらSQL叩けるところまできた。