SUMMARY: How to manually sys-unconfig when single-user mode not an option? [Original post at bottom.] Thanks to all who responded. Extra thanks to... Jon Godfrey included great summaries of all files referenced in the sys-unconfig manpage. Andrea included many of the commands necessary to make the changes manually along with reminders if the host was a NIS or NIS+ server. Jason Santos reminded me to setup proper crash and dump device settings. Ryan Krenzischek suggested checking print and NIS settings, regenerating the ssh keys, and a good find command for finding any other instances of the hostname that might be buried in non-standard files. Ryan also reminded me to check for applications that may use license keys based on the machine's host ID. (Compilers, Veritas, etc...) -John Christian SUMMARY OF FILES REF'D BY sys-unconfig MANPAGE /etc/default/init Usually contains the TZ and CMASK environment variables to set your timezone and default file mask settings /etc/defaultdomain The NIS domain name /etc/defaultrouter IP address of your default gateway. /etc/hostname.interface Each interface on a system can be known by a different name. The format is /etc/hostname.<interface> where the file contains a hostname in ascii. For example, /etc/hostname.qfe0 could contain "mymachine" and /etc/hostname.qfe1 could contain "mymachine-150" (it might be multihomed and the second NIC listens on 1.2.150.0/24 network. /etc/inet/hosts /etc/hosts is symlinked to this file; same content and format that you should know. /etc/inet/netmasks Contains a line for each network your system listens on with two fields per line consisting of the network and the netmask. Example, "1.2.150.0 255.255.255.0" /etc/nodename The primary hostname for your system. /etc/shadow Contains encrypted passwords usually that are usually removed from /etc/passwd. Can be generated with the "pwconv" command when the /etc/passwd file contains crypted passwords. /etc/vfstab Your disk mounttab file. Get yourself a hard copy of this before you manually change anything.... Just in case... /var/nis/NIS_COLD_START /var/yp/binding/*/ypservers These two are NIS related items. I'm not sure about the NIS_COLD_START file, but sys-unconfig just removes this stuff. The second element defines the NIS servers. Not so sure about mucking around with these... /etc/net/*/hosts While I'm still not sure of the exact purpose to each of these three files, their format is the same: "<hostname> <hostname>" /etc/.rootkey Almost never used anymore. Contained a key (like ssh does now) to try to better authenticate the root user. Safe to delete; probably does not exist anyway. PACKAGE THAT INCLUDES sys-unconfig If you dont want to do it manually use following package to do it with the sys-unconfig command SUNWadmap CD1/1 NIS REMINDERS Be carefully if the Server is a NIS or NIS+ Master or Replica. DO NOT modify the server. If it is so. Do not forgett to change DNS entries if neccessary! CRASH AND DUMP REMINDERS mv /var/crash/oldhostname /var/crash/newhostname dumpadm -s /var/crash/newhostname PRINTING, SSH, NETGROUP, HOSTID, AND LICENSE KEY REMINDERS If you have the Sun compiler, you will need to obtain a new license for your new host (or any software that uses a license manager) /etc/printers.conf (if you use this machine as a print spool) Your SSH Keys will need to be regenerated on the new host. /etc/lp/printers/PRINTERNAME/alert.sh will have the hostname hardcoded Your /etc/netgroup file if you're running NIS. These are the only things that come to mind that this time. You might want to also: FINDING HIDDEN HOSTNAME OCCURENCES find /etc -type f -exec grep -il YOUR_HOSTNAME {} \; to see if you're missing anything else. ________________________________ From: sunmanagers-bounces@sunmanagers.org on behalf of John Christian Sent: Tue 8/10/2004 10:55 AM To: sunmanagers@sunmanagers.org Subject: How to manually sys-unconfig when single-user mode not an option? How to manually sys-unconfig when single-user mode not an option? Hi Gurus, QUESTION Although sys-unconfig is great, due to remote-site limitations (no console) I cannot reboot into single user mode to input new hostname/IP/etc... settings, what are *ALL* of the little things sys-unconfig touches that I would need to manually modify before initiating a reboot? BTW: I am currently running on another disk/OS-install than the one I plan to modify then reboot from. See "Additional Details" further below. RESEARCH SO FAR According to sys-unconfig man page, the following files are involved. Most are straightforward, but I'm not familiar with some: Comfortable changing these... /etc/default/init /etc/defaultdomain /etc/defaultrouter /etc/hostname.interface /etc/inet/hosts /etc/inet/netmasks /etc/nodename /etc/shadow /etc/vfstab /var/nis/NIS_COLD_START /var/yp/binding/*/ypservers Not so sure about mucking around with these... /etc/net/*/hosts /etc/.rootkey Other files or areas not mentioned in the man page that will cause trouble? /?/?/??? ADDITIONAL DETAILS E-450 SunOS 5.9 Generic_112233-08 sun4u sparc SUNW,Ultra-4 I've been asked to duplicate a remote E-450 onto another remote E-450. Unfortunately, I do *not* have console access. I am running on disk0 of the E450 I'm building (default install of Solaris 9). I have created the boot block and restored the root file system of the original server onto disk1 of the new E450 (also Solaris 9). The original server is still online. IF I were on-site, I would disconnect the new 450 from the network, boot up as the original host, sys-unconfig (auto-reboot into single user mode), assign name/IP/etc, reboot and connect back to network. But I'm not on-site and don't have console access. Since I have the new root filesystem mounted, I *can* go in and manually modify /etc/hosts and other files to the new settings, use the eeprom command to set the host to boot from this newly ufsrestored slice, and reboot. (Actually, I'll set boot-device to "disk1 disk0" in case disk1 doesn't work.) AGAIN, MY QUESTION IS Since I cannot reboot into single user mode to input new hostname/IP/etc... settings, what are *all* of the little things sys-unconfig touches that I would need to manually modify before initiating a reboot? TIA for tips. I will summarize useful info. -John Christian _______________________________________________ sunmanagers mailing list sunmanagers@sunmanagers.org http://www.sunmanagers.org/mailman/listinfo/sunmanagers _______________________________________________ sunmanagers mailing list sunmanagers@sunmanagers.org http://www.sunmanagers.org/mailman/listinfo/sunmanagersReceived on Wed Aug 11 09:49:23 2004
This archive was generated by hypermail 2.1.8 : Thu Mar 03 2016 - 06:43:36 EST