Originally Posted By: mlord
Here is a more fully commented version of the above:
Code:
modprobe usb-storage        ## Ensure the driver for the USB-stick is loaded
mkdir /tmp/usb              ## Create a directory for use as a mount-point
mount /dev/sda1 /tmp/usb    ## Mount/attach the USB-stick at /tmp/usb
mount mtd:mfg -t jffs2 /mfg ## Mount the manufacturing partition at /mfg
cp /mfg/mfg.dat /tmp/usb/   ## Copy mfg.dat to the USB-stick
umount /mfg                 ## Unmount/detach the manufacturing partition
umount /tmp/usb             ## Unmount/detach the USB-stick
sync                        ## Ensure data is written to the USB-stick before removal



Wow this is awesome! Thanks for the comments. That really helps understand what all this is supposed to do. I'm getting an error "Invalid argument' at the mount /dev/sda1 /tmp/usb

# modprobe usb-storage
# mkdir /tmp/usb
mkdir: can't create directory '/tmp/usb': File exists
# mount /dev/sda1 /tmp/usb
mount: mounting /dev/sda1 on /tmp/usb failed: Invalid argument
#
_________________________
If you want it to break, buy Sony!