jvkolyad8
Posts: 1
Joined: Wed Jun 05, 2019 2:06 am

How can I make my Pi Zero W boot as fast as possible?

Wed Jun 05, 2019 3:24 am

I'm planning on connecting my pi to a hard drive and having it run a program on boot that will copy all files from any other connected USB drive to the hard drive, then clear the USB drive. I'm making it run on battery power so I can use it whenever my GoPro's SD card storage gets used up. This way, all the footage from each card ends up in one place. Because it'll be running on battery power, it will have to boot every time I need to use it. What can I do to make the pi boot faster on raspbian stretch lite?

W. H. Heydt
Posts: 10586
Joined: Fri Mar 09, 2012 7:36 pm
Location: Vallejo, CA (US)

Re: How can I make my Pi Zero W boot as fast as possible?

Wed Jun 05, 2019 4:52 am

The run time limitations for your setup depend more on the HDD than it does on the Pi0W. I'd suggest that you switch to using an SSD for your mass storage and SSDs use far less power than HDDs. That way you could actually leave the Pi up and operating if you use a reasonable sized battery.

User avatar
HawaiianPi
Posts: 4454
Joined: Mon Apr 08, 2013 4:53 am
Location: Aloha, Oregon USA

Re: How can I make my Pi Zero W boot as fast as possible?

Wed Jun 05, 2019 8:55 am

And how are you planning to connect a hard drive and "any other connected USB drive" to a Pi Zero that has only a single USB port?
My mind is like a browser. 27 tabs are open, 9 aren't responding,
lots of pop-ups...and where is that annoying music coming from?

hippy
Posts: 5588
Joined: Fri Sep 09, 2011 10:34 pm
Location: UK

Re: How can I make my Pi Zero W boot as fast as possible?

Wed Jun 05, 2019 9:14 am

HawaiianPi wrote:
Wed Jun 05, 2019 8:55 am
And how are you planning to connect a hard drive and "any other connected USB drive" to a Pi Zero that has only a single USB port?
As the 'hard drive' and 'USB hard drives' are likely all USB device; a simple OTG cable and USB Hub should do the job.

As this is just a boot, detect devices, then copy program, I would be tempted to drop Raspbian and use something which merely does the task required. Ultibo is probably suited to this and should give near instant boot-up.

User avatar
HawaiianPi
Posts: 4454
Joined: Mon Apr 08, 2013 4:53 am
Location: Aloha, Oregon USA

Re: How can I make my Pi Zero W boot as fast as possible?

Wed Jun 05, 2019 9:59 am

hippy wrote:
Wed Jun 05, 2019 9:14 am
As the 'hard drive' and 'USB hard drives' are likely all USB device; a simple OTG cable and USB Hub should do the job.
That adds additional complexity and power requirements. My point being, the Pi Zero might not be the best choice for this task. Perhaps a B+?
My mind is like a browser. 27 tabs are open, 9 aren't responding,
lots of pop-ups...and where is that annoying music coming from?

fanoush
Posts: 460
Joined: Mon Feb 27, 2012 2:37 pm

Re: How can I make my Pi Zero W boot as fast as possible?

Thu Jun 06, 2019 1:24 pm

HawaiianPi wrote:
Wed Jun 05, 2019 9:59 am
That adds additional complexity and power requirements. ..... Perhaps a B+?
That adds additional complexity and power requirements. ;-)
Like Ethernet.
Zero with usb hub might still be cheaper and lower power than b+
Apart from generic hub there are hubs for Zero, one is http://www.uugear.com/product/zero4u/ or ther is http://referencedesigner.com/blog/get-h ... blue/6506/

EDIT: the Zerp4u has also cheaper variant which may even suit better to someone
http://www.uugear.com/product/zero4u-4p ... pogo-pins/
they also sell some power management boards that may be useful with battery for this project
Last edited by fanoush on Thu Jun 06, 2019 1:47 pm, edited 1 time in total.

fanoush
Posts: 460
Joined: Mon Feb 27, 2012 2:37 pm

Re: How can I make my Pi Zero W boot as fast as possible?

Thu Jun 06, 2019 1:35 pm

jvkolyad8 wrote:
Wed Jun 05, 2019 3:24 am
What can I do to make the pi boot faster on raspbian stretch lite?
You can use raspbian stretch lite card to use the software but you can start only your custom script without anything else running.
There is linux kernel parameter init=/path/to/your/executable so you can just run your code directly as a first thing at boot time (shell script, python code,..). So your code can scan usb devices, mount filesystems, copy what you want, unmount and shutdown. It may be a bit tricky since nothing is set up for you at boot time, but there is really not that much needed for doing what you want.

Return to “General discussion”