我有一个包含大量非常小的文件的目录,我想删除这些文件,而简单地删除该目录rm -rf /path/to/the/dir
已经需要多天时间了。
这听起来可能很奇怪,但该目录不是常规文件系统上的目录。它是集群的 Lustre 文件系统上的一个目录。
我在rm
安装了 Lustre 的集群的节点 A 上运行命令,但 Lustre 的后端是 2 个 ZFS 文件系统,一个在节点 B 上,一个在节点 C 上,因此所有网络流量可能是rm
变慢的原因。
有没有人知道比我的方法更快的删除目录的方法?
在sudoers
文件中添加 Active Directory (AD) 组以限制对组成员的本地管理员访问的 Linux (Red Hat) 命令是什么?
例如,我有一个 AD 组linux-admin
,我想添加这一行
%test.com\linux-admin ALL=(ALL) ALL
Run Code Online (Sandbox Code Playgroud) 关于这个问题:How to script make menuconfigmake
,运行和运行有什么区别make oldconfig
?
我假设如果你运行make
,它无论如何都会使用旧的.config
。
当我ambari-server upgrade
从 bash 脚本运行命令时,在升级过程中我们遇到了问题
已经备份了 Ambari Server 数据库 [y/n] (y)?
所以我们想自动化这个过程,通过期待yes
在问题出现时发送的脚本。
请建议如何ambari-server upgrade
通过期望自动化
ambari-server upgrade
Using python /usr/bin/python
Upgrading ambari-server
INFO: Upgrade Ambari Server
INFO: Updating Ambari Server properties in ambari.properties
...
WARNING: Can not find ambari.properties.rpmsave file from
previous version, skipping import of settings
INFO: Updating Ambari Server properties in ambari-env.sh ...
INFO: Can not find ambari-env.sh.rpmsave file from previous
version, skipping restore of environment settings. ambari-env.sh may not
include any user customization. …
Run Code Online (Sandbox Code Playgroud) 我编写了一个任务,如果需要重新启动,则仅打印该任务。我有这个 yum 模块输出,我需要提取单词“Complete | or_some_other_word”,并且此任务仅在上述单词存在时才会运行。
TASK [deploying_security_updates : Installed Packages] **************************************************************************************************************************************************************************************
ok: [192.168.8.26] => {
"yum_update": {
"changed": true,
"changes": {
"installed": [],
"updated": [
[
"xz",
"5.2.2-2.el7_9.x86_64 from rhel-remote"
],
[
"xz-libs",
"5.2.2-2.el7_9.x86_64 from rhel-remote"
]
]
},
"failed": false,
"msg": "",
"rc": 0,
"results": [
"Loaded plugins: langpacks, product-id, search-disabled-repos, subscription-\n : manager\nThis system is not registered with an entitlement server. You can use subscription-manager to register.\n --> device-mapper-persistent-data-0.7.3-3.el7.x86_64 from @anaconda/7.6 removed (updateinfo)\n --> 7:device-mapper-event-1.02.170-6.el7_9.5.x86_64 from rhel-remote removed …
Run Code Online (Sandbox Code Playgroud) 作为在 Linux 机器上安装 SCOM 应用程序的一部分
链接:http : //www.tekronin.net/2014/07/31/monitoring-linux-servers-with-scom-2012-r2/
我需要验证 OpenSSL 是否已启动并正在运行。
验证这个包是否在 Linux 机器上的方法是什么?