- 浏览: 2542448 次
- 性别:
- 来自: 成都
文章分类
最新评论
-
nation:
你好,在部署Mesos+Spark的运行环境时,出现一个现象, ...
Spark(4)Deal with Mesos -
sillycat:
AMAZON Relatedhttps://www.godad ...
AMAZON API Gateway(2)Client Side SSL with NGINX -
sillycat:
sudo usermod -aG docker ec2-use ...
Docker and VirtualBox(1)Set up Shared Disk for Virtual Box -
sillycat:
Every Half an Hour30 * * * * /u ...
Build Home NAS(3)Data Redundancy -
sillycat:
3 List the Cron Job I Have>c ...
Build Home NAS(3)Data Redundancy
Sqlite Database 2019(1)Sqlite3 Installation and Docker phpsqliteadmin
Install SQLite database
On MAC, it already there
> sqlite3 -version
3.24.0 2018-06-04 14:10:15
On Ubuntu, it is already there as well
> sqlite3 -version
3.22.0 2018-01-22 18:45:57
On CentOS 7, it is already there as well
> sqlite3 -version
3.7.17 2013-05-20
We can also download from here
https://www.sqlite.org/download.html
> wget https://www.sqlite.org/2019/sqlite-autoconf-3290000.tar.gz
> tar zxvf sqlite-autoconf-3290000.tar.gz
Compile and install
> cd sqlite-autoconf-3290000
> ./configure --prefix=/usr/local
> make
> sudo make install
Check version again
> sqlite3 -version
3.29.0 2019-07-10
Command line tool to open one sqlite database file
> sqlite3 ./SpiderKeeper.db
Check all tables
> .tables
sk_job_execution sk_job_instance sk_project sk_spider
Exit if needed
> sqlite> .quit
Check database schema
> .schema sk_spider
CREATE TABLE sk_spider (
id INTEGER NOT NULL,
date_created DATETIME,
date_modified DATETIME,
spider_name VARCHAR(100),
project_id INTEGER NOT NULL,
PRIMARY KEY (id)
);
CREATE INDEX ix_sk_spider_project_id ON sk_spider (project_id);
> .schema sk_project
CREATE TABLE sk_project (
id INTEGER NOT NULL,
date_created DATETIME,
date_modified DATETIME,
project_name VARCHAR(50),
PRIMARY KEY (id)
);
> .schema sk_job_instance
CREATE TABLE sk_job_instance (
id INTEGER NOT NULL,
date_created DATETIME,
date_modified DATETIME,
spider_name VARCHAR(100) NOT NULL,
project_id INTEGER NOT NULL,
tags TEXT,
spider_arguments TEXT,
priority INTEGER,
"desc" TEXT,
cron_minutes VARCHAR(20),
cron_hour VARCHAR(20),
cron_day_of_month VARCHAR(20),
cron_day_of_week VARCHAR(20),
cron_month VARCHAR(20),
enabled INTEGER,
run_type VARCHAR(20),
PRIMARY KEY (id)
);
CREATE INDEX ix_sk_job_instance_spider_name ON sk_job_instance (spider_name);
CREATE INDEX ix_sk_job_instance_project_id ON sk_job_instance (project_id);
> .schema sk_job_execution
CREATE TABLE sk_job_execution (
id INTEGER NOT NULL,
date_created DATETIME,
date_modified DATETIME,
project_id INTEGER NOT NULL,
service_job_execution_id VARCHAR(50) NOT NULL,
job_instance_id INTEGER NOT NULL,
create_time DATETIME,
start_time DATETIME,
end_time DATETIME,
running_status INTEGER,
running_on TEXT,
PRIMARY KEY (id)
);
CREATE INDEX ix_sk_job_execution_project_id ON sk_job_execution (project_id);
CREATE INDEX ix_sk_job_execution_service_job_execution_id ON sk_job_execution (service_job_execution_id);
CREATE INDEX ix_sk_job_execution_job_instance_id ON sk_job_execution (job_instance_id);
There is a webUI tool, haha. I should use command line, but UI is easy as well.
https://www.phpliteadmin.org/
Currently, stable version is 1.9.8 https://www.phpliteadmin.org/download/
Then I get the file named phpLiteAdmin_v1-9-8.zip
Create directory, Unzip the file in that directory
> mkdir phpliteadmin-1.9.8
> unzip phpLiteAdmin_v1-9-8.zip
It seems need php and web server for that following this https://bitbucket.org/phpliteadmin/public/wiki/Installation
It may be better to directly use this docker
https://github.com/shadowcodex/phpliteadmin
> git clone https://github.com/shadowcodex/phpliteadmin
Use a text editor to change the configuration, I use sublime here, or you can directly use vi on the server
> subl phpliteadmin/
Make sure I have docker on my CentOS
> sudo yum install docker-ce
> sudo usermod -aG docker $(whoami)
> sudo systemctl enable docker.service
> sudo systemctl start docker.service
If there is permission issue, you may need to restart the machines.
If we can not find the docker-ce package there “ No package docker-ce available."
Solution:
https://docs.docker.com/v17.09/engine/installation/linux/docker-ce/centos/#install-using-the-repository
> sudo yum install -y yum-utils device-mapper-persistent-data lvm2
> sudo yum-config-manager --add-repo https://download.docker.com/linux/centos/docker-ce.repo
Then the install command will work
> sudo yum install docker-ce
Go to the directory of phpliteadmin
> chmod a+x go.sh
Start the service
> ./go.sh /home/carl/data
It is running fine now
> docker ps
CONTAINER ID IMAGE COMMAND CREATED STATUS PORTS NAMES
1af127d6da44 shadowcodex/phpliteadmin "/bin/parent caddy -…" 3 seconds ago Up 2 seconds 80/tcp, 443/tcp, 0.0.0.0:2015->2015/tcp websql
Visit the webpage from this URL
http://centos-dev1:2015/phpliteadmin.php
Change the configuration, specially password here
> vi phpliteadmin.config.php
Restart the service
> ./go.sh /home/carl/data
The password is not working as designed. Open the debug=true, and I saw this in the logging
2019-09-04T22:55:22.608410410Z 04/Sep/2019:22:55:22 +0000 [ERROR 0 /phpliteadmin.php] PHP message: PHP Deprecated: crypt(): Supplied salt is not valid for DES. Possible bug in provided salt format. in /srv/phpliteadmin.php on line 4194
Plan to build the ENV my own, Check my PHP
Content in info.php
<?php phpinfo();?>
http://localhost:8081/info.php
Unzip the latest file
> unzip phpLiteAdmin_v1-9-8-1.zip
Copy them to my html directory
> cp ~/install/phpliteadmin.php ./html/
> cp ~/install/phpliteadmin.config.sample.php ./html/phpliteadmin.config.php
The docker thing is just normal php7, put the phpsqliteadmin under the html directory, that is it.
Check my centos7-sqlitephpadmin
References:
https://www.sqlite.org/download.html
https://www.yiibai.com/sqlite/installation.html
https://bitbucket.org/phpliteadmin/public/wiki/Installation
Install SQLite database
On MAC, it already there
> sqlite3 -version
3.24.0 2018-06-04 14:10:15
On Ubuntu, it is already there as well
> sqlite3 -version
3.22.0 2018-01-22 18:45:57
On CentOS 7, it is already there as well
> sqlite3 -version
3.7.17 2013-05-20
We can also download from here
https://www.sqlite.org/download.html
> wget https://www.sqlite.org/2019/sqlite-autoconf-3290000.tar.gz
> tar zxvf sqlite-autoconf-3290000.tar.gz
Compile and install
> cd sqlite-autoconf-3290000
> ./configure --prefix=/usr/local
> make
> sudo make install
Check version again
> sqlite3 -version
3.29.0 2019-07-10
Command line tool to open one sqlite database file
> sqlite3 ./SpiderKeeper.db
Check all tables
> .tables
sk_job_execution sk_job_instance sk_project sk_spider
Exit if needed
> sqlite> .quit
Check database schema
> .schema sk_spider
CREATE TABLE sk_spider (
id INTEGER NOT NULL,
date_created DATETIME,
date_modified DATETIME,
spider_name VARCHAR(100),
project_id INTEGER NOT NULL,
PRIMARY KEY (id)
);
CREATE INDEX ix_sk_spider_project_id ON sk_spider (project_id);
> .schema sk_project
CREATE TABLE sk_project (
id INTEGER NOT NULL,
date_created DATETIME,
date_modified DATETIME,
project_name VARCHAR(50),
PRIMARY KEY (id)
);
> .schema sk_job_instance
CREATE TABLE sk_job_instance (
id INTEGER NOT NULL,
date_created DATETIME,
date_modified DATETIME,
spider_name VARCHAR(100) NOT NULL,
project_id INTEGER NOT NULL,
tags TEXT,
spider_arguments TEXT,
priority INTEGER,
"desc" TEXT,
cron_minutes VARCHAR(20),
cron_hour VARCHAR(20),
cron_day_of_month VARCHAR(20),
cron_day_of_week VARCHAR(20),
cron_month VARCHAR(20),
enabled INTEGER,
run_type VARCHAR(20),
PRIMARY KEY (id)
);
CREATE INDEX ix_sk_job_instance_spider_name ON sk_job_instance (spider_name);
CREATE INDEX ix_sk_job_instance_project_id ON sk_job_instance (project_id);
> .schema sk_job_execution
CREATE TABLE sk_job_execution (
id INTEGER NOT NULL,
date_created DATETIME,
date_modified DATETIME,
project_id INTEGER NOT NULL,
service_job_execution_id VARCHAR(50) NOT NULL,
job_instance_id INTEGER NOT NULL,
create_time DATETIME,
start_time DATETIME,
end_time DATETIME,
running_status INTEGER,
running_on TEXT,
PRIMARY KEY (id)
);
CREATE INDEX ix_sk_job_execution_project_id ON sk_job_execution (project_id);
CREATE INDEX ix_sk_job_execution_service_job_execution_id ON sk_job_execution (service_job_execution_id);
CREATE INDEX ix_sk_job_execution_job_instance_id ON sk_job_execution (job_instance_id);
There is a webUI tool, haha. I should use command line, but UI is easy as well.
https://www.phpliteadmin.org/
Currently, stable version is 1.9.8 https://www.phpliteadmin.org/download/
Then I get the file named phpLiteAdmin_v1-9-8.zip
Create directory, Unzip the file in that directory
> mkdir phpliteadmin-1.9.8
> unzip phpLiteAdmin_v1-9-8.zip
It seems need php and web server for that following this https://bitbucket.org/phpliteadmin/public/wiki/Installation
It may be better to directly use this docker
https://github.com/shadowcodex/phpliteadmin
> git clone https://github.com/shadowcodex/phpliteadmin
Use a text editor to change the configuration, I use sublime here, or you can directly use vi on the server
> subl phpliteadmin/
Make sure I have docker on my CentOS
> sudo yum install docker-ce
> sudo usermod -aG docker $(whoami)
> sudo systemctl enable docker.service
> sudo systemctl start docker.service
If there is permission issue, you may need to restart the machines.
If we can not find the docker-ce package there “ No package docker-ce available."
Solution:
https://docs.docker.com/v17.09/engine/installation/linux/docker-ce/centos/#install-using-the-repository
> sudo yum install -y yum-utils device-mapper-persistent-data lvm2
> sudo yum-config-manager --add-repo https://download.docker.com/linux/centos/docker-ce.repo
Then the install command will work
> sudo yum install docker-ce
Go to the directory of phpliteadmin
> chmod a+x go.sh
Start the service
> ./go.sh /home/carl/data
It is running fine now
> docker ps
CONTAINER ID IMAGE COMMAND CREATED STATUS PORTS NAMES
1af127d6da44 shadowcodex/phpliteadmin "/bin/parent caddy -…" 3 seconds ago Up 2 seconds 80/tcp, 443/tcp, 0.0.0.0:2015->2015/tcp websql
Visit the webpage from this URL
http://centos-dev1:2015/phpliteadmin.php
Change the configuration, specially password here
> vi phpliteadmin.config.php
Restart the service
> ./go.sh /home/carl/data
The password is not working as designed. Open the debug=true, and I saw this in the logging
2019-09-04T22:55:22.608410410Z 04/Sep/2019:22:55:22 +0000 [ERROR 0 /phpliteadmin.php] PHP message: PHP Deprecated: crypt(): Supplied salt is not valid for DES. Possible bug in provided salt format. in /srv/phpliteadmin.php on line 4194
Plan to build the ENV my own, Check my PHP
Content in info.php
<?php phpinfo();?>
http://localhost:8081/info.php
Unzip the latest file
> unzip phpLiteAdmin_v1-9-8-1.zip
Copy them to my html directory
> cp ~/install/phpliteadmin.php ./html/
> cp ~/install/phpliteadmin.config.sample.php ./html/phpliteadmin.config.php
The docker thing is just normal php7, put the phpsqliteadmin under the html directory, that is it.
Check my centos7-sqlitephpadmin
References:
https://www.sqlite.org/download.html
https://www.yiibai.com/sqlite/installation.html
https://bitbucket.org/phpliteadmin/public/wiki/Installation
发表评论
-
Stop Update Here
2020-04-28 09:00 310I will stop update here, and mo ... -
NodeJS12 and Zlib
2020-04-01 07:44 468NodeJS12 and Zlib It works as ... -
Docker Swarm 2020(2)Docker Swarm and Portainer
2020-03-31 23:18 362Docker Swarm 2020(2)Docker Swar ... -
Docker Swarm 2020(1)Simply Install and Use Swarm
2020-03-31 07:58 364Docker Swarm 2020(1)Simply Inst ... -
Traefik 2020(1)Introduction and Installation
2020-03-29 13:52 330Traefik 2020(1)Introduction and ... -
Portainer 2020(4)Deploy Nginx and Others
2020-03-20 12:06 424Portainer 2020(4)Deploy Nginx a ... -
Private Registry 2020(1)No auth in registry Nginx AUTH for UI
2020-03-18 00:56 428Private Registry 2020(1)No auth ... -
Docker Compose 2020(1)Installation and Basic
2020-03-15 08:10 366Docker Compose 2020(1)Installat ... -
VPN Server 2020(2)Docker on CentOS in Ubuntu
2020-03-02 08:04 445VPN Server 2020(2)Docker on Cen ... -
Buffer in NodeJS 12 and NodeJS 8
2020-02-25 06:43 377Buffer in NodeJS 12 and NodeJS ... -
NodeJS ENV Similar to JENV and PyENV
2020-02-25 05:14 468NodeJS ENV Similar to JENV and ... -
Prometheus HA 2020(3)AlertManager Cluster
2020-02-24 01:47 414Prometheus HA 2020(3)AlertManag ... -
Serverless with NodeJS and TencentCloud 2020(5)CRON and Settings
2020-02-24 01:46 332Serverless with NodeJS and Tenc ... -
GraphQL 2019(3)Connect to MySQL
2020-02-24 01:48 243GraphQL 2019(3)Connect to MySQL ... -
GraphQL 2019(2)GraphQL and Deploy to Tencent Cloud
2020-02-24 01:48 445GraphQL 2019(2)GraphQL and Depl ... -
GraphQL 2019(1)Apollo Basic
2020-02-19 01:36 321GraphQL 2019(1)Apollo Basic Cl ... -
Serverless with NodeJS and TencentCloud 2020(4)Multiple Handlers and Running wit
2020-02-19 01:19 307Serverless with NodeJS and Tenc ... -
Serverless with NodeJS and TencentCloud 2020(3)Build Tree and Traverse Tree
2020-02-19 01:19 310Serverless with NodeJS and Tenc ... -
Serverless with NodeJS and TencentCloud 2020(2)Trigger SCF in SCF
2020-02-19 01:18 286Serverless with NodeJS and Tenc ... -
Serverless with NodeJS and TencentCloud 2020(1)Running with Component
2020-02-19 01:17 303Serverless with NodeJS and Tenc ...
相关推荐
从标题《SQLite Database System Design and Implementation》以及提供的部分内容来看,本书的核心知识点包括: 1. 关系型数据库管理系统(RDBMS)的基本概念:本书在开头部分回顾了关系型数据库的一些基础概念,...
SQLite Database Browser 2.0 b1.app.zip 是一个压缩包,包含了SQLite Database Browser的特定版本——2.0 beta 1的应用程序。SQLite Database Browser是一款直观的图形用户界面(GUI)工具,专门设计用于管理和操作...
3. **查询构建器**:SQLite Database Browser 包含一个可视化的SQL查询构建器,帮助用户生成复杂的SELECT、INSERT、UPDATE和DELETE语句,无需手动编写SQL代码。 4. **数据浏览与编辑**:用户可以在表格视图中浏览...
SQLite Database Browser是一款专为IPHONE用户设计的数据库管理工具,主要功能是帮助用户查看、编辑和管理SQLite数据库。SQLite是一种轻量级的、开源的关系型数据库管理系统,广泛应用于移动设备和嵌入式系统中,...
SQLite Database Browser是一款功能强大的、免费开源的SQLite数据库管理工具,专为Windows用户设计。它允许用户在无需深入了解SQL语法的情况下创建、编辑和管理SQLite数据库。SQLite本身是一个轻量级的、自包含的、...
SQLite数据库编辑工具SQLiteDatabaseBrowser是一款强大的开源工具,专为管理和编辑SQLite数据库而设计。SQLite是一种轻量级的、自包含的、无服务器的、事务性的SQL数据库引擎,广泛应用于移动设备、嵌入式系统以及...
1. **创建数据库**:你可以通过`SQLiteDatabaseBrowser`创建新的SQLite数据库文件,或者打开已存在的数据库进行编辑。 2. **浏览表结构**:打开数据库后,你可以看到所有表的列表,包括每个表的字段名、数据类型和...
SQLite Database Browser是一款强大的开源工具,专门用于管理和操作SQLite数据库。SQLite是一种自包含、无服务器、零配置、事务型的SQL数据库引擎,广泛应用于嵌入式系统和个人计算机应用程序中,因为它轻量级且无需...
1. **数据库创建**:用户可以通过phpSQLiteAdmin创建新的SQLite数据库,并选择保存的路径和文件名。 2. **表管理**:可以创建、修改和删除数据库中的表,包括定义字段类型(如INT、VARCHAR、TEXT等)、设置主键、...
该工具主要用于浏览和编辑 SQLite 数据库,它兼容标准的 SQLite 2.x 和 3.x 数据库。SQLite Browser 的功能强大,用户界面友好,使得数据库的管理变得简单易行。此外,SQLite Browser 项目在 GitHub 上开源,欢迎...
SQLite Database Browser 2.0 是一个专为mac用户设计的SQLite数据库管理工具,它提供了直观且易用的界面,使得数据库的浏览、管理和操作变得轻松。对于那些在Android开发中处理SQLite数据库的开发者来说,这个工具...
码头工人-sqlite3 docker-sqlite3 基于 busybox:ubuntu-14.04 创建一个最小的 sqlite3 docker 镜像。 非常适合 sqlite3 仅数据容器。创造 make将创建一个名为 dbaulig/sqlite3 的 docker 镜像,将该镜像作为可分发...
通过以上策略,我们可以有效地在Android的多线程环境中管理SQLite数据库,防止“database locked”问题的发生。在实践中,应根据具体的应用场景和需求选择合适的解决方案,以保证应用的稳定性和性能。
标题中的“SQLITE3.dll(3350500)的VS2019工程包”指的是一个针对SQLite3数据库引擎的动态链接库(DLL)文件,版本号为3350500,该文件是用Visual Studio 2019(VS2019)开发环境构建的工程。DLL文件在Windows操作...
SQLite Database 是一种轻量级的、开源的、自包含的桌面数据库系统,它无需服务器进程,可以直接在用户的应用程序中使用。这个工具以其高效、可靠和易于集成的特点,被广泛应用于各种小型到中型的数据存储需求,尤其...
SQLite,是一款轻型的数据库,是遵守ACID的关系型数据库管理系统,它包含在一个相对小的C库中。
标题提到的"sqlite3文件"主要包括三个关键组成部分:`sqlite3.dll`、`sqlite3.h`和`sqlite3.lib`,它们在开发和运行使用SQLite3的应用程序时起着至关重要的作用。 1. `sqlite3.dll`: 这是一个动态链接库文件,通常...
### SQLiteODBC 驱动 SQLite3:深入解析与应用指南 #### 一、SQLiteODBC简介 SQLiteODBC是一种连接SQLite数据库与支持ODBC(开放式数据库连接)的应用程序之间的桥梁。通过SQLiteODBC,开发人员可以利用ODBC标准...