问题标签 [rhel]

For questions regarding programming in ECMAScript (JavaScript/JS) and its various dialects/implementations (excluding ActionScript). Note JavaScript is NOT the same as Java! Please include all relevant tags on your question; e.g., [node.js], [jquery], [json], [reactjs], [angular], [ember.js], [vue.js], [typescript], [svelte], etc.

0 投票
1 回答
39732 浏览

linux - 在 RHEL 上安装 tshark

有没有办法使用 yum install 在 RHEL 机器上安装 tshark?

当我这样做时:yum install tshark

我回来了:

当我这样做时: yum list tshark 我回来了:

0 投票
1 回答
8507 浏览

c - 在 rhel 6.1 上安装 gcc

GCC 似乎没有安装在我的 Rhel 6.1 机器上。另外,当我这样做时:

它吐槽:

相同的命令在 rhel 5.5 上运行良好。可能是什么问题呢?

更新:

回报:

回报:

回报:

更新 2:

回报:

0 投票
2 回答
793 浏览

linux - 个人用户的 crontab 条目

在我的 RHEL5 机器上,到目前为止,我已经通过在 /etc/crontab 文件中放置条目来设置 cron 作业,这是出于安全原因,只能由 root 编辑。

还有其他方法可以为个人用户设置 cron 作业吗?最好是,我希望每个用户都有自己的 cron 文件,他们可以随意编辑而不需要 root 权限。

这可以做到吗?

0 投票
1 回答
2234 浏览

linux - crontab 每次运行 3 次运行命令

我在 RHEL 服务器上设置了以下 crontab ...

正如你所看到的,它应该每 2 分钟运行一次,它确实如此,但是它运行了 3 次命令,我不知道为什么。

如果我跑

我得到以下

任何人都可以对此有所了解吗?

0 投票
1 回答
978 浏览

mysql - 无法 gem 安装 do_mysql。不存在mysql目录

我想gem install do_mysql,它失败了,因为找不到 MySQL 头文件。

我的系统管理员将mysql作为一个包安装,所以基本上“/usr/local/mysql”根本不存在!!

所以我该怎么做?

通过查询包

0 投票
1 回答
5901 浏览

git - 为 RHEL 6 安装/构建 git-svn

我无权访问 RHEL6 存储库,那么在 RedHat Enterprise Linux 6 上构建和/或安装 git-svn 工具的最佳方法是什么?


通过卸载现有的(yum erase git)并从源代码安装最新的,管理安装 git 和 git-svn 1.7.9。也适用于 64 位。

0 投票
2 回答
853 浏览

c - Slow initial timing results using gettimeofday - worse under RHEL6 Server

I am using gettimeofday() to time a simple matrix multiply example, but I'm getting results that are close to twice too long initially. On a RHEL6 Server machine, I'm getting "bad" timing results for up to nearly 1 second (~65 individual timings in this example). All our other machines are RHEL5 Workstation boxes and this code works much better on them; I only get a couple of "bad" results initially (for first ~20 milliseconds).

From posts on this site, I think this probably has something to do with the OS process scheduler. If I uncomment the first "for" statement below (thereby inserting an initial busy loop by repeatedly initializing the matrices a, b and c), I get zero "bad" results under both RHEL5 Workstation and RHEL6 Server. Alternatively, if I uncomment the sleep statement, I get ALL "bad" timing results for both RHEL5 & RHEL6.

For some reason, my process is starting up with only about half the access to the CPU initially, then it gets "full" access to the CPU as long as the process stays busy. If it "sleeps" and then resumes timing, it again is temporarily only getting about half the full access to the CPU.

Nothing else is happening on the machine (X is not running). I have tried "chrt" to control the priority of the process, but that changed nothing. I've verified this occurs with both GCC 4.4.6 and ICC 12.1.0. I've tried "nice" as well.

Here's the code:

and here are the results:

I experience the problem regardless of optimization level (-O0, -O1, -O2, etc.).

Does anyone know anything about how scheduling is done under RHEL6 Server? Is it so very different from RHEL5 Workstation? I presume the difference I'm seeing is more a function of the fact that one box is a server edition of RHEL and the other is a workstation edition (rather than the difference between release 5 vs. 6). Is there some simple way to reduce this effect under RHEL6 Server and make it act more like the RHEL5 Workstation boxes?

Any ideas? Thanks.

0 投票
1 回答
103 浏览

multithreading - 在 RHEL 中复制 solaris 命令

是否有任何等效的命令,例如pidmax,max_nprocsmaxuprcat RHEL?或者如何开发?,我的意思是,必须存在一个公式,在内存、cpu 和正在运行的进程等几个变量之间取得平衡。

提前致谢。

0 投票
1 回答
1081 浏览

java - 将 Java 程序作为守护程序服务运行以下指南不起作用?(RHEL 5)

我正在尝试运行此处提到的程序:http: //www.source-code.biz/snippets/java/7.htm

运行以下命令时,我看到错误:

错误如下

如何调试它?或者,如果您遵循本指南,您是否收到此错误?我的JAVA_HOME路径设置正确。

0 投票
3 回答
4678 浏览

php - RHEL + PHP:在 /var/www/html 之外写入文件?

我正在尝试打开一个文件进行读/写。我一直在 Ubuntu 上开发,没有任何问题。现在是部署到 RHEL 服务器的时候了,我发现要写入的文件的位置似乎存在某种限制。

在 RHEL 上,我无法打开文件,除非它位于 /var/www/html 下。我不知道如何允许其他位置。出于磁盘空间管理的原因,我需要操作不同卷上的文件。

以下是无论如何都可以在 Ubuntu 上正常运行的代码,但如果文件位于 Web 根目录之外,则会在 RHEL 上中断:

实际的错误如下,这很奇怪,因为权限很好(由“apache”用户拥有,文件上的权限为 0644,目录上的权限为 755)。

有人可以向我指出描述如何解除 RHEL 的 Apache/PHP 配置以允许写入文件系统上的备用位置的文档吗?

谢谢,~保罗