Netgate Discussion Forum
    • Categories
    • Recent
    • Tags
    • Popular
    • Users
    • Search
    • Register
    • Login

    Using a hard-disk in a Watchguard Firebox X750e for cache/log storage

    Scheduled Pinned Locked Moved Hardware
    49 Posts 11 Posters 16.2k Views
    Loading More Posts
    • Oldest to Newest
    • Newest to Oldest
    • Most Votes
    Reply
    • Reply as topic
    Log in to reply
    This topic has been deleted. Only users with topic management privileges can see it.
    • N
      NozeDive
      last edited by

      Steve,

      I know this is a really old post, but I'm hoping you were subscribed to it, and that this post reaches you.

      I was hoping that you could go in to some more detail on the /etc/rc.embedded section of your post.

      I followed your steps, modifying the device names to match my own set-up (i.e. using /dev/ada1s1a instead of /dev/ad1s1a) except I missed this in a few places. The end result was a system that would not boot correctly, and a file system that could not be re-mounted as read/write, so I ended up having to nuke the CF card and starting over.

      That was totally my fault, but I'd like to try it again, which is why I'm hoping that you could go into a little more detail about what each section of the script in /etc/rc.embedded does.

      In any case, I may end up using a spare 8GB USB flash drive rather than this 250GB SATA spinning rust drive i'm trying to use since that seems like overkill, but I'd really like to get this set-up to work too for academic reasons.

      Again, I know this is an old topic, so if this does reach you, thanks for revisiting this post.

      »Tony

      (BTW I'm using a WatchGuard Firebox XTM 515)

      Best Regards,

      Tony Scardina

      1 Reply Last reply Reply Quote 0
      • S
        Steve Evans
        last edited by

        @NozeDive:

        Steve,

        I know this is a really old post, but I'm hoping you were subscribed to it, and that this post reaches you.

        I was hoping that you could go in to some more detail on the /etc/rc.embedded section of your post.

        I followed your steps, modifying the device names to match my own set-up (i.e. using /dev/ada1s1a instead of /dev/ad1s1a) except I missed this in a few places. The end result was a system that would not boot correctly, and a file system that could not be re-mounted as read/write, so I ended up having to nuke the CF card and starting over.

        That was totally my fault, but I'd like to try it again, which is why I'm hoping that you could go into a little more detail about what each section of the script in /etc/rc.embedded does.

        In any case, I may end up using a spare 8GB USB flash drive rather than this 250GB SATA spinning rust drive i'm trying to use since that seems like overkill, but I'd really like to get this set-up to work too for academic reasons.

        Again, I know this is an old topic, so if this does reach you, thanks for revisiting this post.

        »Tony

        (BTW I'm using a WatchGuard Firebox XTM 515)

        Hi Tony,

        The code section of interest is below:

        # If a hard disk is installed then mount that on /var
        # otherwise use a ramdisk
        harddisk="/dev/ad1s1a"
        if [ -c $harddisk ]
        then
        
        

        This checks that /dev/ad1s1a exists as a character device.

        
                echo -n "Using /var physical disk..."
                mount -o noatime $harddisk /var
        
        

        This mounts the partition (in this case partition 'a') on /var.

        
                # Ensure /var/run is removed on boot before daemons are started
                # It should arguably be a tmpfs, but this works fine
                rm -r /var/run
        
        

        Remove the /var/run directory as nanobsd expects this to not persist across reboots, and whilst that would be true for a RAM disk, the rotating rust remembers.

        
                # sshd won't start if /var/empty exists on boot
                rm -r /var/empty
        
        

        Similarly remove /var/empty.

        
        else
        
        

        The following is the original code which creates a RAM disk for /var..

                echo -n "Using /var memory disk..."
                mdmfs -S -M -s ${varsize} md /var
        
                # Create some needed directories
                /bin/mkdir -p /var/db
        
                # Ensure vi's recover directory is present
                /bin/mkdir -p /var/tmp/vi.recover/
        fi
        

        Steve

        1 Reply Last reply Reply Quote 0
        • N
          NozeDive
          last edited by

          :)

          Steve!

          Thank you very much for taking the time to reply! I'm not sure how I missed your reply (I must have my email settings wrong) but I didn't  see it until just now, and I wanted to make sure I thanked you for replying!

          I did end up going with the 8GB thumb drive, FYI, but I used basically this same method to get it to work, and it's working well.

          Thanks again!

          –Tony

          Best Regards,

          Tony Scardina

          1 Reply Last reply Reply Quote 0
          • L
            Love.IT.Again
            last edited by

            I just installed a 120GB IDE HDD (Samsung) in my X1250e.  It is currently running fine without the SD card.  My problem now is how to fit the HDD inside?  I can't find any tiny rails to use.  Any suggestions and tips will be much appreciated.  I am also planning to upgrade the memory which is currently 256MB.  What's the maximum memory capacity can I install?  Thanks a lot.

            1 Reply Last reply Reply Quote 0
            • ?
              Guest
              last edited by

              @Love.IT.Again

              I just installed a 120GB IDE HDD (Samsung) in my X1250e.

              If you want to use Squid as a caching proxy I suggest you to go with a IDE SSD drive that is
              speeding up much and many things. Something like a "OWC Mercury Legacy Pro 120 GB SSD"
              You will need an adapter from 3,5" to 2,5" for this, in the original version of the X1250e such
              an adapter was selld together with this box. So you might be able with ease and for cheap one
              of them over the Internet. (See the linked tutorial PDF document at the end of this post)

              My problem now is how to fit the HDD inside?  I can't find any tiny rails to use.  Any suggestions and tips will be much appreciated.

              I was only found one Blog where they talk about, if not really helpful please open or download
              the Watchguard pfSense guide from the end of this post there is a caddy shown inside and
              how to mount him into the X1250e series box.

              I am also planning to upgrade the memory which is currently 256MB.
              What's the maximum memory capacity can I install?  Thanks a lot.

              DDR2 533MHz 2GB modul, greater single modules of this ram are not on the market
              able to get so I assume this might be than also the maximum in a single RAM module system.

              A last if VPN becomes a really urgent part of your pfSense you could install or insert a Soekris vpn1411
              miniPCI card that is supported under pfSense. Link

              Watchguard pfSense guide

              1 Reply Last reply Reply Quote 0
              • L
                Love.IT.Again
                last edited by

                @BlueKobold

                Thanks a lot for the very informative reply.  I really appreciate it a lot.

                For the meantime, I will stick at my present hardware configuration while I try to learn PFSense.
                Upgrading to SSD is part of my plan, but with the high price of IDE SSD, makes me think of buying a faster machine instead.

                At the moment, the IDE HDD is mounted with a home made rail from a SPAM can.  Making a better/nicer hdd caddy will be my next project.

                Thanks again.

                1 Reply Last reply Reply Quote 0
                • _
                  _ToXIc_
                  last edited by

                  hi this is exactly what i'm looking for..

                  got all the steps but i got lost at the following.. not sure exactly what to do

                  @Steve:

                  Then modify /etc/rc.embedded to conditionally replace the mounting of the /var ramdisk thus:

                  echo -n "Setting up memory disks..."
                  mdmfs -S -M -s ${tmpsize} md /tmp
                  
                  # If a hard disk is installed then mount that on /var
                  # otherwise use a ramdisk
                  harddisk="/dev/ad1s1a"
                  if [ -c $harddisk ]
                  then
                          echo -n "Using /var physical disk..."
                          mount $harddisk /var
                  
                          # Ensure /var/run is removed on boot before daemons are started
                          # It should arguably be a tmpfs, but this works fine
                          rm -r /var/run
                  
                          # sshd won't start if /var/empty exists on boot
                          rm -r /var/empty
                  else
                          echo -n "Using /var memory disk..."
                          mdmfs -S -M -s ${varsize} md /var
                  
                          # Create some needed directories
                          /bin/mkdir -p /var/db
                  
                          # Ensure vi's recover directory is present
                          /bin/mkdir -p /var/tmp/vi.recover/
                  fi
                  
                  echo " done."
                  

                  Steve

                  1 Reply Last reply Reply Quote 0
                  • _
                    _ToXIc_
                    last edited by

                    do i just copy that script after whats already in the file? below is what i currently have

                    #!/bin/sh
                    #
                    # rc.embedded - embedded system specific startup information
                    # For pfSense
                    
                    # Size of /tmp
                    USE_MFS_TMP_SIZE=`/usr/bin/grep use_mfs_tmp_size /cf/conf/config.xml | /usr/bin/cut -f2 -d'>' | /usr/bin/cut -f1 -d'<'`
                    if [ ! -z ${USE_MFS_TMP_SIZE} ] && [ ${USE_MFS_TMP_SIZE} -gt 0 ]; then
                    	tmpsize="${USE_MFS_TMP_SIZE}m"
                    else
                    	tmpsize="40m"
                    fi
                    
                    # Size of /var
                    USE_MFS_VAR_SIZE=`/usr/bin/grep use_mfs_var_size /cf/conf/config.xml | /usr/bin/cut -f2 -d'>' | /usr/bin/cut -f1 -d'<'`
                    if [ ! -z ${USE_MFS_VAR_SIZE} ] && [ ${USE_MFS_VAR_SIZE} -gt 0 ]; then
                    	varsize="${USE_MFS_VAR_SIZE}m"
                    else
                    	varsize="60m"
                    fi
                    
                    # Run some initialization routines
                    [ -f /etc/rc.d/uzip ] && /etc/rc.d/uzip start
                    
                    echo -n "Setting up memory disks..."
                    mdmfs -S -M -s ${tmpsize} md /tmp
                    mdmfs -S -M -s ${varsize} md /var
                    
                    # Create some needed directories
                    /bin/mkdir -p /var/db /var/spool/lock
                    /usr/sbin/chown uucp:dialer /var/spool/lock
                    
                    # Ensure vi's recover directory is present
                    /bin/mkdir -p /var/tmp/vi.recover/
                    echo " done."
                    
                    

                    Capture.JPG
                    Capture.JPG_thumb

                    1 Reply Last reply Reply Quote 0
                    • _
                      _ToXIc_
                      last edited by

                      bump

                      1 Reply Last reply Reply Quote 0
                      • First post
                        Last post
                      Copyright 2025 Rubicon Communications LLC (Netgate). All rights reserved.