Solved

how to change the hostname is solaris 10

Posted on 2006-11-10
4
15,490 Views
Last Modified: 2013-12-21
hi every one . i am using vmware. and running solaris 10  when it start up its saying unknown hostname. which file do i need to check and correct them  to make it usable

quesition -2
how should be name the hostname
xyz or
xyz.com or
xyz.com.au
or somthing else. what is right way to do it

question-3
i am trying to login remotely using reflectionx in to my solaris server i cant get into with root .it say i cant get
to make it work what the file and permission do i need to change


thanks very much   waiting for your early reply  
0
Comment
Question by:javeedabdul
  • 2
  • 2
4 Comments
 
LVL 6

Author Comment

by:javeedabdul
ID: 17920505
i just did this coammand

#hostname vmsun1
and retype to see  and it worked . but the internet went down. i could able to surf an y more. but i restarted  every thing back . and again its stating as unknown host .

i think (hostname xyz) is just temporary name for a limited until i reboot.

but to be permanent and tob recognized what way should i need to do

on this machine i am thinking to ftp and email server once of my site
thanks inadvance
0
 
LVL 38

Expert Comment

by:yuzh
ID: 17927443
The easy way to do it is to run "sys-unconfig" command to unconfigure the box, then
reboot the system and following the screen instructions to fill in your network configuration infor to get the box connet to you network.

For Solaris 10, you can also edit the following files:

To change  the hostname now only requires editing these files:
1. /etc/hosts
2. /etc/nodename
3. /etc/hostname.<interface name>

To change IP,editing two files:

1. /etc/hosts
2. /etc/inet/ipnodes

To set the domainname, edit:
/etc/defaultdomain   # set you default domain

then reboot

For security reason, you should not allow remote login as root (telnet, XDMCP login).

if you really want to do it, edit /etc/default/login file to comment out:
CONSOLE=/dev/console

make it
#CONSOLE=/dev/console


0
 
LVL 6

Author Comment

by:javeedabdul
ID: 17930977
i did
sys-unconfig  and did put the hostname in my vmware sol10 . but when it restarted its still showing as unknown

after rebooting its still the same

question-1
# cat /etc/hosts
#
# Internet host table
#
127.0.0.1       localhost
192.168.1.13    unknown # Added by DHCP

question-2
/etc/nodename
does not exist
if you asked to type nodename . what is a nodename . where can i find it

question-3
/etc/hostname.<interface name>
well this one also i couldnt find it out

how to find the interfacename.
which file does my interface name is stored in
doe i need to create this file

to every question if they do exist how should i write and what should i write
just my hostname  --vmsun1

please let me know
0
 
LVL 38

Accepted Solution

by:
yuzh earned 250 total points
ID: 17935264
You should mention your Solaris box is the DHCP client, use a test editor (eg) vi
to create /etc/nodename file,

or do: (login as root)
echo "mybox"> /etc/nodename
then reboot.

If you still have problem, have a look at the following doc and fix it:
http://www.rite-group.com/rich/solaris_dhcp.html

question-3
/etc/hostname.<interface name>
well this one also i couldnt find it out

Well, you need to replace .<interface name> with the real interface name for your box, type in:

ls -al /etc/hostname.*
 to see what you get

soemthing like /etc/hostsname.eri0
                     /etc/hostname.hme0
       where eri0, hme0 is the real NIC interface name.
0

Featured Post

Is Your Active Directory as Secure as You Think?

More than 75% of all records are compromised because of the loss or theft of a privileged credential. Experts have been exploring Active Directory infrastructure to identify key threats and establish best practices for keeping data safe. Attend this month’s webinar to learn more.

Question has a verified solution.

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

Introduction Regular patching is part of a system administrator's tasks. However, many patches require that the system be in single-user mode before they can be installed. A cluster patch in particular can take quite a while to apply if the machine…
FreeBSD on EC2 FreeBSD (https://www.freebsd.org) is a robust Unix-like operating system that has been around for many years. FreeBSD is available on Amazon EC2 through Amazon Machine Images (AMIs) provided by FreeBSD developer and security office…
Learn several ways to interact with files and get file information from the bash shell. ls lists the contents of a directory: Using the -a flag displays hidden files: Using the -l flag formats the output in a long list: The file command gives us mor…
In a previous video, we went over how to export a DynamoDB table into Amazon S3.  In this video, we show how to load the export from S3 into a DynamoDB table.

932 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

Need Help in Real-Time?

Connect with top rated Experts

10 Experts available now in Live!

Get 1:1 Help Now