Friday, March 25, 2011

'yes,yes' we can ... on the usefull linux command ...

Recently I started building my own LFS, I was pretty amused by the command 'yes'...

However, today I found a use for that command, when I had to install a binary firmware on multiple servers. The binary is not editable and  expects two times 'yes' to finish the process.
So, the solution is to run on all the computers the following command inside a loop :
'yes | sh binary_firmware.exe' - also, this is a simple example a of parallel programming and pipes.

This little trick saved me quite some typing and waiting in front of the computer !

No comments: