WordPress数据库错误: [Got error 28 from storage engine]
SHOW FULL COLUMNS FROM `wp_options`

WordPress数据库错误: [Got error 28 from storage engine]
SELECT t.*, tt.*, tr.object_id FROM wp_terms AS t INNER JOIN wp_term_taxonomy AS tt ON t.term_id = tt.term_id INNER JOIN wp_term_relationships AS tr ON tr.term_taxonomy_id = tt.term_taxonomy_id WHERE tt.taxonomy IN ('category', 'post_tag', 'post_format') AND tr.object_id IN (607) ORDER BY t.name ASC

如何更改Docker已经挂载的目录 – Crazy knowledge base
Crazy knowledge base

如何更改Docker已经挂载的目录

  1. 更改docker已经挂载的目录,主要有两种方式:一是重新创建容器,二是更改配置文件。第一种方式较为简单,下面具体演示第二种方式,通过更改配置文件来更换目录 挂载。

     

    安装docker

    yum -y install docker

    启动docker服务

    systemctl start docker

    如何更改Docker已经挂载的目录
    如何更改Docker已经挂载的目录
  2. 已nginx镜像为例,进行下面操作。

    下载nginx镜像

    docker pull nginx

    查看下载的nginx镜像

    docker images

    如何更改Docker已经挂载的目录
  3. 启动nginx镜像,将本地/nginx映射到docker中的/usr/share/nginx/html,本地端口80与docker中的80端口映射。

    docker run –name nginx -v /nginx:/usr/share/nginx/html -p 80:80 -d 2073e0bcb60e

    查看目录映射关系

    docker inspect -f “{{.Mounts}}” nginx

    如何更改Docker已经挂载的目录
    如何更改Docker已经挂载的目录
  4. 下面将宿主机挂载的目录从/nginx变更为/html,容器中对应的目录不变/usr/share/nginx/html。步骤如下:

    关闭docker容器

    docker stop nginx

    停止docker服务

    systemctl stop docker

    如何更改Docker已经挂载的目录
  5. 修改容器配置文件

    cd /var/lib/docker/containers/214fda2756f6eb3358c37856560263012387232f9b54484806c7ce29ded0706f

    将文件config.v2.json和hostconfig.json中的”Source”从/nginx更改为/html

    如何更改Docker已经挂载的目录
    如何更改Docker已经挂载的目录
  6. 开启docker服务

    systemctl start docker

    启动nginx容器

    docker start nginx

    如何更改Docker已经挂载的目录
  7. 7

    查看挂载目录,已经从/nginx变为/html。

    docker inspect -f “{{.Mounts}}” nginx

    如何更改Docker已经挂载的目录
如何更改Docker已经挂载的目录

WordPress数据库错误: [Got error 28 from storage engine]
SELECT t.*, tt.* FROM wp_terms AS t INNER JOIN wp_term_taxonomy AS tt ON t.term_id = tt.term_id INNER JOIN wp_term_relationships AS tr ON tr.term_taxonomy_id = tt.term_taxonomy_id WHERE tt.taxonomy IN ('category') AND tr.object_id IN (598) ORDER BY t.name ASC

WordPress数据库错误: [Got error 28 from storage engine]
SELECT t.*, tt.* FROM wp_terms AS t INNER JOIN wp_term_taxonomy AS tt ON t.term_id = tt.term_id INNER JOIN wp_term_relationships AS tr ON tr.term_taxonomy_id = tt.term_taxonomy_id WHERE tt.taxonomy IN ('category') AND tr.object_id IN (609) ORDER BY t.name ASC

发表评论

滚动到顶部