IP地址与mac的绑定

Windows篇:

1.以管理员权限运行CMD.

2.>netsh i i show in

3.得到网卡的index值,(假设为8)

4. >netsh -c “i i” add neighbors 8 “192.168.1.1” “00-1d-0f-6c-1a-ea”

(index值) (绑定的IP地址) (绑定的mac地址)

Linux篇:

1.echo ‘192.168.1.1 00:1D:0F:6C:1A:EA’ >/etc/ip-mac #建立一个文本将要绑定的地址写入

2.cat /etc/ip-mac #确定文本编辑成功

3.echo ‘arp -f /etc/ip-mac’  >>  /etc/rc.d/rc.local #开机自动绑定

4.arp -f /etc/ip-mac #手动执行帮定

RedHat Liunx 图形添加删除解决方法

1.mkdir /media/rhel

2.加载光驱复制到rhel

3. vi /etc/yum.repos.d/rhel-local.repo

4.[Cluster]
name=Red Hat Enterprise Linux $releasever – $basearch – Cluster
baseurl=file:///media/rhel/Cluster
enabled=1
gpgcheck=1
gpgkey=file:///etc/pki/rpm-gpg/RPM-GPG-KEY-redhat-release

[ClusterStorage]
name=Red Hat Enterprise Linux $releasever – $basearch – ClusterStorage
baseurl=file:///media/rhel/ClusterStorage
enabled=1
gpgcheck=1
gpgkey=file:///etc/pki/rpm-gpg/RPM-GPG-KEY-redhat-release

[Server]
name=Red Hat Enterprise Linux $releasever – $basearch – Server
baseurl=file:///media/rhel/Server
enabled=1
gpgcheck=1
gpgkey=file:///etc/pki/rpm-gpg/RPM-GPG-KEY-redhat-release

[VT]
name=Red Hat Enterprise Linux $releasever – $basearch – VT
baseurl=file:///media/rhel/VT
enabled=1
gpgcheck=1
gpgkey=file:///etc/pki/rpm-gpg/RPM-GPG-KEY-redhat-release

5.mkdir -p /var/rhel/{Cluster,ClusterStorage,Server,VT}

6.rpm -vih /media/rhel/Server/createrepo-0.4.4-2.fc6.noarch.rpm

7.createrepo -o /var/rhel/Cluster -g /media/rhel/Cluster/repodata/comps-rhel5-cluster.xml /media/rhel/Cluster

8.createrepo -o /var/rhel/ClusterStorage -g /media/rhel/ClusterStorage/repodata/comps-rhel5-cluster-st.xml /media/rhel/ClusterStorage

9.createrepo -o /var/rhel/Server -g /media/rhel/Server/repodata/comps-rhel5-server-core.xml /media/rhel/Server

10.createrepo -o /var/rhel/VT -g /media/rhel/VT/repodata/comps-rhel5-vt.xml /media/rhel/VT

11.mount –bind /var/rhel/Cluster/repodata /media/rhel/Cluster/repodata

12.mount –bind /var/rhel/ClusterStorage/repodata /media/rhel/ClusterStorage/repodata

13.mount –bind /var/rhel/Server/repodata /media/rhel/Server/repodata

14.mount –bind /var/rhel/VT/repodata /media/rhel/VT/repodata


15.[root@rhel5 rhel5]# yum clean all
Loading “rhnplugin” plugin
Loading “installonlyn” plugin
This system is not registered with RHN.
RHN support will be disabled.
Cleaning up Everything

16.[root@rhel5 rhel5]# system-config-packages(或者)