AskOverflow.Dev

AskOverflow.Dev Logo AskOverflow.Dev Logo

AskOverflow.Dev Navigation

  • 主页
  • 系统&网络
  • Ubuntu
  • Unix
  • DBA
  • Computer
  • Coding
  • LangChain

Mobile menu

Close
  • 主页
  • 系统&网络
    • 最新
    • 热门
    • 标签
  • Ubuntu
    • 最新
    • 热门
    • 标签
  • Unix
    • 最新
    • 标签
  • DBA
    • 最新
    • 标签
  • Computer
    • 最新
    • 标签
  • Coding
    • 最新
    • 标签
主页 / user-180135

famedoro's questions

Martin Hope
famedoro
Asked: 2020-04-30 06:00:01 +0800 CST

为什么 /tmp 绑定在 /tmp 中?如何删除此绑定

  • 0

在 RHEL6 的克隆 Scientific Linux 6 中,我有以下mtab文件:

/dev/sda2 / ext4 rw 0 0
proc /proc proc rw 0 0
sysfs /sys sysfs rw 0 0
devpts /dev/pts devpts rw,gid=5,mode=620 0 0
tmpfs /dev/shm tmpfs rw,rootcontext="system_u:object_r:tmpfs_t:s0" 0 0
/dev/sda1 /boot ext4 rw 0 0
none /proc/sys/fs/binfmt_misc binfmt_misc rw 0 0
/tmp /tmp none rw,bind 0 0
/var/tmp /var/tmp none rw,bind 0 0
/home /home none rw,bind 0 0
sunrpc /var/lib/nfs/rpc_pipefs rpc_pipefs rw 0 0
gvfs-fuse-daemon /root/.gvfs fuse.gvfs-fuse-daemon rw,nosuid,nodev 0 0

fstab的内容是

enter code here
#
# /etc/fstab
# Created by anaconda on Tue Apr 21 14:07:48 2020
#
# Accessible filesystems, by reference, are maintained under '/dev/disk'       
# See man pages fstab(5), findfs(8), mount(8) and/or blkid(8) for more info
#
UUID=ce58d311-5f32-4da6-9f96-ca9353dc421c /                       ext4    defaults        1 1
UUID=1e4e79e3-3317-4c50-8880-c25d6a03f4a4 /boot                   ext4    defaults        1 2
UUID=eec379ab-8116-46ef-b93b-9bdcd0ab65e2 swap                    swap    defaults        0 0
tmpfs                   /dev/shm                tmpfs   defaults        0 0
devpts                  /dev/pts                devpts  gid=5,mode=620  0 0
sysfs                   /sys                    sysfs   defaults        0 0
proc                    /proc                   proc    defaults        0 0

mount命令的输出是:

/dev/sda2 on / type ext4 (rw)
proc on /proc type proc (rw)
sysfs on /sys type sysfs (rw)
devpts on /dev/pts type devpts (rw,gid=5,mode=620)
tmpfs on /dev/shm type tmpfs (rw,rootcontext="system_u:object_r:tmpfs_t:s0")
/dev/sda1 on /boot type ext4 (rw)
none on /proc/sys/fs/binfmt_misc type binfmt_misc (rw)
/tmp on /tmp type none (rw,bind)
/var/tmp on /var/tmp type none (rw,bind)
/home on /home type none (rw,bind)
sunrpc on /var/lib/nfs/rpc_pipefs type rpc_pipefs (rw)
gvfs-fuse-daemon on /root/.gvfs type fuse.gvfs-fuse-daemon (rw,nosuid,nodev)

为什么 /tmp 绑定在 /tmp 上?(还有 /home 在 /home 上,/var/tmp 在 /var/tmp 上)

如何删除此绑定并将 /tmp 作为公共目录放在 / 下?

我需要这个,因为我有一个使用指令重命名的旧可执行文件,它给了我以下错误

EXDEV oldpath 和 newpath 不在同一个挂载的文件系统上。(Linux 允许在多个点挂载文件系统,但 rename() 不能跨不同的挂载点工作,即使在两个挂载点上都挂载了相同的文件系统。)

当它尝试在 / 的子目录下使用 oldpath int /tmp 和 newpath 重命名文件时。

linux mount filesystems fstab fuse
  • 1 个回答
  • 287 Views
Martin Hope
famedoro
Asked: 2016-10-05 03:47:25 +0800 CST

