Translate

Image of Android Wireless Application Development
Image of Modern Operating Systems (3rd Edition)
Image of Beginning Google Maps API 3
Image of XSLT 2.0 and XPath 2.0 Programmer's Reference (Programmer to Programmer)

Write all 1s to file using dd

It is easy to create a file consisting of all zeros in Linux using dd and the /dev/zero device. $ dd if=/dev/zero count=100 bs=1 > outfile So how do you create a file consisting of all binary ones? There is no device to create binary ones so you have to do something like the following: $ dd if=/dev/zero count=100 bs=1 | tr “00” “377” > outfile You can use xxd to see the contents of the resultant file: $ xxd -b outfile 0000000: 11111111 11111111 11111111 11111111 11111111 11111111 …… 0000006: 11111111 11111111 11111111 11111111 11111111 11111111 …… 000000c: 11111111