Netgate SG-1000 microFirewall

Author Topic: How to switch off hard disk after boot  (Read 237 times)

0 Members and 1 Guest are viewing this topic.

Offline Ulysses_

  • Jr. Member
  • **
  • Posts: 50
  • Karma: +0/-0
    • View Profile
How to switch off hard disk after boot
« on: January 27, 2018, 03:55:04 am »
Most of the time the firewall is idle. Could save some electricity by switching off hard disk.

1. Can this be done temporarily when idle?

2. Can this be done permanently as in some linux distros that load the entire filing system to ram if you boot with "toram" boot code?

3. If not, where can I find the best forum for freebsd to have this considered as a feature?

Offline jimp

  • Administrator
  • Hero Member
  • *****
  • Posts: 21571
  • Karma: +1471/-26
    • View Profile
Re: How to switch off hard disk after boot
« Reply #1 on: January 29, 2018, 02:56:34 pm »
We specifically disable drive power management because it has a bad habit of trashing drive heads on FreeBSD due to constant park/unpark load cycles.

If you're worried about power, get an SSD.
Need help fast? Commercial Support!

Co-Author of pfSense: The Definitive Guide. - Check the Doc Wiki for FAQs.

Do not PM for help!

Offline Ulysses_

  • Jr. Member
  • **
  • Posts: 50
  • Karma: +0/-0
    • View Profile
Re: How to switch off hard disk after boot
« Reply #2 on: January 29, 2018, 03:14:27 pm »
Alright, is there something I can do to at least not use the hard drive at all after boot, just like the "toram" boot code in some linuxes? Does the embedded version do that?

Offline jimp

  • Administrator
  • Hero Member
  • *****
  • Posts: 21571
  • Karma: +1471/-26
    • View Profile
Re: How to switch off hard disk after boot
« Reply #3 on: January 29, 2018, 03:15:34 pm »
You can enable RAM disks for /tmp and /var but you can't ever disable the drive entirely.
Need help fast? Commercial Support!

Co-Author of pfSense: The Definitive Guide. - Check the Doc Wiki for FAQs.

Do not PM for help!

Offline Ulysses_

  • Jr. Member
  • **
  • Posts: 50
  • Karma: +0/-0
    • View Profile
Re: How to switch off hard disk after boot
« Reply #4 on: January 29, 2018, 03:18:24 pm »
There's something in my CMOS settings that suspends the hard disk after a given time if enabled. How does the embedded version of pfsense avoid writing to an SSD drive?

Offline jimp

  • Administrator
  • Hero Member
  • *****
  • Posts: 21571
  • Karma: +1471/-26
    • View Profile
Re: How to switch off hard disk after boot
« Reply #5 on: January 29, 2018, 03:21:58 pm »
There is no embedded version as of 2.4.

But it essentially did what the option to put /tmp and /var in RAM did. Anything volatile goes in a RAM disk (logs, config files, status files, etc).

With modern high-quality hardware it really doesn't matter. Nothing to worry about, not worth the effort.
Need help fast? Commercial Support!

Co-Author of pfSense: The Definitive Guide. - Check the Doc Wiki for FAQs.

Do not PM for help!

Offline Ulysses_

  • Jr. Member
  • **
  • Posts: 50
  • Karma: +0/-0
    • View Profile
Re: How to switch off hard disk after boot
« Reply #6 on: January 29, 2018, 03:28:41 pm »
Any idea why the live CD is not available any more?

Offline jimp

  • Administrator
  • Hero Member
  • *****
  • Posts: 21571
  • Karma: +1471/-26
    • View Profile
Re: How to switch off hard disk after boot
« Reply #7 on: January 29, 2018, 03:37:54 pm »
LiveCD was more trouble than it was worth. Seriously, just do a full install to a real drive (SSD or HDD) and let it go. There is nothing to be gained from all that fiddling on modern hardware.

The LiveCD, NanoBSD, and other such things were made obsolete by the advancement of technology. If they still had any value, they wouldn't have been removed.
Need help fast? Commercial Support!

Co-Author of pfSense: The Definitive Guide. - Check the Doc Wiki for FAQs.

Do not PM for help!

Offline SammyWoo

  • Jr. Member
  • **
  • Posts: 40
  • Karma: +0/-0
    • View Profile
Re: How to switch off hard disk after boot
« Reply #8 on: February 11, 2018, 06:15:49 pm »
I too am cheap on electricity, hate noise and heat but I have come to realize, with empirical data, than my past obsession with turning things off is been overtaken by very efficient electronics of today's. I use SSD everywhere except my main storage NAS of course, and fitted with NAS-rated mechanical drives which is designed to turn 24x7, taking less than 10w per 4TB drive.  I tried at first to sleep these drives when idle but then parts of my system would balk and go into hissy-fit having to wait for asleep drives to wake up. It seems developers used to design for slow hard drives and built in wait loops but no longer, software expect storage to be ready to work the instant is called for and error out when not.  I think if you insist you will bump into difficulties at every turn, and well ur on your own.

Offline Ulysses_

  • Jr. Member
  • **
  • Posts: 50
  • Karma: +0/-0
    • View Profile
Re: How to switch off hard disk after boot
« Reply #9 on: February 12, 2018, 07:23:36 am »
What NAS hardware would you recommend? Or perhaps NAS+pfsense? Or even NAS+pfsense+ADSL router?