Solved

Changing operating system name !

Posted on 2002-04-10
9
245 Views
Last Modified: 2013-12-27
I am using a solaris 8 computer,I did the command sys-unconfig and I changed the configurations,a fter that I tried to unisntall an appliction,but I received a meesage telling me that it is unsupported operating system and it mentioned the name of the operating system wrongly.
My quesiton is :is there a coomand to rename the operating system correctly?
yes I mean that ,although it seems stupid and hopeless.
thanks
0
Comment
Question by:norman2000
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 2
  • 2
  • 2
  • +2
9 Comments
 
LVL 4

Expert Comment

by:Otetelisanu
ID: 6930798
Look man uname
uname -a (all)
for operating system is
Example :
uname -rs
SunOS 5.7
0
 
LVL 4

Expert Comment

by:Otetelisanu
ID: 6930815
Look
uname -S

-S system_name

The nodename may be changed by specifying a system
name  argument.  The  system name argument is res-
tricted to SYS_NMLN  characters.  SYS_NMLN  is  an
implementation    specific    value   defined   in
<sys/utsname.h>. Only the  super-user  is  allowed
this capability.
0
 

Author Comment

by:norman2000
ID: 6930998
When Iam trying to change it using the command as folowing:
uname -S sunOS
just  the hostname (nodename)is changed ,& it did not change the operating system name.
and when  displaying it by the command
uname -sn
it returns:
 XXX   YYY
where XXX is the operating system name which we want to change .
and the YYY is hostname .
 
0
Independent Software Vendors: We Want Your Opinion

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

 
LVL 14

Expert Comment

by:chris_calabrese
ID: 6931088
Uname -s changes the hostname of the current computer, not the operating system name.  There is no way to change the operating system name short of editing the kernel image or some such.

Instead, you need to figure out exactly how the uninstall program is determining the OS name and then cheat.

If it's a shell script then you can simply change the script.

If it's a binary that's calling the uname command line program , then you can probably put a fake copy of uname in a directory that you place at the beginning of the PATH before calling the uninstall script.

If it's a binary that's calling the uname() library call, you may be able to edit the binary with a binary editor or link in an alternate version of the uname() library call (by using LD_LIBRARY_PATH).
0
 

Expert Comment

by:masterT
ID: 6960045
why don't you just change the files


1)  /etc/hosts

 ipaddress  sunbox  sunbox.domain.com

2)  /etc/nodename

    sunbox

3)  /etc/hostname.hme0

   sunbox
0
 
LVL 4

Accepted Solution

by:
boxcar7 earned 200 total points
ID: 6970721
I believe the command you want is setuname.  
For example, at a command line, type:
setuname -s MyOS

That will change the OS name to MyOS (from SunOS).
You might want to try just changing the running kernel (ratherher than making a permanent change) by adding the -t parameter to make sure it doesn't break any of your applications that actually make use of the OS name
(i.e. setuname -t -s MyOS).

0
 
LVL 14

Expert Comment

by:chris_calabrese
ID: 6970733
Hmm, didn't know about that one.  Just looked at the man pages and looks like it would work, though.  Suggest giving points to boxcar7.
0
 

Expert Comment

by:masterT
ID: 6970737
Sorry guys !! I totally misread the question1
0
 

Author Comment

by:norman2000
ID: 6974648
I used this command and it worked!
but I have another  problem in the Appache server,I will try to solve it,if i could not i will post it
thanks
0

Featured Post

Industry Leaders: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

Question has a verified solution.

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

Suggested Solutions

When you do backups in the Solaris Operating System, the file system must be inactive. Otherwise, the output may be inconsistent. A file system is inactive when it's unmounted or it's write-locked by the operating system. Although the fssnap utility…
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…
Learn how to navigate the file tree with the shell. Use pwd to print the current working directory: Use ls to list a directory's contents: Use cd to change to a new directory: Use wildcards instead of typing out long directory names: Use ../ to move…

756 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