Go Premium for a chance to win a PS4. Enter to Win

x
?
Solved

need linux commands

Posted on 2002-07-10
6
Medium Priority
?
269 Views
Last Modified: 2010-04-20
Does anyone know the equivalent commands in linux for "ipconfig /release" and "ipconfig /renew"?
0
Comment
Question by:kyiu
  • 3
  • 2
6 Comments
 
LVL 24

Expert Comment

by:SunBow
ID: 7144796
How about "dhcpcd -k" (kill) and "dhcpcd" (start, which usually acts same as renew)

I think this remains dependent on what product was loaded from what vendor, for what client, for what server, which distro, which ftp site.  So you might try "man dhcpcd" first. Generally, client initial request for address is network packet akin to client request for renewal of existing address, so server treats them the same (if subnetted properly). Server should continue to retain address mapping for a period after the release, permitting the same address assignment if user/client restarts dhcp service in a reasonable time frame.
0
 

Author Comment

by:kyiu
ID: 7145123
"The server continue to retain the address mapping" is exactly the problem with my ISP.  It wouldn't renew my IP address if I change the NIC, unless I release the old one first.  In Windows, it is done quite easily...send "ipconfig /release", replace NIC, then "ipconfig /renew". Everything will be happy. I want to do the same in my Linux.  I think what you've suggested does the same during (re)boot.  I need to send the server the "address release" first before the "renew".  This is what I belived how my ISP server works.  
0
 
LVL 4

Accepted Solution

by:
MFCRich earned 150 total points
ID: 7145975
According to man dhcpcd:

dhcpcd -k # DHCP release and destroy its own cache

dhcpcd -n # renew lease if dhcpcd is already running, otherwise follow normal startup procedure
0
Microsoft Certification Exam 74-409

Veeam® is happy to provide the Microsoft community with a study guide prepared by MVP and MCT, Orin Thomas. This guide will take you through each of the exam objectives, helping you to prepare for and pass the examination.

 

Author Comment

by:kyiu
ID: 7148135
I supposed you both are correct.  The problem was the version of linux (RH7.1) which uses "Pump" as the default dhcp client service.  I managed to run the test on a newer versioh RH7.3 that does use dhcpcd as default.  It works just like the Windows IPCONFIG command.  Thanksyou.

Sorry, this support site allows me to award to one guy only.  
0
 
LVL 24

Expert Comment

by:SunBow
ID: 7292835
Oh, but you can give points on the side!!!!!!!!!! <sigh>
Never mind, I don't need 'em. I am happy if you are.
 : ^ )                    Good Fortune!
0
 
LVL 24

Expert Comment

by:SunBow
ID: 7292850
> It wouldn't renew my IP address if I change the NIC, unless I release the old one first.

Uh, that sounds bad somewhere. DHCP assigns by MAC - which is usually the NIC. To change NIC you power off. Power on and you should look like a newbie in either OS, and to ISP. Renew is (at least used to be) the same format (bits in packet) of getting new IP. The difference being the context, of whether or not the server has you listed. But I do remember more poorly these days.
0

Featured Post

Concerto's Cloud Advisory Services

Want to avoid the missteps to gaining all the benefits of the cloud? Learn more about the different assessment options from our Cloud Advisory team.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Ready to get certified? Check out some courses that help you prepare for third-party exams.
This article will show you step-by-step instructions to build your own NTP CentOS server.  The network diagram shows the best practice to setup the NTP server farm for redundancy. ┬áThis article also serves as your NTP server documentation.
Learn how to find files with the shell using the find and locate commands. Use locate to find a needle in a haystack.: With locate, check if the file still exists.: Use find to get the actual location of the file.:
This video will show you how to get GIT to work in Eclipse.   It will walk you through how to install the EGit plugin in eclipse and how to checkout an existing repository.
Suggested Courses
Course of the Month6 days, 14 hours left to enroll

783 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question