SQLite
をテンプレートにして作成
[
トップ
] [
タイトル一覧
|
ページ一覧
|
新規
|
検索
|
最終更新
|
ヘルプ
|
ログイン
]
開始行:
** SQLite [#q1ed9503]
- http://www.sqlite.org/
*** Install [#e3a9970d]
zcat sqlite-3.6.21.tar.gz |tar xfv -
mkdir sqlite_build
cd sqlite_build
../sqlite-3.6.21/configure
make
make install
*** 操作 [#bcacf2b8]
- sqlite3 ~.db
- .database
- .tables
- .quit
- .help
**** example
<pre>
sqlite3 /var/lib/jupyterhub/jupyterhub.sqlite
sqlite> .tables
alembic_version oauth_clients service_role_map spa...
api_tokens oauth_codes services use...
group_role_map roles share_codes use...
groups servers shares users
sqlite> .schema users
CREATE TABLE users (
id INTEGER NOT NULL,
name VARCHAR(255),
admin BOOLEAN,
created DATETIME,
last_activity DATETIME,
cookie_id VARCHAR(255) NOT NULL,
state TEXT,
encrypted_auth_state BLOB,
CONSTRAINT pk_users PRIMARY KEY (id),
CONSTRAINT uq_users_name UNIQUE (name),
CONSTRAINT uq_users_cookie_id UNIQUE (cookie_id)
);
sqlite> .mode line
sqlite> select * from users;
.....
.....
.....
sqlite> select * from spawners;
id = 1
user_id = 2
server_id = 1
state = {"object_id": "8ba99eacf5221c9e2336f2d6...
name =
started = 2024-12-13 07:45:44.824935
last_activity = 2024-12-13 16:45:50.000000
user_options =
oauth_client_id = jupyterhub-user-iseki
sqlite>
</pre>
*** Troubleshooting [#k0d69195]
- Monoなどを使用していて,「sqlite3_column_origin_name関...
make OPTS=-DSQLITE_ENABLE_COLUMN_METADATA=1
**** Memo
sqlite> select * from alembic_version;
version_num = 4621fec11365
[root@castor5 jupyterhub]:1033# docker ps -a
Emulate Docker CLI using podman. Create /etc/containers/n...
CONTAINER ID IMAGE ...
d57342bbd8f0 localhost/jupyterhub-ltictr/singleuser:2024...
426b61ca2ec6 localhost/jupyterhub-ltictr/datascience-not...
[root@castor5 jupyterhub]:1036# docker ps
Emulate Docker CLI using podman. Create /etc/containers/n...
CONTAINER ID IMAGE ...
d57342bbd8f0 localhost/jupyterhub-ltictr/singleuser:2024...
3cf6728b4c7f localhost/jupyterhub-ltictr/singleuser:2024...
sqlite> select * from alembic_version;
version_num = 4621fec11365
sqlite> select * from oauth_clients;
id = 1
identifier = jupyterhub
description = JupyterHub
secret =
redirect_uri =
allowed_scopes = []
sqlite> select * from oauth_clients;
id = 1
identifier = jupyterhub
description = JupyterHub
secret =
redirect_uri =
allowed_scopes = []
sqlite> select * from service_role_map;
service_id = 1
role_id = 2
managed_by_auth = 0
service_id = 2
role_id = 5
managed_by_auth = 0
sqlite> select * from spawners;
id = 1
user_id = 2
server_id =
state =
name =
started =
last_activity =
user_options =
oauth_client_id =
終了行:
** SQLite [#q1ed9503]
- http://www.sqlite.org/
*** Install [#e3a9970d]
zcat sqlite-3.6.21.tar.gz |tar xfv -
mkdir sqlite_build
cd sqlite_build
../sqlite-3.6.21/configure
make
make install
*** 操作 [#bcacf2b8]
- sqlite3 ~.db
- .database
- .tables
- .quit
- .help
**** example
<pre>
sqlite3 /var/lib/jupyterhub/jupyterhub.sqlite
sqlite> .tables
alembic_version oauth_clients service_role_map spa...
api_tokens oauth_codes services use...
group_role_map roles share_codes use...
groups servers shares users
sqlite> .schema users
CREATE TABLE users (
id INTEGER NOT NULL,
name VARCHAR(255),
admin BOOLEAN,
created DATETIME,
last_activity DATETIME,
cookie_id VARCHAR(255) NOT NULL,
state TEXT,
encrypted_auth_state BLOB,
CONSTRAINT pk_users PRIMARY KEY (id),
CONSTRAINT uq_users_name UNIQUE (name),
CONSTRAINT uq_users_cookie_id UNIQUE (cookie_id)
);
sqlite> .mode line
sqlite> select * from users;
.....
.....
.....
sqlite> select * from spawners;
id = 1
user_id = 2
server_id = 1
state = {"object_id": "8ba99eacf5221c9e2336f2d6...
name =
started = 2024-12-13 07:45:44.824935
last_activity = 2024-12-13 16:45:50.000000
user_options =
oauth_client_id = jupyterhub-user-iseki
sqlite>
</pre>
*** Troubleshooting [#k0d69195]
- Monoなどを使用していて,「sqlite3_column_origin_name関...
make OPTS=-DSQLITE_ENABLE_COLUMN_METADATA=1
**** Memo
sqlite> select * from alembic_version;
version_num = 4621fec11365
[root@castor5 jupyterhub]:1033# docker ps -a
Emulate Docker CLI using podman. Create /etc/containers/n...
CONTAINER ID IMAGE ...
d57342bbd8f0 localhost/jupyterhub-ltictr/singleuser:2024...
426b61ca2ec6 localhost/jupyterhub-ltictr/datascience-not...
[root@castor5 jupyterhub]:1036# docker ps
Emulate Docker CLI using podman. Create /etc/containers/n...
CONTAINER ID IMAGE ...
d57342bbd8f0 localhost/jupyterhub-ltictr/singleuser:2024...
3cf6728b4c7f localhost/jupyterhub-ltictr/singleuser:2024...
sqlite> select * from alembic_version;
version_num = 4621fec11365
sqlite> select * from oauth_clients;
id = 1
identifier = jupyterhub
description = JupyterHub
secret =
redirect_uri =
allowed_scopes = []
sqlite> select * from oauth_clients;
id = 1
identifier = jupyterhub
description = JupyterHub
secret =
redirect_uri =
allowed_scopes = []
sqlite> select * from service_role_map;
service_id = 1
role_id = 2
managed_by_auth = 0
service_id = 2
role_id = 5
managed_by_auth = 0
sqlite> select * from spawners;
id = 1
user_id = 2
server_id =
state =
name =
started =
last_activity =
user_options =
oauth_client_id =
ページ名: