OpenBSD Journal

Growfs support for OpenBSD

Contributed by jose on from the expandable-filesystems dept.

tony writes: "When I got back from my awesome job cleaning airplanes at 2am, I was checking some email, and noticed that on the source-changes@ mailing list, growfs support was added to the OpenBSD repository.

You can read about growfs here . It's a FreeBSD specific article, but growfs was mostly imported from FreeBSD anyway, and will give you a run-down on the tool and how to use it."

There have been countless times I needed to do this, and I'm sure you've been in the same boat. Check this out and remember, back up your data before you play with the filesystem.

(Comments are closed)


Comments
  1. By Anonymous Coward () on

    How about shrinkfs?

    Comments
    1. By tedu () on

      everybody knows bigger is better. who wants a smaller file system? :)

      if you really want, you can pull resizefs from netbsd cvs, which should compile cleanly enough. it won't be making it into base however.

      Comments
      1. By gwyllion () on

        Why didn't you port resizefs instead of growfs? Resizefs allows both growing and shrinking, so it seems more feature rich.

        Comments
        1. By Anonymous Coward () on

          "feature rich"

          some how that is good?

          Comments
          1. By Anonymous Coward () on

            what is wrong with reiserfs?

            Comments
            1. By Anonymous Coward () on

              license

            2. By grey () on http://mail-index.netbsd.org/current-users/2001/11

              http://mail-index.netbsd.org/current-users/2001/11/09/0013.html

              Link above has a quick note of why growfs for the time being might be preferable to the NetBSD resizefs implementation; apparently resizefs is known to be buggy, whereas growfs is known to work.

              Seek the orac... the google.

  2. By Anonymous Coward () on

    How about UFS2 ?

    Comments
    1. By Anonymous Coward () on

      How about ReiserFS ?

      Comments
      1. By tedu () on

        How about FFS?

        Comments
        1. By Anonymous Coward () on

          "How about FFS?"

          I second that.

          Comments
          1. By Anonymous Coward () on

            No journalisation.
            No transaction.
            No grouping of small files into the same block (which saves a lot of disk space on mail servers).

            Comments
            1. By RC () on

              Who needs Journaling exactly? People seem to like it for the improved performance over nothing at all, but softupdates make that moot. FSCK times are also considered... I don't know about you, but my large systems NEVER crash, and they are on UPSes and automatically shutdown properly in case the UPS runs low on power. Also, background FSCK that FreeBSD5 offers would take care of that.
              So what does journaling (or tranactions) offer?

              If you have a lot of small files, use a smaller block-size. That's why it's an option... so you can choose what's best for your system.

              Comments
              1. By Anonymous Coward () on

                FSCK times are also considered... I don't know about you, but my large systems NEVER crash...

                My workstation has 3 40gb drives in it. As it's my workstation, sometimes i manage to panic it, and when i do it can be a long fsck wait. Usually i 'boot -s' and fsck/mount the larger partitions by hand, after the rest of the system is up, but a background fsck would be a great addition.

                Comments
                1. By tedu () on

                  mount -f

                  Comments
                  1. By Anonymous Coward () on

                    In the past that's led to hard hangs, so i've been pavlov'd into fsck before mount.

              2. By Anonymous Coward () on

                http://www.usenix.org/publications/library/proceedings/usenix2000/general/seltzer.html

            2. By Anonymous Coward () on

              There are one or two efforts to port a journalled file system. Suggest you either join one, start your own project, or sit on your own face and like it.

            3. By krh () on

              I don't *want* journaling or transactions. I want Soft Updates. I feel more comfortable with the guarantees provided by a properly working Soft Updates system than I do with those provided by a properly working journalling filesystem.

              But grouping small files into the same block would be nice.

              Comments
              1. By tedu () on

                maybe FFS could divide blocks into 8 pieces, and use these "fragments" for storing small files. i'll work on that. :)

      2. By Jadipai () on

        Of course, it can't be integrated. Everyone should know that. Really, it should be interesting to know about UFS2. I guess FreeBSD has had it for long. Some smart person post something intelligent. I'm sick of these toy messages...

        Comments
        1. By Anonymous Coward () on

          NetBSD-current has it. When OpenBSD needs it, they'll take it from NetBSD. Good to know that OpenBSD is adopting some FreeBSD innovations. Hope they can extend/improve growfs.

        2. By tedu () on

          no shipping release of an OS has UFS2. NetBSD 2.0 is like two years away based on their release schedule. FreeBSD is still not advocating 5 for production use. hell, i couldn't even install it! Both projects had some serious problems with the integration. File system eating bugs are not cool, and with a 6 month release schedule, nobody is importing code that hasn't been proven stable.

          Comments
          1. By Anonymous Coward () on

            I haven't had any problems with UFS2. I'm using it now. NetBSD integrated it only a few months ago, so they still may be having problems with it. I don't read many complaints about it though on FreeBSD mail lists. They made it the default file system after all in 5. 5's problems are with recent versions of GNU's compiler and the never ending task of pushing down the GIANT lock.

  3. By Anonymous Coward () on

    Hi Tony,

    What do you do at your job?
    Are you being sarcastic?

    Comments
    1. By tony () tony@libpcap.net on http://libpcap.net

      From 10pm till about 1am or 2am I clean airplanes (seats, bathrooms, where they fix the drinks and snacks).... I was being half-sarcastic, but it's actually an easy job, with a ton of benefits.. free soda, free snacks, free meals, and finders keepers on anything you find on the airplane (gameboys, money, CD's, etc..)

      Comments
      1. By Grant () on

        Is that your only job?
        Are you a programmer?

        Comments
        1. By tony () tony@libpcap.net on http://libpcap.net

          I'm doing consulting at a local car dealership part time as well... I just finished setting up an OpenBSD box *g* which will be running their web, mail, etc. I'm also working on the redesign of their website, but that's not making too much progress.. too many interested parties that what X, Y and Z on the site (one guy asked for sounds, I almost choked him out on the spot).

          The airplane cleaning job is much more fun. The kicker: I make the same hourly rate at both jobs, $10/hr. Ha.

      2. By Anonymous Coward () on

        Damnit, I lost two valuable CD's on an airplane once and was pretty much ignored by the lost & found folks... I guess that's why. :(

        Comments
        1. By Anony Mouse Cow Erd () on

          Yeah, I lost a $180 pair of Oakleys they same
          way, the cleaning crew had just exited a
          plane that was otherwise parked overnight.

          Luckily American Express' Platinum card covers
          all losses, even the accidental kind, although
          that one ranks more as theft to me.

          Comments
          1. By Anonymous Coward () on

            I agree but these people make $10 an hour...

            Comments
            1. By Anonymous Coward () on

              That's American, I make 8.95 Canadian an hour and you don't see me stealing people's stuff.

              Comments
              1. By tony () tony@libpcap.net on http://libpcap.net

                I don't consider it stealing. If I find a $20 on the ground (which I have before), I'm not going to leave it there. I didn't take the $20 from anyone, some careless person left it behind. When we find stuff on the airplane, it's because careless people left it there, not because we were rooting around in their luggage.

                Comments
                1. By MotleyFool () motleyfool@dieselrepower.org on mailto:motleyfool@dieselrepower.org

                  Most organizations I know of have lost & found organizations.

                  Careless person? Next time your stranded 'cause your car broke down I hope nobody stops to help you out, 'cause you were too careless to keep the vehicle in operating condition.

                  side out

                  Comments
                  1. By tedu () on

                    a lost+found for a 20 dollar bill? heh. "hi, i lost some money on my flight. yes, that's correct, mine was the green money. with the portrait of jackson on it."

                  2. By tony () tony@libpcap.net on http://libpcap.net

                    I'd probably call your analogy one of neglect, not carelessness, but I understand what you meant.

                    Eitherway, finders keepers, loosers weepers. :)

                2. By Anonymous Coward () on

                  There's no lost and found?

  4. By Anonymous Coward () on

    How about mksnap_ffs?

    And where's tedu's wishlist? I tried all 3 addresses at amazon. (yes i donate to project. I also like to buy for developers personally).

    Comments
    1. By tedu () on

      snapshots are waiting. they're still under development, and not receommended for production use. until freebsd 5 sees real use, and snapshots actually get tested, it's best to wait.

      Comments
      1. By Chris () chris@unixfu.net on mailto:chris@unixfu.net

        having a testing framework would be handy too. snapshots seems like a hit or miss way to find problems, especially since it also depends on the people doing the "testing".

        unit testing for kernel and base src would be nice, as that is true testing. run it and see if it breaks is a kinda weak form of testing, and by it's very nature a less secure way of finding problems and bugs in software.

        sure, your next question is "write it then, big mouth". i barely have time to post this, much less hours to invest.

        just commenting :)

  5. By Anonymous Coward () on

    It'd be nice if you could grow an fs across multiple devices...

    Comments
    1. By tedu () on

      i've done it with ccd. just add a few more devices to the ccd, and growfs.

      Comments
      1. By Anonymous Coward () on

        Just make sure those devices are UPS'd and redundant disk arrays, and not individual disks.

        CCD is basically RAID0 without the pattern striping.

        Losing data is bad... mmmmk! :)

  6. By Anonymous Coward () on

    What tools are required to actually resize those particular filesystems that have been recommended above?

    Are there FAQ's, this is the first that i've heard that you can do this on *BSD.

    I wonder if people got confused and meant FreeBSD as opposed to OpenBSD?

Credits

Copyright © - Daniel Hartmeier. All rights reserved. Articles and comments are copyright their respective authors, submission implies license to publish on this web site. Contents of the archive prior to as well as images and HTML templates were copied from the fabulous original deadly.org with Jose's and Jim's kind permission. This journal runs as CGI with httpd(8) on OpenBSD, the source code is BSD licensed. undeadly \Un*dead"ly\, a. Not subject to death; immortal. [Obs.]