single host multiple IP address configuration in Linux
来源:互联网 发布:python 定时循环执行 编辑:程序博客网 时间:2024/05/18 03:03
Just write for avoid the forget.
1. configure multiple IP address in /etc/hosts
If we want to assign two IP addresses to a single host named "test", we can just simply configure the /etc/hosts like:
192.168.1.1 test
192.168.1.2 test
After this configuration, if we call the C function gethostbyname("test") to get the IP addresses of host "test", most probably it returns only one single IP address.
2. turn the "multi on" in /etc/host.conf
add the following line to the end of /etc/host.conf
multi on
After this modification, the gethostbyname("test") will return two IP addresses.
- single host multiple IP address configuration in Linux
- Binding multiple IP address in one NIC in linux
- Linux Modify Host's Ip Address
- Static IP address in linux
- Single IP Address Cluster
- How to check ip address in linux
- change Network settings (IP Address, DNS, WINS, Host Name) with code in C#
- How to Find Your IP Address in Ubuntu Linux
- C language——read ip address in linux
- Replacing Multiple Patterns in a Single Pass
- Linux IPv6 address configuration的思考
- Display Multiple Images in Single Window in OpenCV
- Create Multiple IP Addresses to One Single Network Interface
- The host file--map a name to an IP address
- Tomcat 6 Missing Host Header Internal IP Address Disclosure
- [C++] How to get host ip address<ipv4>
- Error, some other host already uses address IP
- telnet: connect to address IP地址: No route to host
- linux内核分析笔记----进程地址空间
- Azure Blob Storage 云存储中实现大文件分块断点续传
- YUM常用命令
- JSON转字符串
- Postgresql version 9.0 和之前版本的一个BUG
- single host multiple IP address configuration in Linux
- 对特定字体设置抗锯齿
- 读取plist文件
- 忽略SIGPIPE信号的方法
- tcp状态机中time_wait状态的理解
- #define 和 #typedef , const的区别
- C primer plus:指向函数的指针
- 如何分析 kernel panic
- Android Intent的几种用法全面总结