Discussion:
bash scripting request
Barry R Cisna
2013-02-09 22:13:45 UTC
Permalink
Hello All,

Can someone here that is into bash scripts give me some insight on how
to accomplish the following?
Our school is in talks of possibly at least partially going to Chromium
os for the next school year. I have built a few 32-bit and 64-bit dev
images and have done several hours of testing at this point.
When using the dd if=myimage of=/dev/sd# bs=4MB the images are taking
almost 15 mins to build on to each usb stick.

Can someone post here,,possibly how to run a shell script that would
contiguously write dd to say all of the inserted usb sticks,in each of
the 8 usb ports of my build bot host machine,with omitting of
course,,the actual hard disk of the build bot machine?

Thank You,
Barry
SteveG
2013-02-09 22:44:01 UTC
Permalink
Try this, Multi-Copy Device - mdcp. http://mdcp.sourceforge.net/

SteveG
Post by Barry R Cisna
Hello All,
Can someone here that is into bash scripts give me some insight on how
to accomplish the following?
Our school is in talks of possibly at least partially going to Chromium
os for the next school year. I have built a few 32-bit and 64-bit dev
images and have done several hours of testing at this point.
When using the dd if=myimage of=/dev/sd# bs=4MB the images are taking
almost 15 mins to build on to each usb stick.
Can someone post here,,possibly how to run a shell script that would
contiguously write dd to say all of the inserted usb sticks,in each of
the 8 usb ports of my build bot host machine,with omitting of
course,,the actual hard disk of the build bot machine?
Thank You,
Barry
_______________________________________________
K12OSN mailing list
https://www.redhat.com/mailman/listinfo/k12osn
For more info see <http://www.k12os.org>
Barry R Cisna
2013-02-10 13:38:06 UTC
Permalink
SteveG,

Thank You for the link for mdcp package. This is exactly what i was
looking for. Never heard of this utility before.
Now I just have to remember when I am in a hurry, and when running it I
do not use /dev/sda(host machine hdd) as a target device to write
to.,,Wipeout!
Don't ask me why i am saying this,,,:)

Thank You,
Barry
Les Mikesell
2013-02-10 20:14:50 UTC
Permalink
Post by Barry R Cisna
Thank You for the link for mdcp package. This is exactly what i was
looking for. Never heard of this utility before.
Now I just have to remember when I am in a hurry, and when running it I
do not use /dev/sda(host machine hdd) as a target device to write
to.,,Wipeout!
Don't ask me why i am saying this,,,:)
I haven't used it to image USB drives but I'd expect clonezilla-live
to be good at it. It knows enough about filesystems to only copy the
used blocks.
--
Les Mikesell
***@gmail.com
Sergio Chaves
2013-02-13 01:34:20 UTC
Permalink
Barry, I do not code much at all but it seems rather simple.
First, make sure you know the name the devices when mounted.
Then you check for it with an if statement: if device is mounted , do
dd..... fi.

This link can point you in the right direction:
http://superuser.com/questions/193437/how-do-i-write-a-bash-script-to-detect-a-mounted-usb-drive
Post by Barry R Cisna
Hello All,
Can someone here that is into bash scripts give me some insight on how
to accomplish the following?
Our school is in talks of possibly at least partially going to Chromium
os for the next school year. I have built a few 32-bit and 64-bit dev
images and have done several hours of testing at this point.
When using the dd if=myimage of=/dev/sd# bs=4MB the images are taking
almost 15 mins to build on to each usb stick.
Can someone post here,,possibly how to run a shell script that would
contiguously write dd to say all of the inserted usb sticks,in each of
the 8 usb ports of my build bot host machine,with omitting of
course,,the actual hard disk of the build bot machine?
Thank You,
Barry
_______________________________________________
K12OSN mailing list
https://www.redhat.com/mailman/listinfo/k12osn
For more info see <http://www.k12os.org>
Loading...