In another group someone asked how to get the run-level.
"who -r" is the answer I gave, but even though this is
still described in the Solaris 10 who(1) man page, I'm
wondering what it reports since Solaris no longer uses
a SysV init system? I don't have a Solaris box to try
this so I thought I'd ask. Does this return the
last milestone reached, nothing at all, or what?
Just curious, thanks!
-Wayne
|
|
0
|
|
|
|
Reply
|
Wayne
|
4/10/2008 12:18:22 AM |
|
Wayne wrote:
> In another group someone asked how to get the run-level.
> "who -r" is the answer I gave, but even though this is
> still described in the Solaris 10 who(1) man page, I'm
> wondering what it reports since Solaris no longer uses
> a SysV init system? I don't have a Solaris box to try
> this so I thought I'd ask. Does this return the
> last milestone reached, nothing at all, or what?
same old
. run-level 3 Nov 29 10:59 3 0 S
|
|
0
|
|
|
|
Reply
|
Oscar
|
4/10/2008 2:01:40 AM
|
|
Wayne <nospam@all4me.invalid> writes:
>In another group someone asked how to get the run-level.
>"who -r" is the answer I gave, but even though this is
>still described in the Solaris 10 who(1) man page, I'm
>wondering what it reports since Solaris no longer uses
>a SysV init system? I don't have a Solaris box to try
>this so I thought I'd ask. Does this return the
>last milestone reached, nothing at all, or what?
>
>Just curious, thanks!
>
I don't think Solaris 10 changed the concept of run levels
as the way to determine which programs to start up, only
the use of shell scripts as the method for sequencing and
starting them.
-Greg
--
Do NOT reply via e-mail.
Reply in the newsgroup.
|
|
0
|
|
|
|
Reply
|
gerg
|
4/10/2008 6:48:57 AM
|
|
Greg Andrews schrieb:
> Wayne <nospam@all4me.invalid> writes:
>> In another group someone asked how to get the run-level.
>> "who -r" is the answer I gave, but even though this is
>> still described in the Solaris 10 who(1) man page, I'm
>> wondering what it reports since Solaris no longer uses
>> a SysV init system? I don't have a Solaris box to try
>> this so I thought I'd ask. Does this return the
>> last milestone reached, nothing at all, or what?
>>
>> Just curious, thanks!
>>
>
> I don't think Solaris 10 changed the concept of run levels
> as the way to determine which programs to start up, only
> the use of shell scripts as the method for sequencing and
> starting them.
>
> -Greg
is there a method to switch to another milestone/runlevel by use of smf?
I remember it can be done, but i still use init/shutdown.
Wolfgang
|
|
0
|
|
|
|
Reply
|
Wolfgang
|
4/10/2008 7:47:30 AM
|
|
On Apr 10, 1:18 am, Wayne <nos...@all4me.invalid> wrote:
> In another group someone asked how to get the run-level.
> "who -r" is the answer I gave, but even though this is
> still described in the Solaris 10 who(1) man page, I'm
> wondering what it reports since Solaris no longer uses
> a SysV init system? I don't have a Solaris box to try
> this so I thought I'd ask. Does this return the
> last milestone reached, nothing at all, or what?
There are still run-levels and who -r still reports them. The
difference is that now init starts svc.startd at boot (from inittab),
and informs it of run-level changes, and it does almost all the work,
translating run-levels into milestones. The whole SVC system is not
very well documented or designed, which is sad as it has huge
possibilities.
|
|
0
|
|
|
|
Reply
|
Tim
|
4/10/2008 8:06:08 AM
|
|
In <47fdc611$0$633$9b4e6d93@newsspool1.arcor-online.net> Wolfgang <wtrappe@AT.web.de> writes:
>Greg Andrews schrieb:
>> Wayne <nospam@all4me.invalid> writes:
>>> In another group someone asked how to get the run-level.
>>
>> I don't think Solaris 10 changed the concept of run levels
>> as the way to determine which programs to start up, only
>> the use of shell scripts as the method for sequencing and
>> starting them.
>is there a method to switch to another milestone/runlevel by use of smf?
>I remember it can be done, but i still use init/shutdown.
You can boot to a milestone. `man kernel' contains this information:
milestone=[milestone]
Boot to the subgraph defined by the given milestone.
Legimate milestones are "none", "single-user",
"multi-user", "multi-user-server", and "all".
--
-Gary Mills- -Unix Support- -U of M Academic Computing and Networking-
|
|
0
|
|
|
|
Reply
|
Gary
|
4/10/2008 12:12:21 PM
|
|
On 2008-04-10, Wayne <nospam@all4me.invalid> wrote:
> In another group someone asked how to get the run-level.
> "who -r" is the answer I gave, but even though this is
> still described in the Solaris 10 who(1) man page, I'm
> wondering what it reports since Solaris no longer uses
> a SysV init system? I don't have a Solaris box to try
> this so I thought I'd ask. Does this return the
> last milestone reached, nothing at all, or what?
>
> Just curious, thanks!
>
> -Wayne
Solaris 10 still has run levels, it just uses svcs
and milestones to implement most of the functionality.
The old-fashioned rc script structure remains available
for software that still wants to start up that way.
Setting a run level now runs the appropriate rc scripts
*and* sets the milestones associated with that run level.
--
Christopher Mattern
NOTICE
Thank you for noticing this new notice
Your noticing it has been noted
And will be reported to the authorities
|
|
0
|
|
|
|
Reply
|
Chris
|
4/10/2008 8:30:11 PM
|
|
Gary Mills schrieb:
> In <47fdc611$0$633$9b4e6d93@newsspool1.arcor-online.net> Wolfgang <wtrappe@AT.web.de> writes:
>
>> Greg Andrews schrieb:
>>> Wayne <nospam@all4me.invalid> writes:
>>>> In another group someone asked how to get the run-level.
>>> I don't think Solaris 10 changed the concept of run levels
>>> as the way to determine which programs to start up, only
>>> the use of shell scripts as the method for sequencing and
>>> starting them.
>
>> is there a method to switch to another milestone/runlevel by use of smf?
>> I remember it can be done, but i still use init/shutdown.
>
> You can boot to a milestone. `man kernel' contains this information:
>
> milestone=[milestone]
>
> Boot to the subgraph defined by the given milestone.
> Legimate milestones are "none", "single-user",
> "multi-user", "multi-user-server", and "all".
>
yes, but how i do switch a runlevel? if runlevel is 3 i can switch to s
by "init s". Smf allows to switch from a lower level to do svcadm enable
milestone, but how to switch to a lower level, also svcadm enable
lower-milestone?
Wolfgang
|
|
0
|
|
|
|
Reply
|
Wolfgang
|
4/11/2008 7:24:07 AM
|
|
On 2008-04-11, Wolfgang <wtrappe@AT.web.de> wrote:
> Gary Mills schrieb:
>> In <47fdc611$0$633$9b4e6d93@newsspool1.arcor-online.net> Wolfgang <wtrappe@AT.web.de> writes:
>>
>>> Greg Andrews schrieb:
>>>> Wayne <nospam@all4me.invalid> writes:
>>>>> In another group someone asked how to get the run-level.
>>>> I don't think Solaris 10 changed the concept of run levels
>>>> as the way to determine which programs to start up, only
>>>> the use of shell scripts as the method for sequencing and
>>>> starting them.
>>
>>> is there a method to switch to another milestone/runlevel by use of smf?
>>> I remember it can be done, but i still use init/shutdown.
>>
>> You can boot to a milestone. `man kernel' contains this information:
>>
>> milestone=[milestone]
>>
>> Boot to the subgraph defined by the given milestone.
>> Legimate milestones are "none", "single-user",
>> "multi-user", "multi-user-server", and "all".
>>
> yes, but how i do switch a runlevel? if runlevel is 3 i can switch to s
> by "init s". Smf allows to switch from a lower level to do svcadm enable
Yes, you switch to a lower run level by using init. I init S on my Solaris
10 box all the time (mainly when I'm doing patching)
> milestone, but how to switch to a lower level, also svcadm enable
> lower-milestone?
>
Just init to the desired runlevel. svcadm is automatically invoked to
reset your milestones.
--
Christopher Mattern
NOTICE
Thank you for noticing this new notice
Your noticing it has been noted
And will be reported to the authorities
|
|
0
|
|
|
|
Reply
|
Chris
|
4/11/2008 2:22:30 PM
|
|
>
> =A0 =A0 . =A0 =A0 =A0 run-level 3 =A0Nov 29 10:59 =A0 =A0 3 =A0 =A0 =A00 =
=A0S
can anyone tell me what each field (output from who -r) represents?
thanks in advance.
|
|
0
|
|
|
|
Reply
|
ubyt3m3
|
5/1/2008 9:54:07 AM
|
|
This message is in MIME format. The first part should be readable text,
while the remaining parts are likely unreadable without MIME-aware tools.
---559023410-1804928587-1209651960=:7265
Content-Type: TEXT/PLAIN; charset=iso-8859-1
Content-Transfer-Encoding: 8BIT
On Thu, 1 May 2008, ubyt3m3 wrote:
> >
> > � � . � � � run-level 3 �Nov 29 10:59 � � 3 � � �0 �S
>
> can anyone tell me what each field (output from who -r) represents?
Yes, but you'd get the answer quicker if you did your own research
(hint: man who).
--
Rich Teer, SCSA, SCNA, SCSECA
CEO,
My Online Home Inventory
URLs: http://www.rite-group.com/rich
http://www.linkedin.com/in/richteer
http://www.myonlinehomeinventory.com
---559023410-1804928587-1209651960=:7265--
|
|
0
|
|
|
|
Reply
|
Rich
|
5/1/2008 2:27:01 PM
|
|
On May 1, 10:27=A0pm, Rich Teer <rich.t...@rite-group.com> wrote:
> On Thu, 1 May 2008, ubyt3m3 wrote:
>
> > > =A0 =A0 . =A0 =A0 =A0 run-level 3 =A0Nov 29 10:59 =A0 =A0 3 =A0 =A0 =
=A00 =A0S
>
> > can anyone tell me what each field (output from who -r) represents?
>
> Yes, but you'd get the answer quicker if you did your own research
> (hint: man who).
>
> --
> Rich Teer, SCSA, SCNA, SCSECA
>
> CEO,
> My Online Home Inventory
>
> URLs:http://www.rite-group.com/rich
> =A0 =A0 =A0http://www.linkedin.com/in/richteer
> =A0 =A0 =A0http://www.myonlinehomeinventory.com
uh... i already checked the man page and there is no explanation for
each field so i'm asking in this group.
who -rH produces below output:
# who -rH
NAME LINE TIME IDLE PID COMMENTS
. run-level 3 Oct 23 18:22 3 0 S
But this doesn't make sense to me. PID =3D 0 and COMMENTS =3D S? I know -
H gives just general headings.
I'm curious what they represents.
|
|
0
|
|
|
|
Reply
|
ubyt3m3
|
5/2/2008 2:38:26 AM
|
|
ubyt3m3 wrote:
> On May 1, 10:27 pm, Rich Teer <rich.t...@rite-group.com> wrote:
>> On Thu, 1 May 2008, ubyt3m3 wrote:
>>
>>>> . run-level 3 Nov 29 10:59 3 0 S
>>> can anyone tell me what each field (output from who -r) represents?
>> Yes, but you'd get the answer quicker if you did your own research
>> (hint: man who).
>>
>> --
>> Rich Teer, SCSA, SCNA, SCSECA
>>
>> CEO,
>> My Online Home Inventory
>>
>> URLs:http://www.rite-group.com/rich
>> http://www.linkedin.com/in/richteer
>> http://www.myonlinehomeinventory.com
>
> uh... i already checked the man page and there is no explanation for
> each field so i'm asking in this group.
>
> who -rH produces below output:
>
> # who -rH
> NAME LINE TIME IDLE PID COMMENTS
> . run-level 3 Oct 23 18:22 3 0 S
>
> But this doesn't make sense to me. PID = 0 and COMMENTS = S? I know -
> H gives just general headings.
> I'm curious what they represents.
Those headers don't apply when using -r. You're right the output
isn't documented, but I'm pretty sure the first part is
the current run-level ("3") and the date the run-level was last changed.
The previous run-level ("S") must be4 that last value, but I don't know
what the "3" and "0" in the middle mean, it isn't documented anywhere.
I tried reading the source code for who at
http://src.opensolaris.org/source/xref/onnv/onnv-gate/usr/src/cmd/who/who.c
(and also utmp.h). But a cursory read doesn't show what that output
means:
675 /*
676 * Handle RUN_LVL process - If no alt. file - Only one!
677 */
678 if (utmpp->ut_type == RUN_LVL) {
679 (void) printf(" %c %5ld %c", pterm, utmpp->ut_pid,
680 pexit);
681 if (optcnt == 1 && !validtype[USER_PROCESS]) {
682 (void) printf("\n");
683 exit(0);
684 }
685 }
This appears to be where the final "3 0 S" are printed from,
but without any comments one would have to read and understand more than
this to interpret those values.
A little work with Google reveals this is a common question. I only
found one answer to it, at:
http://unix.derkeiler.com/Newsgroups/comp.unix.solaris/2003-09/1484.html
From: Senthilraja R (sruthrap_at_cisco.com)
Date: 09/12/03
# who -r
.. run level 3 Jun 9 08:30 3 0 S
3- Current run level
0- Number of times at this run level since last reboot
S- Previous run level
But there is no indication that this answer is authoritative.
This really should be considered a bug in the documentation and
could be easily fixed by someone knowledgeable about who.c.
Would one of the Sun people reading this take care of this long
standing omission please, and update the who(1) man page?
Thanks!
-Wayne
|
|
0
|
|
|
|
Reply
|
Wayne
|
5/2/2008 6:23:05 AM
|
|
On May 2, 2:23=A0pm, Wayne <nos...@all4me.invalid> wrote:
> ubyt3m3 wrote:
> > On May 1, 10:27 pm, Rich Teer <rich.t...@rite-group.com> wrote:
> >> On Thu, 1 May 2008, ubyt3m3 wrote:
>
> >>>> =A0 =A0 . =A0 =A0 =A0 run-level 3 =A0Nov 29 10:59 =A0 =A0 3 =A0 =A0 =
=A00 =A0S
> >>> can anyone tell me what each field (output fromwho -r) represents?
> >> Yes, but you'd get the answer quicker if you did your own research
> >> (hint: man who).
>
> >> --
> >> Rich Teer, SCSA, SCNA, SCSECA
>
> >> CEO,
> >> My Online Home Inventory
>
> >> URLs:http://www.rite-group.com/rich
> >> =A0 =A0 =A0http://www.linkedin.com/in/richteer
> >> =A0 =A0 =A0http://www.myonlinehomeinventory.com
>
> > uh... i already checked the man page and there is no explanation for
> > each field so i'm asking in this group.
>
> > who -rH produces below output:
>
> > # who -rH
> > NAME =A0 =A0 =A0 LINE =A0 =A0 =A0 =A0 TIME =A0 =A0 =A0 =A0 =A0IDLE =A0 =
=A0PID =A0COMMENTS
> > =A0 =A0. =A0 =A0 =A0 run-level 3 =A0Oct 23 18:22 =A0 =A0 3 =A0 =A0 =A00 =
=A0S
>
> > But this doesn't make sense to me. =A0PID =3D 0 and COMMENTS =3D S? =A0I=
know -
> > H gives just general headings.
> > I'm curious what they represents.
>
> Those headers don't apply when using -r. =A0You're right the output
> isn't documented, but I'm pretty sure the first part is
> the current run-level ("3") and the date the run-level was last changed.
> The previous run-level ("S") must be4 that last value, but I don't know
> what the "3" and "0" in the middle mean, it isn't documented anywhere.
>
> I tried reading the source code for who athttp://src.opensolaris.org/sourc=
e/xref/onnv/onnv-gate/usr/src/cmd/who...
> (and also utmp.h). =A0But a cursory read doesn't show what that output
> means:
>
> =A0 =A0 =A0675 =A0 =A0 =A0 =A0/*
> =A0 =A0 =A0676 =A0 =A0 =A0 =A0 * =A0 =A0 =A0Handle RUN_LVL process - If no=
alt. file - Only one!
> =A0 =A0 =A0677 =A0 =A0 =A0 =A0 */
> =A0 =A0 =A0678 =A0 =A0 =A0 =A0if (utmpp->ut_type =3D=3D RUN_LVL) {
> =A0 =A0 =A0679 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0(void) printf(" =A0 =A0 %c =
=A0%5ld =A0%c", pterm, utmpp->ut_pid,
> =A0 =A0 =A0680 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0pexit);
> =A0 =A0 =A0681 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0if (optcnt =3D=3D 1 && !vali=
dtype[USER_PROCESS]) {
> =A0 =A0 =A0682 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0(void) print=
f("\n");
> =A0 =A0 =A0683 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0exit(0);
> =A0 =A0 =A0684 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0}
> =A0 =A0 =A0685 =A0 =A0 =A0 =A0}
>
> This appears to be where the final "3 =A0 0 =A0 S" are printed from,
> but without any comments one would have to read and understand more than
> this to interpret those values.
>
> A little work with Google reveals this is a common question. =A0I only
> found one answer to it, at:
>
> http://unix.derkeiler.com/Newsgroups/comp.unix.solaris/2003-09/1484.html
>
> =A0 From: Senthilraja R (sruthrap_at_cisco.com)
> =A0 Date: 09/12/03
>
> #who -r
> . run level 3 Jun 9 08:30 3 0 S
> 3- Current run level
> 0- Number of times at this run level since last reboot
> S- Previous run level
>
> But there is no indication that this answer is authoritative.
>
> This really should be considered a bug in the documentation and
> could be easily fixed by someone knowledgeable about who.c.
> Would one of the Sun people reading this take care of this long
> standing omission please, and update the who(1) man page?
>
> Thanks!
>
> -Wayne- Hide quoted text -
>
> - Show quoted text -
Thanks for the info, Wayne.
|
|
0
|
|
|
|
Reply
|
ubyt3m3
|
5/3/2008 4:35:30 AM
|
|
ubyt3m3 <ubyt3m3@gmail.com> wrote:
>> > can anyone tell me what each field (output from who -r) represents?
>>
> uh... i already checked the man page and there is no explanation for
> each field so i'm asking in this group.
>
> who -rH produces below output:
>
> # who -rH
> NAME LINE TIME IDLE PID COMMENTS
> . run-level 3 Oct 23 18:22 3 0 S
>
> But this doesn't make sense to me. PID = 0 and COMMENTS = S? I know -
> H gives just general headings.
> I'm curious what they represents.
who -H gives the headings that who normaly puts out.
who -r gives run level which is not related to the -H output.
LINE tells you the current run level as does IDLE (for some reason that will break if its an 'S')
COMMENT S means it got to run level 3 from run level S. The 0 may mean
the run level its going to but I'm not sure and the only way is to do a shutdown -i5 and
run who -r and see if it changes. It may also just be a place holder since I don't think
the field can hold an 'S'
None of this is in the man page.
-tim
http://web.abnormal.com
|
|
0
|
|
|
|
Reply
|
Tim
|
5/6/2008 10:31:10 AM
|
|
|
14 Replies
259 Views
(page loaded in 0.18 seconds)
Similiar Articles: Troubleshooting SCSI tape drive -- with machine running? - comp ...TIA and HAND, > > > Chris > Start by running devfsadm and "cfgadm -a". For a closer look at what is happening on the scsi level, if you are running solaris 10 or ... Solaris 10: cannot gracefully shutdown legacy services? - comp ...i want to know quantize level. - comp.soft-sys.matlab Solaris 10: cannot gracefully shutdown legacy services? - comp ... Solaris 10 legacy run initscripts at shutdown ... gdb for Solaris 10 - comp.unix.solaris... any gdb version available for Solaris 10? I ... NAME: gdb - GNU source level debugger ... comp.unix.solaris ... gdb for Solaris 10 - comp.unix.solaris Opteron clusters running ... Solaris 10 legacy run initscripts at shutdown - comp.unix.solaris ...i want to know quantize level. - comp.soft-sys.matlab Solaris 10: cannot gracefully shutdown legacy services? - comp ... Solaris 10 legacy run initscripts at shutdown ... smf: setting debug level in named? - comp.unix.solarissmf: setting debug level in named? - comp.unix.solaris i want to run named (dns/server) at an elevated debug level. smoking# svccfg -s dns/server listprop shows a bunch of ... What is the minimum hardware requirement for installing and ...... like to know what is the minimum hardware requirement for installing solaris 10? ... What is the minimum hardware requirement for installing and running solaris 10? install_cluster in Solaris 10 Recommended Patch Cluster - comp ...In releases before Solaris 10 NFS client was started at level 2: $ ls -al /etc/rc?.d/*nfs ... can be done but what about machines that are already running Solaris 10 ... What version of Solaris 10 Kernel am I running? - comp.unix ...I have some confusion over the version of the Solaris Kernel I am running. The base install is Solaris 10u4. Having conversations with Sun they are ... shutdown vs. reboot - comp.unix.solarisIn Solaris 10 (I don't know what version it first appeared), the bottom of the man ... your system? /etc/rc0.d/K* is the ticket; are you shutting down through run-level 5 ... How to detect if solaris is running as a guest machine - comp.unix ...Hello, Is there a way to know if solaris operating system is running as a guest virtual machine on a physical host ? There is a utility "virt-... Mounting Cdrom Solaris10 running on VMware - comp.unix.solaris ...Hello everybody, I'm newbie at Solaris and need some help about mounting cdrom. I have a solaris 10 VM running on VMware. While setup, I forgot to a... Solaris 10 floppy disk?? - comp.unix.solarisWhat is the secret to mounting a floppy disk under Solaris 10 ... Solaris 10 floppy disk?? - comp.unix.solaris I'm now running Solaris-9, and am planning to install 10. Max # of files allowed in directory under UFS & under VxFS ...... in a directory under UFS in Solaris 10 ... you can put them in at least 2 levels ... idiot developer left something running while she went on vacation. It wasn't Solaris ... Solaris 10 build number? - comp.unix.solaris... it may be possible to uplift a system with patchadd to the same level as a Solaris ... If you don't need fcinfo you won't notice any difference in running a Solaris 10 03/05 ... Can ufsrestore restore files to a ZFS file system? - comp.unix ...I have a Sun Blade 2000 running Solaris 10 update 5 which is fitted with ... I have a Sun Blade 2000 running Solaris 10 update 5 ... created a level 0 dump of this file ... What is a 'run-level' in Solaris 10? - Database Support @ dbaspot ...In another group someone asked how to get the run-level. who -r is the answer I gave, but even though this is still described in the Solaris 10 who(1) man page, I'm ... Solaris Run level change - nixCraft: Linux Tips, Hacks, Tutorials ...run-level 3 Mar 3 14:04 3 0 S. Solaris changing runlevels after bootup You need to use init command, for example change runlevel to 2. 7/25/2012 5:11:12 AM
|