通过nsenter 进入到docker容器的后端总是报下面的错,,

[root@devdtt ~]# docker inspect -f {{.State.Pid}} mynginx4
11950

[root@devdtt ~]# nsenter --target 11950 --mount --uts --ipc --net --pid
mesg: ttyname failed: No such file or directory

root@3af4221ded44:/# ls
bin boot dev etc home lib lib64 media mnt opt proc root run sbin srv sys tmp usr var
root@3af4221ded44:/#

这里有报错“mesg: ttyname failed: No such file or directory” ,,

解决方法是在 nsenter 指令后面指定一个执行的shell,, /bin/bash 

[root@devdtt ~]# nsenter --target 11950 --mount --uts --ipc --net --pid /bin/bash

root@3af4221ded44:/#

使用nsenter进入docker容器后端报错 mesg: ttyname failed: No such file or directory的更多相关文章

  1. zun 不能创建 docker 容器,报错: datastore for scope "global" is not initialized

    问题:zun不能创建docker容器,报错:datastore for scope "global" is not initialized   解决:修改docker 服务配置文件 ...

  2. egg 连接 mysql 的 docker 容器,报错:Client does not support authentication protocol requested by server; consider upgrading MySQL client

    egg 连接 mysql 的 docker 容器,报错:Client does not support authentication protocol requested by server; con ...

  3. node 报错 env: node\r: No such file or directory

    最近在编写一个命令行工具.使用 npm link 时可以正常运行.但是 ctrl+s 保存后, 再运行则报错 env: node\r: No such file or directory ,需要再 n ...

  4. laravel 报错SQLSTATE[HY000] [2002] No such file or directory

    在mac中执行php artisan migrate时报错 SQLSTATE[HY000] [2002] No such file or directory (SQL: select * from i ...

  5. Linux 格式化分区 报错Could not stat --- No such file or directory 和 partprobe 命令

    分区的过程正常: [root@db1 /]# fdisk -l   Disk /dev/sda: 21.4 GB, 21474836480 bytes 255 heads, 63 sectors/tr ...

  6. Gitlab 备份迁移恢复报错gtar: .: Cannot mkdir: No such file or directory

    1. 版本信息 OS: centos 6.9 Gitlab: gitlab-ce.10.7.4 gitlab-ce.10.8.0 gitlab-ce.10.8.3 gitlab-ce.10.8.4 2 ...

  7. [报错]ios开发 failed to read file attributes for

    下载第三方demo,运行报错:   failed to read file attributes for https://stackoverflow.com/questions/46301270/fa ...

  8. 安装apr-1.6.3报错[cannot remove `libtoolT’: No such file or directory]解决方法

    发现有这个提示:cannot remove `libtoolT’: No such file or directory , 编辑 configure文件,查找 $RM "$cfgfile&q ...

  9. 报错:Error: ENOENT, no such file or directory 'c:\Users\Administrator\WebstormProjects\blogtest\views\footer.ejs'

    这是我在index上引用<%- include footer %>,找不到该文件 所以报错 建立文件footer.ejs

随机推荐

  1. 关于C++ string 的神奇用法

    c++里有大部分字符的操作都在#include<cstring>这个库中,这个库的函数在考试的时候都是可以用的,这个库里包含了很多字符串操作函数,特别是string这个数据类型特别优美,它 ...

  2. github转gitee

    1.20190717,在SHH发现 下载github上的代码很慢(大概有422M),网上搜了 往文件“C:\Windows\System32\drivers\etc\hosts”中添加 ip& ...

  3. [Linux] 003 分区

    1. 磁盘分区 使用分区编辑器再磁盘上划分几个逻辑部分 不用类的目录与文件可以存储进不同的分区 2. 分区类型 主分区 最多只能有 4 个 扩展分区 最多只能有 1 个 主分区加扩展分区最多为 4 个 ...

  4. express框架中router组件的app.use和app.get

    首先看例子: var express = require('express'); var router = express.Router(); var index = require('./route ...

  5. Spring Boot 静态资源处理,妙!

    作者:liuxiaopeng https://www.cnblogs.com/paddix/p/8301331.html 做web开发的时候,我们往往会有很多静态资源,如html.图片.css等.那如 ...

  6. java中高级开发知识准备要点

    转载来源:https://www.cnblogs.com/JavaArchitect/p/10011253.html 在上周,我密集面试了若干位Java后端的候选人,工作经验在3到5年间.我的标准其实 ...

  7. Javascript 数组的一些操作

    (1) shift  删除原数组第一项,并返回删除元素的值:如果数组为空则返回undefined var a = [1,2,3,4,5]; var b = a.shift(); //a:[2,3,4, ...

  8. 联想笔记本 thinkpad BIOS 超级密码 Supervisor Password 清除 破解 亲测有效 转载地址https://blog.csdn.net/ot512csdn/article/details/72571674

    联想笔记本 thinkpad BIOS 超级密码 Supervisor Password 清除 破解 亲测有效 转载地址https://blog.csdn.net/ot512csdn/article/ ...

  9. 【LeetCode+51nod】股票低买高卖N题

    [121]Best Time to Buy and Sell Stock (2018年11月25日重新复习) 给一个数组代表股票每天的价格,只能有一次交易,即一次买入一次卖出,求最大收益. 题解:用一 ...

  10. Vue实例与组件的关系

    所有的 Vue 组件都是 Vue 实例,可以看成Vue组件就是Vue实例的扩展. <div id="app"> <child></child> ...