日韩性视频-久久久蜜桃-www中文字幕-在线中文字幕av-亚洲欧美一区二区三区四区-撸久久-香蕉视频一区-久久无码精品丰满人妻-国产高潮av-激情福利社-日韩av网址大全-国产精品久久999-日本五十路在线-性欧美在线-久久99精品波多结衣一区-男女午夜免费视频-黑人极品ⅴideos精品欧美棵-人人妻人人澡人人爽精品欧美一区-日韩一区在线看-欧美a级在线免费观看

歡迎訪問 生活随笔!

生活随笔

當前位置: 首頁 > 运维知识 > linux >内容正文

linux

【Linux】一步一步学Linux——dhclient命令(156)

發布時間:2024/4/21 linux 27 豆豆
生活随笔 收集整理的這篇文章主要介紹了 【Linux】一步一步学Linux——dhclient命令(156) 小編覺得挺不錯的,現在分享給大家,幫大家做個參考.

00. 目錄

文章目錄

    • 00. 目錄
    • 01. 命令概述
    • 02. 命令格式
    • 03. 常用選項
    • 04. 參考示例
    • 05. 附錄

01. 命令概述

dhclient命令使用動態主機配置協議動態的配置網絡接口的網絡參數,也支持BOOTP協議。

02. 命令格式

dhclient [參數] [網絡接口]

03. 常用選項

-4 : 使用DHCPv4 -6 : 使用DHCPv6 -p 指定dhcp客戶端監聽的端口號(默認端口號86) -d 總是以前臺方式運行程序 -q 安靜模式,不打印任何錯誤的提示信息 -r 釋放ip地址 -n 不配置任何接口 -x 停止正在運行的DHCP客戶端,而不釋放當前租約,殺死現有的dhclient -s 在獲取ip地址之前指定DHCP服務器 -w 即使沒有找到廣播接口,也繼續運行

04. 參考示例

4.1 動態獲取IP

[root@localhost ~]# dhclient

4.2 釋放IP

[root@localhost ~]# dhclient -r

4.3 動態獲取IP,并且顯示過程

[root@localhost ~]# dhclient -v ens33 dhclient(71545) is already running - exiting. This version of ISC DHCP is based on the release available on ftp.isc.org. Features have been added and other changes have been made to the base software release in order to make it work better with this distribution.Please report for this software via the CentOS Bugs Database:http://bugs.centos.org/exiting. [root@localhost ~]#

4.4 釋放IP,顯示過程

[root@localhost ~]# dhclient -r -v ens33 Internet Systems Consortium DHCP Client 4.2.5 Copyright 2004-2013 Internet Systems Consortium. All rights reserved. For info, please visit https://www.isc.org/software/dhcp/Listening on LPF/ens33/00:50:56:26:d8:88 Sending on LPF/ens33/00:50:56:26:d8:88 Sending on Socket/fallback DHCPRELEASE on ens33 to 192.168.12.2 port 67 (xid=0x254c08e2)

4.5 從指定的服務器獲取ip地址

[root@localhost ~]# dhclient -s 192.168.12.2

4.6 停止運行dhclient

[root@localhost ~]# dhclient -x

05. 附錄

參考:【Linux】一步一步學Linux系列教程匯總

總結

以上是生活随笔為你收集整理的【Linux】一步一步学Linux——dhclient命令(156)的全部內容,希望文章能夠幫你解決所遇到的問題。

如果覺得生活随笔網站內容還不錯,歡迎將生活随笔推薦給好友。