如何在我的新安装中使用 grub 启动 grub

  • 0

我在我的第一个驱动器 sda 上安装了 Scientific Linux 6(如 Centos 6)并将其用作我的工作 linux,为了继续使用我的工作分布,我在 sdb 上安装了 Scientific Linux 7。

在 BIOS 设置上使用引导优先级我可以在 sda 上启动 SL 6 或在 sdb 上启动 SL7

是否可以在 sda 上配置 grub,以便在启动时它也会在 sdb 上运行 grub 引导加载程序,所以选择哪个发行版启动?我的意图是让在 sdb 上安装 grub,以便在完成配置后立即准备好新的 SL7 安装

linux grub
  • 1 个回答
  • 44 Views
Martin Hope
famedoro
Asked: 2013-07-10 02:04:18 +0800 CST

手动编辑 /etc/passwd 和 /etc/shadow 后无法进行身份验证

  • 0

在 Scientific Linux 6.4 上(如 CentOs6.4)

配置新服务器时,我手动编辑了文件/etc/shadow以复制密码。

现在我只能以 root 用户身份登录,不能使用任何其他用户。

在引导时,服务器不显示登录消息。

我把之前的shadow文件放了,passwd和group gshadow都不成功

列出文件权限:

----------  1 root root 9   July 1501 11:47 shadow
----------. 1 root root 9   July 1445 11:46 shadow-
----------  1 root root 914 July 9    11:46 gshadow
----------. 1 root root 901 July 9    11:46 gshadow-
-rw-r--r--  1 root root 9   July 2835 11:46 passwd
-rw-r--r--. 1 root root 9   July 2774 11:46 passwd-
-rw-r--r--  1 root root 9   July 1107 11:46 group
-rw-r--r--. 1 root root 9   July 1091 11:46 group-

如果我尝试以普通用户身份登录,我会收到消息:/bin/bash: Permission denied

不允许 SELinux

显示/var/log/boot此消息:

Start di uuidd: runuser: /bin/bash: Permission denied

Start sendmail: 451 4.0.0 /etc/mail/sendmail.cf: line 93: fileclass: cannot open '/etc/mail/local-host-names': Group writable directory
451 4.0.0 /etc/mail/sendmail.cf: line 603: fileclass: cannot open '/etc/mail/trusted-users': Group writable directory
Start di sm-client: /etc/mail/submit.cf: line 556: fileclass: cannot open '/etc/mail/trusted-users': Group writable directory
can not chdir(/var/spool/clientmqueue/): Permission denied
Program mode requires special privileges, e.g., root or TrustedUser.

我做错了什么?

linux
  • 1 个回答
  • 1467 Views

Sidebar

Stats

  • 问题 205573
  • 回答 270741
  • 最佳答案 135370
  • 用户 68524
  • 热门
  • 回答
  • Marko Smith

    新安装后 postgres 的默认超级用户用户名/密码是什么?

    • 5 个回答
  • Marko Smith

    SFTP 使用什么端口?

    • 6 个回答
  • Marko Smith

    命令行列出 Windows Active Directory 组中的用户?

    • 9 个回答
  • Marko Smith

    什么是 Pem 文件,它与其他 OpenSSL 生成的密钥文件格式有何不同?

    • 3 个回答
  • Marko Smith

    如何确定bash变量是否为空?

    • 15 个回答
  • Martin Hope
    Tom Feiner 如何按大小对 du -h 输出进行排序 2009-02-26 05:42:42 +0800 CST
  • Martin Hope
    Noah Goodrich 什么是 Pem 文件,它与其他 OpenSSL 生成的密钥文件格式有何不同? 2009-05-19 18:24:42 +0800 CST
  • Martin Hope
    Brent 如何确定bash变量是否为空? 2009-05-13 09:54:48 +0800 CST
  • Martin Hope
    cletus 您如何找到在 Windows 中打开文件的进程? 2009-05-01 16:47:16 +0800 CST

热门标签

linux nginx windows networking ubuntu domain-name-system amazon-web-services active-directory apache-2.4 ssh

Explore

  • 主页
  • 问题
    • 最新
    • 热门
  • 标签
  • 帮助

Footer

AskOverflow.Dev

关于我们

  • 关于我们
  • 联系我们

Legal Stuff

  • Privacy Policy

Language

  • Pt
  • Server
  • Unix

© 2023 AskOverflow.DEV All Rights Reserve