LinuxQuestions.org
Help answer threads with 0 replies.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Server
User Name
Password
Linux - Server This forum is for the discussion of Linux Software used in a server related context.

Notices


Reply
  Search this Thread
Old 10-10-2019, 09:58 AM   #1
bradvan
Member
 
Registered: Mar 2009
Posts: 326

Rep: Reputation: 59
%post ip address of kickstart server


Have multiple kickstart servers for CentOS/RHEL 7 which use a common set of configuration files/scripts. I'm trying to see if there is a way in the %post section to determine the ip address of the kickstart server that was used? We do quite a few curls from the kickstart server during %post and I'd rather it comes from the "closest" one. Any ideas how to get that?
 
Old 10-11-2019, 08:15 AM   #2
sgrlscz
Member
 
Registered: Aug 2008
Posts: 115

Rep: Reputation: 82
In the kickstart, you should be able to parse /proc/cmdline to get the init.ks value, which would indicate the kickstart server used.
 
Old 10-18-2019, 03:34 AM   #3
bradvan
Member
 
Registered: Mar 2009
Posts: 326

Original Poster
Rep: Reputation: 59
I had a revelation yesterday. In order to simplify the task, everywhere I need the ip address of the local kickstart server, I'm going to use a variable. At the top of each respective switch where I need that variable, I'll put in a line like:
Code:
KS=1.2.3.4
Then in the script that pulls the files out of git on each kickstart server, I'll add code to change 1.2.3.4 to the correct ip address. This way I won't have to worry about trying to do this dynamically during %post and my git repository will remain authoritative and complete for all of the kickstart servers.
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
[SOLVED] Dynamic entry of kickstart server ip in kickstart config file bradvan Linux - Server 1 04-01-2019 07:09 AM
RedHat Satellite Kickstart: Passing IP information from Kernel Parameters to Kickstart Config file galron010 Linux - General 1 03-03-2016 12:11 PM
[SOLVED] RHL 6.0 Unable to download the Kickstart file/ Error downloading kickstart file AnApproach2DigestLinux Linux - Newbie 3 11-23-2012 05:50 PM
Kickstart Error Error opening kickstart file (null): bad address Latitude Linux - Networking 0 06-03-2009 11:20 AM
how to get ip address, broadcast address, mac address of a machine sumeshstar Programming 2 03-12-2005 04:33 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Server

All times are GMT -5. The time now is 07:50 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration