Berkeley CSUA MOTD:Entry 40320
Berkeley CSUA MOTD
 
WIKI | FAQ | Tech FAQ
http://csua.com/feed/
2025/04/04 [General] UID:1000 Activity:popular
4/4     

2005/10/28-31 [Computer/SW/OS/Solaris, Computer/SW/Unix] UID:40320 Activity:moderate
10/28   Docs say I can't do dd from disk that is in use.
        This seems (based on my bad memory) to be contrary to my experience.
        Any opionions on duping an inuse disk (to a non-inuse one).
        this is on solaris 8.
        \_ live update, ufsdump, rsync, dd... you want your filesystem
           as quiesced as possible though for all of the above
        \_ what the above and others say about quiet drives and RO and then:
           since you don't tell us what problem you're trying to solve, my
           very generic advice is this:  dd the drive so you get boot blocks
           and other fun stuff you might want, then do an rsync after that just
           for kicks in the hopes of catching a few of the files that might
           have been in use while doing dd.  no, this followup rsync will not
           make a perfect mirror on an active disk but if you wanted to do a
           real backup, you'd use real software for it or at least take the
           source drive offline.  you're well into kludge territory already,
           anyway.
        \_ You can dd from a disk that is in use. You will obviously not
           get an exact duplicate and, as above, I would not try this
           on a very busy filesystem. However, it works fine under Solaris
           9/10 and Red Hat Linux. I've done this to make 'backup' disks
           (successfully) many times.
        \_ If you need to keep the filesystem mounted RW, I'd suggest
           using rsync rather than dd. If the filesystem is mounted RO
           it seems like dd would be fine.
           \_ Rsync is slower and won't grab the boot blocks (if you want
              them).
                \_ rsync is NOT slower than DD unless the filesystems are
                   basically full. -top
                   \_ Yes, it is. Best case scenario (using the right
                      rsync options) they are about equal. "dd" can use
                      the raw device and bypass the filesystem entirely.
                      Amended: You are right that if the filesystem/disk is
                      not very full then "dd" will be slower merely because it
                      is copying "empty" space but not because "dd" is
                      intrinsically slower.
        \_ What problem are you trying to solve?
           What are your priorities?
                      \_ so it's not "intrinsically slower", it just takes
                         longer to run?  Get a clue.  -tom
                         \_ I think you need the clue, tom. "dd" is
                            faster. If you want to prune the list of files
                            you want to "dd" first it will kick the butt
                            of "rsync". You know that, too, but you just
                            like to argue. When copying the exact same
                            volume of data, "dd" is faster.
                            \_ While driving a car is faster than walking,
                               walking from Telegraph and Bancroft to
                               Telegraph and Durant is much faster than
                               driving.  "dd is faster" is meaningless
                               unless the problem is well-defined.  -tom
                               \_ Even your example is false.
                                  \_ Alright, we're convinced: you're an idiot.
                                     You don't have to try this hard just for
                                     us.
                                     \_ You may as well say that a plane
                                        is slower than walking, too. The
                                        statement about a 'well-defined'
                                        problem is your own parameter but
                                        doesn't change the fact that
                                        planes are faster than walking.
                                        \_ To put this in a way that even
                                           an idiotic computer geek might
                                           understand, if you have two
                                           different sort algorithms,
                                           one that's usually faster in
                                           practice but O(N^2), and one
                                           that's usually slower in practice
                                           but O(N log N), it makes no sense
                                           to say that one is intrinsically
                                           faster than the other.  It
                                           depends on the problem you have
                                           to solve.  -tom
                            \_ HAMMER GOOD!
                               If you took a second to think, you'd realize
                               you're clueless.  Or maybe not.  It's dim.
                               \_ Do you know what the word 'intrinsic'
                                  means?
                                  \_ Yes.  You seem to have trouble with the
                                     word 'slower', though.
                                     \_ "dd" is intrinsically faster.
                                        \_ Not for the problem posed (ergo
                                           "HAMMER GOOD").  If you want to
                                           keep spouting your technically
                                           correct and completely irrelevent
                                           point, by all means...  You will
                                           still be wrong.
                                           \_ You have come to know that which
                                              is tom.
                                              \_ hey moron: he's replying to
                                                 !tom.
                                           \_ We don't even *know* what the
                                              problem posed is yet. However,
                                              we do know the guy wants to
                                              use 'dd' to solve it. Rsync
                                              may not even be a viable
                                              solution in this particular case.
        \_ What problem are you trying to solve? What are your priorities?
        \_ try using solaris' Volume Manager (also known as disksuite).
           create a one way mirror containing the current live FS as the
           initial submirror, then attach the second empty FS as another
           submirror.  wait for the second submirror to sync up, then at
           your leisure, detach the second submirror.
           look at metadb, metainit, metattach, metadetach, metaclear,
           and other "meta"commands. --Jon
           look at metadb, metainit, metattach, metaoffline/online,
           metadetach, metaclear, and other "meta"commands. --Jon
           \- i have a solaris 10 sunblade 1500 which some colleages
              wanted to clone to save time. i rebooted my machine and used
              /usr/bin/dd if=/dev/dsk/c0t0d0s2 of=/dev/dsk/c0t1d0s2 bs=1000k
              and thne fscked. all the machines work fine ( 5 clones). it
              sounds like you know what the issues are so just take this an
              a data point. 73gig disks ... i think it tok 40min or so.
              oh i am sure i booted it su and killed off most of the
              processes before running dd.
              \_ The thing with the Solaris LVM method is that you don't
                 really need to have the filesystem quiescent.  You get a
                 valid, consistent snapshot at the time of metaoffline or
                 metadetach. --Jon
              \_ As long as you understand this isn't considered "production
                 quality", if that worked for you, great.  I wouldn't do that
                 for something going into a data center 24x7, etc.
                 \- i bet lot of production operations were running on
                    less reliable windows installations (i dont know how
                    reliable windows OS is today). anyway, these are
                    cheep sun workstations with ide disks, so what do you
                    think. anyway, it seemed to be the OP was aware of the
                    "issues" and was just interested if it was "crazy talk"
                    [you'ld be lucky if it worked] vs. 99%chance it should
                    be fine. hence the "datapoint x5" comment.
                    \_ who said that just because you put a windows box in
                       production means its production quality?  thanks for
                       pointing out they're workstations.  that was so unclear.
                       i was pointing out that this isn't production quality.
                       sheesh.
                       \- are you a frequent visitor to Casino Troll?
                       \_ And what is "production quality"? This is essentially
                          what tools like "System Imager" do. What are you
                          afraid of? 'cksum' the OS if you want to. Bits
                          is bits.
                          \_ PQ: built correctly, not a hack job with dd
                             from another box.  Something you'd bet your
                             career on.  Workstation for the guys?  Whatever.
                             Server in the colo running critical db?  No way
                             is that getting built from a dd clone off a hot
                             drive.  Building a few dozen/hundred/whatever
                             web/whatever servers?  Jump/Kick Start.  I've
                             done the clone thing for workstations.  I'd
                             never do it for servers.  If you want to discuss
                             it in detail, post your name and we'll take it
                             to email.
2025/04/04 [General] UID:1000 Activity:popular
4/4     

You may also be interested in these entries...
2010/2/8-18 [Computer/SW/Apps/Media, Computer/SW/Apps] UID:53695 Activity:kinda low
2/5     I like Adobe Flash. When written correctly, it scales along
        with your browser size. It looks consistent on every single
        browser. It is predictable. On the other hand, I'm not a big
        fan of CSS/HTML, which for the most part, look wildly different
        between browsers, and don't even work consistently or
        correctly at times. So why do so many people (like Steve Jobs)
	...
2009/10/27-11/3 [Computer/SW/Unix] UID:53475 Activity:nil
10/27   http://www.maxgames.com/play/flash-mind-reader.html
        how does this work?
        \_ sh -c 'for ((i=0;i<10;i++)); do for ((j=0;j<10;j++)); do echo "$i$j-(\
$i+$j)" | bc; done ; done' | uniq
        \_ bash -c 'for ((i=0;i<10;i++)); do for ((j=0;j<10;j++)); do echo "$i$j\
-($i+$j)" | bc; done ; done' | uniq
	...
2009/4/20-23 [Computer/SW/Database] UID:52876 Activity:nil
4/19    ORCL u SUNW = ORCL.
        What is Larry Ellison thinking? What is he going to do with a bunch of
        legacy Sun hardware that no one uses anymore, its fading workstation
        customer base, and open source Sun MySQL that doesn't even generate
        revenue? I really don't get all this acquisition business.
        \_ A lot of big companies still use big, fat Sun hardware. Or use
	...
2009/1/15-23 [Computer/SW/OS/OsX] UID:52398 Activity:nil
1/15    can any serious development be done on OSX that is not *for OSX*.
        i'll grant that ruby on rails has excellent tutorials for the mac.
        discuss:
        \_ What kind of serious development?  If you want to use the standard
           OSX ui then your ui code will be pretty much useless elsewhere,
           but that's why concepts like MVC are so important.  Otherwise
	...
2008/11/29-12/6 [Computer/SW/OS/FreeBSD, Computer/SW/OS/VM] UID:52129 Activity:moderate
11/29   I'm experimenting with virtualization, and as a poor college student
        I'm wondering what the best alternatives for virtualization are, and
        how best to cut my teeth on messing with non-linux platforms (or I
        guess interesting stuff on Linux would work too). Right now I've got
        FreeBSD7 running on KVM on my home computer (on a Core 2 Quad), and am
        somewhat at a loss as to how to use it. (More details: bridged
	...
2008/11/14-26 [Computer/SW/Languages/Java, Computer/SW/OS/Solaris] UID:51970 Activity:moderate
11/13   http://sfgate.com/cgi-bin/article.cgi?f=/n/a/2008/11/14/financial/f051352S72.DTL
        http://preview.tinyurl.com/6nngpm
        Sun Microsystems Inc. plans to cut up to 6,000 jobs, or 18 percent of
        its global work force, as sales of its high-end computer servers have
        collapsed.  The drastic move announced Friday highlights Sun's
        desperation to cut costs and survive as an independent company. Sun's
	...
2008/11/14-26 [Computer/SW/OS/Linux, Computer/SW/OS/Solaris] UID:51989 Activity:moderate
11/14   lulz why doesn't GOOG buy JAVA i mean SUN i mean whatever the hell they
        are these days.
        \_ Even GOOG isn't THAT stupid
           \_ Sorry, but WHY would Google do something like that? They
              run 99.2% Linux servers on the backend. They don't use
              Solaris for development. I mean, what does Sun have to
	...
2008/9/24-29 [Computer/SW/OS/Windows, Computer/SW/OS/Solaris] UID:51283 Activity:nil
9/24    Why is nscd going crazy?  DoS?
        \- back in the solaris say 2.5-2.6 era, it had both some bugs
           (some malformed nis maps made it go crazy) and architectural
           flaws in the IPC/door+threading mechanism. if you are running
           OS-recent, dunno, but you can trace it.
           \_ Yeah, I think it's just buggy.  I've restarted it, and it seems
	...
2008/4/3-9 [Computer/SW/Languages/Misc, Computer/SW/OS/Solaris] UID:49658 Activity:nil
4/3     Solaris experts: I've never played with ZFS. Does it have a native
        dump command a la ufsdump?
        \_ This might be what you are looking for:
           http://preview.tinyurl.com/2xqkda [sun - bigadmin]
	...
2008/3/30-4/6 [Computer/SW/OS/Solaris] UID:49614 Activity:nil
3/30    Question: I just deleted 60 GB of files from an 80 GB disk. The
        disk activity lights were blinking like crazy and I could hear the
        drive crunch while the data was deleted. This is under Solaris.
        Anyway, I think UNIX uses unlink() when files are deleted. Shouldn't
        it just update the free list on the superblock and call it a day?
        What is all the crunching about?
	...
2007/11/27-30 [Computer/SW/Languages/C_Cplusplus, Computer/SW/OS/Solaris] UID:48701 Activity:high
11/27   I'm using select to do a nonblocking check to see if a single socket
        has anything to read off it.  Problem is, I can have up to 12228
        file descriptors, and Linux fd_set only supports up to 4096.  Any idea
        what I can do about this?  (Or a better solution?) -jrleek
        \- 1. who are you
           2. i am busy this week and you didnt mention language
	...
2012/8/30-11/7 [Computer/SW/Apps, Computer/SW/Unix] UID:54470 Activity:nil
8/30    Is wall just dead? The wallall command dies for me, muttering
        something about /var/wall/ttys not existing.
        \_ its seen a great drop in usage, though it seems mostly functional.
            -ERic
        \_ Couldn't open wall log!: Bad file descriptor
           Could not open wall subscription directory /var/wall/ttys: No such file or directory
	...
2011/11/20-2012/2/6 [Computer/Companies/Apple, Computer/SW/Unix] UID:54237 Activity:nil
11/20   Are there tools that can justify a chunk of plain ASCII text by
        replacing words with words of similar meaning and inserting/removing
        commas into the text?  I received a 40-line plain text mail where
        all the lines are justified on left and right.  Every word and comma
        is followed by only one space, and every period is followed by two
        spaces.  The guy is my kid's karate instructor which I don't think is
	...
2011/10/26-12/6 [Computer/SW/Unix] UID:54202 Activity:nil
10/24  What's an easy way to see if say column 3 of a file matches a list of
       expressions in a file? Basically I want to combine "grep -f <file>"
       to store the patterns and awk's $3 ~ /(AAA|BBB|CCC)/ ... I realize
       I can do this with "egrep -f " and use regexp instead of strings, but
       was wondering if there was some magic way to do this.
       \_ UNIX has no magic. Make a shell script to produce the ask or egrep
	...
2011/9/14-10/25 [Computer/HW/Drives] UID:54173 Activity:nil
9/13    Thanks to Jordan, our disk server is no longer virtualized. Our long
        nightmare of poor IO performance should hopefully be over. Prepare for
        another long nightmare of poor hardware reliability!
        ...
        Just kidding! (I hope)
        In any case, this means that cooler was taken out back and shot, and
	...
2010/11/21-2011/1/13 [Computer/SW/Languages/Web] UID:53988 Activity:moderate
11/21   Lifehacker's recommending Dreamhost as a personal web hosting service.
        Apart from csua, who do you guys use? --erikred
        \_ What do you want to use it for? Do you need CGI or PHP?  My
           brother worked for Dreamhost and said they are unethical. In
           fact, he sued them. This refers to their treatment of customers
           and employees both. I don't know who  or what "Lifehacker" is,
	...