您好,欢迎来到三六零分类信息网!老站,搜索引擎当天收录,欢迎发信息

Oracle 管理之 Linux 网络基础

2024/10/27 8:28:13发布32次查看
1、tcp/ip 网络配置文件2、使用命令配置网络3、网络诊断工具 tcp/ip 网络配置文件ip配置文件:/etc/sysconfig/network-scripts/i
首页 → 数据库技术
背景:
阅读新闻
oracle 管理之 linux 网络基础
[日期:2013-02-16]来源:blog.csdn.net/xiangsir 作者:xiangsir[字体:]
1、tcp/ip 网络配置文件
2、使用命令配置网络
3、网络诊断工具
tcp/ip 网络配置文件
ip配置文件:/etc/sysconfig/network-scripts/ifcfg-eth0
网管配置文件:/etc/sysconfig/network
域名解析:/etc/host.conf
主机配置:/etc/hosts
路由配置:/etc/resolv.conf
服务端口配置:/etc/services
网络接口启动脚本:
[root@asm ~]#  more /etc/sysconfig/network-scripts/ifcfg-eth0
# advanced micro devices [amd] 79c970 [pcnet32 lance]
device=eth0
bootproto=static
broadcast=192.168.8.255
hwaddr=00:0c:29:8b:86:65
ipaddr=192.168.8.160
netmask=255.255.255.0
network=192.168.8.0
onboot=yes
[root@asm ~]# more /etc/sysconfig/network
networking=yes
networking_ipv6=no
hostname=asm.oracle.com
gateway=192.168.8.1
/etc/hosts
该文件是系统本地的主机名称解析数据库
[root@asm ~]# more /etc/hosts
# do not remove the following line, or various programs
# that require network functionality will fail.
127.0.0.1      localhost.localdomain localhost
::1            localhost6.localdomain6 localhost6
192.168.8.160  asm.oracle.com  asm
/etc/host.conf 文件用于指定如何解析主机名,可用选项:
order:设置主机名解析的可用方法及顺序,可用方法包括hosts(使用/etc/hosts文件进行解析)、bind
(使用dns服务器解析)、nis(使用网络信息服务nis解析)
multi:设置是否从 /etc/hosts 文件中返回主机的多个 ip 地址,取值为 on/off
/etc/resolv.conf 文件是 dns (dns域名服务的客户端配置文件):
[root@asm ~]# more /etc/resolv.conf
nameserver 192.168.8.11
search oracle.com
domain oracle.com
/etc/services 设置网络服务默认使用的 tcp 或 udp 端口
使用命令行工具或gui工具配置 linux 网络:
[root@asm ~]# ifconfig
eth0      link encap:ethernet  hwaddr 00:0c:29:8b:86:65 
          inet addr:192.168.8.160  bcast:192.168.8.255  mask:255.255.255.0
          up broadcast running multicast  mtu:1500  metric:1
          rx packets:23894 errors:0 dropped:0 overruns:0 frame:0
          tx packets:1864 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:1000
          rx bytes:1708719 (1.6 mib)  tx bytes:309503 (302.2 kib)
          interrupt:75 base address:0x2000
lo        link encap:local loopback 
          inet addr:127.0.0.1  mask:255.0.0.0
          up loopback running  mtu:16436  metric:1
          rx packets:18747 errors:0 dropped:0 overruns:0 frame:0
          tx packets:18747 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:0
          rx bytes:1215290 (1.1 mib)  tx bytes:1215290 (1.1 mib)
[root@asm ~]# ifconfig eth0 192.168.8.161 netnask 255.255.255.0 up
[root@asm ~]# ifconfig eth0 192.168.8.160 netnask 255.255.255.0 up
[root@asm ~]# ifconfig eth0
eth0      link encap:ethernet  hwaddr 00:0c:29:8b:86:65 
          inet addr:192.168.8.160  bcast:192.168.8.255  mask:255.255.255.0
          up broadcast running multicast  mtu:1500  metric:1
          rx packets:24260 errors:0 dropped:0 overruns:0 frame:0
          tx packets:2001 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:1000
          rx bytes:1736070 (1.6 mib)  tx bytes:327830 (320.1 kib)
          interrupt:75 base address:0x2000
修改配置文件重启网卡也可修改ip地址:
vi /etc/sysconfig/network-scripts/ifcfg-eth0
service network restart
vi /etc/sysconfig/network
vi /etc/resolv.conf
0
oracle中的转义字符用法
oracle goldengate安装配置
相关资讯       oracle基础教程  oracle管理  linux网络基础
图片资讯
本文评论查看全部评论 (0)
评论声明
最新资讯
本周热门
该用户其它信息

VIP推荐

免费发布信息,免费发布B2B信息网站平台 - 三六零分类信息网 沪ICP备09012988号-2
企业名录 Product