• 0601月1,2,3日

    2006-02-10

    Tag:

    版权声明:转载时请以超链接形式标明文章原始出处和作者信息及本声明
    http://mmmmn.blogbus.com/logs/1905655.html

    1、There is a script being triggered by root occassionally. I have checked

    the cron file but no avail. Is there a way to track which process trigger the

    script?

    PS: I have which script is being triggered.
    If you can modify the script, just add "ptree $$" to the top of it.
    Try "ptree $$" at the command line to get an idea what it does.


      - Logan

    2、I have Solaris 10 standard running on a SunBlade 1000 server,
    and this server's SVGA output is connected to my TV SVGA
    input (Proscan PS3600).

    Wow, I've never heard of a television with a VGA input, but
    googling seems to confirm that, yes, the Proscan PS3600 really
    is a television.  Interesting.


    Two questions:


    (1) I can see ASCII output in tty mode (before dt/X
    starts), but its too big and wraps around the screen.
    So, for example, a "ps -ef | more" scrolls too far
    and also it wraps around the screen because the font
    is not correctly set. I tried 'stty rows|cols' as
    well as changing the equivalent values at the OBP
    level, both with no luck.

    I think the problem is that the video is not being sent
    in a resolution that the TV can handle, and I don't think
    setting the tty values is going to help this.


    Does anyone know how to adjust this? Im used to
    the serverless world.

    Serverless world?  Sounds nice, although I guess you
    mean monitorless server world or something like that,
    perhaps?


    (2) DT/X is not able to start, I think for the same
    reason since, when I try to start it, the TV clicks
    a few times in trying to sync up, then gives up and
    goes back to text mode - and I get a message indicating
    that I cannot start X on DISPLAY :0.

    It could be instructive to look at /var/dt/Xerrors to
    get more detail about the errors that the X server is
    having when trying to start.


    I thought xdmconfig(1M) would help but Im not sure
    if that comes on SPARC distributions (I can't find
    it on my system and I loaded the Entire Distribution
    less OEM support).

    I think you mean kdmconfig, not xdmconfig.  I've never
    used the particular machine you're talking about, but
    it seems that fbconfig would be worth a try.  You could
    probably use that to set the resolution and refresh rate
    to something your TV/monitor can cope with.


      - Logan


    3、>
    > Stupid question here: what is type 'f'?

    'man prototype' -- basically, he's referring to a certain field in one
    of the files comprising a package; it's got meta information about the
    package contents itself.

    'f' here refers to a file or directory that is *not* expected to change;
    Solaris will perform and store a checksum on it at installation time.

    This is how the sheer majority of files in any given package is
    specified and delivered.

    -Dan
    ----
    >> Stupid question here: what is type 'f'?
    >
    > 'man prototype' -- basically, he's referring to a certain field in one
    > of the files comprising a package; it's got meta information about the
    > package contents itself.
    >
    > 'f' here refers to a file or directory that is *not* expected to change;
    > Solaris will perform and store a checksum on it at installation time.

    The problem isn't the checksum (setting the setuid bit doesn't change the
    checksum - just the file mode). But probably the change might be overwritten
    by a patch.

    No problems - just re-apply your changes after patch install. I haven't seen
    a patch failed to apply if a "required" file was missing or has been changed.

    Or mustn't I from now on do
    rm -f /etc/rc3.d/S75seaport
    after Solaris installation?

    Ok, this package was probably mispackaged. Usually scripts in /etc/rc?.d
    are of type "l" with hardlinks to /etc/init.d (I prefer symlinks though).


    4、> but ...
    > ERROR: The boot environment <s10_hw1> contains the GRUB menu.
    > ERROR: You are not allowed to delete this BE.
    > Unable to delete boot environment.

    > So I cannot get rid of the s10_hw1 boot environment because GRUB is still
    > located on this disk. So I cannot re-mirror the new boot device.

    > How am I supposed to move GRUB to c4d0s0? In which magical places does GRUB
    > and LU note the boot device?

    Here's some notes...
    http://blogs.sun.com/roller/page/jclingan?entry=up_and_running_centos_under

    > BTW: How does GRUB work with mirrored root devices? With the old

    boot-loader
    > I had "bootpath" ald "altbootpath". What if the disk with GRUB installed
    > fails?

    Same thing that used to happen. Your system needs to try to "boot" from
    both disks, and you need to have a bootloader on both. I'm guessing
    that the old installer doesn't understand all the new grub stuff yet,
    but then I didn't think it always did the right thing on the old one
    either.

    > <rant>
    > I really disliked GRUB from the first moment I saw it on Solaris Express.
    > I'm missing the simple "b -s" or "b -v" boot parameters. Instead I have to
    > go through a bunch of GRUB menus to change the boot parameters...
    > </rant>

    I find it a little opaque because I'm not used to it, but the
    flexibility it gives is *so* much better than the old stuff. Trying to
    PXE boot via newer network devices was just impossible.

    Have you read through the FAQ on it? Seeing some of the details makes
    it a bit less frightening to me...

    http://www.sun.com/bigadmin/features/articles/grub_boot_faq.html

    --
    >> How am I supposed to move GRUB to c4d0s0? In which magical places does

    GRUB
    >> and LU note the boot device?
    >
    > Here's some notes...
    > http://blogs.sun.com/roller/page/jclingan?entry=up_and_running_centos_under

    Yes, I already figured that out by myself. But isn't there an official way
    of getting rid of the old boot environment.

    >> <rant>
    >> I really disliked GRUB from the first moment I saw it on Solaris Express.
    >> I'm missing the simple "b -s" or "b -v" boot parameters. Instead I have to
    >> go through a bunch of GRUB menus to change the boot parameters...
    >> </rant>
    >
    > I find it a little opaque because I'm not used to it, but the
    > flexibility it gives is *so* much better than the old stuff. Trying to
    > PXE boot via newer network devices was just impossible.

    What I dislike most is the creation of the boot archive. It adds another
    level of redundancy/indirection and isn't transparent (I cannot use safely
    "uadmin 2 6" to quickly power-off my machine any more ...)

    --


    5、> Group,
    >
    > I have a solaris 10 (V880) system and have set up disk suite for the
    > root disk. I have a couple of problems. The meta device d3 is /usr and
    > following the reboot I have this symptom
    >
    > d3: Mirror
    > Submirror 0: d13
    > State: Needs maintenance
    > Submirror 1: d23
    > State: Needs maintenance
    > Pass: 1
    > Read option: roundrobin (default)
    > Write option: parallel (default)
    > Size: 12720000 blocks (6.1 GB)
    >
    > d13: Submirror of d3
    > State: Needs maintenance
    > Invoke: after replacing "Maintenance" components:
    > metareplace d3 c1t0d0s3 <new device>
    > Size: 12720000 blocks (6.1 GB)
    > Stripe 0:
    > Device Start Block Dbase State Reloc Hot Spare
    > c1t0d0s3 0 No Last Erred Yes
    >
    >
    > d23: Submirror of d3
    > State: Needs maintenance
    > Invoke: metasync d3
    > Size: 12720000 blocks (6.1 GB)
    > Stripe 0:
    > Device Start Block Dbase State Reloc Hot Spare
    > c1t1d0s3 0 No Okay Yes
    >
    >
    > Device Relocation Information:
    > Device Reloc Device ID
    > c1t0d0 Yes id1,ssd@n20000004cf98c53d
    > c1t1d0 Yes id1,ssd@n20000004cf98d6b6
    >
    >
    > When I try "metareplace -e d3 c1t0d0s3" I get "metareplace: gunss801:
    > d3: c1t0d0s3: component in invalid state to replace - Replace
    > "Maintenance" components first"
    >
    > Also following a reboot, all the metadevices come up as "Needs
    > maintenance" and all they require is metasync d0 d1 etc.
    >
    > Any ideas?
    >
    > Thanks,
    > Vic
    >

    I don't know if this is the correct answer, but when I had similar problems
    before, I used metadetatch and the metaclear, to stop the disks being
    mirrored, then set it up again with metainit and metattach.
    That worked for me....

    6、Thanks for the reply, thats a good idea but since I use logger with the -f

    flag which reads from a serial port how do I prepend the serial message with

    `date`?


    cheers

    Michael


    How about something like this, where you just need to sort out the format of

    the date to add to the awk command?


    # cat /dev/term/a | awk '{ print $0}' | logger

    -------
    With a quick search on the web, I found this would work. It seems to need

    /usr/xpg4/bin/awk, not /bin/awk. It logs my commands on ther serial port,

    pre-pending the date.

    chaffinch # cat /dev/term/a | /usr/xpg4/bin/awk '{ "date +%H:%M:%S" | getline

    D;print D" "$0 ;close("date +%H:%M:%S")}'


    13:32:51 ls
    13:32:53 pwd
    13:33:01 date
    --------


    8、Then suddenly I remembered that FTP was trying to use /bin/ls command.
    So just did ls -lrt in / fs and found that a sym link of bin to
    /usr/bin was missing. I created with ln -s /usr/bin bin and TELNET
    STARTED WORKING!! MY MY!!

    Not surprising:


            $ strings /usr/sbin/in.telnetd | grep /bin
     /bin/login
     SHELL=/bin/sh
     /bin/login
     $


    As far as I know, telnetd just prints a banner message and then connects
    you up to /bin/login to do the authentication, starting of the shell,
    etc.  So if it can't find /bin/login...


      - Logan


    9、> I just did S10 -> S10U1 LU (SPARC) and the procedure for creation of SVM
    > RAID-1 based new BE described in
    > http://docs.sun.com/app/docs/doc/817-5505/6mkv5m1lq?a=view didn't work.
    >
    > The original BE (S10 FCS) has /, swap and a couple of other (shared
    > between BEs) filesystems, all mirrored with SVM. The new BE (S10 U1) is
    > supposed to have the very same disk layout. Accordingly to the book,
    > mirrored root device for the new BE is supposed to be created with
    > something like
    >
    > lucreate -A 'mydescription' \
    > -m /:/dev/md/dsk/d10:ufs,mirror \
    > -m /:/dev/dsk/c0t0d0s0,d1:attach \
    > -m /:/dev/dsk/c0t1c0s0,d2:attach -n another_disk
    >
    > That didn't work in the sense that lucreate complains that it knows
    > nothing about /dev/md/dsk/d10 (well, indeed, it doesn't exist yet)
    > instead of creating it as instructed. Only after the new mirror, d10,
    > is fully configured (w/o newfs, of course) by hand and the example above
    > is reduced to just
    >
    > lucreate -A 'mydescription' \
    > -m /:/dev/md/dsk/d10:ufs -n another_disk
    >
    > things work. LU certainly understands SVM configuration, it correctly
    > determines physical boot devices for both old and new BE, etc., but the
    > promised ability to perform simple volume management operations seems to
    > be not there.
    >
    > It's been repeatedly stated in many documents, with command line
    > examples that look consistent, that current LU properly supports [not
    > too sophisticated] SVM configurations. So why didn't it work for me?
    >

    I can't tell you why it did not work for you, because there is too few
    information.

    But I can tell you what I usually do:

    I usually have a layout like this:
    two physical disks - e.g. c1t0 and c1t1 (even better c2t0)
    on each disk there is a slice for swap (slice 0), root (slice 1), and
    svm metadata (slice 7).

    Then svm has a submirror for each root and swap slice and a mirror
    for swap and root.

    e.g. d0 consists of d100 (c1t0d0s0) and d110 (c1t1d0s0)
    d1 consists of d101 (c1t0d0s1) and d111 (c1t1d0s1)
    c1t0d0s7 and c1t0d0s7 contain the metadata

    for a live upgrade I break the mirror and preserve its data:

    #### I guess the following line is the one most important to you:
    #### you must name the mirror and its submirrors (at least one)
    #### to get a valid setup.
    lucreate -n new_be -m /:d2:ufs,mirror -m /:d111:detach,attach,preserve

    The I upgrade new_be and boot it.
    If everything is fine I delete the old boot environment

    $ ludelete old_be

    clear off the old mirror
    $ metaclear d1

    and attach its submirror to the new root mirror
    $ metattach d2 d101

    Works for me.

    ---------
    > Tom,
    >
    > thanks for your response. My understanding, however, is that your
    > scenario is just one of the possible ways to deal with mirror-to-mirror
    > upgrade. It's an advantage if you want to avoid the step of copying the
    > entire old BE: everything's already there when a detached submirror is
    > used as a basis for the new BE.
    >
    > I'm talking about another scenario when the target (new BE) mirrored
    > root device is to be built from scratch as a part of the new BE creation
    > procedure. [Think of an upgrade from non-SVM BE to SVM-RAID-1 based BE:
    > you don't have a detachable submirror as a starting point in such a case.]
    >
    > As to the insufficient information, what more needs to be told? The old
    > BE is completely patched, including the "laundry list" from InfoDoc
    > 72099. The problem still is lucreate wants the target mirror it's
    > supposed (accordingly to all documentation) to create to be already
    > existent. As soon as the mirror is made outside of the LU process, it
    > can be used by lucreate as any other, regular slice. Does this behavior
    > somehow depend on the particular SPARC model, or physical disks/HA
    > configuration? Did it work for anybody as described? -- that's what's
    > most interesting to me.
    >
    > Or I'm not getting something essential here?
    >

    yes, the tagged lines, I would say.
    The command I mentioned also works if you have a 3-way mirror and no
    boot environment setup. This is pretty similar to no boot environment
    and mirror on new boot environment.

    But to make a long story short, look at example 8 of lucreate(1M). I
    think this is very close to what you want...


    ---------
    > Well, example 8 in lucreate(1m) man page is exactly what I wanted,
    > exactly what I quoted in my original message and exactly what did not
    > work for me. This part 1 in
    >
    > Example 8: Using Solaris Volume Manager Volumes
    >
    > The command shown below does the following:
    >
    > 1. Creates the mirror d10 and establishes this mirror as
    > the receptacle for the root file system.
    >
    > is what was my problem: lucreate did not show any intention to *create*
    > the requested mirror, it wanted it to be already created.
    >
    > Anyway, to make this too long already story even shorter: I managed to
    > do all I needed, although a slightly different way, and I can live with
    > it: not by the book, but it worked.
    >
    > Thanks!
    >

    but that's what the book ought do be for. I suppose you don't have any
    log of what happened - somebody might care... I only once had a problem
    with liveupgrade, when it denied creating a root mirror on slice 0. I
    cannot remember what the problem back then was.


    -------
     LiveUpgrade -- Sun Jan 1 12:37:29 EST 2006
    > + 1> /opt/local/install/upgrade2.log
    > + lucreate -c s10fcs -n s10u1 -A Solaris 10 Update 1 -m
    > /:/dev/md/dsk/d3:mirror,ufs -m /:/dev/dsk/c0t0d0s3,d103:attach -m
    > /:/dev/dsk/c0t2d0s3,d123:attach
    > Discovering physical storage devices
    > Discovering logical storage devices
    > Cross referencing storage devices with boot environment configurations
    > Determining types of file systems supported
    > Validating file system requests
    > ERROR: device </dev/md/dsk/d3> does not exist
    > ERROR: device </dev/md/dsk/d3> is not available for use with mount point
    > </>
    > ERROR: cannot create new boot environment using file systems as configured
    > ERROR: please review all file system configuration options
    > ERROR: cannot create new boot environment using options provided
    >
    >

    In my eyes this should have worked...
    .



    收藏到:Del.icio.us