rhel7中smstools的使用方法

How to use smstools in rhel7

我想在 rhel7 中使用 smstools。但我无法获得正确的转速。 请帮忙。

我试过从互联网上获得的 rpm。 安装软件包时显示以下错误。

yum 搜索显示输出。

[root@localhost ~]# yum search sms
Loaded plugins: langpacks, product-id, subscription-manager
This system is not registered to Red Hat Subscription Management. You can       use subscription-manager to register.
file:///root/Downloads/smstools3-3.1.15-1.1.x86_64.rpm/repodata/repomd.xml:    [Errno 14] curl#37 - "Couldn't open file /root/Downloads/smstools3-3.1.15-  1.1.x86_64.rpm/repodata/repomd.xml"
Trying other mirror.
=============================== N/S matched: sms  ===============================
smstools3.x86_64 : Send text messages via GSM modems

Name and summary matches only, use "search all" for everything.

但是当使用 yum insatll 时出现以下错误

[root@localhost ~]# yum install smstools3.x86_64
Loaded plugins: langpacks, product-id, subscription-manager
This system is not registered to Red Hat Subscription Management. You can use subscription-manager to register.
file:///root/Downloads/smstools3-3.1.15-1.1.x86_64.rpm/repodata/repomd.xml: [Errno 14] curl#37 - "Couldn't open file /root/Downloads/smstools3-3.1.15-1.1.x86_64.rpm/repodata/repomd.xml"
Trying other mirror.
Nothing to do

我的仓库是这样的

[root@localhost ~]# vim /etc/yum.repos.d/smstools3-3.1.15-1.1.x86_64.rpm.repo 

[smstools3-3.1.15-1.1.x86_64.rpm]
name=added from: smstools3-3.1.15-1.1.x86_64.rpm
baseurl=file:///root/Downloads/smstools3-3.1.15-1.1.x86_64.rpm
enabled=1
gpgcheck=0
skip_if_unavailable = 1
keepcache = 0

谁能帮忙...

我能够解决问题。

首先将rpm复制到一个目录。

cp /root/Downloads/smstools3-3.1.15-1.1.x86_64.rpm /root/sms

然后再次创建存储库

yum-config-manager --add-repo=///root/sms

进入目录并执行 createrepo 后。

这解决了我的问题。